diff options
| author | Alexei Starovoitov <ast@kernel.org> | 2026-09-04 07:58:36 -0700 |
|---|---|---|
| committer | Alexei Starovoitov <ast@kernel.org> | 2026-09-04 07:58:37 -0700 |
| commit | 41e6f03658adfa9df68642750b53a046f1abdea9 (patch) | |
| tree | ec8406fa98b9cc67556f8bfd4f637a2612600ec9 /include/linux/bpf_verifier.h | |
| parent | 6b31560c6bc1a8a7a70792c7b3ca4c1ea322063b (diff) | |
| parent | 9492baf8532ca285c58b82a269acd7a57e205ae9 (diff) | |
| download | linux-next-41e6f03658adfa9df68642750b53a046f1abdea9.tar.gz linux-next-41e6f03658adfa9df68642750b53a046f1abdea9.zip | |
Merge branch 'misc-bug-fixes-part-3'
Kumar Kartikeya Dwivedi says:
====================
Misc bug fixes - part 3
A set of miscellaneous fixes for bugs reported by Nicholas, batched
together again. See commit logs for details. Some of this was caught and
posted by Ning before, but AI raised some concerns, so I'm resolving
those issues and commandeering their patches now.
Changelog:
----------
v1 -> v2
v1: https://lore.kernel.org/bpf/20260904063650.3877826-1-memxor@gmail.com
* Fix GCC-BPF failure due to missed BTF emission for a type.
====================
Link: https://patch.msgid.link/20260904084325.52250-1-memxor@gmail.com
Signed-off-by: Alexei Starovoitov <ast@kernel.org>
Diffstat (limited to 'include/linux/bpf_verifier.h')
| -rw-r--r-- | include/linux/bpf_verifier.h | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/include/linux/bpf_verifier.h b/include/linux/bpf_verifier.h index 1339c2f028db..36b65797877d 100644 --- a/include/linux/bpf_verifier.h +++ b/include/linux/bpf_verifier.h @@ -1381,7 +1381,9 @@ static inline bool bpf_type_has_unsafe_modifiers(u32 type) static inline bool type_is_ptr_alloc_obj(u32 type) { - return base_type(type) == PTR_TO_BTF_ID && type_flag(type) & MEM_ALLOC; + return base_type(type) == PTR_TO_BTF_ID && + type_flag(type) & MEM_ALLOC && + !(type_flag(type) & PTR_UNTRUSTED); } static inline bool type_is_non_owning_ref(u32 type) |
