diff options
author | Linus Torvalds <torvalds@linux-foundation.org> | 2008-10-20 12:06:35 -0400 |
---|---|---|
committer | Linus Torvalds <torvalds@linux-foundation.org> | 2008-10-20 12:06:35 -0400 |
commit | 5fdf11283e26719543eb5f9b68707e1af77eb875 (patch) | |
tree | 2d9a3fe6909e013c0bd2f5fc4c5bf5996eff7b19 | |
parent | 2be508d847392e431759e370d21cea9412848758 (diff) | |
parent | fdc9314cbe027281b5440780692105d49b53cf2c (diff) |
Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/net-2.6
* git://git.kernel.org/pub/scm/linux/kernel/git/davem/net-2.6:
netfilter: replace old NF_ARP calls with NFPROTO_ARP
netfilter: fix compilation error with NAT=n
netfilter: xt_recent: use proc_create_data()
netfilter: snmp nat leaks memory in case of failure
netfilter: xt_iprange: fix range inversion match
netfilter: netns: use NFPROTO_NUMPROTO instead of NUMPROTO for tables array
netfilter: ctnetlink: remove obsolete NAT dependency from Kconfig
pkt_sched: sch_generic: Fix oops in sch_teql
dccp: Port redirection support for DCCP
tcp: Fix IPv6 fallout from 'Port redirection support for TCP'
netdev: change name dropping error codes
ipvs: Update CONFIG_IP_VS_IPV6 description and help text
-rw-r--r-- | include/net/netns/x_tables.h | 4 | ||||
-rw-r--r-- | net/bridge/br_netfilter.c | 2 | ||||
-rw-r--r-- | net/core/dev.c | 6 | ||||
-rw-r--r-- | net/dccp/ipv6.c | 4 | ||||
-rw-r--r-- | net/dccp/minisocks.c | 1 | ||||
-rw-r--r-- | net/dccp/output.c | 2 | ||||
-rw-r--r-- | net/ipv4/arp.c | 4 | ||||
-rw-r--r-- | net/ipv4/netfilter/nf_nat_snmp_basic.c | 1 | ||||
-rw-r--r-- | net/ipv6/syncookies.c | 1 | ||||
-rw-r--r-- | net/ipv6/tcp_ipv6.c | 6 | ||||
-rw-r--r-- | net/netfilter/Kconfig | 1 | ||||
-rw-r--r-- | net/netfilter/ipvs/Kconfig | 4 | ||||
-rw-r--r-- | net/netfilter/nf_conntrack_netlink.c | 2 | ||||
-rw-r--r-- | net/netfilter/xt_NFQUEUE.c | 2 | ||||
-rw-r--r-- | net/netfilter/xt_iprange.c | 8 | ||||
-rw-r--r-- | net/netfilter/xt_recent.c | 10 | ||||
-rw-r--r-- | net/sched/sch_generic.c | 2 |
17 files changed, 33 insertions, 27 deletions
diff --git a/include/net/netns/x_tables.h b/include/net/netns/x_tables.h index 0cb63ed2c1fc..b8093971ccb4 100644 --- a/include/net/netns/x_tables.h +++ b/include/net/netns/x_tables.h | |||
@@ -2,9 +2,9 @@ | |||
2 | #define __NETNS_X_TABLES_H | 2 | #define __NETNS_X_TABLES_H |
3 | 3 | ||
4 | #include <linux/list.h> | 4 | #include <linux/list.h> |
5 | #include <linux/net.h> | 5 | #include <linux/netfilter.h> |
6 | 6 | ||
7 | struct netns_xt { | 7 | struct netns_xt { |
8 | struct list_head tables[NPROTO]; | 8 | struct list_head tables[NFPROTO_NUMPROTO]; |
9 | }; | 9 | }; |
10 | #endif | 10 | #endif |
diff --git a/net/bridge/br_netfilter.c b/net/bridge/br_netfilter.c index a4abed5b4c44..fa5cda4e552a 100644 --- a/net/bridge/br_netfilter.c +++ b/net/bridge/br_netfilter.c | |||
@@ -719,7 +719,7 @@ static unsigned int br_nf_forward_arp(unsigned int hook, struct sk_buff *skb, | |||
719 | return NF_ACCEPT; | 719 | return NF_ACCEPT; |
720 | } | 720 | } |
721 | *d = (struct net_device *)in; | 721 | *d = (struct net_device *)in; |
722 | NF_HOOK(NF_ARP, NF_ARP_FORWARD, skb, (struct net_device *)in, | 722 | NF_HOOK(NFPROTO_ARP, NF_ARP_FORWARD, skb, (struct net_device *)in, |
723 | (struct net_device *)out, br_nf_forward_finish); | 723 | (struct net_device *)out, br_nf_forward_finish); |
724 | 724 | ||
725 | return NF_STOLEN; | 725 | return NF_STOLEN; |
diff --git a/net/core/dev.c b/net/core/dev.c index 868ec0ba8b77..b8a4fd0806af 100644 --- a/net/core/dev.c +++ b/net/core/dev.c | |||
@@ -924,10 +924,10 @@ int dev_change_name(struct net_device *dev, const char *newname) | |||
924 | strlcpy(dev->name, newname, IFNAMSIZ); | 924 | strlcpy(dev->name, newname, IFNAMSIZ); |
925 | 925 | ||
926 | rollback: | 926 | rollback: |
927 | err = device_rename(&dev->dev, dev->name); | 927 | ret = device_rename(&dev->dev, dev->name); |
928 | if (err) { | 928 | if (ret) { |
929 | memcpy(dev->name, oldname, IFNAMSIZ); | 929 | memcpy(dev->name, oldname, IFNAMSIZ); |
930 | return err; | 930 | return ret; |
931 | } | 931 | } |
932 | 932 | ||
933 | write_lock_bh(&dev_base_lock); | 933 | write_lock_bh(&dev_base_lock); |
diff --git a/net/dccp/ipv6.c b/net/dccp/ipv6.c index 11062780bb02..d4ce1224e008 100644 --- a/net/dccp/ipv6.c +++ b/net/dccp/ipv6.c | |||
@@ -259,7 +259,7 @@ static int dccp_v6_send_response(struct sock *sk, struct request_sock *req) | |||
259 | fl.fl6_flowlabel = 0; | 259 | fl.fl6_flowlabel = 0; |
260 | fl.oif = ireq6->iif; | 260 | fl.oif = ireq6->iif; |
261 | fl.fl_ip_dport = inet_rsk(req)->rmt_port; | 261 | fl.fl_ip_dport = inet_rsk(req)->rmt_port; |
262 | fl.fl_ip_sport = inet_sk(sk)->sport; | 262 | fl.fl_ip_sport = inet_rsk(req)->loc_port; |
263 | security_req_classify_flow(req, &fl); | 263 | security_req_classify_flow(req, &fl); |
264 | 264 | ||
265 | opt = np->opt; | 265 | opt = np->opt; |
@@ -558,7 +558,7 @@ static struct sock *dccp_v6_request_recv_sock(struct sock *sk, | |||
558 | ipv6_addr_copy(&fl.fl6_src, &ireq6->loc_addr); | 558 | ipv6_addr_copy(&fl.fl6_src, &ireq6->loc_addr); |
559 | fl.oif = sk->sk_bound_dev_if; | 559 | fl.oif = sk->sk_bound_dev_if; |
560 | fl.fl_ip_dport = inet_rsk(req)->rmt_port; | 560 | fl.fl_ip_dport = inet_rsk(req)->rmt_port; |
561 | fl.fl_ip_sport = inet_sk(sk)->sport; | 561 | fl.fl_ip_sport = inet_rsk(req)->loc_port; |
562 | security_sk_classify_flow(sk, &fl); | 562 | security_sk_classify_flow(sk, &fl); |
563 | 563 | ||
564 | if (ip6_dst_lookup(sk, &dst, &fl)) | 564 | if (ip6_dst_lookup(sk, &dst, &fl)) |
diff --git a/net/dccp/minisocks.c b/net/dccp/minisocks.c index b2804e2d1b8c..e6bf99e3e41a 100644 --- a/net/dccp/minisocks.c +++ b/net/dccp/minisocks.c | |||
@@ -309,6 +309,7 @@ void dccp_reqsk_init(struct request_sock *req, struct sk_buff *skb) | |||
309 | struct dccp_request_sock *dreq = dccp_rsk(req); | 309 | struct dccp_request_sock *dreq = dccp_rsk(req); |
310 | 310 | ||
311 | inet_rsk(req)->rmt_port = dccp_hdr(skb)->dccph_sport; | 311 | inet_rsk(req)->rmt_port = dccp_hdr(skb)->dccph_sport; |
312 | inet_rsk(req)->loc_port = dccp_hdr(skb)->dccph_dport; | ||
312 | inet_rsk(req)->acked = 0; | 313 | inet_rsk(req)->acked = 0; |
313 | req->rcv_wnd = sysctl_dccp_feat_sequence_window; | 314 | req->rcv_wnd = sysctl_dccp_feat_sequence_window; |
314 | dreq->dreq_timestamp_echo = 0; | 315 | dreq->dreq_timestamp_echo = 0; |
diff --git a/net/dccp/output.c b/net/dccp/output.c index d06945c7d3df..809d803d5006 100644 --- a/net/dccp/output.c +++ b/net/dccp/output.c | |||
@@ -347,7 +347,7 @@ struct sk_buff *dccp_make_response(struct sock *sk, struct dst_entry *dst, | |||
347 | /* Build and checksum header */ | 347 | /* Build and checksum header */ |
348 | dh = dccp_zeroed_hdr(skb, dccp_header_size); | 348 | dh = dccp_zeroed_hdr(skb, dccp_header_size); |
349 | 349 | ||
350 | dh->dccph_sport = inet_sk(sk)->sport; | 350 | dh->dccph_sport = inet_rsk(req)->loc_port; |
351 | dh->dccph_dport = inet_rsk(req)->rmt_port; | 351 | dh->dccph_dport = inet_rsk(req)->rmt_port; |
352 | dh->dccph_doff = (dccp_header_size + | 352 | dh->dccph_doff = (dccp_header_size + |
353 | DCCP_SKB_CB(skb)->dccpd_opt_len) / 4; | 353 | DCCP_SKB_CB(skb)->dccpd_opt_len) / 4; |
diff --git a/net/ipv4/arp.c b/net/ipv4/arp.c index b043eda60b04..1a9dd66511fc 100644 --- a/net/ipv4/arp.c +++ b/net/ipv4/arp.c | |||
@@ -663,7 +663,7 @@ out: | |||
663 | void arp_xmit(struct sk_buff *skb) | 663 | void arp_xmit(struct sk_buff *skb) |
664 | { | 664 | { |
665 | /* Send it off, maybe filter it using firewalling first. */ | 665 | /* Send it off, maybe filter it using firewalling first. */ |
666 | NF_HOOK(NF_ARP, NF_ARP_OUT, skb, NULL, skb->dev, dev_queue_xmit); | 666 | NF_HOOK(NFPROTO_ARP, NF_ARP_OUT, skb, NULL, skb->dev, dev_queue_xmit); |
667 | } | 667 | } |
668 | 668 | ||
669 | /* | 669 | /* |
@@ -928,7 +928,7 @@ static int arp_rcv(struct sk_buff *skb, struct net_device *dev, | |||
928 | 928 | ||
929 | memset(NEIGH_CB(skb), 0, sizeof(struct neighbour_cb)); | 929 | memset(NEIGH_CB(skb), 0, sizeof(struct neighbour_cb)); |
930 | 930 | ||
931 | return NF_HOOK(NF_ARP, NF_ARP_IN, skb, dev, NULL, arp_process); | 931 | return NF_HOOK(NFPROTO_ARP, NF_ARP_IN, skb, dev, NULL, arp_process); |
932 | 932 | ||
933 | freeskb: | 933 | freeskb: |
934 | kfree_skb(skb); | 934 | kfree_skb(skb); |
diff --git a/net/ipv4/netfilter/nf_nat_snmp_basic.c b/net/ipv4/netfilter/nf_nat_snmp_basic.c index ffeaffc3fffe..8303e4b406c0 100644 --- a/net/ipv4/netfilter/nf_nat_snmp_basic.c +++ b/net/ipv4/netfilter/nf_nat_snmp_basic.c | |||
@@ -742,6 +742,7 @@ static unsigned char snmp_object_decode(struct asn1_ctx *ctx, | |||
742 | *obj = kmalloc(sizeof(struct snmp_object) + len, | 742 | *obj = kmalloc(sizeof(struct snmp_object) + len, |
743 | GFP_ATOMIC); | 743 | GFP_ATOMIC); |
744 | if (*obj == NULL) { | 744 | if (*obj == NULL) { |
745 | kfree(p); | ||
745 | kfree(id); | 746 | kfree(id); |
746 | if (net_ratelimit()) | 747 | if (net_ratelimit()) |
747 | printk("OOM in bsalg (%d)\n", __LINE__); | 748 | printk("OOM in bsalg (%d)\n", __LINE__); |
diff --git a/net/ipv6/syncookies.c b/net/ipv6/syncookies.c index ec394cf5a19b..676c80b5b14b 100644 --- a/net/ipv6/syncookies.c +++ b/net/ipv6/syncookies.c | |||
@@ -204,6 +204,7 @@ struct sock *cookie_v6_check(struct sock *sk, struct sk_buff *skb) | |||
204 | 204 | ||
205 | req->mss = mss; | 205 | req->mss = mss; |
206 | ireq->rmt_port = th->source; | 206 | ireq->rmt_port = th->source; |
207 | ireq->loc_port = th->dest; | ||
207 | ipv6_addr_copy(&ireq6->rmt_addr, &ipv6_hdr(skb)->saddr); | 208 | ipv6_addr_copy(&ireq6->rmt_addr, &ipv6_hdr(skb)->saddr); |
208 | ipv6_addr_copy(&ireq6->loc_addr, &ipv6_hdr(skb)->daddr); | 209 | ipv6_addr_copy(&ireq6->loc_addr, &ipv6_hdr(skb)->daddr); |
209 | if (ipv6_opt_accepted(sk, skb) || | 210 | if (ipv6_opt_accepted(sk, skb) || |
diff --git a/net/ipv6/tcp_ipv6.c b/net/ipv6/tcp_ipv6.c index e5310c9b84dc..b6b356b7912a 100644 --- a/net/ipv6/tcp_ipv6.c +++ b/net/ipv6/tcp_ipv6.c | |||
@@ -476,7 +476,7 @@ static int tcp_v6_send_synack(struct sock *sk, struct request_sock *req) | |||
476 | fl.fl6_flowlabel = 0; | 476 | fl.fl6_flowlabel = 0; |
477 | fl.oif = treq->iif; | 477 | fl.oif = treq->iif; |
478 | fl.fl_ip_dport = inet_rsk(req)->rmt_port; | 478 | fl.fl_ip_dport = inet_rsk(req)->rmt_port; |
479 | fl.fl_ip_sport = inet_sk(sk)->sport; | 479 | fl.fl_ip_sport = inet_rsk(req)->loc_port; |
480 | security_req_classify_flow(req, &fl); | 480 | security_req_classify_flow(req, &fl); |
481 | 481 | ||
482 | opt = np->opt; | 482 | opt = np->opt; |
@@ -1309,7 +1309,7 @@ static struct sock * tcp_v6_syn_recv_sock(struct sock *sk, struct sk_buff *skb, | |||
1309 | ipv6_addr_copy(&fl.fl6_src, &treq->loc_addr); | 1309 | ipv6_addr_copy(&fl.fl6_src, &treq->loc_addr); |
1310 | fl.oif = sk->sk_bound_dev_if; | 1310 | fl.oif = sk->sk_bound_dev_if; |
1311 | fl.fl_ip_dport = inet_rsk(req)->rmt_port; | 1311 | fl.fl_ip_dport = inet_rsk(req)->rmt_port; |
1312 | fl.fl_ip_sport = inet_sk(sk)->sport; | 1312 | fl.fl_ip_sport = inet_rsk(req)->loc_port; |
1313 | security_req_classify_flow(req, &fl); | 1313 | security_req_classify_flow(req, &fl); |
1314 | 1314 | ||
1315 | if (ip6_dst_lookup(sk, &dst, &fl)) | 1315 | if (ip6_dst_lookup(sk, &dst, &fl)) |
@@ -1865,7 +1865,7 @@ static void get_openreq6(struct seq_file *seq, | |||
1865 | i, | 1865 | i, |
1866 | src->s6_addr32[0], src->s6_addr32[1], | 1866 | src->s6_addr32[0], src->s6_addr32[1], |
1867 | src->s6_addr32[2], src->s6_addr32[3], | 1867 | src->s6_addr32[2], src->s6_addr32[3], |
1868 | ntohs(inet_sk(sk)->sport), | 1868 | ntohs(inet_rsk(req)->loc_port), |
1869 | dest->s6_addr32[0], dest->s6_addr32[1], | 1869 | dest->s6_addr32[0], dest->s6_addr32[1], |
1870 | dest->s6_addr32[2], dest->s6_addr32[3], | 1870 | dest->s6_addr32[2], dest->s6_addr32[3], |
1871 | ntohs(inet_rsk(req)->rmt_port), | 1871 | ntohs(inet_rsk(req)->rmt_port), |
diff --git a/net/netfilter/Kconfig b/net/netfilter/Kconfig index 78892cf2b021..25dcef9f2194 100644 --- a/net/netfilter/Kconfig +++ b/net/netfilter/Kconfig | |||
@@ -271,7 +271,6 @@ config NF_CONNTRACK_TFTP | |||
271 | config NF_CT_NETLINK | 271 | config NF_CT_NETLINK |
272 | tristate 'Connection tracking netlink interface' | 272 | tristate 'Connection tracking netlink interface' |
273 | select NETFILTER_NETLINK | 273 | select NETFILTER_NETLINK |
274 | depends on NF_NAT=n || NF_NAT | ||
275 | default m if NETFILTER_ADVANCED=n | 274 | default m if NETFILTER_ADVANCED=n |
276 | help | 275 | help |
277 | This option enables support for a netlink-based userspace interface | 276 | This option enables support for a netlink-based userspace interface |
diff --git a/net/netfilter/ipvs/Kconfig b/net/netfilter/ipvs/Kconfig index 05048e403266..79a698052218 100644 --- a/net/netfilter/ipvs/Kconfig +++ b/net/netfilter/ipvs/Kconfig | |||
@@ -25,11 +25,13 @@ menuconfig IP_VS | |||
25 | if IP_VS | 25 | if IP_VS |
26 | 26 | ||
27 | config IP_VS_IPV6 | 27 | config IP_VS_IPV6 |
28 | bool "IPv6 support for IPVS (DANGEROUS)" | 28 | bool "IPv6 support for IPVS" |
29 | depends on EXPERIMENTAL && (IPV6 = y || IP_VS = IPV6) | 29 | depends on EXPERIMENTAL && (IPV6 = y || IP_VS = IPV6) |
30 | ---help--- | 30 | ---help--- |
31 | Add IPv6 support to IPVS. This is incomplete and might be dangerous. | 31 | Add IPv6 support to IPVS. This is incomplete and might be dangerous. |
32 | 32 | ||
33 | See http://www.mindbasket.com/ipvs for more information. | ||
34 | |||
33 | Say N if unsure. | 35 | Say N if unsure. |
34 | 36 | ||
35 | config IP_VS_DEBUG | 37 | config IP_VS_DEBUG |
diff --git a/net/netfilter/nf_conntrack_netlink.c b/net/netfilter/nf_conntrack_netlink.c index 2e4ad9671e19..a040d46f85d6 100644 --- a/net/netfilter/nf_conntrack_netlink.c +++ b/net/netfilter/nf_conntrack_netlink.c | |||
@@ -813,6 +813,7 @@ out: | |||
813 | return err; | 813 | return err; |
814 | } | 814 | } |
815 | 815 | ||
816 | #ifdef CONFIG_NF_NAT_NEEDED | ||
816 | static int | 817 | static int |
817 | ctnetlink_parse_nat_setup(struct nf_conn *ct, | 818 | ctnetlink_parse_nat_setup(struct nf_conn *ct, |
818 | enum nf_nat_manip_type manip, | 819 | enum nf_nat_manip_type manip, |
@@ -840,6 +841,7 @@ ctnetlink_parse_nat_setup(struct nf_conn *ct, | |||
840 | 841 | ||
841 | return parse_nat_setup(ct, manip, attr); | 842 | return parse_nat_setup(ct, manip, attr); |
842 | } | 843 | } |
844 | #endif | ||
843 | 845 | ||
844 | static int | 846 | static int |
845 | ctnetlink_change_status(struct nf_conn *ct, struct nlattr *cda[]) | 847 | ctnetlink_change_status(struct nf_conn *ct, struct nlattr *cda[]) |
diff --git a/net/netfilter/xt_NFQUEUE.c b/net/netfilter/xt_NFQUEUE.c index 2cc1fff49307..f9977b3311f7 100644 --- a/net/netfilter/xt_NFQUEUE.c +++ b/net/netfilter/xt_NFQUEUE.c | |||
@@ -48,7 +48,7 @@ static struct xt_target nfqueue_tg_reg[] __read_mostly = { | |||
48 | }, | 48 | }, |
49 | { | 49 | { |
50 | .name = "NFQUEUE", | 50 | .name = "NFQUEUE", |
51 | .family = NF_ARP, | 51 | .family = NFPROTO_ARP, |
52 | .target = nfqueue_tg, | 52 | .target = nfqueue_tg, |
53 | .targetsize = sizeof(struct xt_NFQ_info), | 53 | .targetsize = sizeof(struct xt_NFQ_info), |
54 | .me = THIS_MODULE, | 54 | .me = THIS_MODULE, |
diff --git a/net/netfilter/xt_iprange.c b/net/netfilter/xt_iprange.c index 6f62c36948d9..7ac54eab0b00 100644 --- a/net/netfilter/xt_iprange.c +++ b/net/netfilter/xt_iprange.c | |||
@@ -61,7 +61,7 @@ iprange_mt4(const struct sk_buff *skb, const struct xt_match_param *par) | |||
61 | if (info->flags & IPRANGE_SRC) { | 61 | if (info->flags & IPRANGE_SRC) { |
62 | m = ntohl(iph->saddr) < ntohl(info->src_min.ip); | 62 | m = ntohl(iph->saddr) < ntohl(info->src_min.ip); |
63 | m |= ntohl(iph->saddr) > ntohl(info->src_max.ip); | 63 | m |= ntohl(iph->saddr) > ntohl(info->src_max.ip); |
64 | m ^= info->flags & IPRANGE_SRC_INV; | 64 | m ^= !!(info->flags & IPRANGE_SRC_INV); |
65 | if (m) { | 65 | if (m) { |
66 | pr_debug("src IP " NIPQUAD_FMT " NOT in range %s" | 66 | pr_debug("src IP " NIPQUAD_FMT " NOT in range %s" |
67 | NIPQUAD_FMT "-" NIPQUAD_FMT "\n", | 67 | NIPQUAD_FMT "-" NIPQUAD_FMT "\n", |
@@ -75,7 +75,7 @@ iprange_mt4(const struct sk_buff *skb, const struct xt_match_param *par) | |||
75 | if (info->flags & IPRANGE_DST) { | 75 | if (info->flags & IPRANGE_DST) { |
76 | m = ntohl(iph->daddr) < ntohl(info->dst_min.ip); | 76 | m = ntohl(iph->daddr) < ntohl(info->dst_min.ip); |
77 | m |= ntohl(iph->daddr) > ntohl(info->dst_max.ip); | 77 | m |= ntohl(iph->daddr) > ntohl(info->dst_max.ip); |
78 | m ^= info->flags & IPRANGE_DST_INV; | 78 | m ^= !!(info->flags & IPRANGE_DST_INV); |
79 | if (m) { | 79 | if (m) { |
80 | pr_debug("dst IP " NIPQUAD_FMT " NOT in range %s" | 80 | pr_debug("dst IP " NIPQUAD_FMT " NOT in range %s" |
81 | NIPQUAD_FMT "-" NIPQUAD_FMT "\n", | 81 | NIPQUAD_FMT "-" NIPQUAD_FMT "\n", |
@@ -114,14 +114,14 @@ iprange_mt6(const struct sk_buff *skb, const struct xt_match_param *par) | |||
114 | if (info->flags & IPRANGE_SRC) { | 114 | if (info->flags & IPRANGE_SRC) { |
115 | m = iprange_ipv6_sub(&iph->saddr, &info->src_min.in6) < 0; | 115 | m = iprange_ipv6_sub(&iph->saddr, &info->src_min.in6) < 0; |
116 | m |= iprange_ipv6_sub(&iph->saddr, &info->src_max.in6) > 0; | 116 | m |= iprange_ipv6_sub(&iph->saddr, &info->src_max.in6) > 0; |
117 | m ^= info->flags & IPRANGE_SRC_INV; | 117 | m ^= !!(info->flags & IPRANGE_SRC_INV); |
118 | if (m) | 118 | if (m) |
119 | return false; | 119 | return false; |
120 | } | 120 | } |
121 | if (info->flags & IPRANGE_DST) { | 121 | if (info->flags & IPRANGE_DST) { |
122 | m = iprange_ipv6_sub(&iph->daddr, &info->dst_min.in6) < 0; | 122 | m = iprange_ipv6_sub(&iph->daddr, &info->dst_min.in6) < 0; |
123 | m |= iprange_ipv6_sub(&iph->daddr, &info->dst_max.in6) > 0; | 123 | m |= iprange_ipv6_sub(&iph->daddr, &info->dst_max.in6) > 0; |
124 | m ^= info->flags & IPRANGE_DST_INV; | 124 | m ^= !!(info->flags & IPRANGE_DST_INV); |
125 | if (m) | 125 | if (m) |
126 | return false; | 126 | return false; |
127 | } | 127 | } |
diff --git a/net/netfilter/xt_recent.c b/net/netfilter/xt_recent.c index 4ebd4ca9a991..280c471bcdf4 100644 --- a/net/netfilter/xt_recent.c +++ b/net/netfilter/xt_recent.c | |||
@@ -318,15 +318,15 @@ static bool recent_mt_check(const struct xt_mtchk_param *par) | |||
318 | for (i = 0; i < ip_list_hash_size; i++) | 318 | for (i = 0; i < ip_list_hash_size; i++) |
319 | INIT_LIST_HEAD(&t->iphash[i]); | 319 | INIT_LIST_HEAD(&t->iphash[i]); |
320 | #ifdef CONFIG_PROC_FS | 320 | #ifdef CONFIG_PROC_FS |
321 | t->proc = proc_create(t->name, ip_list_perms, recent_proc_dir, | 321 | t->proc = proc_create_data(t->name, ip_list_perms, recent_proc_dir, |
322 | &recent_mt_fops); | 322 | &recent_mt_fops, t); |
323 | if (t->proc == NULL) { | 323 | if (t->proc == NULL) { |
324 | kfree(t); | 324 | kfree(t); |
325 | goto out; | 325 | goto out; |
326 | } | 326 | } |
327 | #ifdef CONFIG_NETFILTER_XT_MATCH_RECENT_PROC_COMPAT | 327 | #ifdef CONFIG_NETFILTER_XT_MATCH_RECENT_PROC_COMPAT |
328 | t->proc_old = proc_create(t->name, ip_list_perms, proc_old_dir, | 328 | t->proc_old = proc_create_data(t->name, ip_list_perms, proc_old_dir, |
329 | &recent_old_fops); | 329 | &recent_old_fops, t); |
330 | if (t->proc_old == NULL) { | 330 | if (t->proc_old == NULL) { |
331 | remove_proc_entry(t->name, proc_old_dir); | 331 | remove_proc_entry(t->name, proc_old_dir); |
332 | kfree(t); | 332 | kfree(t); |
@@ -334,11 +334,9 @@ static bool recent_mt_check(const struct xt_mtchk_param *par) | |||
334 | } | 334 | } |
335 | t->proc_old->uid = ip_list_uid; | 335 | t->proc_old->uid = ip_list_uid; |
336 | t->proc_old->gid = ip_list_gid; | 336 | t->proc_old->gid = ip_list_gid; |
337 | t->proc_old->data = t; | ||
338 | #endif | 337 | #endif |
339 | t->proc->uid = ip_list_uid; | 338 | t->proc->uid = ip_list_uid; |
340 | t->proc->gid = ip_list_gid; | 339 | t->proc->gid = ip_list_gid; |
341 | t->proc->data = t; | ||
342 | #endif | 340 | #endif |
343 | spin_lock_bh(&recent_lock); | 341 | spin_lock_bh(&recent_lock); |
344 | list_add_tail(&t->list, &tables); | 342 | list_add_tail(&t->list, &tables); |
diff --git a/net/sched/sch_generic.c b/net/sched/sch_generic.c index 7b5572d6beb5..93cd30ce6501 100644 --- a/net/sched/sch_generic.c +++ b/net/sched/sch_generic.c | |||
@@ -326,6 +326,7 @@ struct Qdisc_ops noop_qdisc_ops __read_mostly = { | |||
326 | 326 | ||
327 | static struct netdev_queue noop_netdev_queue = { | 327 | static struct netdev_queue noop_netdev_queue = { |
328 | .qdisc = &noop_qdisc, | 328 | .qdisc = &noop_qdisc, |
329 | .qdisc_sleeping = &noop_qdisc, | ||
329 | }; | 330 | }; |
330 | 331 | ||
331 | struct Qdisc noop_qdisc = { | 332 | struct Qdisc noop_qdisc = { |
@@ -352,6 +353,7 @@ static struct Qdisc_ops noqueue_qdisc_ops __read_mostly = { | |||
352 | static struct Qdisc noqueue_qdisc; | 353 | static struct Qdisc noqueue_qdisc; |
353 | static struct netdev_queue noqueue_netdev_queue = { | 354 | static struct netdev_queue noqueue_netdev_queue = { |
354 | .qdisc = &noqueue_qdisc, | 355 | .qdisc = &noqueue_qdisc, |
356 | .qdisc_sleeping = &noqueue_qdisc, | ||
355 | }; | 357 | }; |
356 | 358 | ||
357 | static struct Qdisc noqueue_qdisc = { | 359 | static struct Qdisc noqueue_qdisc = { |