From: Philippe Gerum <rpm@xenomai.org>
To: Florian Bezdeka <florian.bezdeka@siemens.com>
Cc: xenomai@lists.linux.dev
Subject: Re: [RFC Dovetail 6.16]: Lockdep warning, IRQ while holding pci_config_lock
Date: Mon, 08 Sep 2025 16:08:44 +0200 [thread overview]
Message-ID: <87v7lt6npv.fsf@xenomai.org> (raw)
In-Reply-To: <871poh82tx.fsf@xenomai.org> (Philippe Gerum's message of "Mon, 08 Sep 2025 15:56:58 +0200")
Philippe Gerum <rpm@xenomai.org> writes:
> Philippe Gerum <rpm@xenomai.org> writes:
>
>> Florian Bezdeka <florian.bezdeka@siemens.com> writes:
>>
>>> Hi Philippe,
>>>
>>> from time to time I can see the following lockdep warning when testing
>>> on qemu.
>>>
>>> I'm not sure if my interpretation is correct. Should we convert
>>> pci_config_lock into a hard_spin_lock_t?
>>>
>>
>> No, we can't convert this lock. This would be a massive trauma, both
>> with respect to the PCI locking model and latency figures.
>
> Besides, that would not fix the core issue since the deadlock would
> still be there, and lockdep would still notice anyway (Dovetail locks
> are lockdep-tracked too).
However, that one should be turned into an hybrid lock. Not nice because
then we are going to disable hard irqs while fiddling with CPU masks,
but this would happen at irq startup exclusively. This said, that hidden
global lock looks pretty weird.
int irq_setup_affinity(struct irq_desc *desc)
{
struct cpumask *set = irq_default_affinity;
int node = irq_desc_get_node(desc);
static DEFINE_RAW_SPINLOCK(mask_lock);
--
Philippe.
next prev parent reply other threads:[~2025-09-08 14:08 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-09-08 13:35 [RFC Dovetail 6.16]: Lockdep warning, IRQ while holding pci_config_lock Florian Bezdeka
2025-09-08 13:54 ` Philippe Gerum
2025-09-08 13:56 ` Philippe Gerum
2025-09-08 14:08 ` Philippe Gerum [this message]
2025-09-09 14:04 ` Florian Bezdeka
2025-09-10 7:22 ` Philippe Gerum
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=87v7lt6npv.fsf@xenomai.org \
--to=rpm@xenomai.org \
--cc=florian.bezdeka@siemens.com \
--cc=xenomai@lists.linux.dev \
/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.