android_packages_modules_Co.../bpf_progs
Repository files (latest commit first)
Filename Latest commit message Latest commit date
Lorenzo Colitti 60cbed385d Support more than 8 firewall chains / match types.
In the BPF code, per-UID network access (e.g., for doze mode,
standby, etc.) is stored in UidOwnerValue structures. Each of
these stores that UID's rules in a 32-bit bitmask of
UidOwnerMatchType values, so the code can support ~31 match
types.

However, which match types are enabled is stored in
configuration_map at index UID_RULES_CONFIGURATION_KEY, and
configuration_map only stores 8-bit values. So it's not
possible to define more than 7 match types.

Widen configuration_map to from 8 to 32 bits to match the width
of UidOwnerValue.rule. This doesn't impact memory because
configuration_map only has 2 entries.

Bug: 208371987
Test: TreeHugger
Signed-off-by: Maciej Żenczykowski <maze@google.com>
Change-Id: I7e1eee2daedd66d27965a2dd4ce6b4c3667892f7
2022-05-31 09:59:11 +00:00
..
Android.bp move netd maps and progs into /sys/fs/bpf/netd_shared/... 2022-05-16 23:24:37 +00:00
block.c bpf programs: switch from integers to #define'd bpfloader versions 2022-05-24 16:11:09 -07:00
bpf_net_helpers.h rename try_make_readable() to try_make_writable() 2022-04-11 23:58:36 -07:00
bpf_shared.h Support more than 8 firewall chains / match types. 2022-05-31 09:59:11 +00:00
bpf_tethering.h remove unused #defines 2022-05-03 06:14:34 +00:00
clatd.c bpf programs: switch from integers to #define'd bpfloader versions 2022-05-24 16:11:09 -07:00
dscp_policy.c bpf programs: switch from integers to #define'd bpfloader versions 2022-05-24 16:11:09 -07:00
dscp_policy.h dscp_policy - use a more efficient v6_equal() 2022-05-18 09:05:32 +00:00
netd.c Support more than 8 firewall chains / match types. 2022-05-31 09:59:11 +00:00
offload.c bpf programs: switch from integers to #define'd bpfloader versions 2022-05-24 16:11:09 -07:00
test.c bpf programs: switch from integers to #define'd bpfloader versions 2022-05-24 16:11:09 -07:00