summaryrefslogtreecommitdiff
path: root/net/bridge/br_input.c
diff options
context:
space:
mode:
authorSun Jian <sun.jian.kdev@gmail.com>2026-02-25 19:14:50 +0800
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2026-03-13 17:20:45 +0100
commit4614301b900adba02c685bec9c7e5932eb83a676 (patch)
treeef9501848ab9fad7050f374e0009a751458443ee /net/bridge/br_input.c
parent0b7cd6fa9affca49c70f324594a02ecf1bc7f15d (diff)
selftests/harness: order TEST_F and XFAIL_ADD constructors
[ Upstream commit 6be2681514261324c8ee8a1c6f76cefdf700220f ] TEST_F() allocates and registers its struct __test_metadata via mmap() inside its constructor, and only then assigns the _##fixture_##test##_object pointer. XFAIL_ADD() runs in a constructor too and reads _##fixture_##test##_object to initialize xfail->test. If XFAIL_ADD runs first, xfail->test can be NULL and the expected failure will be reported as FAIL. Use constructor priorities to ensure TEST_F registration runs before XFAIL_ADD, without adding extra state or runtime lookups. Fixes: 2709473c9386 ("selftests: kselftest_harness: support using xfail") Signed-off-by: Sun Jian <sun.jian.kdev@gmail.com> Link: https://patch.msgid.link/20260225111451.347923-1-sun.jian.kdev@gmail.com Signed-off-by: Jakub Kicinski <kuba@kernel.org> Signed-off-by: Sasha Levin <sashal@kernel.org>
Diffstat (limited to 'net/bridge/br_input.c')
0 files changed, 0 insertions, 0 deletions