Re: [PATCH v2] usb: dwc3: Trigger a GCTL soft reset when switching modes in DRD

2020-12-11 Thread John Stultz
Hey Felipe, Sorry for taking so long to get back to this. :( On Fri, Oct 23, 2020 at 12:02 AM Felipe Balbi wrote: > John Stultz writes: > > On Thu, Oct 22, 2020 at 12:55 AM Felipe Balbi wrote: > >> The only thing we need to do is verify > >> which registers are shadowed between host and

Re: [PATCH v2] usb: dwc3: Trigger a GCTL soft reset when switching modes in DRD

2020-11-10 Thread Thinh Nguyen
Hi, Felipe Balbi wrote: > Hi, > > Thinh Nguyen writes: >> John Stultz wrote: >>> static void __dwc3_set_mode(struct work_struct *work) >>> { >>> struct dwc3 *dwc = work_to_dwc(work); >>> unsigned long flags; >>> + int hw_mode; >>> int ret; >>> u32 reg; >>> >>> @@ -154,6

Re: [PATCH v2] usb: dwc3: Trigger a GCTL soft reset when switching modes in DRD

2020-10-23 Thread Felipe Balbi
Hi, John Stultz writes: > On Thu, Oct 22, 2020 at 12:55 AM Felipe Balbi wrote: >> John Stultz writes: >> > From: Yu Chen >> > >> > With the current dwc3 code on the HiKey960 we often see the >> > COREIDLE flag get stuck off in __dwc3_gadget_start(), which >> > seems to prevent the reset irq

Re: [PATCH v2] usb: dwc3: Trigger a GCTL soft reset when switching modes in DRD

2020-10-22 Thread John Stultz
On Thu, Oct 22, 2020 at 12:55 AM Felipe Balbi wrote: > John Stultz writes: > > From: Yu Chen > > > > With the current dwc3 code on the HiKey960 we often see the > > COREIDLE flag get stuck off in __dwc3_gadget_start(), which > > seems to prevent the reset irq and causes the USB gadget to > >

Re: [PATCH v2] usb: dwc3: Trigger a GCTL soft reset when switching modes in DRD

2020-10-22 Thread Felipe Balbi
Hi, Thinh Nguyen writes: > John Stultz wrote: >> static void __dwc3_set_mode(struct work_struct *work) >> { >> struct dwc3 *dwc = work_to_dwc(work); >> unsigned long flags; >> +int hw_mode; >> int ret; >> u32 reg; >> >> @@ -154,6 +168,11 @@ static void

Re: [PATCH v2] usb: dwc3: Trigger a GCTL soft reset when switching modes in DRD

2020-10-22 Thread Felipe Balbi
Hi, John Stultz writes: > From: Yu Chen > > With the current dwc3 code on the HiKey960 we often see the > COREIDLE flag get stuck off in __dwc3_gadget_start(), which > seems to prevent the reset irq and causes the USB gadget to > fail to initialize. > > We had seen occasional initialization

Re: [PATCH v2] usb: dwc3: Trigger a GCTL soft reset when switching modes in DRD

2020-10-21 Thread John Stultz
On Wed, Oct 21, 2020 at 6:17 PM Thinh Nguyen wrote: > > John Stultz wrote: > > From: Yu Chen > > > > With the current dwc3 code on the HiKey960 we often see the > > COREIDLE flag get stuck off in __dwc3_gadget_start(), which > > seems to prevent the reset irq and causes the USB gadget to > >

Re: [PATCH v2] usb: dwc3: Trigger a GCTL soft reset when switching modes in DRD

2020-10-21 Thread Thinh Nguyen
John Stultz wrote: > From: Yu Chen > > With the current dwc3 code on the HiKey960 we often see the > COREIDLE flag get stuck off in __dwc3_gadget_start(), which > seems to prevent the reset irq and causes the USB gadget to > fail to initialize. > > We had seen occasional initialization failures

[PATCH v2] usb: dwc3: Trigger a GCTL soft reset when switching modes in DRD

2020-10-21 Thread John Stultz
From: Yu Chen With the current dwc3 code on the HiKey960 we often see the COREIDLE flag get stuck off in __dwc3_gadget_start(), which seems to prevent the reset irq and causes the USB gadget to fail to initialize. We had seen occasional initialization failures with older kernels but with recent