aboutsummaryrefslogtreecommitdiff
path: root/tools/testing/selftests/bpf/prog_tests/autoload.c
diff options
context:
space:
mode:
authorMiklos Szeredi <[email protected]>2023-10-25 16:02:02 +0200
committerChristian Brauner <[email protected]>2023-12-11 19:11:02 +0100
commit46eae99ef73302f9fb3dddcd67c374b3dffe8fd6 (patch)
tree03dd787e3f3f2e9341a3471097e66cb195643fdf /tools/testing/selftests/bpf/prog_tests/autoload.c
parent56c94c626785001dbb683312725b7d87c6ec6a91 (diff)
add statmount(2) syscall
Add a way to query attributes of a single mount instead of having to parse the complete /proc/$PID/mountinfo, which might be huge. Lookup the mount the new 64bit mount ID. If a mount needs to be queried based on path, then statx(2) can be used to first query the mount ID belonging to the path. Design is based on a suggestion by Linus: "So I'd suggest something that is very much like "statfsat()", which gets a buffer and a length, and returns an extended "struct statfs" *AND* just a string description at the end." The interface closely mimics that of statx. Handle ASCII attributes by appending after the end of the structure (as per above suggestion). Pointers to strings are stored in u64 members to make the structure the same regardless of pointer size. Strings are nul terminated. Link: https://lore.kernel.org/all/CAHk-=wh5YifP7hzKSbwJj94+DZ2czjrZsczy6GBimiogZws=rg@mail.gmail.com/ Signed-off-by: Miklos Szeredi <[email protected]> Link: https://lore.kernel.org/r/[email protected] Reviewed-by: Ian Kent <[email protected]> [Christian Brauner <[email protected]>: various minor changes] Signed-off-by: Christian Brauner <[email protected]>
Diffstat (limited to 'tools/testing/selftests/bpf/prog_tests/autoload.c')
0 files changed, 0 insertions, 0 deletions