* [PATCH] ethtool: FLOW_EXT may confuse drivers
@ 2011-05-13 14:19 Sebastian.Poehn
2011-05-13 15:01 ` Ben Hutchings
0 siblings, 1 reply; 2+ messages in thread
From: Sebastian.Poehn @ 2011-05-13 14:19 UTC (permalink / raw)
To: netdev
The FLOW_EXT bit must be masked out. Otherwise if e.g. vlan is set a driver receiving the ntuple may not detect the flow_type correctly!
Signed-off-by: Sebastian Poehn <sebastian.poehn@belden.com>
diff --git a/ethtool.c b/ethtool.c
index 34fe107..0b7ec05 100644
--- a/ethtool.c
+++ b/ethtool.c
@@ -3134,6 +3134,9 @@ static int flow_spec_to_ntuple(struct ethtool_rx_flow_spec *fsp,
(u64)ntohl(~fsp->m_ext.data[1]);
}
}
+
+ /*Mask out the extended bit, because ntuple does not know it!*/
+ ntuple->flow_type &= ~FLOW_EXT;
return 0;
}
DISCLAIMER:
Privileged and/or Confidential information may be contained in this
message. If you are not the addressee of this message, you may not
copy, use or deliver this message to anyone. In such event, you
should destroy the message and kindly notify the sender by reply
e-mail. It is understood that opinions or conclusions that do not
relate to the official business of the company are neither given
nor endorsed by the company.
Thank You.
^ permalink raw reply related [flat|nested] 2+ messages in thread
* Re: [PATCH] ethtool: FLOW_EXT may confuse drivers
2011-05-13 14:19 [PATCH] ethtool: FLOW_EXT may confuse drivers Sebastian.Poehn
@ 2011-05-13 15:01 ` Ben Hutchings
0 siblings, 0 replies; 2+ messages in thread
From: Ben Hutchings @ 2011-05-13 15:01 UTC (permalink / raw)
To: Sebastian.Poehn; +Cc: netdev
Please send ethtool patches directly to me as well as to netdev.
On Fri, 2011-05-13 at 10:19 -0400, Sebastian.Poehn@Belden.com wrote:
> The FLOW_EXT bit must be masked out. Otherwise if e.g. vlan is set a
> driver receiving the ntuple may not detect the flow_type correctly!
>
> Signed-off-by: Sebastian Poehn <sebastian.poehn@belden.com>
>
> diff --git a/ethtool.c b/ethtool.c
> index 34fe107..0b7ec05 100644
> --- a/ethtool.c
> +++ b/ethtool.c
> @@ -3134,6 +3134,9 @@ static int flow_spec_to_ntuple(struct ethtool_rx_flow_spec *fsp,
> (u64)ntohl(~fsp->m_ext.data[1]);
> }
> }
> +
> + /*Mask out the extended bit, because ntuple does not know it!*/
> + ntuple->flow_type &= ~FLOW_EXT;
>
> return 0;
> }
>
> DISCLAIMER:
>
> Privileged and/or Confidential information may be contained in this
> message. If you are not the addressee of this message, you may not
> copy, use or deliver this message to anyone. In such event, you
> should destroy the message and kindly notify the sender by reply
> e-mail. It is understood that opinions or conclusions that do not
> relate to the official business of the company are neither given
> nor endorsed by the company.
I am not the addressee, so I won't apply this (even though it looks
right). Please get rid of this disclaimer on messages to public mailing
lists.
Ben.
--
Ben Hutchings, Senior Software Engineer, Solarflare
Not speaking for my employer; that's the marketing department's job.
They asked us to note that Solarflare product names are trademarked.
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2011-05-13 15:01 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2011-05-13 14:19 [PATCH] ethtool: FLOW_EXT may confuse drivers Sebastian.Poehn
2011-05-13 15:01 ` Ben Hutchings
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).