usb: gadget: core: Fix use-after-free of usb_request
Driver is tracing usb_request after freeing it. Fix it by changing the order. Signed-off-by: Manu Gautam <mgautam@codeaurora.org> Signed-off-by: Felipe Balbi <felipe.balbi@linux.intel.com>
This commit is contained in:
parent
c49f63055e
commit
e74bd4d358
|
@ -180,8 +180,8 @@ EXPORT_SYMBOL_GPL(usb_ep_alloc_request);
|
|||
void usb_ep_free_request(struct usb_ep *ep,
|
||||
struct usb_request *req)
|
||||
{
|
||||
ep->ops->free_request(ep, req);
|
||||
trace_usb_ep_free_request(ep, req, 0);
|
||||
ep->ops->free_request(ep, req);
|
||||
}
|
||||
EXPORT_SYMBOL_GPL(usb_ep_free_request);
|
||||
|
||||
|
|
Loading…
Reference in New Issue