Re: [PATCH] usb: dwc3: gadget: fix crash in dwc3_gadget_giveback()

2024-06-03 Thread Mattijs Korpershoek
Hi, On Tue, 28 May 2024 10:35:03 +0200, Neil Armstrong wrote: > If the ep0 stalls or request are dequeued when gagdet is stopped, > the request dma may not be mapped yet and dwc3_flush_cache() may be > called with a NULL pointer. > > Check req->request.dma before calling dwc3_flush_cache() and la

Re: [PATCH] usb: dwc3: gadget: fix crash in dwc3_gadget_giveback()

2024-05-28 Thread Mattijs Korpershoek
Hi Neil, Thank you for the patch. On mar., mai 28, 2024 at 10:35, Neil Armstrong wrote: > If the ep0 stalls or request are dequeued when gagdet is stopped, > the request dma may not be mapped yet and dwc3_flush_cache() may be > called with a NULL pointer. > > Check req->request.dma before call

[PATCH] usb: dwc3: gadget: fix crash in dwc3_gadget_giveback()

2024-05-28 Thread Neil Armstrong
If the ep0 stalls or request are dequeued when gagdet is stopped, the request dma may not be mapped yet and dwc3_flush_cache() may be called with a NULL pointer. Check req->request.dma before calling dwc3_flush_cache() and later the usb_gadget_unmap_request() functions since it means that usb_gadg