Subject: [alternative-merged] net-netfilter-ipset-ip_set_hash_netnetc-fix-build-with-older-gcc.patch removed from -mm tree To: akpm@xxxxxxxxxxxxxxxxxxxx,kadlec@xxxxxxxxxxxxxxxxx,oliver@xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx,mm-commits@xxxxxxxxxxxxxxx From: akpm@xxxxxxxxxxxxxxxxxxxx Date: Wed, 06 Nov 2013 12:27:43 -0800 The patch titled Subject: net/netfilter/ipset/ip_set_hash_netnet.c: fix build with older gcc has been removed from the -mm tree. Its filename was net-netfilter-ipset-ip_set_hash_netnetc-fix-build-with-older-gcc.patch This patch was dropped because an alternative patch was merged ------------------------------------------------------ From: Andrew Morton <akpm@xxxxxxxxxxxxxxxxxxxx> Subject: net/netfilter/ipset/ip_set_hash_netnet.c: fix build with older gcc net/netfilter/ipset/ip_set_hash_netnet.c: In function 'hash_netnet4_kadt': net/netfilter/ipset/ip_set_hash_netnet.c:141: error: unknown field 'cidr' specified in initializer net/netfilter/ipset/ip_set_hash_netnet.c:141: warning: missing braces around initializer net/netfilter/ipset/ip_set_hash_netnet.c:141: warning: (near initialization for 'e.<anonymous>') etc. gcc-4.4.4 doesn't like that anonymous union initializer and I couldnt' find a way of tricking it into doing the right thing, so open-code it. Cc: Oliver Smith <oliver@xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx> Cc: Jozsef Kadlecsik <kadlec@xxxxxxxxxxxxxxxxx> Signed-off-by: Andrew Morton <akpm@xxxxxxxxxxxxxxxxxxxx> --- net/netfilter/ipset/ip_set_hash_netnet.c | 28 ++++++++++++--------- 1 file changed, 16 insertions(+), 12 deletions(-) diff -puN net/netfilter/ipset/ip_set_hash_netnet.c~net-netfilter-ipset-ip_set_hash_netnetc-fix-build-with-older-gcc net/netfilter/ipset/ip_set_hash_netnet.c --- a/net/netfilter/ipset/ip_set_hash_netnet.c~net-netfilter-ipset-ip_set_hash_netnetc-fix-build-with-older-gcc +++ a/net/netfilter/ipset/ip_set_hash_netnet.c @@ -137,12 +137,12 @@ hash_netnet4_kadt(struct ip_set *set, co { const struct hash_netnet *h = set->data; ipset_adtfn adtfn = set->variant->adt[adt]; - struct hash_netnet4_elem e = { - .cidr[0] = h->nets[0].cidr[0] ? h->nets[0].cidr[0] : HOST_MASK, - .cidr[1] = h->nets[0].cidr[1] ? h->nets[0].cidr[1] : HOST_MASK, - }; + struct hash_netnet4_elem e = { }; struct ip_set_ext ext = IP_SET_INIT_KEXT(skb, opt, set); + e.cidr[0] = h->nets[0].cidr[0] ? h->nets[0].cidr[0] : HOST_MASK; + e.cidr[1] = h->nets[0].cidr[1] ? h->nets[0].cidr[1] : HOST_MASK; + if (adt == IPSET_TEST) e.ccmp = (HOST_MASK << (sizeof(e.cidr[0]) * 8)) | HOST_MASK; @@ -160,13 +160,15 @@ hash_netnet4_uadt(struct ip_set *set, st { const struct hash_netnet *h = set->data; ipset_adtfn adtfn = set->variant->adt[adt]; - struct hash_netnet4_elem e = { .cidr[0] = HOST_MASK, - .cidr[1] = HOST_MASK }; struct ip_set_ext ext = IP_SET_INIT_UEXT(set); u32 ip = 0, ip_to = 0, last; u32 ip2 = 0, ip2_from = 0, ip2_to = 0, last2; u8 cidr, cidr2; int ret; + struct hash_netnet4_elem e = { }; + + e.cidr[0] = HOST_MASK; + e.cidr[1] = HOST_MASK; if (unlikely(!tb[IPSET_ATTR_IP] || !tb[IPSET_ATTR_IP2] || !ip_set_optattr_netorder(tb, IPSET_ATTR_TIMEOUT) || @@ -364,12 +366,12 @@ hash_netnet6_kadt(struct ip_set *set, co { const struct hash_netnet *h = set->data; ipset_adtfn adtfn = set->variant->adt[adt]; - struct hash_netnet6_elem e = { - .cidr[0] = h->nets[0].cidr[0] ? h->nets[0].cidr[0] : HOST_MASK, - .cidr[1] = h->nets[0].cidr[1] ? h->nets[0].cidr[1] : HOST_MASK - }; + struct hash_netnet6_elem e = { }; struct ip_set_ext ext = IP_SET_INIT_KEXT(skb, opt, set); + e.cidr[0] = h->nets[0].cidr[0] ? h->nets[0].cidr[0] : HOST_MASK; + e.cidr[1] = h->nets[0].cidr[1] ? h->nets[0].cidr[1] : HOST_MASK; + if (adt == IPSET_TEST) e.ccmp = (HOST_MASK << (sizeof(u8)*8)) | HOST_MASK; @@ -386,11 +388,13 @@ hash_netnet6_uadt(struct ip_set *set, st enum ipset_adt adt, u32 *lineno, u32 flags, bool retried) { ipset_adtfn adtfn = set->variant->adt[adt]; - struct hash_netnet6_elem e = { .cidr[0] = HOST_MASK, - .cidr[1] = HOST_MASK }; + struct hash_netnet6_elem e = { }; struct ip_set_ext ext = IP_SET_INIT_UEXT(set); int ret; + e.cidr[0] = HOST_MASK; + e.cidr[1] = HOST_MASK; + if (unlikely(!tb[IPSET_ATTR_IP] || !tb[IPSET_ATTR_IP2] || !ip_set_optattr_netorder(tb, IPSET_ATTR_TIMEOUT) || !ip_set_optattr_netorder(tb, IPSET_ATTR_CADT_FLAGS) || _ Patches currently in -mm which might be from akpm@xxxxxxxxxxxxxxxxxxxx are linux-next.patch arch-alpha-kernel-systblss-remove-debug-check.patch i-need-old-gcc.patch kernel-time-tick-commonc-document-tick_do_timer_cpu.patch mm-readaheadc-do_readhead-dont-check-for-readpage.patch drivers-block-ccissc-cciss_init_one-use-proper-errnos.patch posix_acl-uninlining.patch mm.patch mm-thp-khugepaged-add-policy-for-finding-target-node-fix.patch mm-factor-commit-limit-calculation-fix.patch kernel-printk-printkc-convert-to-pr_foo.patch maintainers-remove-richard-purdie-as-backlight-maintainer-fix.patch checkpatch-extend-camelcase-types-and-ignore-existing-camelcase-uses-in-a-patch.patch checkpatch-add-test-for-defines-of-arch_has_foo.patch epoll-do-not-take-global-epmutex-for-simple-topologies-fix.patch binfmt_elfc-use-get_random_int-to-fix-entropy-depleting.patch init-do_mounts_rdc-fix-null-pointer-dereference-while-loading-initramfs-fix.patch drivers-rtc-rtc-as3722-add-rtc-driver-checkpatch-fixes.patch fs-hfs-btreeh-remove-duplicate-defines-fix.patch gcov-add-support-for-gcc-47-gcov-format-fix.patch gcov-add-support-for-gcc-47-gcov-format-fix-fix.patch gcov-add-support-for-gcc-47-gcov-format-checkpatch-fixes.patch kernel-modulec-use-pr_foo.patch kernel-gcov-fsc-use-pr_warn.patch ipc-msg-fix-message-length-check-for-negative-values-fix.patch net-netfilter-ipset-ip_set_hash_netportnetc-fix-build-with-older-gccs.patch mm-drop-actor-argument-of-do_generic_file_read-fix.patch mm-hugetlb-convert-hugetlbfs-to-use-split-pmd-lock-checkpatch-fixes.patch x86-mm-enable-split-page-table-lock-for-pmd-level-checkpatch-fixes.patch mm-dynamically-allocate-page-ptl-if-it-cannot-be-embedded-to-struct-page-fix-fix.patch tree-wide-use-reinit_completion-instead-of-init_completion-fix.patch kernel-provide-a-__smp_call_function_single-stub-for-config_smp-fix.patch llists-move-llist_reverse_order-from-raid5-to-llistc-fix.patch debugging-keep-track-of-page-owners-fix-2-fix.patch debugging-keep-track-of-page-owners-fix-2-fix-fix-fix.patch journal_add_journal_head-debug.patch kernel-forkc-export-kernel_thread-to-modules.patch mutex-subsystem-synchro-test-module.patch slab-leaks3-default-y.patch put_bh-debug.patch -- To unsubscribe from this list: send the line "unsubscribe mm-commits" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html