netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* Netlink handler for ethtool --show-rxfh breaks driver compatibility
@ 2024-07-11 11:45 Vladimir Oltean
  2024-07-15  7:37 ` Mogilappagari, Sudheer
  0 siblings, 1 reply; 11+ messages in thread
From: Vladimir Oltean @ 2024-07-11 11:45 UTC (permalink / raw)
  To: Michal Kubecek, Sudheer Mogilappagari, netdev; +Cc: Wei Fang

Hi,

Commit ffab99c1f382 ("netlink: add netlink handler for get rss (-x)") in
the ethtool user space binary breaks compatibility with device drivers.

Namely, before the change, ethtool --show-rxfh did not emit a
ETHTOOL_MSG_CHANNELS_GET netlink message or even the ETHTOOL_GCHANNELS
ioctl variant. Now it does, and this effectively forces a new
requirement for drivers to implement ethtool_ops :: get_channels() in
the kernel.

The following drivers implement ethtool_ops :: get_rxfh() but not
ethtool_ops :: get_channels():
- drivers/net/ethernet/microchip/lan743x_ethtool.c
- drivers/net/ethernet/freescale/enetc/enetc_ethtool.c
- drivers/net/ethernet/marvell/mvpp2/mvpp2_main.c
- drivers/net/ethernet/marvell/mvneta.c
- drivers/net/ethernet/aquantia/atlantic/aq_ethtool.c
- drivers/net/ethernet/chelsio/cxgb4/cxgb4_ethtool.c
- drivers/net/ethernet/sfc/ef100_ethtool.c
- drivers/net/ethernet/sfc/falcon/ethtool.c
- drivers/net/ethernet/sfc/siena/ethtool.c
- drivers/net/ethernet/sfc/ethtool.c
- drivers/net/ethernet/intel/ixgbevf/ethtool.c

Thus, for them, this is a breaking ABI change which must be addressed.

A demo for the enetc driver.

Before:
  $ ethtool --show-rxfh eno0
  RX flow hash indirection table for eno0 with 2 RX ring(s):
      0:      0     1     0     1     0     1     0     1
      8:      0     1     0     1     0     1     0     1
     16:      0     1     0     1     0     1     0     1
     24:      0     1     0     1     0     1     0     1
     32:      0     1     0     1     0     1     0     1
     40:      0     1     0     1     0     1     0     1
     48:      0     1     0     1     0     1     0     1
     56:      0     1     0     1     0     1     0     1
  RSS hash key:
  0d:1f:cb:76:88:82:dd:ea:70:c9:ef:53:3e:f3:bf:60:5c:79:60:09:32:ff:88:fa:aa:39:63:31:ef:ad:31:e4:ac:57:ec:d2:09:4d:9a:01
  RSS hash function:
      toeplitz: on
      xor: off
      crc32: off

After:
  $ ethtool --show-rxfh eno0
  netlink error: Operation not supported

Sadly, I do not have the time to investigate a possible fix for this
issue, but I am more than happy to test out proposals.

Thanks,
Vladimir

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

end of thread, other threads:[~2024-07-17 16:45 UTC | newest]

Thread overview: 11+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2024-07-11 11:45 Netlink handler for ethtool --show-rxfh breaks driver compatibility Vladimir Oltean
2024-07-15  7:37 ` Mogilappagari, Sudheer
2024-07-15 11:58   ` Vladimir Oltean
2024-07-15 13:11     ` Jakub Kicinski
2024-07-15 13:22       ` Vladimir Oltean
2024-07-15 13:39         ` Jakub Kicinski
2024-07-15 15:05           ` Vladimir Oltean
2024-07-15 15:26             ` Jakub Kicinski
2024-07-15 15:45               ` Michal Kubecek
2024-07-15 15:46               ` Vladimir Oltean
2024-07-17 16:45                 ` Jakub Kicinski

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).