usb: xhci: fix return value of xhci_setup_device()
Subsystems (3)
PATCH 1/1 usb: xhci: fix return value of xhci_setup_device()
From: "Lu, Baolu" <[email protected]>
xhci_setup_device() should return failure with correct error number when xhci host has died, removed or halted.
--- drivers/usb/host/xhci.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-)
drivers/usb/host/xhci.c +3 -1
@@ -3785,8 +3785,10 @@ static int xhci_setup_device(struct usb_hcd *hcd, struct usb_device *udev,mutex_lock (&xhci->mutex); -if (xhci->xhc_state)/* dying, removing or halted */ +if (xhci->xhc_state) {/* dying, removing or halted */ + ret = -ESHUTDOWN ; goto out; + }if (!udev->slot_id) { xhci_dbg_trace(xhci, trace_xhci_dbg_address,
Signature · 1 line
2.1.4
Quoted 5 lines · Lu Baolu
From: "Lu, Baolu" <[email protected]>
xhci_setup_device()should return failure with correct error number when xhci host has died, removed or halted.
Thanks, will add.
Might go to 4.9 as 4.8-rc5 is already out
-Mathias
Hi Mathias,
Quoted 9 lines · Mathias Nyman
Quoted 5 lines · Lu Baolu
From: "Lu, Baolu" <[email protected]>
xhci_setup_device()should return failure with correct error number when xhci host has died, removed or halted.Thanks, will add.
Might go to 4.9 as 4.8-rc5 is already out
I'm sorry, I just realized that "From" signature is different from "Signed-off-by" signature in this patch.
Do you mind if I resend this patch with this fixed?
Best regards,
Lu Baolu
Quoted 10 lines · Lu Baolu
Hi Mathias,
Quoted 7 lines · Mathias Nyman
Quoted 5 lines · Lu Baolu
From: "Lu, Baolu" <[email protected]>
xhci_setup_device()should return failure with correct error number when xhci host has died, removed or halted.
Quoted 8 lines
Quoted 2 lines
Thanks, will add.
Might go to 4.9 as 4.8-rc5 is already outI'm sorry, I just realized that "From" signature is different from "Signed-off-by" signature in this patch.
Do you mind if I resend this patch with this fixed?
Not at all, I'll take v2
-Mathias