Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 7bc5d5af authored by Mathias Nyman's avatar Mathias Nyman Committed by Greg Kroah-Hartman
Browse files

usb: xhci: trace URB before giving it back instead of after



Don't access any members of a URB after giving it back.
URB might be freed by then already.

Signed-off-by: default avatarMathias Nyman <mathias.nyman@linux.intel.com>
Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
parent 5120a266
Loading
Loading
Loading
Loading
+1 −1
Original line number Original line Diff line number Diff line
@@ -641,8 +641,8 @@ static void xhci_giveback_urb_in_irq(struct xhci_hcd *xhci,
	xhci_urb_free_priv(urb_priv);
	xhci_urb_free_priv(urb_priv);
	usb_hcd_unlink_urb_from_ep(hcd, urb);
	usb_hcd_unlink_urb_from_ep(hcd, urb);
	spin_unlock(&xhci->lock);
	spin_unlock(&xhci->lock);
	usb_hcd_giveback_urb(hcd, urb, status);
	trace_xhci_urb_giveback(urb);
	trace_xhci_urb_giveback(urb);
	usb_hcd_giveback_urb(hcd, urb, status);
	spin_lock(&xhci->lock);
	spin_lock(&xhci->lock);
}
}