{
u32 val;
+ /* Kill any ep0 requests as controller will be reinitialized */
+ kill_all_requests(hsotg, hsotg->eps_out[0], -ECONNRESET);
+
if (!is_usb_reset)
if (dwc2_hsotg_corereset(hsotg))
return;
if (time_after(jiffies, hsotg->last_rst +
msecs_to_jiffies(200))) {
- kill_all_requests(hsotg, hsotg->eps_out[0],
- -ECONNRESET);
-
dwc2_hsotg_core_init_disconnected(hsotg, true);
}
}
if (hsotg->lx_state == DWC2_L2)
dwc2_exit_hibernation(hsotg, false);
- /* Kill any ep0 requests as controller will be reinitialized */
- kill_all_requests(hsotg, hsotg->eps_out[0], -ECONNRESET);
dwc2_hsotg_core_init_disconnected(hsotg, false);
if (hsotg->enabled)
dwc2_hsotg_core_connect(hsotg);
wf_otg);
u32 count = 0;
u32 gotgctl;
+ unsigned long flags;
dev_dbg(hsotg->dev, "%s()\n", __func__);
hsotg->op_state = OTG_STATE_B_PERIPHERAL;
dwc2_core_init(hsotg, false, -1);
dwc2_enable_global_interrupts(hsotg);
+ spin_lock_irqsave(&hsotg->lock, flags);
dwc2_hsotg_core_init_disconnected(hsotg, false);
+ spin_unlock_irqrestore(&hsotg->lock, flags);
dwc2_hsotg_core_connect(hsotg);
} else {
/* A-Device connector (Host Mode) */