diff options
author | Alexandre Courbot <[email protected]> | 2015-08-17 17:23:52 +0900 |
---|---|---|
committer | Linus Walleij <[email protected]> | 2015-08-17 10:56:24 +0200 |
commit | 7fa25937542358bfa01ef5c5a1e9a00bd164c000 (patch) | |
tree | d4edc6026912b6b8ad9450aa84f26f06d4b23794 /tools/perf/scripts/python/event_analyzing_sample.py | |
parent | ac49fbd1f9d437cca7234473850aef4165779383 (diff) |
gpio/grgpio: fix deadlock in grgpio_irq_unmap()
As reported by Alexey Khoroshilov:
grgpio_irq_unmap() code looks quite suspicious regarding usage of
priv->bgc.lock spinlock.
It locks the spinlock in line 310:
spin_lock_irqsave(&priv->bgc.lock, flags);
and then it can call grgpio_set_imask() in line 317:
grgpio_set_imask(priv, i, 0);
But grgpio_set_imask() unconditionally locks the spinlock by itself.
Fix this by moving the spinlock acquisition outside of
grgpio_set_imask().
Found by Linux Driver Verification project (linuxtesting.org).
Reported-by: Alexey Khoroshilov <[email protected]>
Signed-off-by: Alexandre Courbot <[email protected]>
Cc: Alexey Khoroshilov <[email protected]>
Cc: Andreas Larsson <[email protected]>
Signed-off-by: Linus Walleij <[email protected]>
Diffstat (limited to 'tools/perf/scripts/python/event_analyzing_sample.py')
0 files changed, 0 insertions, 0 deletions