summaryrefslogtreecommitdiff
path: root/include/linux/mmap_lock.h
diff options
context:
space:
mode:
authorJean-Philippe Brucker <jean-philippe@linaro.org>2021-09-06 17:36:38 +0100
committerDaniel Borkmann <daniel@iogearbox.net>2021-09-07 17:23:19 +0200
commit3a029e1f3d6e2ee809e85abecce619a48016bd4b (patch)
tree148c398b99ac7f954aa7a3b19bc402e9e48c1424 /include/linux/mmap_lock.h
parent49ca6153208f6efc409c1deb82dd5bcbb519d7e1 (diff)
selftests/bpf: Fix build of task_pt_regs test for arm64
struct pt_regs is not exported to userspace on all archs. arm64 and s390 export "user_pt_regs" instead, which causes build failure at the moment: progs/test_task_pt_regs.c:8:16: error: variable has incomplete type 'struct pt_regs' struct pt_regs current_regs = {}; Instead of using pt_regs from ptrace.h, use the larger kernel struct from vmlinux.h directly. Since the test runner task_pt_regs.c does not have access to the kernel struct definition, copy it into a char array. Fixes: 576d47bb1a92 ("bpf: selftests: Add bpf_task_pt_regs() selftest") Suggested-by: Andrii Nakryiko <andrii.nakryiko@gmail.com> Signed-off-by: Jean-Philippe Brucker <jean-philippe@linaro.org> Signed-off-by: Daniel Borkmann <daniel@iogearbox.net> Tested-by: Ilya Leoshkevich <iii@linux.ibm.com> Acked-by: Ilya Leoshkevich <iii@linux.ibm.com> Link: https://lore.kernel.org/bpf/20210906163635.302307-1-jean-philippe@linaro.org
Diffstat (limited to 'include/linux/mmap_lock.h')
0 files changed, 0 insertions, 0 deletions