Commit 20658b3d authored by Alexander Stein's avatar Alexander Stein Committed by Greg Kroah-Hartman

pinctrl: baytrail: Add missing spinlock usage in byt_gpio_irq_handler

commit cdca06e4 upstream.

According to VLI64 Intel Atom E3800 Specification Update (#329901)
concurrent read accesses may result in returning 0xffffffff and write
accesses may be dropped silently.
To workaround all accesses must be protected by locks.
Signed-off-by: default avatarAlexander Stein <alexander.stein@systec-electronic.com>
Acked-by: default avatarMika Westerberg <mika.westerberg@linux.intel.com>
Signed-off-by: default avatarLinus Walleij <linus.walleij@linaro.org>
Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
parent 7396685a
...@@ -1612,7 +1612,9 @@ static void byt_gpio_irq_handler(struct irq_desc *desc) ...@@ -1612,7 +1612,9 @@ static void byt_gpio_irq_handler(struct irq_desc *desc)
continue; continue;
} }
raw_spin_lock(&vg->lock);
pending = readl(reg); pending = readl(reg);
raw_spin_unlock(&vg->lock);
for_each_set_bit(pin, &pending, 32) { for_each_set_bit(pin, &pending, 32) {
virq = irq_find_mapping(vg->chip.irqdomain, base + pin); virq = irq_find_mapping(vg->chip.irqdomain, base + pin);
generic_handle_irq(virq); generic_handle_irq(virq);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment