USB stops working after a while (xhci_hcd 0000:00:14.0: Timeout while waiting for setup device command)

Bug #1413440 reported by Chris Halse Rogers
144
This bug affects 29 people
Affects Status Importance Assigned to Milestone
System76
Triaged
High
Unassigned
linux (Ubuntu)
Triaged
High
Unassigned

Bug Description

On my laptop the kernel will sometimes drop the USB hub. After this, the laptop doesn't recognise any device plugged in to the USB ports - plugging and unplugging any device I've tried into any of the USB ports produces no response, not even dmesg entries.

Strangely this also applies to bluetooth - it no longer works once USB has dropped (possibly the module is hung of the bus internally).

Once this has happened only a reboot fixes it; I've not managed to find any combination of module unload/reload or suspend cycles to reinitialise things correctly.

Relevant snippet of dmesg:
[48830.625057] xhci_hcd 0000:00:14.0: Timeout while waiting for setup device command
[48838.079718] xhci_hcd 0000:00:14.0: Stopped the command ring failed, maybe the host is dead
[48838.079742] xhci_hcd 0000:00:14.0: Abort command ring failed
[48838.079746] xhci_hcd 0000:00:14.0: HC died; cleaning up
[48838.079770] xhci_hcd 0000:00:14.0: Timeout while waiting for setup device command
[48838.079806] sched: RT throttling activated
[48838.079981] usb 1-1: USB disconnect, device number 16
[48838.079985] usb 1-1.2: USB disconnect, device number 18
[48838.079987] usb 1-1.2.3: USB disconnect, device number 19
[48838.080285] usb 1-1.2.4: USB disconnect, device number 20
[48838.111892] usb 1-1.4: USB disconnect, device number 17
[48838.191292] usb 1-4: USB disconnect, device number 6
[48838.267550] usb 1-10: USB disconnect, device number 8
[48838.282968] usb 2-1: device not accepting address 8, error -62
[48838.282983] usb 2-1: USB disconnect, device number 8
[48838.282986] usb 2-1.2: USB disconnect, device number 9

ProblemType: Bug
DistroRelease: Ubuntu 15.04
Package: linux-image-3.18.0-9-generic 3.18.0-9.10
ProcVersionSignature: Ubuntu 3.18.0-9.10-generic 3.18.2
Uname: Linux 3.18.0-9-generic x86_64
ApportVersion: 2.15.1-0ubuntu2
Architecture: amd64
AudioDevicesInUse:
 USER PID ACCESS COMMAND
 /dev/snd/controlC1: chris 4255 F.... pulseaudio
 /dev/snd/controlC0: chris 4255 F.... pulseaudio
CRDA:
 country AU: DFS-UNSET
  (2402 - 2482 @ 40), (N/A, 20), (N/A)
  (5170 - 5250 @ 40), (3, 23), (N/A)
  (5250 - 5330 @ 40), (3, 23), (0 ms), DFS
  (5735 - 5835 @ 40), (3, 30), (N/A)
CurrentDesktop: Unity
Date: Thu Jan 22 12:59:27 2015
InstallationDate: Installed on 2013-08-06 (533 days ago)
InstallationMedia: Ubuntu 13.04 "Raring Ringtail" - Release amd64 (20130424)
MachineType: System76, Inc. Galago UltraPro
ProcFB: 0 inteldrmfb
ProcKernelCmdLine: BOOT_IMAGE=/vmlinuz-3.18.0-9-generic.efi.signed root=UUID=92c2fa03-f29c-4bcc-87ab-f0fe28c134f2 ro quiet splash vt.handoff=7 init=/lib/systemd/systemd break=mount
RelatedPackageVersions:
 linux-restricted-modules-3.18.0-9-generic N/A
 linux-backports-modules-3.18.0-9-generic N/A
 linux-firmware 1.141
RfKill:
 1: phy0: Wireless LAN
  Soft blocked: no
  Hard blocked: no
SourcePackage: linux
UpgradeStatus: Upgraded to vivid on 2013-08-06 (533 days ago)
dmi.bios.date: 07/09/2013
dmi.bios.vendor: American Megatrends Inc.
dmi.bios.version: 4.6.5
dmi.board.asset.tag: Tag 12345
dmi.board.name: Galago UltraPro
dmi.board.vendor: System76, Inc.
dmi.board.version: galu1
dmi.chassis.asset.tag: No Asset Tag
dmi.chassis.type: 9
dmi.chassis.vendor: System76, Inc,
dmi.chassis.version: galu1
dmi.modalias: dmi:bvnAmericanMegatrendsInc.:bvr4.6.5:bd07/09/2013:svnSystem76,Inc.:pnGalagoUltraPro:pvrgalu1:rvnSystem76,Inc.:rnGalagoUltraPro:rvrgalu1:cvnSystem76,Inc,:ct9:cvrgalu1:
dmi.product.name: Galago UltraPro
dmi.product.version: galu1
dmi.sys.vendor: System76, Inc.

Revision history for this message
Chris Halse Rogers (raof) wrote :
Revision history for this message
Brad Figg (brad-figg) wrote : Status changed to Confirmed

This change was made by a bot.

Changed in linux (Ubuntu):
status: New → Confirmed
Changed in linux (Ubuntu):
importance: Undecided → Critical
Revision history for this message
Joseph Salisbury (jsalisbury) wrote :

Would it be possible for you to test the latest upstream kernel? Refer to https://wiki.ubuntu.com/KernelMainlineBuilds . Please test the latest v3.19 kernel[0].

If this bug is fixed in the mainline kernel, please add the following tag 'kernel-fixed-upstream'.

If the mainline kernel does not fix this bug, please add the tag: 'kernel-bug-exists-upstream'.

If you are unable to test the mainline kernel, for example it will not boot, please add the tag: 'kernel-unable-to-test-upstream'.
Once testing of the upstream kernel is complete, please mark this bug as "Confirmed".

Thanks in advance.

[0] http://kernel.ubuntu.com/~kernel-ppa/mainline/v3.19-rc5-vivid/

Changed in linux (Ubuntu):
importance: Critical → High
status: Confirmed → Incomplete
Revision history for this message
Chris Halse Rogers (raof) wrote :

Ah, there we go. Reproduced on:
Linux RedTail 3.19.0-031900rc5-generic #201501180935 SMP Sun Jan 18 09:36:49 UTC 2015 x86_64 x86_64 x86_64 GNU/Linux

tags: added: kernel-bug-exists-upstream
Changed in linux (Ubuntu):
status: Incomplete → Confirmed
Revision history for this message
penalvch (penalvch) wrote :

Chris Halse Rogers, did this problem not occur in either a prior kernel version or release prior to Vivid?

Also, could you please test the latest mainline kernel 3.19-rc6 and advise to the results?

Changed in linux (Ubuntu):
status: Confirmed → Incomplete
Revision history for this message
Chris Halse Rogers (raof) wrote :

From memory it has occurred in all the Vivid kernels; I can't recall whether or not it applied to earlier kernels.

I'll test the rc6 kernel, but is there any particular reason to think it got fixed since rc5?

Revision history for this message
Chris Halse Rogers (raof) wrote :

(This means it has occurred at least as far back as the 3.16 kernel)

Changed in linux (Ubuntu):
status: Incomplete → Confirmed
Revision history for this message
penalvch (penalvch) wrote :

Chris Halse Rogers, just to clarify, this is or is not reproducible in 3.19-rc6?

Changed in linux (Ubuntu):
status: Confirmed → Incomplete
Revision history for this message
Chris Halse Rogers (raof) wrote :

I have not yet reproduced it with 3.19-rc6, but it generally only happens about once a day, and I'm in Brussels for this week.

Revision history for this message
Chris Halse Rogers (raof) wrote :

Yup. Reproduced on 3.19 final.

Changed in linux (Ubuntu):
status: Incomplete → Confirmed
Revision history for this message
penalvch (penalvch) wrote :

Chris Halse Rogers, the issue you are reporting is an upstream one. Could you please report this problem to the appropriate mailing list (linux-usb) via https://wiki.ubuntu.com/Bugs/Upstream/kernel ?

Please provide a direct URL to your e-mail to the mailing list once you have made it so that it may be tracked via http://vger.kernel.org/vger-lists.html . It can take a day for the new e-mail to show up in the respective archive.

Thank you for your understanding.

tags: added: kernel-bug-exists-upstream-3.19
Changed in linux (Ubuntu):
status: Confirmed → Triaged
Revision history for this message
Colan Schwartz (colan) wrote :

Getting this on my System76 Galago UltraPro. Looks like the latest incarnation of bug #1254581 which I previously got.

Changed in system76:
status: New → Triaged
importance: Undecided → High
Revision history for this message
Clancy (spamplz) wrote :
Download full text (8.4 KiB)

I have a similar issue, though I've so far only seen it once. I plugged in two separate HDD's into two separate USB3 ports and neither worked. The syslog is below. Rebooting the system cleared up the issue and they both work ok afterwards.

Kernel: 3.13.0-62-generic
Linux Mint 17 qiana
ASUS P8H61-I Motherboard

Oct 7 08:41:01 server kernel: [246482.379384] usb 4-1: new SuperSpeed USB device number 2 using xhci_hcd
Oct 7 08:41:01 server kernel: [246482.392411] usb 4-1: Parent hub missing LPM exit latency info. Power management will be impacted.
Oct 7 08:41:03 server kernel: [246484.150227] usb 4-1: New USB device found, idVendor=174c, idProduct=5106
Oct 7 08:41:03 server kernel: [246484.150234] usb 4-1: New USB device strings: Mfr=2, Product=3, SerialNumber=1
Oct 7 08:41:03 server kernel: [246484.150237] usb 4-1: Product: AS2105
Oct 7 08:41:03 server kernel: [246484.150240] usb 4-1: Manufacturer: ASMedia
Oct 7 08:41:03 server kernel: [246484.150242] usb 4-1: SerialNumber: TF755AY9KZXWGM
Oct 7 08:41:03 server kernel: [246484.231617] usb-storage 4-1:1.0: USB Mass Storage device detected
Oct 7 08:41:03 server kernel: [246484.231831] scsi6 : usb-storage 4-1:1.0
Oct 7 08:41:03 server kernel: [246484.232051] usbcore: registered new interface driver usb-storage
Oct 7 08:41:04 server kernel: [246485.231633] scsi 6:0:0:0: Direct-Access HGST HTS 725050A7E630 GH2Z PQ: 0 ANSI: 0
Oct 7 08:41:04 server kernel: [246485.232021] sd 6:0:0:0: Attached scsi generic sg3 type 0
Oct 7 08:41:04 server kernel: [246485.232283] sd 6:0:0:0: [sdc] 976773168 512-byte logical blocks: (500 GB/465 GiB)
Oct 7 08:41:04 server kernel: [246485.232674] sd 6:0:0:0: [sdc] Write Protect is off
Oct 7 08:41:04 server kernel: [246485.232678] sd 6:0:0:0: [sdc] Mode Sense: 23 00 00 00
Oct 7 08:41:04 server kernel: [246485.233944] sd 6:0:0:0: [sdc] No Caching mode page found
Oct 7 08:41:04 server kernel: [246485.233948] sd 6:0:0:0: [sdc] Assuming drive cache: write through
Oct 7 08:41:04 server kernel: [246485.235344] sd 6:0:0:0: [sdc] No Caching mode page found
Oct 7 08:41:04 server kernel: [246485.235349] sd 6:0:0:0: [sdc] Assuming drive cache: write through
Oct 7 08:41:04 server kernel: [246485.271401] sdc: sdc1
Oct 7 08:41:04 server kernel: [246485.272560] sd 6:0:0:0: [sdc] No Caching mode page found
Oct 7 08:41:04 server kernel: [246485.272563] sd 6:0:0:0: [sdc] Assuming drive cache: write through
Oct 7 08:41:04 server kernel: [246485.272566] sd 6:0:0:0: [sdc] Attached SCSI disk
Oct 7 08:41:11 server kernel: [246492.384511] usb 3-2: new high-speed USB device number 4 using xhci_hcd
Oct 7 08:41:27 server kernel: [246497.388741] xhci_hcd 0000:04:00.0: Timeout while waiting for address device command

Oct 7 08:41:27 server kernel: [246508.406142] usb 3-2: Device not responding to set address.
Oct 7 08:41:27 server kernel: [246508.610298] usb 3-2: device not accepting address 4, error -71
Oct 7 08:41:48 server kernel: [246513.614556] xhci_hcd 0000:04:00.0: Timeout while waiting for a slot
Oct 7 08:41:48 server kernel: [246524.820348] ------------[ cut here ]------------
Oct 7 08:41:48 server kernel: [246524.820356] WARNING: CPU: 0 PID:...

Read more...

Revision history for this message
Federico Briata (federicobriata) wrote :

Hi Folks,
I have the same problem and I'm on nc4400 with USB2 only.
Anyone know latest stable kernel?

$ uname -a
Linux HP 3.13.0-65-generic #106-Ubuntu SMP Fri Oct 2 22:12:08 UTC 2015 i686 i686 i686 GNU/Linux
$ dmesg | grep usb | grep USB
[57876.412150] usb 3-2: new full-speed USB device number 91 using uhci_hcd
[57876.592397] usb 3-2: New USB device found, idVendor=1ec4, idProduct=8004
[57876.592407] usb 3-2: New USB device strings: Mfr=1, Product=2, SerialNumber=0
[57876.916335] usb 3-2: USB disconnect, device number 91
[57878.944147] usb 3-2: new full-speed USB device number 92 using uhci_hcd
[57879.124356] usb 3-2: New USB device found, idVendor=1ec4, idProduct=8004
[57879.124366] usb 3-2: New USB device strings: Mfr=1, Product=2, SerialNumber=0
[57879.396302] usb 3-2: USB disconnect, device number 92
[57881.620115] usb 3-2: new full-speed USB device number 93 using uhci_hcd
[57881.801383] usb 3-2: New USB device found, idVendor=1ec4, idProduct=8004
[57881.801394] usb 3-2: New USB device strings: Mfr=1, Product=2, SerialNumber=0
[57882.124227] usb 3-2: USB disconnect, device number 93
[57884.348170] usb 3-2: new full-speed USB device number 94 using uhci_hcd
[57884.528399] usb 3-2: New USB device found, idVendor=1ec4, idProduct=8004
[57884.528410] usb 3-2: New USB device strings: Mfr=1, Product=2, SerialNumber=0
[57884.852319] usb 3-2: USB disconnect, device number 94

Revision history for this message
Chris Halse Rogers (raof) wrote :

FWIW I can't recall getting this error on the 4.2 kernels currently in Wily. This might be fixed in 15.10.

Revision history for this message
Matthew D. Mower (mdmower) wrote :

Chris Halse Rogers: This issue still exists in Wily (as of Nov 18, 2015 with kernel 4.2.0-18-generic.

Kernel log: http://paste.ubuntu.com/13335527/
Note: I've stripped out UFW lines that are cumbersome to read past.

Line 1109 marks the time that I had to hard reset my computer because every USB port was dead (re-plugging did not help).

Revision history for this message
Matthew D. Mower (mdmower) wrote :

Following-up on #16: Obviously, this is _not_ the solution for everyone, but for my work computer, system stability is far more important that USB3. I disabled xhci in UEFI (so ehci is used instead) and have not had any more non-responsive USB ports in close to two weeks.

Revision history for this message
Rocko (rockorequin) wrote :

Does this bug happen for people after a USB drive has spun down and the computer tries to access it? My USB freezing issue goes away if I disable UAS for a particular drive. It works fine with UAS until it spins down but the USB subsystem freezes when it tries to spin it up, requiring me to reboot the PC and power cycle the drive.

To disable UAS for the drive, first find its identifier with the lsbusb command. For example mine looks like this, ie with identifier 1058:1230:

Bus 002 Device 003: ID 1058:1230 Western Digital Technologies, Inc. My Book

Add a file like /etc/modprobe.d/usb_storage.conf with the contents and the appropriate identifier:

options usb_storage quirks=1058:1230:u

and run "sudo update-initramfs -u -k all" and reboot.

Revision history for this message
Colan Schwartz (colan) wrote :

In my case there are no drives involved, just a hub with a camera.

Revision history for this message
Ian Canino (ian-canino) wrote :

This issue still exists on
Laptop: Macbook Pro 11,1 (2014 13" model)
Ubuntu: Yakkety (16.10)
Kernel: Linux version 4.8.0-41-generic (buildd@lgw01-18)

Revision history for this message
Max Rumpf (maxr1998) wrote :

I also have this issue on my Asus M5A99X EVO motherboard with a AMD FX-4100 CPU; Ubuntu 16.10 and kernel version 4.8.0-46-generic.

Revision history for this message
martonmiklos (martonmiklosqdev) wrote :

This issue still exists on:
iMac 27" late 2015
Ubuntu 14.04 both with
Kernel: 3.19.0-80 and 4.4.0-62

It only happends when I a Saleae USB 3.0 Logic analyzer is plugged into the machine. (This is the only USB 3.0 device attached to the system)

Revision history for this message
Kai-Heng Feng (kaihengfeng) wrote :

Latest mainline kernel has several xhci race condition fix. Can you try it?

Revision history for this message
Jason A. Donenfeld (zx2c4) wrote :

I'm having this issue on kernel 4.11.1.

[48112.422418] ------------[ cut here ]------------
[48112.422441] WARNING: CPU: 0 PID: 14420 at drivers/usb/host/xhci-ring.c:1390 handle_cmd_completion+0xb17/0xc00 [xhci_hcd]
[48112.422446] Modules linked in: xt_hashlimit ip6_udp_tunnel udp_tunnel rfcomm pl2303 hid_lenovo bnep cdc_mbim cdc_ncm qcserial cdc_wdm usb_wwan usbnet usbserial mii uvcvideo videobuf2_vmalloc videobuf2_memops
[48112.422480] xhci_hcd 0000:00:14.0: Timeout while waiting for setup device command
[48112.422481] videobuf2_v4l2 videobuf2_core cdc_acm videodev btusb btintel usbhid bluetooth af_packet nf_conntrack_ipv4 nf_defrag_ipv4 iptable_filter xt_hl nf_conntrack_ipv6 nf_defrag_ipv6 xt_multiport 8021q xt_conntrack nf_conntrack ip6table_filter ip6_tables algif_skcipher joydev mousedev snd_hda_codec_realtek snd_hda_codec_generic arc4 iwlmvm mac80211 rtsx_pci_sdmmc mmc_core intel_rapl iosf_mbi x86_pkg_temp_thermal intel_powerclamp coretemp kvm_intel kvm iwlwifi snd_hda_intel ahci irqbypass snd_hda_codec crc32_pclmul snd_hwdep xhci_pci xhci_hcd libahci crc32c_intel snd_hda_core mei_me cfg80211 usbcore snd_pcm rtsx_pci ie31200_edac input_leds mfd_core e1000e libata usb_common mei snd_timer psmouse edac_core intel_pch_thermal thinkpad_acpi snd soundcore led_class rfkill tpm_tis tpm_tis_core evdev
[48112.422556] tpm sch_fq_codel
[48112.422565] CPU: 0 PID: 14420 Comm: kworker/0:7 Tainted: P W O 4.11.1-gentoo #1
[48112.422567] Hardware name: LENOVO 20ENCTO1WW/20ENCTO1WW, BIOS N1EET65W (1.38 ) 02/09/2017
[48112.422577] Workqueue: events xhci_handle_command_timeout [xhci_hcd]
[48112.422580] Call Trace:
[48112.422583] <IRQ>
[48112.422589] ? dump_stack+0x46/0x5e
[48112.422595] ? __warn+0xb9/0xe0
[48112.422603] ? handle_cmd_completion+0xb17/0xc00 [xhci_hcd]
[48112.422609] ? try_to_wake_up+0x22e/0x390
[48112.422617] ? xhci_irq+0x38f/0x1460 [xhci_hcd]
[48112.422624] ? run_timer_softirq.part.2+0x4c/0xa0
[48112.422629] ? expire_timers+0x6e/0xe0
[48112.422634] ? __handle_irq_event_percpu+0x36/0x190
[48112.422637] ? handle_irq_event_percpu+0x1b/0x50
[48112.422640] ? handle_irq_event+0x22/0x40
[48112.422644] ? handle_edge_irq+0x65/0x120
[48112.422649] ? handle_irq+0x11/0x20
[48112.422653] ? do_IRQ+0x3c/0xc0
[48112.422658] ? common_interrupt+0x7f/0x7f
[48112.422660] </IRQ>
[48112.422664] ? _raw_spin_unlock_irqrestore+0x5/0x10
[48112.422671] ? xhci_handle_command_timeout+0xf4/0x1b0 [xhci_hcd]
[48112.422684] ? process_one_work+0x1d9/0x450
[48112.422689] ? worker_thread+0x42/0x4b0
[48112.422695] ? process_one_work+0x450/0x450
[48112.422698] ? kthread+0x112/0x130
[48112.422702] ? kthread_create_on_node+0x40/0x40
[48112.422705] ? ret_from_fork+0x23/0x30
[48112.422709] ---[ end trace eb9505885b6e349e ]---
[48113.446247] xhci_hcd 0000:00:14.0: xHCI host not responding to stop endpoint command.
[48113.446250] xhci_hcd 0000:00:14.0: Assuming host is dying, halting host.
[48113.446348] xhci_hcd 0000:00:14.0: HC died; cleaning up

Revision history for this message
Sebastiaan Breedveld (s-breedveld) wrote :

I am having the same problem, but only after resume from suspend or hibernate. I first thought it was a bluetooth problem, as my bluetooth mouse stops working after a minute or so after resume. However, both the bluetooth adapter is gone (bluetoothctl says "No Default controller"), but also ordinary USB mice will not work.

It seems that HCI dies, and the kernel decides to remove everything else as well. Touchpad works however.

I am running 18.04 alpha with 4.16rc3 (4.16.0-041600rc3-generic) mainline kernel. Hardware: Lenovo Thinkpad E580.

Full syslog output. BTW: "MX Anywhere 2" is a BT mouse, not a keyboard. Not sure why it is registered as such.

Feb 28 14:18:00 miCycle bluetoothd[1040]: Unable to register org.bluez.Battery1 interface for /org/bluez/hci0/dev_E8_02_AE_59_01_F8
Feb 28 14:18:01 miCycle kernel: [13423.017919] input: MX Anywhere 2 as /devices/virtual/misc/uhid/0005:046D:B018.0002/input/input19
Feb 28 14:18:01 miCycle kernel: [13423.018374] hid-generic 0005:046D:B018.0002: input,hidraw0: BLUETOOTH HID v0.09 Keyboard [MX Anywhere 2] on A0:D3:7A:E0:62:A2
Feb 28 14:18:01 miCycle upowerd[1731]: unhandled action 'bind' on /sys/devices/virtual/misc/uhid/0005:046D:B018.0002
Feb 28 14:18:15 miCycle blueman-mechanism: Exiting
Feb 28 14:18:42 miCycle kernel: [13464.682662] xhci_hcd 0000:00:14.0: xHC is not running.
Feb 28 14:18:42 miCycle kernel: [13464.724396] xhci_hcd 0000:00:14.0: xHCI host controller not responding, assume dead
Feb 28 14:18:42 miCycle kernel: [13464.724414] xhci_hcd 0000:00:14.0: HC died; cleaning up
Feb 28 14:18:42 miCycle kernel: [13464.746152] usb 1-5: USB disconnect, device number 4
Feb 28 14:18:42 miCycle kernel: [13464.801790] usb 1-6: USB disconnect, device number 3
Feb 28 14:18:42 miCycle systemd[1]: bluetooth.target: Unit not needed anymore. Stopping.
Feb 28 14:18:42 miCycle systemd[1]: Stopped target Bluetooth.
Feb 28 14:18:42 miCycle upowerd[1731]: unhandled action 'unbind' on /sys/devices/pci0000:00/0000:00:14.0/usb1/1-5/1-5:1.1
Feb 28 14:18:42 miCycle upowerd[1731]: unhandled action 'unbind' on /sys/devices/pci0000:00/0000:00:14.0/usb1/1-5/1-5:1.0
Feb 28 14:18:42 miCycle upowerd[1731]: unhandled action 'unbind' on /sys/devices/pci0000:00/0000:00:14.0/usb1/1-6/1-6:1.1
Feb 28 14:18:42 miCycle upowerd[1731]: unhandled action 'unbind' on /sys/devices/pci0000:00/0000:00:14.0/usb1/1-6/1-6:1.0
Feb 28 14:18:42 miCycle upowerd[1731]: unhandled action 'unbind' on /sys/devices/pci0000:00/0000:00:14.0/usb1/1-5
Feb 28 14:18:42 miCycle upowerd[1731]: unhandled action 'unbind' on /sys/devices/pci0000:00/0000:00:14.0/usb1/1-6
Feb 28 14:18:42 miCycle acpid: input device has been disconnected, fd 19
Feb 28 14:18:42 miCycle bluetoothd[1040]: Endpoint unregistered: sender=:1.52 path=/MediaEndpoint/A2DPSource
Feb 28 14:18:42 miCycle bluetoothd[1040]: Endpoint unregistered: sender=:1.52 path=/MediaEndpoint/A2DPSink
Feb 28 14:18:42 miCycle upowerd[1731]: unhandled action 'unbind' on /sys/devices/virtual/misc/uhid/0005:046D:B018.0002
Feb 28 14:18:42 miCycle NetworkManager[879]: <info> [1519823922.9176] bluez5: NAP: removed interface A0:D3:7A:E0:62:A2

Revision history for this message
Sebastiaan Breedveld (s-breedveld) wrote :

I can finally report a working solution for me.

Ubuntu 18.04 alpha
kernel 4.15.0-13-generic

Add these options to the GRUB command line:
pci=nomsi iommu=soft

USB works like a charm after resume :)

Revision history for this message
Daniel Mulholland (dan-mulholland) wrote :

FWIW With a Dell XPS 9360 and Kubuntu 17.10, same issue on the latest kernel and many previous:

uname -a
Linux mulhollandd-XPS-13-9360 4.16.2-041602-generic #201804121130 SMP Thu Apr 12 11:32:17 UTC 2018 x86_64 x86_64 x86_64 GNU/Linux

lsb
_release -a
No LSB modules are available.
Distributor ID: Ubuntu
Description: Ubuntu 17.10
Release: 17.10
Codename: artful

I will test the solution mentioned by @s-breedveld of applying: "pci=nomsi iommu=soft" and report if this helps.

In my case this is a bluetooth mouse which disappears after suspend.

A dmesg output indicates:

[ 3380.759427] xhci_hcd 0000:00:14.0: xHC is not running.
[ 3380.774604] xhci_hcd 0000:00:14.0: xHCI host controller not responding, assume dead
[ 3380.774627] xhci_hcd 0000:00:14.0: HC died; cleaning up
[ 3380.775306] usb 2-1: USB disconnect, device number 2
[ 3381.059095] usb 1-1: USB disconnect, device number 2
[ 3381.059098] usb 1-1.2: USB disconnect, device number 4
[ 3381.059408] usb 1-3: USB disconnect, device number 3
[ 3381.059735] usb 1-5: USB disconnect, device number 5

A power-down is usually required to fix this, a reboot does bring the device back to life.

Revision history for this message
Felipe Reyes (freyes) wrote :

dell latitude 7380, having the same issue, I will try the workaround from comment #26

 ~ $ uname -a
Linux maul 4.15.0-15-generic #16-Ubuntu SMP Wed Apr 4 13:58:14 UTC 2018 x86_64 x86_64 x86_64 GNU/Linux
 ~ $ lsb_release -a
LSB Version: core-9.20170808ubuntu1-noarch:security-9.20170808ubuntu1-noarch
Distributor ID: Ubuntu
Description: Ubuntu Bionic Beaver (development branch)
Release: 18.04
Codename: bionic

[170301.135847] ACPI: Waking up from system sleep state S3
[170301.907173] ACPI: EC: event unblocked
[170301.929222] usb usb1: root hub lost power or was reset
[170301.929225] usb usb2: root hub lost power or was reset
[170302.273594] usb 1-5: reset high-speed USB device number 2 using xhci_hcd
[170302.449792] restoring control 00000000-0000-0000-0000-000000000101/10/5
[170302.449795] restoring control 00000000-0000-0000-0000-000000000101/12/11
[170303.165975] [drm] RC6 on
[170304.839647] xhci_hcd 0000:00:14.0: Cannot set link state.
[170304.839723] usb usb2-port2: cannot disable (err = -32)
...
[170304.844725] OOM killer enabled.
[170304.844725] Restarting tasks ...
[170304.848669] usb 2-2: USB disconnect, device number 9
...
[170307.034795] xhci_hcd 0000:00:14.0: xHCI host controller not responding, assume dead
[170307.034810] xhci_hcd 0000:00:14.0: HC died; cleaning up
[170307.034880] usb 1-5: USB disconnect, device number 2

Revision history for this message
Alex Garel (alex-garel) wrote :
Download full text (17.2 KiB)

Hello, I have the same issue with my laptop (very annoying).

I will try to upgrade to 18.04, see if it fixes, and, if not, try on s-breedveld solution.

$ sudo lshw
[sudo] Mot de passe de alex :
Désolé, essayez de nouveau.
[sudo] Mot de passe de alex :
tignasse
    description: Ordinateur portable
    produit: Skylake Platform (System SKUNumber)
    fabriquant: Intel Corporation
    version: 0.1
    numéro de série: System Serial Number
    bits: 64 bits
    fonctionnalités: smbios-3.0 dmi-3.0 smp vsyscall32
    configuration: boot=normal chassis=laptop family=Skylake System sku=System SKUNumber uuid=00020003-0004-0005-0006-000700080009
  *-core
       description: Carte mère
       produit: WhiteTip Mountain1 Fab2
       fabriquant: Topstar
       identifiant matériel: 0
       version: RVP7
       numéro de série: 1
       emplacement: Part Component
     *-firmware
          description: BIOS
          fabriquant: American Megatrends Inc.
          identifiant matériel: 0
          version: 5.11
          date: 11/06/2015
          taille: 64KiB
          capacité: 6080KiB
          fonctionnalités: pci upgrade shadowing cdboot bootselect socketedrom edd int13floppy1200 int13floppy720 int13floppy2880 int5printscreen int9keyboard int14serial int17printer acpi usb biosbootspecification uefi
     *-cache:0
          description: L1 cache
          identifiant matériel: 3d
          emplacement: L1 Cache
          taille: 64KiB
          capacité: 64KiB
          fonctionnalités: synchronous internal write-back data
          configuration: level=1
     *-cache:1
          description: L1 cache
          identifiant matériel: 3e
          emplacement: L1 Cache
          taille: 64KiB
          capacité: 64KiB
          fonctionnalités: synchronous internal write-back instruction
          configuration: level=1
     *-cache:2
          description: L2 cache
          identifiant matériel: 3f
          emplacement: L2 Cache
          taille: 512KiB
          capacité: 512KiB
          fonctionnalités: synchronous internal write-back unified
          configuration: level=2
     *-cache:3
          description: L3 cache
          identifiant matériel: 40
          emplacement: L3 Cache
          taille: 4MiB
          capacité: 4MiB
          fonctionnalités: synchronous internal write-back unified
          configuration: level=3
     *-cpu
          description: CPU
          produit: Intel(R) Core(TM) i7-6500U CPU @ 2.50GHz
          fabriquant: Intel Corp.
          identifiant matériel: 41
          information bus: cpu@0
          version: Intel(R) Core(TM) i7-6500U CPU @ 2.50GHz
          numéro de série: To Be Filled By O.E.M.
          emplacement: U3E1
          taille: 730MHz
          capacité: 4005MHz
          bits: 64 bits
          horloge: 100MHz
          fonctionnalités: x86-64 fpu fpu_exception wp vme de pse tsc msr pae mce cx8 apic sep mtrr pge mca cmov pat pse36 clflush dts acpi mmx fxsr sse sse2 ss ht tm pbe syscall nx pdpe1gb rdtscp constant_tsc art arch_perfmon pebs bts rep_good nopl xtopology nonstop_tsc cpuid aperfmperf tsc_known_freq pni pclmulqdq dtes64 monitor ds_cpl vmx est tm2 ssse3 sdbg fm...

Revision history for this message
bp0 (bullet-proof-0) wrote :

The workaround in comment #26 works for me on a Lenovo Yoga 720-15 running kernel 4.17.0-041700rc3-generic.

Revision history for this message
Alex Garel (alex-garel) wrote :

Just upgrading to 18.04 seems to fix the problem for me !

$ uname -a
Linux tignasse 4.15.0-20-generic #21-Ubuntu SMP Tue Apr 24 06:16:15 UTC 2018 x86_64 x86_64 x86_64 GNU/Linux

$ lsb_release -a
LSB Version: core-9.20170808ubuntu1-noarch:printing-9.20170808ubuntu1-noarch:security-9.20170808ubuntu1-noarch
Distributor ID: Ubuntu
Description: Ubuntu 18.04 LTS
Release: 18.04
Codename: bionic

Revision history for this message
Erik Kallen (erikkallen) wrote :

Upgrading to 18.04 seems has made this bug appear for me.
I have tried updating to the latest kernel but that did not help.

$ uname -a

Linux erikkallen-laptop 4.17.0-041700rc4-generic #201805070430 SMP Mon May 7 04:31:46 UTC 2018 x86_64 x86_64 x86_64 GNU/Linux

$ lsb_release -a

No LSB modules are available.
Distributor ID: Ubuntu
Description: Ubuntu 18.04 LTS
Release: 18.04
Codename: bionic

Revision history for this message
Sebastiaan Breedveld (s-breedveld) wrote :

@info-erikkallen : did you try the solution proposed in post #26 ?

Revision history for this message
Volodymyr Shymanskyi (vshymanskyi) wrote :

Lenovo IdeaPad 720s (i5-8250U), the same issue.

On resume, I get:
[ 213.347656] usb 1-7: device descriptor read/64, error -110

➜ ~ lsusb -t
/: Bus 02.Port 1: Dev 1, Class=root_hub, Driver=xhci_hcd/6p, 5000M
    |__ Port 2: Dev 2, If 0, Class=Mass Storage, Driver=usb-storage, 5000M
/: Bus 01.Port 1: Dev 1, Class=root_hub, Driver=xhci_hcd/12p, 480M
    |__ Port 5: Dev 2, If 1, Class=Video, Driver=uvcvideo, 480M
    |__ Port 5: Dev 2, If 0, Class=Video, Driver=uvcvideo, 480M
    |__ Port 6: Dev 3, If 0, Class=Vendor Specific Class, Driver=, 12M
    |__ Port 7: Dev 5, If 0, Class=Wireless, Driver=btusb, 12M
    |__ Port 7: Dev 5, If 1, Class=Wireless, Driver=btusb, 12M

This way, i was getting my BT adapter disconnected.
But also I was experiencing a USB3 flash drive reconnecting unexpectedly during normal operation (no sleep/resume).

'pci=nomsi iommu=soft' helped, at least for now.

➜ ~ lsb_release -a
No LSB modules are available.
Distributor ID: Ubuntu
Description: Ubuntu 18.04 LTS
Release: 18.04
Codename: bionic
➜ ~ uname -a
Linux vshymanskyy-720S 4.15.0-20-generic #21-Ubuntu SMP Tue Apr 24 06:16:15 UTC 2018 x86_64 x86_64 x86_64 GNU/Linux

Revision history for this message
Volodymyr Shymanskyi (vshymanskyi) wrote :

OK, still saw it at least once after applying 'pci=nomsi iommu=soft'.
But in general, it is much much better ;)

Revision history for this message
Sebastiaan Breedveld (s-breedveld) wrote :

@vshymanskyi: did you fully restart after adding these options to GRUB? I.e. not boot, add to GRUB, hibernate, boot again and resume. The system really needs to boot with these options prior to the first hibernate.

Another option you can try: intel_iommu=off (or perhaps amd_iommu=off, depending on your chipset).

Revision history for this message
Volodymyr Shymanskyi (vshymanskyi) wrote :

@s-breedveld thanks. I'm absolutely sure as:

➜ ~ cat /proc/cmdline
BOOT_IMAGE=/boot/vmlinuz-4.15.0-22-generic root=UUID=69ba76e3-5381-4011-99c1-195ad0e6d288 ro quiet splash pci=nomsi iommu=soft vt.handoff=1

I'll try intel_iommu=off. As I said, Intel i5-8250U.

Revision history for this message
Volodymyr Shymanskyi (vshymanskyi) wrote :

Happened again :(

When this happens:

[10006.322991] ACPI: Waking up from system sleep state S3
[10006.433962] ACPI: EC: event unblocked
[10006.441688] ACPI: button: The lid device is not compliant to SW_LID.
[10006.670082] usb 1-6: reset full-speed USB device number 3 using xhci_hcd
[10006.946396] usb 1-5: reset high-speed USB device number 2 using xhci_hcd
[10007.222532] usb 1-7: reset full-speed USB device number 4 using xhci_hcd
[10007.830663] [drm] RC6 on
??? [10011.663755] ideapad_laptop: Unknown event: 10
>>> [10012.502311] usb 1-7: device descriptor read/64, error -110
??? [10016.568097] OOM killer enabled.
[10016.568098] Restarting tasks ... done.
[10016.625870] PM: suspend exit
[10016.636823] IPv6: ADDRCONF(NETDEV_UP): wlp58s0: link is not ready
>>> [10016.885790] usb 1-7: USB disconnect, device number 4
[10017.400431] ath10k_pci 0000:3a:00.0: Unknown eventid: 118809
[10017.403476] ath10k_pci 0000:3a:00.0: Unknown eventid: 90118
[10017.419240] IPv6: ADDRCONF(NETDEV_UP): wlp58s0: link is not ready
[10017.485763] IPv6: ADDRCONF(NETDEV_UP): wlp58s0: link is not ready
[10026.334678] xhci_hcd 0000:00:14.0: Secondary root hub is not suspended
[10026.402269] xhci_hcd 0000:00:14.0: Root hub is not suspended

➜ ~ cat /proc/cmdline
BOOT_IMAGE=/boot/vmlinuz-4.15.0-22-generic root=UUID=69ba76e3-5381-4011-99c1-195ad0e6d288 ro quiet splash pci=nomsi iommu=soft intel_iommu=off vt.handoff=1

Revision history for this message
Sebastiaan Breedveld (s-breedveld) wrote :

Hmm, that's outright annoying. Do you resume from hibernate or from suspend?

I can only think of 2 other options to try:
- upgrade to a newer kernel (or even try downgrading - see what that does):
http://kernel.ubuntu.com/~kernel-ppa/mainline/

- use software suspend (uswsusp package). Configuring can be a bit tricky though, as the system suspend/hibernate commands are not automatically adjusted, so invoke hibernate manually by s2disk .

Revision history for this message
Mark van Beek (mark-appelit) wrote :

There are a few variations on the "USB stops working after a while" bug(s), I have come across one on a (newly bought) desktop machine that tells me "xHCI host controller not responding, assume dead". The only fix I found is turning of autosuspend for USB completely.

While searching I found this message on the kernel usb mailinglist: https://www.spinics.net/lists/linux-usb/msg168676.html, though my bug might not actually be related to this one, I thought I'd point to the patch since it might be the fix for this issue as well.

Revision history for this message
Martin Dünkelmann (nc-duenkekl3-deactivatedaccount) wrote :
Download full text (123.1 KiB)

Kernel 4.15
Linux Mint 19 / Ubuntu 18.04
ThinkPad 460p
I locked my laptop, after a while, I unlocked it.
USB dead.

[ 0.000000] Linux version 4.15.0-23-generic (buildd@lgw01-amd64-055) (gcc version 7.3.0 (Ubuntu 7.3.0-16ubuntu3)) #25-Ubuntu SMP Wed May 23 18:02:16 UTC 2018 (Ubuntu 4.15.0-23.25-generic 4.15.18)
[ 0.000000] Command line: BOOT_IMAGE=/boot/vmlinuz-4.15.0-23-generic root=UUID=e0c22f5c-524e-413d-a972-b04e72fcc526 ro quiet splash nopti vt.handoff=1
[ 0.000000] KERNEL supported cpus:
[ 0.000000] Intel GenuineIntel
[ 0.000000] AMD AuthenticAMD
[ 0.000000] Centaur CentaurHauls
[ 0.000000] x86/fpu: Supporting XSAVE feature 0x001: 'x87 floating point registers'
[ 0.000000] x86/fpu: Supporting XSAVE feature 0x002: 'SSE registers'
[ 0.000000] x86/fpu: Supporting XSAVE feature 0x004: 'AVX registers'
[ 0.000000] x86/fpu: Supporting XSAVE feature 0x008: 'MPX bounds registers'
[ 0.000000] x86/fpu: Supporting XSAVE feature 0x010: 'MPX CSR'
[ 0.000000] x86/fpu: xstate_offset[2]: 576, xstate_sizes[2]: 256
[ 0.000000] x86/fpu: xstate_offset[3]: 832, xstate_sizes[3]: 64
[ 0.000000] x86/fpu: xstate_offset[4]: 896, xstate_sizes[4]: 64
[ 0.000000] x86/fpu: Enabled xstate features 0x1f, context size is 960 bytes, using 'compacted' format.
[ 0.000000] e820: BIOS-provided physical RAM map:
[ 0.000000] BIOS-e820: [mem 0x0000000000000000-0x0000000000057fff] usable
[ 0.000000] BIOS-e820: [mem 0x0000000000058000-0x0000000000058fff] reserved
[ 0.000000] BIOS-e820: [mem 0x0000000000059000-0x000000000009cfff] usable
[ 0.000000] BIOS-e820: [mem 0x000000000009d000-0x00000000000fffff] reserved
[ 0.000000] BIOS-e820: [mem 0x0000000000100000-0x00000000a33fbfff] usable
[ 0.000000] BIOS-e820: [mem 0x00000000a33fc000-0x00000000a33fcfff] ACPI NVS
[ 0.000000] BIOS-e820: [mem 0x00000000a33fd000-0x00000000a3446fff] reserved
[ 0.000000] BIOS-e820: [mem 0x00000000a3447000-0x00000000ad61bfff] usable
[ 0.000000] BIOS-e820: [mem 0x00000000ad61c000-0x00000000ad66bfff] type 20
[ 0.000000] BIOS-e820: [mem 0x00000000ad66c000-0x00000000afeadfff] reserved
[ 0.000000] BIOS-e820: [mem 0x00000000afeae000-0x00000000affadfff] ACPI NVS
[ 0.000000] BIOS-e820: [mem 0x00000000affae000-0x00000000afffdfff] ACPI data
[ 0.000000] BIOS-e820: [mem 0x00000000afffe000-0x00000000afffefff] usable
[ 0.000000] BIOS-e820: [mem 0x00000000affff000-0x00000000b7ffffff] reserved
[ 0.000000] BIOS-e820: [mem 0x00000000b8600000-0x00000000bc7fffff] reserved
[ 0.000000] BIOS-e820: [mem 0x00000000f80fa000-0x00000000f80fafff] reserved
[ 0.000000] BIOS-e820: [mem 0x00000000f80fd000-0x00000000f80fdfff] reserved
[ 0.000000] BIOS-e820: [mem 0x00000000fe000000-0x00000000fe010fff] reserved
[ 0.000000] BIOS-e820: [mem 0x0000000100000000-0x00000008417fffff] usable
[ 0.000000] NX (Execute Disable) protection: active
[ 0.000000] efi: EFI v2.40 by Lenovo
[ 0.000000] efi: SMBIOS=0xaef68000 ACPI=0xafffd000 ACPI 2.0=0xafffd014 ESRT=0xaeddd000
[ 0.000000] secureboot: Secure boot could not be determined (mode 0)
[ 0.000000] random: fast init done
[ 0.000000] SMBIOS 2.8 present.
[ 0.000000] ...

Revision history for this message
Kai-Heng Feng (kaihengfeng) wrote :

For those who see "xhci_hcd 0000:00:14.0: xHCI host controller not responding, assume dead" in the dmesg, please subscribe to LP: #1763594.

I am building a test kernel for that bug.

Revision history for this message
Jeremy David Parsons (ubuntu-jeremyparsons) wrote :
Download full text (3.5 KiB)

My HP Intel laptop drops all USB ports when I use the Bluetooth Internet connection for 30 minutes or so after a wake. I notice that the laptop also seems to be using power whilst suspended sometimes and Hibernate doesn't work. I'm running 18.04 Ubuntu Mate. rmmod and modprobe didn't revive anything on the usual modules but some self reference so cannot easily be removed.

Here is dmesg immediately after the bluetooth connection is lost:

[39669.384218] ata2.00: configured for UDMA/133
[39669.466221] IPv6: ADDRCONF(NETDEV_UP): eno1: link is not ready
[39669.490467] r8169 0000:03:00.0 eno1: link down
[39669.490580] IPv6: ADDRCONF(NETDEV_UP): eno1: link is not ready
[39669.491931] IPv6: ADDRCONF(NETDEV_UP): wlo1: link is not ready
[39669.609788] IPv6: ADDRCONF(NETDEV_UP): wlo1: link is not ready
[39669.677970] IPv6: ADDRCONF(NETDEV_UP): wlo1: link is not ready
[39795.587223] xhci_hcd 0000:00:14.0: Root hub is not suspended
[39798.567935] xhci_hcd 0000:00:14.0: xHC is not running.
[39798.644797] Bluetooth: hci0: ACL packet for unknown connection handle 256
[39801.599009] xhci_hcd 0000:00:14.0: xHC is not running.
[39930.151365] xhci_hcd 0000:00:14.0: Root hub is not suspended
[39951.299946] xhci_hcd 0000:00:14.0: Root hub is not suspended
[39954.175628] xhci_hcd 0000:00:14.0: Root hub is not suspended
[39964.351385] xhci_hcd 0000:00:14.0: Root hub is not suspended
[39969.676926] xhci_hcd 0000:00:14.0: Root hub is not suspended
[39997.547921] xhci_hcd 0000:00:14.0: Root hub is not suspended
[40007.545234] xhci_hcd 0000:00:14.0: Root hub is not suspended
[40578.991313] xhci_hcd 0000:00:14.0: Root hub is not suspended
[40916.053930] xhci_hcd 0000:00:14.0: xHC is not running.
[40916.065492] xhci_hcd 0000:00:14.0: xHCI host controller not responding, assume dead
[40916.065504] xhci_hcd 0000:00:14.0: HC died; cleaning up
[40918.489785] usb 1-4: USB disconnect, device number 3
[40918.490068] usb 1-7: USB disconnect, device number 4

lspci
00:00.0 Host bridge: Intel Corporation Skylake Host Bridge/DRAM Registers (rev 07)
00:02.0 VGA compatible controller: Intel Corporation HD Graphics 530 (rev 06)
00:04.0 Signal processing controller: Intel Corporation Skylake Processor Thermal Subsystem (rev 07)
00:14.0 USB controller: Intel Corporation Sunrise Point-H USB 3.0 xHCI Controller (rev 31)
00:14.2 Signal processing controller: Intel Corporation Sunrise Point-H Thermal subsystem (rev 31)
00:16.0 Communication controller: Intel Corporation Sunrise Point-H CSME HECI #1 (rev 31)
00:17.0 SATA controller: Intel Corporation Sunrise Point-H SATA Controller [AHCI mode] (rev 31)
00:1c.0 PCI bridge: Intel Corporation Sunrise Point-H PCI Express Root Port #5 (rev f1)
00:1c.5 PCI bridge: Intel Corporation Sunrise Point-H PCI Express Root Port #6 (rev f1)
00:1c.6 PCI bridge: Intel Corporation Sunrise Point-H PCI Express Root Port #7 (rev f1)
00:1f.0 ISA bridge: Intel Corporation Sunrise Point-H LPC Controller (rev 31)
00:1f.2 Memory controller: Intel Corporation Sunrise Point-H PMC (rev 31)
00:1f.3 Audio device: Intel Corporation Sunrise Point-H HD Audio (rev 31)
00:1f.4 SMBus: Intel Corporation Sunrise Point-H SMBus (rev 31)
01:00.0 Unassigned class [ff00]: Realtek Semi...

Read more...

Revision history for this message
Kai-Heng Feng (kaihengfeng) wrote :

Does this issue still happen on latest Bionic kernel?

Revision history for this message
Sebastiaan Breedveld (s-breedveld) wrote :

@kaihenfeng: I have been running linux-image-unsigned-4.15.0-38-generic from the main repository since your comment, and haven't experienced this error anymore!

Brad Figg (brad-figg)
tags: added: cscc
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.