3
0
Fork 0
forked from mirrors/linux
kernel/drivers/net/netdevsim
Jakub Kicinski 29b036be1b selftests: drv-net: test XDP, HDS auto and the ioctl path
Test XDP and HDS interaction. While at it add a test for using the IOCTL,
as that turned out to be the real culprit.

Testing bnxt:

  # NETIF=eth0 ./ksft-net-drv/drivers/net/hds.py
  KTAP version 1
  1..12
  ok 1 hds.get_hds
  ok 2 hds.get_hds_thresh
  ok 3 hds.set_hds_disable # SKIP disabling of HDS not supported by the device
  ok 4 hds.set_hds_enable
  ok 5 hds.set_hds_thresh_zero
  ok 6 hds.set_hds_thresh_max
  ok 7 hds.set_hds_thresh_gt
  ok 8 hds.set_xdp
  ok 9 hds.enabled_set_xdp
  ok 10 hds.ioctl
  ok 11 hds.ioctl_set_xdp
  ok 12 hds.ioctl_enabled_set_xdp
  # Totals: pass:11 fail:0 xfail:0 xpass:0 skip:1 error:0

and netdevsim:

  # ./ksft-net-drv/drivers/net/hds.py
  KTAP version 1
  1..12
  ok 1 hds.get_hds
  ok 2 hds.get_hds_thresh
  ok 3 hds.set_hds_disable
  ok 4 hds.set_hds_enable
  ok 5 hds.set_hds_thresh_zero
  ok 6 hds.set_hds_thresh_max
  ok 7 hds.set_hds_thresh_gt
  ok 8 hds.set_xdp
  ok 9 hds.enabled_set_xdp
  ok 10 hds.ioctl
  ok 11 hds.ioctl_set_xdp
  ok 12 hds.ioctl_enabled_set_xdp
  # Totals: pass:12 fail:0 xfail:0 xpass:0 skip:0 error:0

Netdevsim needs a sane default for tx/rx ring size.

ethtool 6.11 is needed for the --disable-netlink option.

Acked-by: Stanislav Fomichev <sdf@fomichev.me>
Tested-by: Taehee Yoo <ap420073@gmail.com>
Link: https://patch.msgid.link/20250221025141.1132944-2-kuba@kernel.org
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
2025-02-24 14:16:37 -08:00
..
bpf.c
bus.c netdevsim: allow two netdevsim ports to be connected 2024-03-01 10:43:10 +00:00
dev.c netdevsim: use cond_resched() in nsim_dev_trap_report_work() 2024-10-15 09:58:43 -07:00
ethtool.c selftests: drv-net: test XDP, HDS auto and the ioctl path 2025-02-24 14:16:37 -08:00
fib.c netdevsim: Add trailing zero to terminate the string in nsim_nexthop_bucket_activity_write() 2024-10-29 11:43:01 -07:00
health.c netdevsim: prevent bad user input in nsim_dev_health_break_write() 2024-12-15 13:26:47 -08:00
hwstats.c netdevsim: don't embed file_operations into your structs 2025-01-15 13:14:36 +01:00
ipsec.c netdevsim: copy addresses for both in and out paths 2024-10-11 15:44:27 -07:00
macsec.c netdevsim: macsec: pad u64 to correct length in logs 2024-10-23 09:51:06 +02:00
Makefile
netdev.c net: move HDS config from ethtool state 2025-01-20 11:44:57 -08:00
netdevsim.h net: netdevsim: try to close UDP port harness races 2025-01-27 14:24:34 -08:00
psample.c
udp_tunnels.c net: netdevsim: try to close UDP port harness races 2025-01-27 14:24:34 -08:00