android_kernel_xiaomi_sm8450/tools
Andrii Nakryiko 641b7a8920 libbpf: Fix no-args func prototype BTF dumping syntax
[ Upstream commit 189f1a976e426011e6a5588f1d3ceedf71fe2965 ]

For all these years libbpf's BTF dumper has been emitting not strictly
valid syntax for function prototypes that have no input arguments.

Instead of `int (*blah)()` we should emit `int (*blah)(void)`.

This is not normally a problem, but it manifests when we get kfuncs in
vmlinux.h that have no input arguments. Due to compiler internal
specifics, we get no BTF information for such kfuncs, if they are not
declared with proper `(void)`.

The fix is trivial. We also need to adjust a few ancient tests that
happily assumed `()` is correct.

Fixes: 351131b51c ("libbpf: add btf_dump API for BTF-to-C conversion")
Reported-by: Tejun Heo <tj@kernel.org>
Signed-off-by: Andrii Nakryiko <andrii@kernel.org>
Signed-off-by: Daniel Borkmann <daniel@iogearbox.net>
Acked-by: Stanislav Fomichev <sdf@fomichev.me>
Link: https://lore.kernel.org/bpf/20240712224442.282823-1-andrii@kernel.org
Signed-off-by: Sasha Levin <sashal@kernel.org>
2024-08-19 05:41:03 +02:00
..
accounting
arch x86/insn: Fix PUSH instruction in x86 instruction decoder opcode map 2024-06-16 13:32:13 +02:00
bootconfig bootconfig: Fix testcase to increase max node 2023-04-05 11:23:34 +02:00
bpf bpf: Fix potential integer overflow in resolve_btfids 2024-06-16 13:32:28 +02:00
build tools build: Switch to new openssl API for test-libcrypto 2022-08-25 11:38:01 +02:00
cgroup tools/cgroup/slabinfo.py: updated to work on current kernel 2021-05-07 11:04:31 +02:00
debugging
edid
firewire
firmware
gpio tools: gpio: fix debounce_period_us output of lsgpio 2023-06-21 15:45:35 +02:00
hv vmbus_testing: fix wrong python syntax for integer value comparison 2023-09-19 12:20:05 +02:00
iio tools: iio: replace seekdir() in iio_generic_buffer 2024-04-13 12:59:51 +02:00
include hugetlb_encode.h: fix undefined behaviour (34 << 26) 2024-07-05 09:12:32 +02:00
io_uring tools/io_uring: fix compile breakage 2020-09-21 07:50:58 -06:00
kvm/kvm_stat tools/kvm_stat: fix display of error when multiple processes are found 2022-08-11 13:06:45 +02:00
laptop
leds
lib libbpf: Fix no-args func prototype BTF dumping syntax 2024-08-19 05:41:03 +02:00
memory-model tools/memory-model: Fix bug in lock.cat 2024-08-19 05:40:58 +02:00
objtool exit: Rename module_put_and_exit to module_put_and_kthread_exit 2024-06-21 14:53:29 +02:00
pci
pcmcia
perf perf report: Fix condition in sort__sym_cmp() 2024-08-19 05:40:49 +02:00
power tools/power turbostat: Fix Bzy_MHz documentation typo 2024-05-17 11:48:04 +02:00
scripts tools: Allow proper CC/CXX/... override with LLVM=1 in Makefile.include 2021-07-31 08:16:10 +02:00
spi spi: tools: Make default_tx/rx and input_tx static 2020-06-11 16:27:24 +01:00
testing libbpf: Fix no-args func prototype BTF dumping syntax 2024-08-19 05:41:03 +02:00
thermal/tmon tools/thermal: Fix possible path truncations 2022-08-21 15:16:12 +02:00
time
usb usb: testusb: Fix for showing the connection speed 2021-10-09 14:40:56 +02:00
virtio tools/virtio: fix the vringh test for virtio ring changes 2023-02-22 12:55:53 +01:00
vm tools/vm/slabinfo-gnuplot: use "grep -E" instead of "egrep" 2022-12-08 11:23:57 +01:00
wmi
Makefile bpf: Compile resolve_btfids tool at kernel compilation start 2020-07-13 10:42:02 -07:00