diff options
author | alexlzhu <alexlzhu@fb.com> | 2021-08-19 01:01:05 +0200 |
---|---|---|
committer | Lennart Poettering <lennart@poettering.net> | 2021-10-12 12:48:23 +0200 |
commit | 76dc17254f7c78eae2dec2b9b1cfb60657a7b6e7 (patch) | |
tree | eaf61330174b3b5b5647cd11ec6951f5d1609220 /src/test/test-bpf-foreign-programs.c | |
parent | network: dhcp6-pd: also assign addresses in IA_PD prefixes on uplink interface (diff) | |
download | systemd-76dc17254f7c78eae2dec2b9b1cfb60657a7b6e7.tar.xz systemd-76dc17254f7c78eae2dec2b9b1cfb60657a7b6e7.zip |
core: remove refcount for bpf program
Currently ref count of bpf-program is kept in user space. However, the
kernel already implements its own ref count. Thus the ref count we keep for
bpf-program is redundant.
This PR removes ref count for bpf program as part of a task to simplify
bpf-program and remove redundancies, which will make the switch to
code-compiled BPF programs easier.
Part of #19270
Diffstat (limited to '')
-rw-r--r-- | src/test/test-bpf-foreign-programs.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/test/test-bpf-foreign-programs.c b/src/test/test-bpf-foreign-programs.c index 86e05e23ab..1765dc7a9b 100644 --- a/src/test/test-bpf-foreign-programs.c +++ b/src/test/test-bpf-foreign-programs.c @@ -155,7 +155,7 @@ static int pin_programs(Unit *u, CGroupContext *cc, const Test *test_suite, size assert_se(paths_ret); for (size_t i = 0; i < test_suite_size; i++) { - _cleanup_(bpf_program_unrefp) BPFProgram *prog = NULL; + _cleanup_(bpf_program_freep) BPFProgram *prog = NULL; _cleanup_free_ char *str = NULL; r = bpf_foreign_test_to_string(test_suite[i].attach_type, test_suite[i].bpffs_path, &str); |