libbpf: add bpf_core_cast() helper
Status from this message: This series was applied to bpf/bpf-next.git (master)
Get series with b4
b4 am [email protected]Versions newest first
Patches in v1 All 2 applied
| # | Subject and files | Size | Replies | Applied |
|---|---|---|---|---|
| 1/2 | libbpf: add bpf_core_cast() macrotools/ tools/ tools/ +1 more | +15 | 0 replies | Applied |
| 2/2 | selftests/bpf: convert bpf_rdonly_cast() uses to bpf_core_cast() macrotools/ tools/ tools/ +5 more | +12 | 0 replies | Applied |
Reviews trailers per patch
1 of 2 patches has a Reviewed-by or Acked-by.
| Patch | Eduard Zingerman |
|---|---|
| 1/2 | A-b |
| 2/2 |
Trailers given in replies are filled; those carried in the patches from earlier versions are outlined with dashes.
Cover letter [PATCH bpf-next 0/2] libbpf: add bpf_core_cast() helper
Add bpf_core_cast(<ptr>, <type>) macro wrapper around bpf_rdonly_cast() kfunc to make it easier to use this functionality in BPF code. See patch #2 for BPF selftests conversions demonstrating improvements in code succinctness.
Andrii Nakryiko (2):
libbpf: add bpf_core_cast() macro
selftests/bpf: convert bpf_rdonly_cast() uses to bpf_core_cast() macro
tools/lib/bpf/bpf_core_read.h | 13 +++++++++++++ tools/testing/selftests/bpf/bpf_kfuncs.h | 2 +- .../testing/selftests/bpf/progs/connect_unix_prog.c | 3 +-- .../selftests/bpf/progs/getpeername_unix_prog.c | 3 +-- .../selftests/bpf/progs/getsockname_unix_prog.c | 3 +-- .../testing/selftests/bpf/progs/recvmsg_unix_prog.c | 3 +-- .../testing/selftests/bpf/progs/sendmsg_unix_prog.c | 3 +-- .../selftests/bpf/progs/sk_storage_omem_uncharge.c | 4 +--- tools/testing/selftests/bpf/progs/sock_iter_batch.c | 4 ++-- tools/testing/selftests/bpf/progs/type_cast.c | 13 +++++-------- 10 files changed, 27 insertions(+), 24 deletions(-)
Signature · 1 line
2.34.1