linux/tools/testing/selftests/drivers/net/hw/Makefile
Jakub Kicinski 878b56de01 selftests: drv-net: hide the devlink port_split test
The devlink port_split test has limited applicability.
NICs (as opposed to switches) require at least a re-probe
to apply the split configuration.

On top of that the test is not compatible with our driver env,
it just splits all ports on the system, not only what NETIF
points at.

Long term we may want to add some indication in devlink whether
the port splitting is runtime (cmode of sorts), and fix the
test to follow driver env. But since no (known) NIC driver can
support runtime anyway let's just hide the test from the selftest
framework by moving it to extra files.

Having this test randomly break unrelated NICs within the DUT
makes people implement allow-lists for ksft, which then means
their setups don't run new tests. It's very useful during test
review to see whether the test works across all the runners.

Reviewed-by: Petr Machata <petrm@nvidia.com>
Link: https://patch.msgid.link/20260811004645.1072124-1-kuba@kernel.org
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
2026-08-11 18:31:19 -07:00

96 lines
1.8 KiB
Makefile

# SPDX-License-Identifier: GPL-2.0+ OR MIT
# Check if io_uring supports zero-copy receive
HAS_IOURING_ZCRX := $(shell \
echo -e '#include <liburing.h>\n' \
'void *func = (void *)io_uring_register_ifq;\n' \
'int main() {return 0;}' | \
$(CC) -luring -x c - -o /dev/null 2>&1 && echo y)
ifeq ($(HAS_IOURING_ZCRX),y)
COND_GEN_FILES += iou-zcrx
else
$(warning excluding iouring tests, liburing not installed or too old)
endif
TEST_GEN_FILES := \
$(COND_GEN_FILES) \
# end of TEST_GEN_FILES
TEST_PROGS = \
csum.py \
devlink_rate_cross_esw.py \
devlink_rate_tc_bw.py \
devmem.py \
ethtool.sh \
ethtool_extended_state.sh \
ethtool_mm.sh \
ethtool_rmon.sh \
ethtool_std_stats.sh \
gro_hw.py \
hw_stats_l3.sh \
hw_stats_l3_gre.sh \
iou-zcrx.py \
ipsec_vxlan.py \
irq.py \
loopback.sh \
nic_timestamp.py \
nk_devmem.py \
nk_netns.py \
nk_qlease.py \
ntuple.py \
pp_alloc_fail.py \
rss_api.py \
rss_ctx.py \
rss_drv.py \
rss_flow_label.py \
rss_input_xfrm.py \
toeplitz.py \
tso.py \
userns_devmem.py \
uso.py \
xdp_metadata.py \
xsk_reconfig.py \
#
TEST_PROGS_EXTENDED := \
devlink_port_split.py \
# end of TEST_PROGS_EXTENDED
TEST_FILES := \
devmem_lib.py \
ethtool_lib.sh \
#
TEST_INCLUDES := \
$(wildcard lib/py/*.py ../lib/py/*.py) \
../../../net/lib.sh \
../../../net/forwarding/ipip_lib.sh \
../../../net/forwarding/lib.sh \
../../../net/forwarding/tc_common.sh \
#
# YNL files, must be before "include ..lib.mk"
YNL_GEN_FILES := \
ncdevmem \
toeplitz \
# end of YNL_GEN_FILES
TEST_GEN_FILES += $(YNL_GEN_FILES)
TEST_GEN_FILES += $(patsubst %.c,%.o,$(wildcard *.bpf.c))
include ../../../lib.mk
# YNL build
YNL_GENS := \
ethtool \
netdev \
# end of YNL_GENS
include ../../../net/ynl.mk
include ../../../net/bpf.mk
ifeq ($(HAS_IOURING_ZCRX),y)
$(OUTPUT)/iou-zcrx: LDLIBS += -luring
endif