linux/drivers/net
Corinna Vinschen 218c597325 net: stmmac: fix up RX flow hash indirection table when setting channels
stmmac_reinit_queues() fails to fix up the RX hash.  Even if the number
of channels gets restricted, the output of `ethtool -x' indicates that
all RX queues are used:

  $ ethtool -l enp0s29f2
  Channel parameters for enp0s29f2:
  Pre-set maximums:
  RX:		8
  TX:		8
  Other:		n/a
  Combined:	n/a
  Current hardware settings:
  RX:		8
  TX:		8
  Other:		n/a
  Combined:	n/a
  $ ethtool -x enp0s29f2
  RX flow hash indirection table for enp0s29f2 with 8 RX ring(s):
      0:      0     1     2     3     4     5     6     7
      8:      0     1     2     3     4     5     6     7
  [...]
  $ ethtool -L enp0s29f2 rx 3
  $ ethtool -x enp0s29f2
  RX flow hash indirection table for enp0s29f2 with 3 RX ring(s):
      0:      0     1     2     3     4     5     6     7
      8:      0     1     2     3     4     5     6     7
  [...]

Fix this by setting the indirection table according to the number
of specified queues.  The result is now as expected:

  $ ethtool -L enp0s29f2 rx 3
  $ ethtool -x enp0s29f2
  RX flow hash indirection table for enp0s29f2 with 3 RX ring(s):
      0:      0     1     2     0     1     2     0     1
      8:      2     0     1     2     0     1     2     0
  [...]

Tested on Intel Elkhart Lake.

Fixes: 0366f7e06a ("net: stmmac: add ethtool support for get/set channels")
Signed-off-by: Corinna Vinschen <vinschen@redhat.com>
Link: https://lore.kernel.org/r/20230403121120.489138-1-vinschen@redhat.com
Signed-off-by: Paolo Abeni <pabeni@redhat.com>
2023-04-04 15:17:15 +02:00
..
appletalk
arcnet
bonding bonding: restore bond's IFF_SLAVE flag if a non-eth dev enslave fails 2023-03-17 07:56:41 +00:00
caif
can net: Use of_property_read_bool() for boolean properties 2023-03-16 17:41:28 +00:00
dsa net: dsa: mv88e6xxx: Reset mv88e6393x force WD event bit 2023-04-02 13:32:37 +01:00
ethernet net: stmmac: fix up RX flow hash indirection table when setting channels 2023-04-04 15:17:15 +02:00
fddi
fjes
hamradio
hippi
hyperv Networking changes for 6.3. 2023-02-21 18:24:12 -08:00
ieee802154 ca8210: Fix unsigned mac_len comparison with zero in ca8210_skb_tx() 2023-03-16 17:28:27 +01:00
ipa net: ipa: compute DMA pool size properly 2023-03-29 21:27:40 -07:00
ipvlan ipvlan: Make skb->skb_iif track skb->dev for l3s mode 2023-03-10 21:27:15 -08:00
mctp
mdio net: mdio: thunder: Add missing fwnode_handle_put() 2023-03-23 08:46:55 +00:00
netdevsim
pcs
phy net: sfp: add quirk enabling 2500Base-x for HG MXPD-483II 2023-04-03 10:01:17 +01:00
plip
ppp
pse-pd
slip
team
thunderbolt
usb net: asix: fix modprobe "sysfs: cannot create duplicate filename" 2023-03-22 22:04:04 -07:00
vmxnet3 vmxnet3: use gro callback when UPT is enabled 2023-03-24 19:13:49 -07:00
vxlan
wan net: Use of_property_read_bool() for boolean properties 2023-03-16 17:41:28 +00:00
wireguard cpumask: fix incorrect cpumask scanning result checks 2023-03-06 12:15:13 -08:00
wireless wireless fixes for v6.3 2023-03-23 15:47:53 -07:00
wwan net: wwan: t7xx: do not compile with -Werror 2023-03-31 09:34:53 +01:00
xen-netback xen/netback: use same error messages for same errors 2023-03-30 15:39:23 +02:00
amt.c
bareudp.c
dummy.c
eql.c
geneve.c
gtp.c
ifb.c
Kconfig Networking changes for 6.3. 2023-02-21 18:24:12 -08:00
LICENSE.SRC
loopback.c
macsec.c Networking changes for 6.3. 2023-02-21 18:24:12 -08:00
macvlan.c
macvtap.c
Makefile
mdio.c
mhi_net.c
mii.c
net_failover.c net/net_failover: fix txq exceeding warning 2023-03-27 08:08:57 +01:00
netconsole.c
nlmon.c
ntb_netdev.c
rionet.c
sb1000.c
Space.c
sungem_phy.c
tap.c
tun.c
veth.c bpf-for-netdev 2023-03-23 16:03:33 -07:00
virtio_net.c virtio_net: free xdp shinfo frags when build_skb_from_xdp_buff() fails 2023-03-16 17:46:05 +00:00
vrf.c
vsockmon.c
xen-netfront.c