netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] ethtool: mask out FLOW_EXT
@ 2011-05-23 13:53 Sebastian Pöhn
  2011-06-01 20:02 ` Ben Hutchings
  0 siblings, 1 reply; 2+ messages in thread
From: Sebastian Pöhn @ 2011-05-23 13:53 UTC (permalink / raw)
  To: netdev; +Cc: sebastian.poehn, bhutchings

Sorry for the disclaimer the last time!

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;
 }

^ permalink raw reply related	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2011-06-01 20:02 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2011-05-23 13:53 [PATCH] ethtool: mask out FLOW_EXT Sebastian Pöhn
2011-06-01 20:02 ` 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).