Commit 2d369b4b authored by Ilya Leoshkevich's avatar Ilya Leoshkevich Committed by Daniel Borkmann

libbpf: Extend BPF_KSYSCALL documentation

Explicitly list known quirks. Mention that socket-related syscalls can be
invoked via socketcall().
Signed-off-by: default avatarIlya Leoshkevich <iii@linux.ibm.com>
Signed-off-by: default avatarDaniel Borkmann <daniel@iogearbox.net>
Acked-by: default avatarJiri Olsa <jolsa@kernel.org>
Link: https://lore.kernel.org/bpf/20220726134008.256968-2-iii@linux.ibm.com
parent bd82ea52
...@@ -523,10 +523,17 @@ static __always_inline typeof(name(0)) ____##name(struct pt_regs *ctx, ##args) ...@@ -523,10 +523,17 @@ static __always_inline typeof(name(0)) ____##name(struct pt_regs *ctx, ##args)
* Original struct pt_regs * context is preserved as 'ctx' argument. This might * Original struct pt_regs * context is preserved as 'ctx' argument. This might
* be necessary when using BPF helpers like bpf_perf_event_output(). * be necessary when using BPF helpers like bpf_perf_event_output().
* *
* At the moment BPF_KSYSCALL does not handle all the calling convention * At the moment BPF_KSYSCALL does not transparently handle all the calling
* quirks for mmap(), clone() and compat syscalls transparrently. This may or * convention quirks for the following syscalls:
* may not change in the future. User needs to take extra measures to handle *
* such quirks explicitly, if necessary. * - mmap(): __ARCH_WANT_SYS_OLD_MMAP.
* - clone(): CONFIG_CLONE_BACKWARDS, CONFIG_CLONE_BACKWARDS2 and
* CONFIG_CLONE_BACKWARDS3.
* - socket-related syscalls: __ARCH_WANT_SYS_SOCKETCALL.
* - compat syscalls.
*
* This may or may not change in the future. User needs to take extra measures
* to handle such quirks explicitly, if necessary.
* *
* This macro relies on BPF CO-RE support and virtual __kconfig externs. * This macro relies on BPF CO-RE support and virtual __kconfig externs.
*/ */
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment