Re: [patch net-next 6/6] selftests: virtio_net: add initial tests

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On 2024-04-12 17:13 +0200, Jiri Pirko wrote:
> From: Jiri Pirko <jiri@xxxxxxxxxx>
> 
> Introduce initial tests for virtio_net driver. Focus on feature testing
> leveraging previously introduced debugfs feature filtering
> infrastructure. Add very basic ping and F_MAC feature tests.
> 
> To run this, do:
> $ make -C tools/testing/selftests/ TARGETS=drivers/net/virtio_net/ run_tests
> 
> Run it on a system with 2 virtio_net devices connected back-to-back
> on the hypervisor.
> 
> Signed-off-by: Jiri Pirko <jiri@xxxxxxxxxx>
> ---
>  tools/testing/selftests/Makefile              |   1 +
>  .../selftests/drivers/net/virtio_net/Makefile |   5 +
>  .../drivers/net/virtio_net/basic_features.sh  | 127 ++++++++++++++++++
>  .../net/virtio_net/virtio_net_common.sh       |  99 ++++++++++++++
>  4 files changed, 232 insertions(+)
>  create mode 100644 tools/testing/selftests/drivers/net/virtio_net/Makefile
>  create mode 100755 tools/testing/selftests/drivers/net/virtio_net/basic_features.sh
>  create mode 100644 tools/testing/selftests/drivers/net/virtio_net/virtio_net_common.sh
> 
> diff --git a/tools/testing/selftests/Makefile b/tools/testing/selftests/Makefile
> index 6dab886d6f7a..a8e40599c65f 100644
> --- a/tools/testing/selftests/Makefile
> +++ b/tools/testing/selftests/Makefile
> @@ -20,6 +20,7 @@ TARGETS += drivers/s390x/uvdevice
>  TARGETS += drivers/net
>  TARGETS += drivers/net/bonding
>  TARGETS += drivers/net/team
> +TARGETS += drivers/net/virtio
>  TARGETS += dt
>  TARGETS += efivarfs
>  TARGETS += exec
> diff --git a/tools/testing/selftests/drivers/net/virtio_net/Makefile b/tools/testing/selftests/drivers/net/virtio_net/Makefile
> new file mode 100644
> index 000000000000..c6edf5ddb0e4
> --- /dev/null
> +++ b/tools/testing/selftests/drivers/net/virtio_net/Makefile
> @@ -0,0 +1,5 @@
> +# SPDX-License-Identifier: GPL-2.0+ OR MIT
> +
> +TEST_PROGS = basic_features.sh
> +
> +include ../../../lib.mk

Makefile is missing something like

TEST_FILES = \
	virtio_net_common.sh \
	#

TEST_INCLUDES = \
	../../../net/forwarding/lib.sh \
	../../../net/lib.sh \
	#

Without those, these files are missing when exporting the tests, such as
with:

cd tools/testing/selftests/
make install TARGETS=drivers/net/virtio_net/
./kselftest_install/run_kselftest.sh




[Index of Archives]     [KVM Development]     [Libvirt Development]     [Libvirt Users]     [CentOS Virtualization]     [Netdev]     [Ethernet Bridging]     [Linux Wireless]     [Kernel Newbies]     [Security]     [Linux for Hams]     [Netfilter]     [Bugtraq]     [Yosemite Forum]     [MIPS Linux]     [ARM Linux]     [Linux RAID]     [Linux Admin]     [Samba]

  Powered by Linux