[PATCH 3/4] rps: Infrastructure in __skb_get_rxhash for deep inspection

Subsystems: networking [general], the rest

STALE5574d

2 messages, 2 authors, 2011-05-19 · open the first message on its own page

[PATCH 3/4] rps: Infrastructure in __skb_get_rxhash for deep inspection

From: Tom Herbert <hidden>
Date: 2011-05-19 15:39:28

Basics for looking for ports in encapsulated packets in tunnels.

Signed-off-by: Tom Herbert <redacted>
---
 net/core/dev.c |    7 +++++++
 1 files changed, 7 insertions(+), 0 deletions(-)
diff --git a/net/core/dev.c b/net/core/dev.c
index 37ddece..0c83494 100644
--- a/net/core/dev.c
+++ b/net/core/dev.c
@@ -133,6 +133,7 @@
 #include <linux/pci.h>
 #include <linux/inetdevice.h>
 #include <linux/cpu_rmap.h>
+#include <linux/if_tunnel.h>
 
 #include "net-sysfs.h"
 
@@ -2521,6 +2522,7 @@ void __skb_get_rxhash(struct sk_buff *skb)
 	nhoff = skb_network_offset(skb);
 	proto = skb->protocol;
 
+again:
 	switch (proto) {
 	case __constant_htons(ETH_P_IP):
 		if (!pskb_may_pull(skb, sizeof(*ip) + nhoff))
@@ -2549,6 +2551,11 @@ void __skb_get_rxhash(struct sk_buff *skb)
 		goto done;
 	}
 
+	switch (ip_proto) {
+	default:
+		break;
+	}
+
 	ports.v32 = 0;
 	poff = proto_ports_offset(ip_proto);
 	if (poff >= 0) {
-- 
1.7.3.1

Re: [PATCH 3/4] rps: Infrastructure in __skb_get_rxhash for deep inspection

From: Eric Dumazet <hidden>
Date: 2011-05-19 20:27:41

Le jeudi 19 mai 2011 à 08:39 -0700, Tom Herbert a écrit :
Basics for looking for ports in encapsulated packets in tunnels.

Signed-off-by: Tom Herbert <redacted>
---
 net/core/dev.c |    7 +++++++
 1 files changed, 7 insertions(+), 0 deletions(-)
Reviewed-by: Eric Dumazet <redacted>


Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help