From mboxrd@z Thu Jan 1 00:00:00 1970 Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.remote-ip=100.103.45.18 ARC-Seal: i=1; d=subspace.kernel.org; s=arc20261015; a=rsa-sha256; cv=none; t=1796478847; b=Tik7yYxWEYwoGjKg0B5k83MCHmxRKUuaiM4kqRWBF4CdCXgDQtN0o/MqiFBuQbxYziCp ghd5oGU9ZaGt8RRs7jf7aCmRUWDHCOuLM3NubiRoUF+uUbxO8nXcvWEmQ/ZcULqorO1V1 sLRDlFzOhz98upNCsuib2ZTFnMiHcuGk6l1n+eD/kZA6zK/H5k3+E/IL5oCCDYrefnnNs /5HlWDwRQpFBD58ihu/8W8iPevhC8PP5VXdehRU6pPsHpDX4z6Kp/C7BMQaIRFQixxVTD BMiur0Pda1Sx2b4b7FuxB0vdj+z2Yr3/OcQBTxDE0R5xPXTc2arN8UPvanY7Ksz7Pzg== ARC-Message-Signature: i=1; d=subspace.kernel.org; s=arc20261015; a=rsa-sha256; c=relaxed/relaxed; t=1796478847; h=Received:DKIM-Signature:Content-Type:MIME-Version:Message-Id: In-Reply-To:References:Subject:From:To:Cc:Date; bh=3nO/dTluVIQfSBrR/nGXeWjmC+iRK/IoARcd2lKkCj0=; b=nnot2myZgC5wkql3/WhLyYPWvoJynzsTJhLEk6/K4zhsqK69csGXx2xzZsI+Zwrc/QsP F96cnWy4Zg1N25hv3vbCAyqfPCh3hwTHoQoG7WSIyFVRqEfjgX7ydTYImQxiC8spp+BMj QJPKt0TcRiVLW3KNOe81AyQG84OKzKXd/EF4Np2gn+6GHpGy1tFzfZLM1oYsOT2G3zZdW 9AkhlCio/jAAK7Ms6woDi0jW+HFNydwa2V9oW+/GT8GB2pi0pu9BX6haIhOA/bnIRYpDr ZcnbuExVjOlpTb4GSjhf+Ah/zwVQBRXLZZBbCoiQi/ZWup8BdS2qI7N8wZNqeNXH04w== ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dkim=pass header.d=kernel.org header.i=@kernel.org header.a=rsa-sha256 header.s=k20260515 header.b=RWePX7co; arc=none smtp.remote-ip=100.103.45.18 Received: from smtp.kernel.org (quasi.space.kernel.org [100.103.45.18]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (prime256v1)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id E5CC4606A330; Sat, 5 Dec 2026 13:54:06 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.a=rsa-sha256 header.s=k20260515 header.b=RWePX7co Received: by smtp.kernel.org (Postfix) with ESMTPSA id 898781F00936; Sat, 5 Dec 2026 13:54:03 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=kernel.org; s=k20260515; t=1796478846; bh=3nO/dTluVIQfSBrR/nGXeWjmC+iRK/IoARcd2lKkCj0=; h=In-Reply-To:References:Subject:From:To:Cc:Date; b=RWePX7colpvXmZ9saDlFVta77mW+6qRj0bg0fQYcajq6U3+arqCfSUE5T1E4MBYRH KOlewgjWsQRLvxmq22vUOhqgqwQ25PtIHUHDufcdfdqU9ejzgYS64YQzI9cWqh4huW wQkt/ld1wb7F0X2+FsQ185+nrRsNDpMif0IOeYT1Ng8/LQKHqxCFRzlOrByJ9PW6YX thWt8ihq3Ss+Y48IcEVcfGcJ8X/Srk6XEn6c03Q3IZsui6p7y3kuAkutAvfCasVWTX naXXHctNBV3q1oqU0/Rf916SroQukJdC+P/+gTqIqECCGxlnwVdy5z7wpfD30Mdmch rqKC5vbkuP85w== Content-Type: multipart/mixed; boundary="===============3395755289360396789==" X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Post: List-Help: List-Subscribe: List-Unsubscribe: List-Owner: Precedence: list MIME-Version: 1.0 Message-Id: In-Reply-To: <20261204233428.14861-9-mason@kernel.org> References: <20261204233428.14861-9-mason@kernel.org> Subject: Re: [RFC PATCH v2 8/8] signal: move group_leader into signal_struct From: bot+bpf-ci@kernel.org To: mason@kernel.org,brauner@kernel.org,oleg@redhat.com,ast@kernel.org,daniel@iogearbox.net,andrii@kernel.org,bpf@vger.kernel.org,linux-kernel@vger.kernel.org Cc: akpm@linux-foundation.org,peterz@infradead.org,mingo@redhat.com,kees@kernel.org,viro@zeniv.linux.org.uk,jack@suse.cz,tj@kernel.org,hannes@cmpxchg.org,mkoutny@suse.com,bsingharora@gmail.com,eddyz87@gmail.com,memxor@gmail.com,yonghong.song@linux.dev,martin.lau@linux.dev,song@kernel.org,jolsa@kernel.org,emil@etsalapatis.com,ihor.solodrai@linux.dev,sched-ext@lists.linux.dev,cgroups@vger.kernel.org,linux-fsdevel@vger.kernel.org,linux-mm@kvack.org,mason@kernel.org,ast@kernel.org,andrii@kernel.org,daniel@iogearbox.net,martin.lau@kernel.org,eddyz87@gmail.com,yonghong.song@linux.dev,mason@kernel.org,ihor.solodrai@linux.dev Date: Sat, 5 Dec 2026 13:54:03 +0000 (UTC) --===============3395755289360396789== Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit > signal: move group_leader into signal_struct TL;DR: Removing task_struct::group_leader may break the verifier_arena_cast selftest, which still reads it via CO-RE. The load may fail and the "arena cast" subtest may then fail. Unverified; it likely needs converting like the other selftests. > diff --git a/include/linux/sched.h b/include/linux/sched.h > index 691a1e322985..123877b74262 100644 > --- a/include/linux/sched.h > +++ b/include/linux/sched.h > @@ -1104,7 +1104,6 @@ struct task_struct { > */ > struct list_head children; > struct list_head sibling; > - struct task_struct *group_leader; > > /* This removes task_struct::group_leader, but tools/testing/selftests/bpf/progs/verifier_arena_cast.c still reads it through its own preserve_access_index definition of struct task_struct: struct task_struct { struct task_struct *group_leader; void *stack; } __attribute__((preserve_access_index)); ... int untrusted_btf_id(void *ctx) { CAST_R6(bpf_get_current_task_btf()->group_leader); return 0; } Because the local struct is used, the file still compiles. At load time, though, can libbpf resolve the CO-RE relocation for task_struct.group_leader against a vmlinux BTF that no longer has the field? If it can't, the load instruction is poisoned and the verifier rejects untrusted_btf_id(), which is annotated __success with __msg("R6=untrusted_ptr_task_struct()"). Won't "test_progs -t verifier_arena_cast" then fail for the "arena cast: an untrusted pointer to task_struct, it's a move" subtest? This was the only remaining group_leader reference under tools/testing/selftests/, and none of the later patches in the series converts it. Should it get the same conversion as the other selftests, for example bpf_get_current_task_btf()->signal->group_leader with a matching local struct signal_struct? Alternatively, another task_struct pointer field that the verifier treats as untrusted, such as real_parent read outside an RCU section, would also satisfy the test. --- AI reviewed your patch. Please fix the bug or email reply why it's not a bug. See: https://github.com/kernel-patches/vmtest/blob/master/ci/claude/README.md CI run summary: https://github.com/kernel-patches/bpf/actions/runs/47525108594 --===============3395755289360396789==--