Skip to content

Add bpf_getxattr

KP Singh bpf linux-fsdevel linux-security-module 5 versions – In review

Get series with b4
b4 am [email protected]

Versions newest first · linked by author and title

  1. v5 Latest5 patches 30 repliesIn review
  2. v45 patches 5 repliesSuperseded
  3. v35 patches 4 repliesSuperseded
Earlier versions · 2
VersionPostedPatchesRepliesStatus
v25 patches16 repliesSuperseded
v12 patches2 repliesSuperseded

Changes in v5 from the cover letter

- Fixes suggested by Andrii

Patches in v5 No applies recorded yet

#Subject and filesSizeRepliesApplied
1/5btf: Add a new kfunc set which allows to mark a function to be sleepableinclude/linux/btf.h kernel/bpf/btf.c+12 -20 replies
2/5bpf: kfunc support for ARG_PTR_TO_CONST_STRinclude/linux/bpf_verifier.h kernel/bpf/btf.c kernel/bpf/verifier.c+83 -380 replies
3/5bpf: Allow kfuncs to be used in LSM programskernel/bpf/btf.c+1 -00 replies
4/5bpf: Add a bpf_getxattr kfunckernel/trace/bpf_trace.c+42 -03 replies
5/5bpf/selftests: Add a selftest for bpf_getxattrtools/testing/selftests/bpf/prog_tests/xattr.c tools/testing/selftests/bpf/progs/xattr.c+91 -021 replies

Reviews trailers per patch

1 of 5 patches has a Reviewed-by or Acked-by.

PatchKP Singh
1/5A-b
2/5
3/5
4/5
5/5

Trailers given in replies are filled; those carried in the patches from earlier versions are outlined with dashes.

Read the v5 thread

Cover letter [PATCH v5 bpf-next 0/5] Add bpf_getxattr

v4 -> v5

- Fixes suggested by Andrii

v3 -> v4

- Fixed issue incorrect increment of arg counter
- Removed __weak and noinline from kfunc definiton
- Some other minor fixes.

v2 -> v3

- Fixed missing prototype error
- Fixes suggested by other Joanne and Kumar.

v1 -> v2

- Used kfuncs as suggested by Alexei
- Used Benjamin Tissoires' patch from the HID v4 series to add a sleepable kfunc set (I sent the patch as a part of this series as it seems to have been dropped from v5) and acked it. Hope this is okay.
- Added support for verifying string constants to kfuncs

Benjamin Tissoires (1):
btf: Add a new kfunc set which allows to mark a function to be
sleepable

KP Singh (4):
bpf: kfunc support for ARG_PTR_TO_CONST_STR
bpf: Allow kfuncs to be used in LSM programs
bpf: Add a bpf_getxattr kfunc
bpf/selftests: Add a selftest for bpf_getxattr

 include/linux/bpf_verifier.h                  |  2 +
 include/linux/btf.h                           |  2 +
 kernel/bpf/btf.c                              | 43 ++++++++-
 kernel/bpf/verifier.c                         | 89 +++++++++++--------
 kernel/trace/bpf_trace.c                      | 42 +++++++++
 .../testing/selftests/bpf/prog_tests/xattr.c  | 54 +++++++++++
 tools/testing/selftests/bpf/progs/xattr.c     | 37 ++++++++
 7 files changed, 229 insertions(+), 40 deletions(-)
 create mode 100644 tools/testing/selftests/bpf/prog_tests/xattr.c
 create mode 100644 tools/testing/selftests/bpf/progs/xattr.c
Signature · 1 line
2.37.0.rc0.161.g10f37bed90-goog