diff options
author | Hou Tao <houtao1@huawei.com> | 2025-05-26 14:25:34 +0800 |
---|---|---|
committer | Alexei Starovoitov <ast@kernel.org> | 2025-05-27 10:45:59 -0700 |
commit | d4965578267e2e81f67c86e2608481e77e9c8569 (patch) | |
tree | 8e2808bbfe81b419d6fc5f3b63b3fd88b8af55e9 /scripts/lib/kdoc/kdoc_re.py | |
parent | 86bc9c742426a16b52a10ef61f5b721aecca2344 (diff) |
bpf: Check rcu_read_lock_trace_held() in bpf_map_lookup_percpu_elem()
bpf_map_lookup_percpu_elem() helper is also available for sleepable bpf
program. When BPF JIT is disabled or under 32-bit host,
bpf_map_lookup_percpu_elem() will not be inlined. Using it in a
sleepable bpf program will trigger the warning in
bpf_map_lookup_percpu_elem(), because the bpf program only holds
rcu_read_lock_trace lock. Therefore, add the missed check.
Reported-by: syzbot+dce5aae19ae4d6399986@syzkaller.appspotmail.com
Closes: https://lore.kernel.org/bpf/000000000000176a130617420310@google.com/
Signed-off-by: Hou Tao <houtao1@huawei.com>
Link: https://lore.kernel.org/r/20250526062534.1105938-1-houtao@huaweicloud.com
Signed-off-by: Alexei Starovoitov <ast@kernel.org>
Diffstat (limited to 'scripts/lib/kdoc/kdoc_re.py')
0 files changed, 0 insertions, 0 deletions