Skip to contentSkip to conversation

usb: dwc3: gadget: synchronize_irq dwc irq in suspend

DISCUSSION Felipe Balbi 1 participant 1 message Jan 29, 2019 USB

lore
Share & tools
lore
#0 lore raw

Hi,

Quoted 4 lines · Bo

agree your findings.

so it's better move the synchronize_irq() after the spin_unlock_irqrestore(). static int dwc3_suspend_common(struct dwc3 *dwc)

Quoted 10 lines
{
	unsigned long	flags;

	switch (dwc->dr_mode) {
	case USB_DR_MODE_PERIPHERAL:
	case USB_DR_MODE_OTG:
		spin_lock_irqsave(&dwc->lock, flags);
		dwc3_gadget_suspend(dwc);
		spin_unlock_irqrestore(&dwc->lock, flags);
		synchronize_irq()

indeed, I missed that when I first reviewed the patch. Care to send a fix?