Re: ~90s reboot delay with v6.19 and PREEMPT_RT

From: Bert Karwatzki

Date: Fri Feb 27 2026 - 17:58:41 EST


Am Freitag, dem 27.02.2026 um 15:13 +0100 schrieb Sebastian Andrzej Siewior:
> On 2026-02-25 23:31:36 [+0100], To Bert Karwatzki wrote:
>
> > Until the sched_switch, everything is the same. But then systemd-1828
> > (the one with the cgroup_notify_populated event) seems to get impatient
> > and sends a SIGTERM+SIGCONT. It gets the exit code, the
> > cgroup_notify_populated event is there later and just once. The
> > app.slice notify is missing. And the rmdir gets in much later.
>
>
> I so proud of myself. Bert, can you confirm that this works?
>
> --- a/kernel/cgroup/cgroup.c
> +++ b/kernel/cgroup/cgroup.c
> @@ -5283,6 +5283,11 @@ static void *cgroup_procs_start(struct seq_file *s, loff_t *pos)
>
> static int cgroup_procs_show(struct seq_file *s, void *v)
> {
> + struct task_struct *tsk = v;
> +
> + if (READ_ONCE(tsk->__state) & TASK_DEAD)
> + return 0;
> +
> seq_printf(s, "%d\n", task_pid_vnr(v));
> return 0;
> }

I tested this with 10 reboots, it worked 9 times, one reboot was delayed (perhaps
for a different reason, sometime these delays occur on no-RT or older kernels, too)

Bert Karwatzki