diff options
author | David S. Miller <davem@davemloft.net> | 2013-03-20 12:46:26 -0400 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2013-03-20 12:46:26 -0400 |
commit | 61816596d1c9026d0ecb20c44f90452c41596ffe (patch) | |
tree | 3027ed6dc62f71e14b9d525405747fa0eb8f074d /net/core | |
parent | 23a9072e3af0d9538e25837fb2b56bb94e4a8e67 (diff) | |
parent | da2191e31409d1058dcbed44e8f53e39a40e86b3 (diff) |
Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/net
Pull in the 'net' tree to get Daniel Borkmann's flow dissector
infrastructure change.
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'net/core')
-rw-r--r-- | net/core/dev.c | 2 | ||||
-rw-r--r-- | net/core/flow_dissector.c | 2 | ||||
-rw-r--r-- | net/core/rtnetlink.c | 2 |
3 files changed, 4 insertions, 2 deletions
diff --git a/net/core/dev.c b/net/core/dev.c index 8c47ab243926..de930b751712 100644 --- a/net/core/dev.c +++ b/net/core/dev.c | |||
@@ -2211,9 +2211,9 @@ EXPORT_SYMBOL(skb_checksum_help); | |||
2211 | __be16 skb_network_protocol(struct sk_buff *skb) | 2211 | __be16 skb_network_protocol(struct sk_buff *skb) |
2212 | { | 2212 | { |
2213 | __be16 type = skb->protocol; | 2213 | __be16 type = skb->protocol; |
2214 | int vlan_depth = ETH_HLEN; | ||
2214 | 2215 | ||
2215 | while (type == htons(ETH_P_8021Q)) { | 2216 | while (type == htons(ETH_P_8021Q)) { |
2216 | int vlan_depth = ETH_HLEN; | ||
2217 | struct vlan_hdr *vh; | 2217 | struct vlan_hdr *vh; |
2218 | 2218 | ||
2219 | if (unlikely(!pskb_may_pull(skb, vlan_depth + VLAN_HLEN))) | 2219 | if (unlikely(!pskb_may_pull(skb, vlan_depth + VLAN_HLEN))) |
diff --git a/net/core/flow_dissector.c b/net/core/flow_dissector.c index f8d9e03b7a7c..f4be293bab9e 100644 --- a/net/core/flow_dissector.c +++ b/net/core/flow_dissector.c | |||
@@ -151,6 +151,8 @@ ipv6: | |||
151 | flow->ports = *ports; | 151 | flow->ports = *ports; |
152 | } | 152 | } |
153 | 153 | ||
154 | flow->thoff = (u16) nhoff; | ||
155 | |||
154 | return true; | 156 | return true; |
155 | } | 157 | } |
156 | EXPORT_SYMBOL(skb_flow_dissect); | 158 | EXPORT_SYMBOL(skb_flow_dissect); |
diff --git a/net/core/rtnetlink.c b/net/core/rtnetlink.c index 0e86baf8f809..9a9b99e1fb70 100644 --- a/net/core/rtnetlink.c +++ b/net/core/rtnetlink.c | |||
@@ -2690,7 +2690,7 @@ static int rtnetlink_rcv_msg(struct sk_buff *skb, struct nlmsghdr *nlh) | |||
2690 | struct rtattr *attr = (void *)nlh + NLMSG_ALIGN(min_len); | 2690 | struct rtattr *attr = (void *)nlh + NLMSG_ALIGN(min_len); |
2691 | 2691 | ||
2692 | while (RTA_OK(attr, attrlen)) { | 2692 | while (RTA_OK(attr, attrlen)) { |
2693 | unsigned int flavor = attr->rta_type; | 2693 | unsigned int flavor = attr->rta_type & NLA_TYPE_MASK; |
2694 | if (flavor) { | 2694 | if (flavor) { |
2695 | if (flavor > rta_max[sz_idx]) | 2695 | if (flavor > rta_max[sz_idx]) |
2696 | return -EINVAL; | 2696 | return -EINVAL; |