On 1/23/26 18:09, [email protected] wrote: >> diff --git >> a/tools/testing/selftests/bpf/prog_tests/sockmap_interrupted_connect.c >> b/tools/testing/selftests/bpf/prog_tests/sockmap_interrupted_connect.c >> new file mode 100644 >> index 000000000000..aa48ae483dab >> --- /dev/null >> +++ b/tools/testing/selftests/bpf/prog_tests/sockmap_interrupted_connect.c >> @@ -0,0 +1,200 @@ >> +// SPDX-License-Identifier: GPL-2.0 > > [ ... ] > >> +#include "sockmap_helpers.h" > > [ ... ] > >> +void serial_test_sockmap_interrupted_connect(void) >> +{ >> + sighandler_t orig_handler; >> + struct context ctx = {0}; >> + pthread_t tid; >> + >> + orig_handler = signal(SIGUSR1, handler); >> + if (!ASSERT_NEQ(orig_handler, SIG_ERR, "signal")) >> + return; >> + >> + if (xpthread_create(&tid, NULL, racer, &ctx)) >> + goto restore; >> + >> + test_map(&ctx, BPF_MAP_TYPE_SOCKMAP); >> + >> + if (!xpthread_cancel(tid)) > ^^^^^^^^^^^^^^^^ > > Is xpthread_cancel() defined somewhere? I see sockmap_helpers.h defines > xpthread_create() and xpthread_join(), but there does not appear to be a > definition for xpthread_cancel(). This would cause a compilation failure.
xpthread_cancel() is defined in patch 1/2 of this series. But apparently patch 1/2 is still missing from https://lore.kernel.org/bpf. FWIW, it's already here: https://lore.kernel.org/lkml/[email protected]/

