Message ID | 1536071716-11766-1-git-send-email-mathias.nyman@linux.intel.com (mailing list archive) |
---|---|
State | New, archived |
Headers | show |
Series | usb: Don't die twice if PCI xhci host is not responding in resume | expand |
On Tue, 4 Sep 2018, Mathias Nyman wrote: > usb_hc_died() should only be called once, and with the primary HCD > as parameter. It will mark both primary and secondary hcd's dead. > > Remove the extra call to usb_cd_died with the shared hcd as parameter. > > Fixes: ff9d78b36f76 ("USB: Set usb_hcd->state and flags for shared roothubs") > Signed-off-by: Mathias Nyman <mathias.nyman@linux.intel.com> > --- > drivers/usb/core/hcd-pci.c | 2 -- > 1 file changed, 2 deletions(-) > > diff --git a/drivers/usb/core/hcd-pci.c b/drivers/usb/core/hcd-pci.c > index 66fe1b7..0343246 100644 > --- a/drivers/usb/core/hcd-pci.c > +++ b/drivers/usb/core/hcd-pci.c > @@ -515,8 +515,6 @@ static int resume_common(struct device *dev, int event) > event == PM_EVENT_RESTORE); > if (retval) { > dev_err(dev, "PCI post-resume error %d!\n", retval); > - if (hcd->shared_hcd) > - usb_hc_died(hcd->shared_hcd); > usb_hc_died(hcd); > } > } Acked-by: Alan Stern <stern@rowland.harvard.edu>
diff --git a/drivers/usb/core/hcd-pci.c b/drivers/usb/core/hcd-pci.c index 66fe1b7..0343246 100644 --- a/drivers/usb/core/hcd-pci.c +++ b/drivers/usb/core/hcd-pci.c @@ -515,8 +515,6 @@ static int resume_common(struct device *dev, int event) event == PM_EVENT_RESTORE); if (retval) { dev_err(dev, "PCI post-resume error %d!\n", retval); - if (hcd->shared_hcd) - usb_hc_died(hcd->shared_hcd); usb_hc_died(hcd); } }
usb_hc_died() should only be called once, and with the primary HCD as parameter. It will mark both primary and secondary hcd's dead. Remove the extra call to usb_cd_died with the shared hcd as parameter. Fixes: ff9d78b36f76 ("USB: Set usb_hcd->state and flags for shared roothubs") Signed-off-by: Mathias Nyman <mathias.nyman@linux.intel.com> --- drivers/usb/core/hcd-pci.c | 2 -- 1 file changed, 2 deletions(-)