* [PATCH] flow_diseector: Add support for IPPROTO_IPV6
@ 2013-07-29 15:06 Tom Herbert
2013-07-29 15:37 ` Stephen Hemminger
2013-07-29 17:10 ` Eric Dumazet
0 siblings, 2 replies; 3+ messages in thread
From: Tom Herbert @ 2013-07-29 15:06 UTC (permalink / raw)
To: davem; +Cc: netdev
Add support for dissecting flows in IPv6/IPv4 packets.
Signed-off-by: Tom Herbert <therbert@google.com>
---
net/core/flow_dissector.c | 6 +++++-
1 file changed, 5 insertions(+), 1 deletion(-)
diff --git a/net/core/flow_dissector.c b/net/core/flow_dissector.c
index 00ee068..96901de 100644
--- a/net/core/flow_dissector.c
+++ b/net/core/flow_dissector.c
@@ -139,7 +139,11 @@ ipv6:
break;
}
case IPPROTO_IPIP:
- goto again;
+ proto = __constant_htons(ETH_P_IP);
+ goto ip;
+ case IPPROTO_IPV6:
+ proto = __constant_htons(ETH_P_IPV6);
+ goto ipv6;
default:
break;
}
--
1.8.3
^ permalink raw reply related [flat|nested] 3+ messages in thread
* Re: [PATCH] flow_diseector: Add support for IPPROTO_IPV6
2013-07-29 15:06 [PATCH] flow_diseector: Add support for IPPROTO_IPV6 Tom Herbert
@ 2013-07-29 15:37 ` Stephen Hemminger
2013-07-29 17:10 ` Eric Dumazet
1 sibling, 0 replies; 3+ messages in thread
From: Stephen Hemminger @ 2013-07-29 15:37 UTC (permalink / raw)
To: Tom Herbert; +Cc: davem, netdev
On Mon, 29 Jul 2013 08:06:51 -0700 (PDT)
Tom Herbert <therbert@google.com> wrote:
> Add support for dissecting flows in IPv6/IPv4 packets.
>
> Signed-off-by: Tom Herbert <therbert@google.com>
> ---
> net/core/flow_dissector.c | 6 +++++-
> 1 file changed, 5 insertions(+), 1 deletion(-)
>
> diff --git a/net/core/flow_dissector.c b/net/core/flow_dissector.c
> index 00ee068..96901de 100644
> --- a/net/core/flow_dissector.c
> +++ b/net/core/flow_dissector.c
> @@ -139,7 +139,11 @@ ipv6:
> break;
> }
> case IPPROTO_IPIP:
> - goto again;
> + proto = __constant_htons(ETH_P_IP);
> + goto ip;
> + case IPPROTO_IPV6:
> + proto = __constant_htons(ETH_P_IPV6);
> + goto ipv6;
> default:
> break;
> }
The __constant_htons() is unnecessary, the simple macro htons()
is smart enough to figure out what is constant. The current style
preference is to use htons() instead; shorter is better.
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: [PATCH] flow_diseector: Add support for IPPROTO_IPV6
2013-07-29 15:06 [PATCH] flow_diseector: Add support for IPPROTO_IPV6 Tom Herbert
2013-07-29 15:37 ` Stephen Hemminger
@ 2013-07-29 17:10 ` Eric Dumazet
1 sibling, 0 replies; 3+ messages in thread
From: Eric Dumazet @ 2013-07-29 17:10 UTC (permalink / raw)
To: Tom Herbert; +Cc: davem, netdev
On Mon, 2013-07-29 at 08:06 -0700, Tom Herbert wrote:
> Add support for dissecting flows in IPv6/IPv4 packets.
>
> Signed-off-by: Tom Herbert <therbert@google.com>
> ---
> net/core/flow_dissector.c | 6 +++++-
> 1 file changed, 5 insertions(+), 1 deletion(-)
>
> diff --git a/net/core/flow_dissector.c b/net/core/flow_dissector.c
> index 00ee068..96901de 100644
> --- a/net/core/flow_dissector.c
> +++ b/net/core/flow_dissector.c
> @@ -139,7 +139,11 @@ ipv6:
> break;
> }
> case IPPROTO_IPIP:
> - goto again;
> + proto = __constant_htons(ETH_P_IP);
> + goto ip;
> + case IPPROTO_IPV6:
> + proto = __constant_htons(ETH_P_IPV6);
> + goto ipv6;
> default:
> break;
> }
It seems this patch makes two different changes, but changelog is vague.
(As if we were not dissecting flows in IPv4/IPv6 packets ...)
How about :
1) Fix a problem if IPIP is tunneled into IPv6
Prior code assumed IPIP was encapsulated into IPv4 only.
2) Add support for IPPROTO_IPV6
Thanks
BTW it looks like we do not support ETH_P_8021AD yet
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2013-07-29 17:10 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2013-07-29 15:06 [PATCH] flow_diseector: Add support for IPPROTO_IPV6 Tom Herbert
2013-07-29 15:37 ` Stephen Hemminger
2013-07-29 17:10 ` Eric Dumazet
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).