提交 e74bd4d3 编写于 作者: M Manu Gautam 提交者: Felipe Balbi

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: NManu Gautam <mgautam@codeaurora.org>
Signed-off-by: NFelipe Balbi <felipe.balbi@linux.intel.com>
上级 c49f6305
......@@ -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);
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册