Commit graph android_system_bpf/loader/BpfLoadTest.cpp
Message SHA1
BpfLoadTest: change some EXPECT's to ASSERT's
This should hopefully cause test failures to be clean test failures instead of hitting abort() and bringing down the entire test framework.

Test: TreeHugger
Bug: 366103938
Signed-off-by: Maciej Żenczykowski <maze@google.com>
Change-Id: I26b78c904102e581e2d1e7b259a80dd0a6f3e50e

Maciej Żenczykowski   commited 2024-09-17 00:04:20 +00:00
f381ae9268
deparametrize BpfLoadTest
as this is no longer needed, since everything now
runs with the default of 'btf: true' (with the exception
of the 2 mainline .o's still shipped to Android S)

Test: TreeHugger, atest libbpf_load_test
Signed-off-by: Maciej Żenczykowski <maze@google.com>
Change-Id: I91bdfea5b13367ce00a29f942af504eeef8db9cc

Maciej Żenczykowski   commited 2024-08-02 11:05:19 -07:00
fee8f17fe0
BpfLoadTest: Set rlimit memlock for old kernels
BpfLoadTest was failing on android13-5.10 kernels due to the rlimit
memlock not being configured large enough for the test process. Add the
necessary call to set rlimit memlock for pre-5.11 kernels.

5.11 kernels introduced cgroup-based memory accounting for bpf as
discussed at https://lore.kernel.org/bpf/20201201215900.3569844-1-guro@fb.com/

Flag: n/a
Test: atest libbpf_load_test
Bug: 326156952

Change-Id: I8eda9fe6cee099b1fd979720a4e94d685a571943
Signed-off-by: Neill Kapron <nkapron@google.com>

Neill Kapron   commited 2024-04-09 17:22:02 +00:00
bc4ae410ff
Platform BpfLoader: remove support for per-map/prog dir & selinux context
For platform bpf .o files per-map/prog selinux context can simply
be added by genfscon selinux policy modifications.

(while per-map/prog pin dir really only exists to support the selinux context)

Test: TreeHugger
  Both before and after this patch 'adb shell find /sys/fs/bpf | wc -l' returns 103
Signed-off-by: Maciej Żenczykowski <maze@google.com>
Change-Id: Ic700db2870c16a04c9498e529519051a672a28c8

Maciej Żenczykowski   commited 2024-03-11 04:01:07 +00:00
c1647d764f
move libbpf_android into loader subdirectory
The only (real) user is the platform bpfloader binary.
This is a library purely to facilitate testing.

It's easier to develop / code-search if everything is in the same directory.

Test: TreeHugger
Signed-off-by: Maciej Żenczykowski <maze@google.com>
Change-Id: Iebe8a5c4f8bb9ada220acec6ed8c1be0fc9d438c

Maciej Żenczykowski   commited 2024-03-11 04:00:13 +00:00
5c412c6c0e
Renamed from libbpf_android/BpfLoadTest.cpp (Browse further)