[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <c8876216-c37d-4d7d-9301-b051273e69b0@davidwei.uk>
Date: Sat, 22 Nov 2025 16:55:05 -0800
From: David Wei <dw@...idwei.uk>
To: Jakub Kicinski <kuba@...nel.org>, davem@...emloft.net
Cc: netdev@...r.kernel.org, edumazet@...gle.com, pabeni@...hat.com,
andrew+netdev@...n.ch, horms@...nel.org, willemb@...gle.com,
petrm@...dia.com, shuah@...nel.org, linux-kselftest@...r.kernel.org
Subject: Re: [PATCH net-next 1/5] selftests: hw-net: auto-disable building the
iouring C code
On 2025-11-20 20:02, Jakub Kicinski wrote:
> Looks like the liburing is not updated by distros very aggressively.
> Presumably because a lot of packages depend on it. I just updated
> to Fedora 43 and it's still on liburing 2.9. The test is 9mo old,
> at this stage I think this warrants handling the build failure
> more gracefully.
>
> Detect if iouring is recent enough and if not print a warning
> and exclude the C prog from build. The Python test will just
> fail since the binary won't exist. But it removes the major
> annoyance of having to update liburing from sources when
> developing other tests.
>
> Signed-off-by: Jakub Kicinski <kuba@...nel.org>
> ---
> tools/testing/selftests/drivers/net/hw/Makefile | 17 ++++++++++++++++-
> 1 file changed, 16 insertions(+), 1 deletion(-)
>
> diff --git a/tools/testing/selftests/drivers/net/hw/Makefile b/tools/testing/selftests/drivers/net/hw/Makefile
> index 1760238e9d4f..949aeeeb357d 100644
> --- a/tools/testing/selftests/drivers/net/hw/Makefile
> +++ b/tools/testing/selftests/drivers/net/hw/Makefile
> @@ -1,7 +1,20 @@
> # 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)
Would you want to mention the min ver needed (2.10)?
Powered by blists - more mailing lists