From 1780108641f27ac388d51faadb37fd2391d8a71f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Maciej=20=C5=BBenczykowski?= Date: Tue, 5 Aug 2025 12:06:38 -0700 Subject: [PATCH] bpf_existence_test: remove support for Android R MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit As of M-2025-11 mainline is only being pushed to S+ Test: TreeHugger Flag: EXEMPT test only Signed-off-by: Maciej Żenczykowski Change-Id: Id0cf9d2cce27fb90ce076fcdd0f6ee0a95ea9741 --- bpf/tests/mts/bpf_existence_test.cpp | 18 ++---------------- 1 file changed, 2 insertions(+), 16 deletions(-) diff --git a/bpf/tests/mts/bpf_existence_test.cpp b/bpf/tests/mts/bpf_existence_test.cpp index 3a2d962bb2..dc15e22d55 100644 --- a/bpf/tests/mts/bpf_existence_test.cpp +++ b/bpf/tests/mts/bpf_existence_test.cpp @@ -49,15 +49,6 @@ using android::bpf::isAtLeast25Q4; class BpfExistenceTest : public ::testing::Test { }; -// Part of Android R platform (for 4.9+), but mainlined in S -static const set PLATFORM_ONLY_IN_R = { - PLATFORM "map_offload_tether_ingress_map", - PLATFORM "map_offload_tether_limit_map", - PLATFORM "map_offload_tether_stats_map", - PLATFORM "prog_offload_schedcls_ingress_tether_ether", - PLATFORM "prog_offload_schedcls_ingress_tether_rawip", -}; - // Provided by *current* mainline module for S+ devices static const set MAINLINE_FOR_S_PLUS = { TETHERING "map_kernel_bugs", @@ -182,19 +173,14 @@ TEST_F(BpfExistenceTest, TestPrograms) { set mustExist; set mustNotExist; - // We do not actually check the platform P/Q (netd) and Q (clatd) things - // and only verify the mainline module relevant R+ offload maps & progs. + // We only verify the mainline module relevant S+ offload maps & progs. // // The goal of this test is to verify compatibility with the tethering mainline module, // and not to test the platform itself, which may have been modified by vendor or oems, // so we should only test for the removal of stuff that was mainline'd, // and for the presence of mainline stuff. - // Note: Q is no longer supported by mainline - ASSERT_TRUE(isAtLeastR); - - // R can potentially run on pre-4.9 kernel non-eBPF capable devices. - DO_EXPECT(isAtLeastR && !isAtLeastS && isAtLeastKernelVersion(4, 9, 0), PLATFORM_ONLY_IN_R); + ASSERT_TRUE(isAtLeastS); // Q & R are no longer supported by mainline // S requires Linux Kernel 4.9+ and thus requires eBPF support. if (isAtLeastS) ASSERT_TRUE(isAtLeastKernelVersion(4, 9, 0));