OSDN Git Service

mfd: dln2: Use irqsave() in USB's complete callback
authorSebastian Andrzej Siewior <bigeasy@linutronix.de>
Mon, 2 Jul 2018 07:31:32 +0000 (09:31 +0200)
committerLee Jones <lee.jones@linaro.org>
Fri, 27 Jul 2018 07:13:25 +0000 (08:13 +0100)
commit50d44f82c7f1b0d2676a7c5c11feb321e4ea6c44
tree3d334ac1a0570fe99ae7ab38f0f3c43f319a03ad
parentf99fea949736b6a79cddaaaec7e3b8830fd81c93
mfd: dln2: Use irqsave() in USB's complete callback

The USB completion callback does not disable interrupts while acquiring
the lock. We want to remove the local_irq_disable() invocation from
__usb_hcd_giveback_urb() and therefore it is required for the callback
handler to disable the interrupts while acquiring the lock.
The callback may be invoked either in IRQ or BH context depending on the
USB host controller.
Use the _irqsave() variant of the locking primitives.

Reviewed-by: Johan Hovold <johan@kernel.org>
Signed-off-by: Sebastian Andrzej Siewior <bigeasy@linutronix.de>
Signed-off-by: Lee Jones <lee.jones@linaro.org>
drivers/mfd/dln2.c