* [PATCH] cred: remove RCU initializer for init_task.cred
@ 2026-08-12 14:51 Jann Horn
2026-08-12 15:48 ` Paul Moore
0 siblings, 1 reply; 2+ messages in thread
From: Jann Horn @ 2026-08-12 14:51 UTC (permalink / raw)
To: Paul Moore
Cc: Serge E. Hallyn, linux-security-module, linux-kernel,
kernel test robot, Jann Horn
sparse noticed that an RCU initializer was left behind for init_task.cred,
which is no longer marked __rcu. Fix it up.
Fixes: a4229a2a16a8 ("cred: clarify that task_struct::cred is only for the current task")
Reported-by: kernel test robot <lkp@intel.com>
Closes: https://lore.kernel.org/oe-kbuild-all/202608121153.nzs6HZg7-lkp@intel.com/
Signed-off-by: Jann Horn <jannh@google.com>
---
maybe squash this into the original commit, if that is a thing you do on
the dev-staging branch?
---
init/init_task.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/init/init_task.c b/init/init_task.c
index b67ef6040a65..6529b002135b 100644
--- a/init/init_task.c
+++ b/init/init_task.c
@@ -159,7 +159,7 @@ struct task_struct init_task __aligned(L1_CACHE_BYTES) = {
.sibling = LIST_HEAD_INIT(init_task.sibling),
.group_leader = &init_task,
RCU_POINTER_INITIALIZER(real_cred, &init_cred),
- RCU_POINTER_INITIALIZER(cred, &init_cred),
+ .cred = &init_cred,
.comm = INIT_TASK_COMM,
.thread = INIT_THREAD,
.fs = &init_fs,
---
base-commit: 1f2f7a1fd1fc34e757107e3a3849f8d22b14cc6b
change-id: 20260812-task-cred-fixup-2e5c5dbe6a3b
Best regards,
--
Jann Horn <jannh@google.com>
^ permalink raw reply related [flat|nested] 2+ messages in thread* Re: [PATCH] cred: remove RCU initializer for init_task.cred
2026-08-12 14:51 [PATCH] cred: remove RCU initializer for init_task.cred Jann Horn
@ 2026-08-12 15:48 ` Paul Moore
0 siblings, 0 replies; 2+ messages in thread
From: Paul Moore @ 2026-08-12 15:48 UTC (permalink / raw)
To: Jann Horn
Cc: Serge E. Hallyn, linux-security-module, linux-kernel,
kernel test robot
On Wed, Aug 12, 2026 at 10:51 AM Jann Horn <jannh@google.com> wrote:
>
> sparse noticed that an RCU initializer was left behind for init_task.cred,
> which is no longer marked __rcu. Fix it up.
>
> Fixes: a4229a2a16a8 ("cred: clarify that task_struct::cred is only for the current task")
> Reported-by: kernel test robot <lkp@intel.com>
> Closes: https://lore.kernel.org/oe-kbuild-all/202608121153.nzs6HZg7-lkp@intel.com/
> Signed-off-by: Jann Horn <jannh@google.com>
> ---
> maybe squash this into the original commit, if that is a thing you do on
> the dev-staging branch?
Yep, I'll go ahead and do that. The lsm/dev-staging branch isn't a
stable/reliable branch like some of the others, it can change
frequently; see the doc below if you are interested.
https://github.com/LinuxSecurityModule/kernel/blob/main/README.md#dev-staging-branch
--
paul-moore.com
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2026-08-12 15:48 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2026-08-12 14:51 [PATCH] cred: remove RCU initializer for init_task.cred Jann Horn
2026-08-12 15:48 ` Paul Moore
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox