mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
synced 2025-01-16 01:54:00 +00:00
USB: xhci: Don't oops if the host doesn't halt.
Signed-off-by: Sarah Sharp <sarah.a.sharp@linux.intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
This commit is contained in:
parent
66e49d8774
commit
d3512f6349
@ -103,7 +103,10 @@ int xhci_reset(struct xhci_hcd *xhci)
|
|||||||
u32 state;
|
u32 state;
|
||||||
|
|
||||||
state = xhci_readl(xhci, &xhci->op_regs->status);
|
state = xhci_readl(xhci, &xhci->op_regs->status);
|
||||||
BUG_ON((state & STS_HALT) == 0);
|
if ((state & STS_HALT) == 0) {
|
||||||
|
xhci_warn(xhci, "Host controller not halted, aborting reset.\n");
|
||||||
|
return 0;
|
||||||
|
}
|
||||||
|
|
||||||
xhci_dbg(xhci, "// Reset the HC\n");
|
xhci_dbg(xhci, "// Reset the HC\n");
|
||||||
command = xhci_readl(xhci, &xhci->op_regs->command);
|
command = xhci_readl(xhci, &xhci->op_regs->command);
|
||||||
|
Loading…
x
Reference in New Issue
Block a user