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
| ||
|
Message-ID: <20221210185555.7abc4de4@gandalf.local.home> Date: Sat, 10 Dec 2022 18:55:55 -0500 From: Steven Rostedt <rostedt@...dmis.org> To: Thomas Gleixner <tglx@...utronix.de> Cc: "Paul E. McKenney" <paulmck@...nel.org>, linux-kernel@...r.kernel.org, Masami Hiramatsu <mhiramat@...nel.org>, Andrew Morton <akpm@...ux-foundation.org>, Karol Herbst <karolherbst@...il.com>, Pekka Paalanen <ppaalanen@...il.com>, Dave Hansen <dave.hansen@...ux.intel.com>, Andy Lutomirski <luto@...nel.org>, Peter Zijlstra <peterz@...radead.org>, Ingo Molnar <mingo@...nel.org>, Borislav Petkov <bp@...en8.de> Subject: Re: [for-next][PATCH 13/25] x86/mm/kmmio: Use rcu_read_lock_sched_notrace() On Sun, 11 Dec 2022 00:30:36 +0100 Thomas Gleixner <tglx@...utronix.de> wrote: > On Sat, Dec 10 2022 at 13:34, Steven Rostedt wrote: > > On Sat, 10 Dec 2022 09:47:53 -0800 "Paul E. McKenney" <paulmck@...nel.org> wrote: > >> This does mess with preempt_count() redundantly, but the overhead from > >> that should be way down in the noise. > > > > I was going to remove it, but then I realized that it would be a functional > > change, as from the comment above, it uses "preempt_enable_no_resched(), > > which there is not a rcu_read_unlock_sched() variant. > > preempt_enable_no_resched() in this context is simply garbage. > > preempt_enable_no_resched() tries to avoid the overhead of checking > whether rescheduling is due after decrementing preempt_count() because > the code which it this claims to know that it is _not_ the outermost one > which brings preempt count back to preemtible state. > > I concede that there are hot paths which actually can benefit, but this > code has exactly _ZERO_ benefit from that. Taking that tracing exception > and handling it is orders of magnitudes more expensive than a regular > preempt_enable(). > > So just get rid of it and don't proliferate cargo cult programming. > The point of the patch is to just fix the lockdep issue. I'm happy to remove that "no_resched" (I was planning to), but that would be a separate change, with a different purpose, and thus a separate patch. -- Steve
Powered by blists - more mailing lists