[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <aFBfY1oyme5PkmqS@Mac.home>
Date: Mon, 16 Jun 2025 11:16:03 -0700
From: Boqun Feng <boqun.feng@...il.com>
To: Joel Fernandes <joelagnelf@...dia.com>
Cc: Lyude Paul <lyude@...hat.com>, rust-for-linux@...r.kernel.org,
Thomas Gleixner <tglx@...utronix.de>, linux-kernel@...r.kernel.org,
Daniel Almeida <daniel.almeida@...labora.com>,
Ingo Molnar <mingo@...hat.com>, Peter Zijlstra <peterz@...radead.org>,
Juri Lelli <juri.lelli@...hat.com>,
Vincent Guittot <vincent.guittot@...aro.org>,
Dietmar Eggemann <dietmar.eggemann@....com>,
Steven Rostedt <rostedt@...dmis.org>, Ben Segall <bsegall@...gle.com>,
Mel Gorman <mgorman@...e.de>, Valentin Schneider <vschneid@...hat.com>,
Will Deacon <will@...nel.org>, Waiman Long <longman@...hat.com>,
Miguel Ojeda <ojeda@...nel.org>, Alex Gaynor <alex.gaynor@...il.com>,
Gary Guo <gary@...yguo.net>,
Björn Roy Baron <bjorn3_gh@...tonmail.com>,
Benno Lossin <lossin@...nel.org>,
Andreas Hindborg <a.hindborg@...nel.org>,
Alice Ryhl <aliceryhl@...gle.com>, Trevor Gross <tmgross@...ch.edu>,
Danilo Krummrich <dakr@...nel.org>, David Woodhouse <dwmw@...zon.co.uk>,
Jens Axboe <axboe@...nel.dk>,
Sebastian Andrzej Siewior <bigeasy@...utronix.de>,
NeilBrown <neilb@...e.de>, Caleb Sander Mateos <csander@...estorage.com>,
Ryo Takakura <ryotkkr98@...il.com>,
K Prateek Nayak <kprateek.nayak@....com>
Subject: Re: [RFC RESEND v10 03/14] irq & spin_lock: Add counted interrupt
disabling/enabling
On Mon, Jun 16, 2025 at 02:10:01PM -0400, Joel Fernandes wrote:
> On Tue, May 27, 2025 at 06:21:44PM -0400, Lyude Paul wrote:
> > From: Boqun Feng <boqun.feng@...il.com>
> >
> > Currently the nested interrupt disabling and enabling is present by
> > _irqsave() and _irqrestore() APIs, which are relatively unsafe, for
> > example:
> [...]
> > diff --git a/include/linux/irqflags_types.h b/include/linux/irqflags_types.h
> > index c13f0d915097a..277433f7f53eb 100644
> > --- a/include/linux/irqflags_types.h
> > +++ b/include/linux/irqflags_types.h
> > @@ -19,4 +19,10 @@ struct irqtrace_events {
> >
> > #endif
> >
> > +/* Per-cpu interrupt disabling state for local_interrupt_{disable,enable}() */
> > +struct interrupt_disable_state {
> > + unsigned long flags;
> > + long count;
>
> Is count unused? I found it in earlier series but not this one. Now count
You're right, the original proposal is to use a separate count, but it
turned out we can use preempt count.
> should be in the preempt counter, not in this new per-cpu var?
>
> Sorry if I missed it from some other patch in this series. thanks,
>
Nope, it's merely some code we forgot to clean up from the previous
version.
Regards,
Boqun
> - Joel
[...]
Powered by blists - more mailing lists