Commit a510bb87 authored by Claudiu Beznea's avatar Claudiu Beznea Committed by Thomas Gleixner
Browse files

genirq/irqdesc: Remove double locking in hwirq_show()



&desc->lock is acquired on 2 consecutive lines in hwirq_show(). This leads
obviously to a deadlock. Drop the raw_spin_lock_irq() and keep guard().

Fixes: 5d964a9f ("genirq/irqdesc: Switch to lock guards")
Signed-off-by: default avatarClaudiu Beznea <claudiu.beznea.uj@bp.renesas.com>
Signed-off-by: default avatarThomas Gleixner <tglx@linutronix.de>
Link: https://lore.kernel.org/all/20250521142541.3832130-1-claudiu.beznea.uj@bp.renesas.com
parent 788019eb
Loading
Loading
Loading
Loading
+0 −1
Original line number Diff line number Diff line
@@ -281,7 +281,6 @@ static ssize_t hwirq_show(struct kobject *kobj, struct kobj_attribute *attr, cha
	struct irq_desc *desc = container_of(kobj, struct irq_desc, kobj);

	guard(raw_spinlock_irq)(&desc->lock);
	raw_spin_lock_irq(&desc->lock);
	if (desc->irq_data.domain)
		return sysfs_emit(buf, "%lu\n", desc->irq_data.hwirq);
	return 0;