All of lore.kernel.org
 help / color / mirror / Atom feed
From: Sebastian Andrzej Siewior <bigeasy@linutronix.de>
To: Steven Rostedt <rostedt@goodmis.org>
Cc: Guenter Roeck <linux@roeck-us.net>,
	Clark Williams <clrkwllms@kernel.org>,
	linux-rt-devel@lists.linux.dev,
	Thomas Gleixner <tglx@linutronix.de>,
	Peter Zijlstra <peterz@infradead.org>
Subject: Re: possible circular locking dependency backtrace seen when enabling PREEMPT_RT
Date: Wed, 12 Feb 2025 18:24:17 +0100	[thread overview]
Message-ID: <20250212172417.DQF_YTTy@linutronix.de> (raw)
In-Reply-To: <20250212121837.3b25b941@gandalf.local.home>

On 2025-02-12 12:18:37 [-0500], Steven Rostedt wrote:
> On Wed, 12 Feb 2025 18:09:55 +0100
> Sebastian Andrzej Siewior <bigeasy@linutronix.de> wrote:
> 
> > > Why not? It keeps the same paradigm as non PREEMPT_RT. Do we really want to
> > > litter local_bh_disable around all these cases that spin_lock_irq*() is
> > > used to disable bh?  
> > 
> > Yes.
> 
> OK, after testing that patch I see the issue. The local_bh_disable() makes
> it look like we are in a softirq, and that triggers a bunch of
> BUG(in_interrupt()) that are around the kernel.
> 
> Couldn't we make the spin_lock_irq*() also disable softirqs without making
> softirq_count() return true?

Maybe. But I don't see the advantage. See my other reply.

> That would keep the same paradigm between non-PREEMPT_RT as well as
> PREEMPT_RT without having to litter these all over the place.

I am working on getting rid of the lock in local_bh_disable(). Guess
what happens then in terms of "same paradigm".

> -- Steve

Sebastian

  reply	other threads:[~2025-02-12 17:24 UTC|newest]

Thread overview: 16+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2025-02-12 15:56 possible circular locking dependency backtrace seen when enabling PREEMPT_RT Guenter Roeck
2025-02-12 16:45 ` Steven Rostedt
2025-02-12 16:59   ` Sebastian Andrzej Siewior
2025-02-12 17:03     ` Steven Rostedt
2025-02-12 17:07       ` Steven Rostedt
2025-02-12 17:21         ` Sebastian Andrzej Siewior
2025-02-12 17:09       ` Sebastian Andrzej Siewior
2025-02-12 17:18         ` Steven Rostedt
2025-02-12 17:24           ` Sebastian Andrzej Siewior [this message]
2025-02-12 17:33             ` Steven Rostedt
2025-02-13  8:38               ` Sebastian Andrzej Siewior
2025-02-12 17:54   ` Guenter Roeck
2025-02-12 18:17     ` Steven Rostedt
2025-02-12 16:56 ` Sebastian Andrzej Siewior
2025-02-12 18:36   ` Guenter Roeck
2025-02-13  8:28     ` Sebastian Andrzej Siewior

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20250212172417.DQF_YTTy@linutronix.de \
    --to=bigeasy@linutronix.de \
    --cc=clrkwllms@kernel.org \
    --cc=linux-rt-devel@lists.linux.dev \
    --cc=linux@roeck-us.net \
    --cc=peterz@infradead.org \
    --cc=rostedt@goodmis.org \
    --cc=tglx@linutronix.de \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.