summaryrefslogtreecommitdiff
path: root/scripts/Makefile.thinlto
diff options
context:
space:
mode:
authorTejun Heo <tj@kernel.org>2026-08-19 19:20:21 -1000
committerKumar Kartikeya Dwivedi <memxor@gmail.com>2026-08-20 19:07:53 +0200
commitaed1bf1a352acd4f5ffd2a81e23d2bb6e8e9b636 (patch)
tree69e62fa768584f082f205d2665a295f871dd362c /scripts/Makefile.thinlto
parent91ec2035134982b98fab0609a9fd8480e8217dc1 (diff)
downloadlinux-next-aed1bf1a352acd4f5ffd2a81e23d2bb6e8e9b636.tar.gz
linux-next-aed1bf1a352acd4f5ffd2a81e23d2bb6e8e9b636.zip
bpf: sched_ext: Mark ops argument container pointer fields as trusted
Walking an unannotated pointer field of a trusted struct yields a bare PTR_TO_BTF_ID in non-sleepable programs, which kfuncs and helpers accept, but PTR_UNTRUSTED in sleepable programs, which they reject. This gets in the way of making ops.init_task() sleepable, which schedulers want for allocations. For example, passing args->cgroup into bpf_cgrp_storage_get() then fails verification and the only recourse is round-tripping through the cgroup ID with bpf_cgroup_from_id(). The pointer fields in the sched_ext ops argument containers are all pinned by the callers for the duration of the ops calls and are never NULL. Add them to the verifier's trusted-fields whitelist so that they are PTR_TRUSTED in both sleepable and non-sleepable programs. Fixes: 8195136669661 ("sched_ext: Add cgroup support") Signed-off-by: Tejun Heo <tj@kernel.org> Acked-by: Kumar Kartikeya Dwivedi <memxor@gmail.com> Link: https://lore.kernel.org/bpf/95d7ccc17681aa3a4a2eeb1b073f00f7@kernel.org Signed-off-by: Kumar Kartikeya Dwivedi <memxor@gmail.com>
Diffstat (limited to 'scripts/Makefile.thinlto')
0 files changed, 0 insertions, 0 deletions