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: <20231020082531.GS33217@noisy.programming.kicks-ass.net>
Date:   Fri, 20 Oct 2023 10:25:31 +0200
From:   Peter Zijlstra <peterz@...radead.org>
To:     Frederic Weisbecker <frederic@...nel.org>
Cc:     LKML <linux-kernel@...r.kernel.org>,
        Boqun Feng <boqun.feng@...il.com>,
        Joel Fernandes <joel@...lfernandes.org>,
        Josh Triplett <josh@...htriplett.org>,
        Mathieu Desnoyers <mathieu.desnoyers@...icios.com>,
        Neeraj Upadhyay <neeraj.upadhyay@....com>,
        "Paul E . McKenney" <paulmck@...nel.org>,
        Steven Rostedt <rostedt@...dmis.org>,
        Uladzislau Rezki <urezki@...il.com>, rcu <rcu@...r.kernel.org>,
        Zqiang <qiang.zhang1211@...il.com>,
        Lai Jiangshan <jiangshanlai@...il.com>,
        "Liam R . Howlett" <Liam.Howlett@...cle.com>,
        Sebastian Siewior <bigeasy@...utronix.de>,
        Thomas Gleixner <tglx@...utronix.de>
Subject: Re: [PATCH 4/4] Revert "kernel/sched: Modify initial boot task idle
 setup"

On Fri, Oct 20, 2023 at 01:35:43AM +0200, Frederic Weisbecker wrote:
> Now that rcutiny can deal with early boot PF_IDLE setting, revert
> commit cff9b2332ab762b7e0586c793c431a8f2ea4db04.
> 
> This fixes several subtle issues introduced on RCU-tasks(-trace):
> 
> 1) RCU-tasks stalls when:
> 
>    1.1 Grace period is started before init/0 had a chance to set PF_IDLE,
>        keeping it stuck in the holdout list until idle ever schedules.
> 
>    1.2 Grace period is started when some possible CPUs have never been
>        online, keeping their idle tasks stuck in the holdout list until
>        the CPU ever boots up.
> 
>    1.3 Similar to 1.1 but with secondary CPUs: Grace period is started
>        concurrently with secondary CPU booting, putting its idle task in
>        the holdout list because PF_IDLE isn't yet observed on it. It
>        stays then stuck in the holdout list until that CPU ever
>        schedules. The effect is mitigated here by all the smpboot
>        kthreads and the hotplug AP thread that must run to bring the
>        CPU up.
> 
> 2) Spurious warning on RCU task trace that assumes offline CPU's idle
>    task is always PF_IDLE.
> 
> More issues have been found in RCU-tasks related to PF_IDLE which should
> be fixed with later changes as those are not regressions:
> 
> 3) The RCU-Tasks semantics consider the idle loop as a quiescent state,
>    however:
> 
>    3.1 The boot code preceding the idle entry is included in this
>        quiescent state. Especially after the completion of kthreadd_done
>        after which init/1 can launch userspace concurrently. The window
>        is tiny before PF_IDLE is set but it exists.
> 
>    3.2 Similarly, the boot code preceding the idle entry on secondary
>        CPUs is wrongly accounted as RCU tasks quiescent state.
> 

Urgh... so the plan is to fix RCU-tasks for all of the above to not rely
on PF_IDLE ? Because I rather like the more strict PF_IDLE and
subsequently don't much like this revert.

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ