Commit 26fda92
PCI: tegra: Convert struct tegra_msi mask_lock into raw spinlock
The tegra_msi_irq_unmask() function may be called from a PCI driver
request_threaded_irq() function. This triggers kernel/irq/manage.c
__setup_irq() which locks raw spinlock &desc->lock descriptor lock
and with that descriptor lock held, calls tegra_msi_irq_unmask().
Since the &desc->lock descriptor lock is a raw spinlock, and the tegra_msi
.mask_lock is not a raw spinlock, this setup triggers 'BUG: Invalid wait
context' with CONFIG_PROVE_RAW_LOCK_NESTING=y.
Use scoped_guard() to simplify the locking.
Fixes: 2c99e55 ("PCI: tegra: Convert to MSI domains")
Reported-by: Geert Uytterhoeven <geert+renesas@glider.be>
Closes: https://patchwork.kernel.org/project/linux-pci/patch/20250909162707.13927-2-marek.vasut+renesas@mailbox.org/#26574451
Signed-off-by: Marek Vasut <marek.vasut+renesas@mailbox.org>
Signed-off-by: Manivannan Sadhasivam <mani@kernel.org>
Signed-off-by: Bjorn Helgaas <bhelgaas@google.com>
Cc: stable@vger.kernel.org
Link: https://patch.msgid.link/20250922150811.88450-1-marek.vasut+renesas@mailbox.org1 parent 4f15233 commit 26fda92
1 file changed
+13
-14
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
14 | 14 | | |
15 | 15 | | |
16 | 16 | | |
| 17 | + | |
17 | 18 | | |
18 | 19 | | |
19 | 20 | | |
| |||
270 | 271 | | |
271 | 272 | | |
272 | 273 | | |
273 | | - | |
| 274 | + | |
274 | 275 | | |
275 | 276 | | |
276 | 277 | | |
| |||
1581 | 1582 | | |
1582 | 1583 | | |
1583 | 1584 | | |
1584 | | - | |
1585 | 1585 | | |
1586 | 1586 | | |
1587 | | - | |
1588 | | - | |
1589 | | - | |
1590 | | - | |
1591 | | - | |
| 1587 | + | |
| 1588 | + | |
| 1589 | + | |
| 1590 | + | |
| 1591 | + | |
1592 | 1592 | | |
1593 | 1593 | | |
1594 | 1594 | | |
1595 | 1595 | | |
1596 | 1596 | | |
1597 | 1597 | | |
1598 | 1598 | | |
1599 | | - | |
1600 | 1599 | | |
1601 | 1600 | | |
1602 | | - | |
1603 | | - | |
1604 | | - | |
1605 | | - | |
1606 | | - | |
| 1601 | + | |
| 1602 | + | |
| 1603 | + | |
| 1604 | + | |
| 1605 | + | |
1607 | 1606 | | |
1608 | 1607 | | |
1609 | 1608 | | |
| |||
1711 | 1710 | | |
1712 | 1711 | | |
1713 | 1712 | | |
1714 | | - | |
| 1713 | + | |
1715 | 1714 | | |
1716 | 1715 | | |
1717 | 1716 | | |
| |||
0 commit comments