From 54960932b497a27f3c7ba9baeab6687660221bf0 Mon Sep 17 00:00:00 2001 From: Changli Gao Date: Tue, 20 Sep 2011 22:36:07 +0000 Subject: [PATCH] --- yaml --- r: 266196 b: refs/heads/master c: 5dd17e08f333cde0fa11000792e33d8d39b5599f h: refs/heads/master v: v3 --- [refs] | 2 +- trunk/net/core/dev.c | 12 +++++++++++- 2 files changed, 12 insertions(+), 2 deletions(-) diff --git a/[refs] b/[refs] index 18b306173372..a95f66d807ad 100644 --- a/[refs] +++ b/[refs] @@ -1,2 +1,2 @@ --- -refs/heads/master: 16e5726269611b71c930054ffe9b858c1cea88eb +refs/heads/master: 5dd17e08f333cde0fa11000792e33d8d39b5599f diff --git a/trunk/net/core/dev.c b/trunk/net/core/dev.c index bf49a47ddfdb..7f4486e127e9 100644 --- a/trunk/net/core/dev.c +++ b/trunk/net/core/dev.c @@ -135,6 +135,7 @@ #include #include #include +#include #include "net-sysfs.h" @@ -2556,6 +2557,7 @@ void __skb_get_rxhash(struct sk_buff *skb) again: switch (proto) { case __constant_htons(ETH_P_IP): +ip: if (!pskb_may_pull(skb, sizeof(*ip) + nhoff)) goto done; @@ -2569,6 +2571,7 @@ void __skb_get_rxhash(struct sk_buff *skb) nhoff += ip->ihl * 4; break; case __constant_htons(ETH_P_IPV6): +ipv6: if (!pskb_may_pull(skb, sizeof(*ip6) + nhoff)) goto done; @@ -2591,7 +2594,14 @@ void __skb_get_rxhash(struct sk_buff *skb) proto = *((__be16 *) (skb->data + nhoff + sizeof(struct pppoe_hdr))); nhoff += PPPOE_SES_HLEN; - goto again; + switch (proto) { + case __constant_htons(PPP_IP): + goto ip; + case __constant_htons(PPP_IPV6): + goto ipv6; + default: + goto done; + } default: goto done; }