aboutsummaryrefslogtreecommitdiff
path: root/scripts/clang-tools/gen_compile_commands.py
diff options
context:
space:
mode:
authorKumar Kartikeya Dwivedi <[email protected]>2022-06-15 09:51:51 +0530
committerDaniel Borkmann <[email protected]>2022-06-15 19:32:12 +0200
commitd1a374a1aeb7e31191448e225ed2f9c5e894f280 (patch)
treeb585239a187d9415698d6841b05a1b8263a36153 /scripts/clang-tools/gen_compile_commands.py
parent3046a827316c0e55fc563b4fb78c93b9ca5c7c37 (diff)
bpf: Limit maximum modifier chain length in btf_check_type_tags
On processing a module BTF of module built for an older kernel, we might sometimes find that some type points to itself forming a loop. If such a type is a modifier, btf_check_type_tags's while loop following modifier chain will be caught in an infinite loop. Fix this by defining a maximum chain length and bailing out if we spin any longer than that. Fixes: eb596b090558 ("bpf: Ensure type tags precede modifiers in BTF") Reported-by: Daniel Borkmann <[email protected]> Signed-off-by: Kumar Kartikeya Dwivedi <[email protected]> Signed-off-by: Daniel Borkmann <[email protected]> Acked-by: Yonghong Song <[email protected]> Link: https://lore.kernel.org/bpf/[email protected]
Diffstat (limited to 'scripts/clang-tools/gen_compile_commands.py')
0 files changed, 0 insertions, 0 deletions