Re: [PATCH bpf 1/1] selftests/bpf: Enable BLK_DEV_NBD for raw_tp_writable_reject_nbd_invalid

From: Eduard Zingerman

Date: Mon Jul 13 2026 - 16:48:16 EST


On Mon, 2026-07-13 at 14:35 +0800, Shung-Hsi Yu wrote:
>
> The raw_tp_writable_reject_nbd_invalid test relies on availability of the
> nbd_send_request tracepoint, which is only present if the selftest kernel is
> built with CONFIG_BLK_DEV_NBD=y and the kernel built from current BPF selftests
> config lacks.
>
> Without it, the bpf_raw_tracepoint_open() call always returns with -2, leaving
> raw_tp_writable_reject_nbd_invalid test always passing without exercising the
> checks bpf_probe_register().
>
> Cc: <stable@xxxxxxxxxxxxxxx> # 5.2.0
> Link: https://lore.kernel.org/bpf/alRtilWhKw4zzMkI@u94a
> Signed-off-by: Shung-Hsi Yu <shung-hsi.yu@xxxxxxxx>
> ---
> Not sure if fixes tag is the right thing to use here, so use the cc
> stable tag instead to get this config change propogated to other stable
> branches to make stable BPF CI's job easier.

Shung-Hsi,

Thank you for figuring this out.
I'd suggest we switch to bpf_testmod_test_writable_bare_tp() [1]
from the test module to avoid the config dependency and let
Sun pack all of this as a single patch-set to simplify backports
(if such are necessary). Wdyt?

[1] https://lore.kernel.org/bpf/3430dc0a2a141769a596ab21d7abdd86a0a804db.camel@xxxxxxxxx/2-tp-test.diff