diff mbox series

[1/3] usb: mtu3: sync interrupt before unbind the udc

Message ID 20220609074233.15532-1-chunfeng.yun@mediatek.com
State New
Headers show
Series [1/3] usb: mtu3: sync interrupt before unbind the udc | expand

Commit Message

Chunfeng Yun (云春峰) June 9, 2022, 7:42 a.m. UTC
Register gadget irq to avoid the interrupt handler is occurred
or scheduled during the unbind flow, may happen when do android
function switch stress test.

Signed-off-by: Chunfeng Yun <chunfeng.yun@mediatek.com>
---
 drivers/usb/mtu3/mtu3_gadget.c | 1 +
 1 file changed, 1 insertion(+)

Comments

AngeloGioacchino Del Regno June 10, 2022, 10:36 a.m. UTC | #1
Il 09/06/22 09:42, Chunfeng Yun ha scritto:
> Use threaded irq to improve time consuming top-half
> 
> Signed-off-by: Chunfeng Yun <chunfeng.yun@mediatek.com>

Reviewed-by: AngeloGioacchino Del Regno <angelogioacchino.delregno@collabora.com>
AngeloGioacchino Del Regno June 10, 2022, 10:36 a.m. UTC | #2
Il 09/06/22 09:42, Chunfeng Yun ha scritto:
> Register gadget irq to avoid the interrupt handler is occurred
> or scheduled during the unbind flow, may happen when do android
> function switch stress test.
> 
> Signed-off-by: Chunfeng Yun <chunfeng.yun@mediatek.com>

Reviewed-by: AngeloGioacchino Del Regno <angelogioacchino.delregno@collabora.com>
diff mbox series

Patch

diff --git a/drivers/usb/mtu3/mtu3_gadget.c b/drivers/usb/mtu3/mtu3_gadget.c
index 9977600616d7..d57cea62fe6b 100644
--- a/drivers/usb/mtu3/mtu3_gadget.c
+++ b/drivers/usb/mtu3/mtu3_gadget.c
@@ -680,6 +680,7 @@  int mtu3_gadget_setup(struct mtu3 *mtu)
 	mtu->g.speed = USB_SPEED_UNKNOWN;
 	mtu->g.sg_supported = 0;
 	mtu->g.name = MTU3_DRIVER_NAME;
+	mtu->g.irq = mtu->irq;
 	mtu->is_active = 0;
 	mtu->delayed_status = false;