lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20251020101602.GK3419281@noisy.programming.kicks-ass.net>
Date: Mon, 20 Oct 2025 12:16:02 +0200
From: Peter Zijlstra <peterz@...radead.org>
To: Steven Rostedt <rostedt@...dmis.org>
Cc: jpoimboe@...nel.org, rostedt@...nel.org, linux-kernel@...r.kernel.org
Subject: Re: [PATCH 05/12] unwind: Add comment to unwind_deferred_task_exit()

On Wed, Oct 01, 2025 at 11:35:05AM -0400, Steven Rostedt wrote:
> On Wed, 24 Sep 2025 09:59:53 +0200
> Peter Zijlstra <peterz@...radead.org> wrote:
> 
> > Explain why unwind_deferred_task_exit() exist and its constraints.
> > 
> > Signed-off-by: Peter Zijlstra (Intel) <peterz@...radead.org>
> > ---
> >  kernel/exit.c |    7 ++++++-
> >  1 file changed, 6 insertions(+), 1 deletion(-)
> > 
> > --- a/kernel/exit.c
> > +++ b/kernel/exit.c
> > @@ -934,7 +934,6 @@ void __noreturn do_exit(long code)
> >  
> >  	tsk->exit_code = code;
> >  	taskstats_exit(tsk, group_dead);
> > -	unwind_deferred_task_exit(tsk);
> >  	trace_sched_process_exit(tsk, group_dead);
> >  
> >  	/*
> > @@ -945,6 +944,12 @@ void __noreturn do_exit(long code)
> >  	 * gets woken up by child-exit notifications.
> >  	 */
> >  	perf_event_exit_task(tsk);
> > +	/*
> > +	 * PF_EXITING (above) ensures unwind_deferred_request() will no
> > +	 * longer add new unwinds. While exit_mm() (below) will destroy the
> > +	 * abaility to do unwinds.
> 
> 
> I would state that it also flushes any unwind that is currently pending, as
> exit_mm() will prevent it from happening.

It now reads:

+       /*
+        * PF_EXITING (above) ensures unwind_deferred_request() will no
+        * longer add new unwinds. While exit_mm() (below) will destroy the
+        * abaility to do unwinds. So flush any pending unwinds here.
+        */
+       unwind_deferred_task_exit(tsk);


Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ