Skip to contentSkip to conversation

mfd: arizona: Fix lockdep recursion warning on set_irq_wake

PATCH Applied Charles Keepax 3 participants 3 messages Mar 25, 2016 – Apr 11, 2016

Subsystems (2)
lore
Share & tools
lore
#0 lore raw

PATCH v2 1/1 mfd: arizona: Fix lockdep recursion warning on set_irq_wake

Avoid a false recursive locking warning from lockdep by adding a lock class for the arizona IRQ chip.

---
 drivers/mfd/arizona-irq.c | 3 +++
 1 file changed, 3 insertions(+)

Thanks for the pointers guys and sorry again for missing this the first time around.

Changes since v1:
- Ditch the bus_lock stuff and use irq_set_lockdep_class

Thanks,
Charles

drivers/mfd/arizona-irq.c +3 -0
index 5fef014..edeb495 100644
@@ -168,12 +168,15 @@ static struct irq_chip arizona_irq_chip = {
 	.irq_set_wake		= arizona_irq_set_wake,
 };
 
+static struct lock_class_key arizona_irq_lock_class;
+
 static int arizona_irq_map(struct irq_domain *h, unsigned int virq,
 			      irq_hw_number_t hw)
 {
 	struct arizona *data = h->host_data;
 
 	irq_set_chip_data(virq, data);
+	irq_set_lockdep_class(virq, &arizona_irq_lock_class);
 	irq_set_chip_and_handler(virq, &arizona_irq_chip, handle_simple_irq);
 	irq_set_nested_thread(virq, 1);
 	irq_set_noprobe(virq);
Signature · 1 line
2.1.4
Applied
#2 lore raw
In reply to Charles Keepax
Quoted 7 lines · Charles Keepax

Avoid a false recursive locking warning from lockdep by adding a lock class for the arizona IRQ chip.

---
 drivers/mfd/arizona-irq.c | 3 +++
 1 file changed, 3 insertions(+)

Applied, thanks.

Quoted 29 lines

Thanks for the pointers guys and sorry again for missing this the first time around.

Changes since v1:
- Ditch the bus_lock stuff and use irq_set_lockdep_class

Thanks,
Charles

drivers/mfd/arizona-irq.c +3 -0
index 5fef014..edeb495 100644
@@ -168,12 +168,15 @@ static struct irq_chip arizona_irq_chip = {
 	.irq_set_wake		= arizona_irq_set_wake,
 };
 
+static struct lock_class_key arizona_irq_lock_class;
+
 static int arizona_irq_map(struct irq_domain *h, unsigned int virq,
 			      irq_hw_number_t hw)
 {
 	struct arizona *data = h->host_data;
 
 	irq_set_chip_data(virq, data);
+	irq_set_lockdep_class(virq, &arizona_irq_lock_class);
 	irq_set_chip_and_handler(virq, &arizona_irq_chip, handle_simple_irq);
 	irq_set_nested_thread(virq, 1);
 	irq_set_noprobe(virq);
Signature · 4 lines
Lee Jones
Linaro STMicroelectronics Landing Team Lead
Linaro.org │ Open source software for ARM SoCs
Follow Linaro: Facebook | Twitter | Blog