Now and then, my xhci bus will hang, resulting in these kinds of messages in dmesg: [252220.002102] xhci_hcd 0000:00:14.0: xHC is not running. [252220.037491] xhci_hcd 0000:00:14.0: xHCI host controller not responding, assume dead [252220.037500] xhci_hcd 0000:00:14.0: HC died; cleaning up [252220.133794] usb 1-2: USB disconnect, device number 2 [252220.135042] usb 1-7: USB disconnect, device number 3 [252220.137455] usb 1-8: USB disconnect, device number 4 [252220.243317] usb 1-9: USB disconnect, device number 5 Usually, I can fix this bij resetting the bus by calling a script reset-xhci: for xhci in /sys/bus/pci/drivers/?hci_hcd ; do cd $xhci echo Resetting devices from $xhci... for i in ????:??:??.? ; do echo -n "$i" > unbind echo -n "$i" > bind done done But doing this today resulted in a kernel bug: [252243.401814] xhci_hcd 0000:00:14.0: remove, state 4 [252243.401887] usb usb2: USB disconnect, device number 1 [252243.470365] xhci_hcd 0000:00:14.0: USB bus 2 deregistered [252243.470378] xhci_hcd 0000:00:14.0: remove, state 4 [252243.470383] usb usb1: USB disconnect, device number 1 [252243.470831] xhci_hcd 0000:00:14.0: Host halt failed, -19 [252243.470837] xhci_hcd 0000:00:14.0: Host not accessible, reset failed. [252243.475918] xhci_hcd 0000:00:14.0: USB bus 1 deregistered [252243.475938] ------------[ cut here ]------------ [252243.475939] xhci_hcd 0000:00:14.0: disabling already-disabled device [252243.475951] WARNING: CPU: 2 PID: 1787 at /build/linux-bdpCf2/linux-4.15.0/drivers/pci/pci.c:1642 pci_disable_device+0x9c/0xc0 [252243.475951] Modules linked in: cpuid snd_seq_dummy usb_storage hid_generic hidp ip6t_REJECT nf_reject_ipv6 ip6table_nat nf_nat_ipv6 ip6table_mangle xt_hashlimit ip6table_raw nf_conntrack_ipv6 nf_defrag_ipv6 nf_log_ipv6 xt_recent xt_comment ipt_REJECT nf_reject_ipv4 xt_mark iptable_mangle xt_tcpudp xt_CT iptable_raw xt_multiport xt_NFLOG nfnetlink_log nf_log_ipv4 nf_log_common xt_LOG nf_conntrack_sane nf_conntrack_netlink nfnetlink nf_nat_tftp nf_nat_snmp_basic nf_conntrack_snmp nf_nat_sip nf_nat_pptp nf_nat_proto_gre nf_nat_irc nf_nat_h323 nf_nat_ftp nf_nat_amanda nf_conntrack_tftp nf_conntrack_sip nf_conntrack_pptp nf_conntrack_proto_gre nf_conntrack_netbios_ns nf_conntrack_broadcast nf_conntrack_irc nf_conntrack_h323 nf_conntrack_ftp ts_kmp nf_conntrack_amanda ipt_MASQUERADE nf_nat_masquerade_ipv4 [252243.475984] xfrm_user xfrm_algo iptable_nat nf_conntrack_ipv4 nf_defrag_ipv4 nf_nat_ipv4 xt_addrtype xt_conntrack nf_nat nf_conntrack br_netfilter aufs vhost_net vhost tap ccm rfcomm bridge stp llc devlink ebtable_filter ebtables ip6table_filter ip6_tables iptable_filter msr cmac bnep binfmt_misc snd_hda_codec_hdmi nls_iso8859_1 arc4 snd_soc_skl snd_hda_codec_realtek snd_soc_skl_ipc snd_hda_ext_core snd_hda_codec_generic snd_soc_sst_dsp snd_soc_sst_ipc snd_soc_acpi snd_soc_core snd_compress ac97_bus snd_pcm_dmaengine snd_hda_intel dell_laptop dell_smbios_smm dcdbas snd_hda_codec dell_smm_hwmon snd_hda_core snd_hwdep snd_pcm intel_rapl snd_seq_midi snd_seq_midi_event x86_pkg_temp_thermal intel_powerclamp coretemp snd_rawmidi kvm_intel kvm btusb irqbypass intel_cstate intel_rapl_perf snd_seq btrtl [252243.476023] iwlmvm btbcm btintel mac80211 hid_multitouch uvcvideo joydev input_leds dell_smbios_wmi snd_seq_device dell_wmi bluetooth serio_raw snd_timer videobuf2_vmalloc videobuf2_memops videobuf2_v4l2 dell_smbios videobuf2_core iwlwifi sparse_keymap ecdh_generic snd wmi_bmof dell_wmi_descriptor videodev cfg80211 media soundcore rtsx_pci_ms memstick shpchp mei_me mei processor_thermal_device intel_pch_thermal intel_soc_dts_iosf int3400_thermal acpi_thermal_rel dell_rbtn mac_hid acpi_pad int3403_thermal int340x_thermal_zone tpm_crb sch_fq_codel cuse parport_pc ppdev nfsd lp parport auth_rpcgss nfs_acl lockd grace sunrpc ip_tables x_tables autofs4 btrfs zstd_compress algif_skcipher af_alg dm_crypt raid10 raid456 async_raid6_recov async_memcpy async_pq async_xor async_tx xor raid6_pq libcrc32c raid1 [252243.476067] raid0 multipath linear dm_mirror dm_region_hash dm_log usbhid hid crct10dif_pclmul crc32_pclmul ghash_clmulni_intel pcbc i915 rtsx_pci_sdmmc i2c_algo_bit drm_kms_helper e1000e syscopyarea sysfillrect sysimgblt fb_sys_fops ptp aesni_intel psmouse drm pps_core rtsx_pci aes_x86_64 ahci crypto_simd glue_helper libahci wmi cryptd video [252243.476089] CPU: 2 PID: 1787 Comm: reset-xhci Tainted: G U W 4.15.0-13-generic #14-Ubuntu [252243.476090] Hardware name: Dell Inc. Latitude E7470/0T6HHJ, BIOS 1.18.5 12/11/2017 [252243.476092] RIP: 0010:pci_disable_device+0x9c/0xc0 [252243.476092] RSP: 0018:ffffa61206edfd40 EFLAGS: 00010286 [252243.476094] RAX: 0000000000000000 RBX: ffff9356fcc25000 RCX: ffffffffa9862888 [252243.476095] RDX: 0000000000000001 RSI: 0000000000000082 RDI: 0000000000000247 [252243.476096] RBP: ffffa61206edfd50 R08: 0000000000000038 R09: 000000000000c694 [252243.476097] R10: ffffa61206edfcf0 R11: 0000000000000000 R12: ffff9356fced8700 [252243.476098] R13: ffffffffa99d52c0 R14: ffffffffa99d5330 R15: 0000000000000060 [252243.476100] FS: 00007f13a7aea740(0000) GS:ffff93570fd00000(0000) knlGS:0000000000000000 [252243.476102] CS: 0010 DS: 0000 ES: 0000 CR0: 0000000080050033 [252243.476102] CR2: 000055f5dcf9cef0 CR3: 000000011db38006 CR4: 00000000003626e0 [252243.476103] DR0: 0000000000000000 DR1: 0000000000000000 DR2: 0000000000000000 [252243.476104] DR3: 0000000000000000 DR6: 00000000fffe0ff0 DR7: 0000000000000400 [252243.476105] Call Trace: [252243.476110] usb_hcd_pci_remove+0xcf/0x130 [252243.476112] xhci_pci_remove+0x6b/0x70 [252243.476116] pci_device_remove+0x3e/0xb0 [252243.476124] device_release_driver_internal+0x15b/0x220 [252243.476126] device_release_driver+0x12/0x20 [252243.476127] unbind_store+0x87/0x150 [252243.476130] drv_attr_store+0x27/0x40 [252243.476132] sysfs_kf_write+0x3c/0x50 [252243.476135] kernfs_fop_write+0x125/0x1a0 [252243.476138] __vfs_write+0x1b/0x40 [252243.476140] vfs_write+0xb1/0x1a0 [252243.476142] SyS_write+0x55/0xc0 [252243.476145] do_syscall_64+0x73/0x130 [252243.476148] entry_SYSCALL_64_after_hwframe+0x3d/0xa2 [252243.476150] RIP: 0033:0x7f13a71f0154 [252243.476151] RSP: 002b:00007fff8cf40498 EFLAGS: 00000246 ORIG_RAX: 0000000000000001 [252243.476153] RAX: ffffffffffffffda RBX: 000000000000000c RCX: 00007f13a71f0154 [252243.476154] RDX: 000000000000000c RSI: 000055ef072cc230 RDI: 0000000000000001 [252243.476155] RBP: 000055ef072cc230 R08: 00007f13a74cd8c0 R09: 00007f13a7aea740 [252243.476156] R10: 00000000fffffff4 R11: 0000000000000246 R12: 00007f13a74cc760 [252243.476157] R13: 000000000000000c R14: 00007f13a74c82a0 R15: 00007f13a74c7760 [252243.476158] Code: 00 c6 05 5a 6f 12 01 01 4d 85 e4 74 36 48 8d bb a0 00 00 00 e8 26 55 15 00 4c 89 e2 48 89 c6 48 c7 c7 28 90 51 a9 e8 e4 11 ba ff <0f> 0b eb 82 48 89 df e8 d8 fe ff ff 80 a3 c1 07 00 00 f7 5b 41 [252243.476192] ---[ end trace abf3a4d94dd3a5a8 ]--- [252243.513857] BUG: unable to handle kernel NULL pointer dereference at 0000000000000128 [252243.513866] IP: check_root_hub_suspended+0x10/0x60 [252243.513868] PGD 0 P4D 0 [252243.513872] Oops: 0000 [#1] SMP PTI [252243.513876] Modules linked in: cpuid snd_seq_dummy usb_storage hid_generic hidp ip6t_REJECT nf_reject_ipv6 ip6table_nat nf_nat_ipv6 ip6table_mangle xt_hashlimit ip6table_raw nf_conntrack_ipv6 nf_defrag_ipv6 nf_log_ipv6 xt_recent xt_comment ipt_REJECT nf_reject_ipv4 xt_mark iptable_mangle xt_tcpudp xt_CT iptable_raw xt_multiport xt_NFLOG nfnetlink_log nf_log_ipv4 nf_log_common xt_LOG nf_conntrack_sane nf_conntrack_netlink nfnetlink nf_nat_tftp nf_nat_snmp_basic nf_conntrack_snmp nf_nat_sip nf_nat_pptp nf_nat_proto_gre nf_nat_irc nf_nat_h323 nf_nat_ftp nf_nat_amanda nf_conntrack_tftp nf_conntrack_sip nf_conntrack_pptp nf_conntrack_proto_gre nf_conntrack_netbios_ns nf_conntrack_broadcast nf_conntrack_irc nf_conntrack_h323 nf_conntrack_ftp ts_kmp nf_conntrack_amanda ipt_MASQUERADE nf_nat_masquerade_ipv4 [252243.513913] xfrm_user xfrm_algo iptable_nat nf_conntrack_ipv4 nf_defrag_ipv4 nf_nat_ipv4 xt_addrtype xt_conntrack nf_nat nf_conntrack br_netfilter aufs vhost_net vhost tap ccm rfcomm bridge stp llc devlink ebtable_filter ebtables ip6table_filter ip6_tables iptable_filter msr cmac bnep binfmt_misc snd_hda_codec_hdmi nls_iso8859_1 arc4 snd_soc_skl snd_hda_codec_realtek snd_soc_skl_ipc snd_hda_ext_core snd_hda_codec_generic snd_soc_sst_dsp snd_soc_sst_ipc snd_soc_acpi snd_soc_core snd_compress ac97_bus snd_pcm_dmaengine snd_hda_intel dell_laptop dell_smbios_smm dcdbas snd_hda_codec dell_smm_hwmon snd_hda_core snd_hwdep snd_pcm intel_rapl snd_seq_midi snd_seq_midi_event x86_pkg_temp_thermal intel_powerclamp coretemp snd_rawmidi kvm_intel kvm btusb irqbypass intel_cstate intel_rapl_perf snd_seq btrtl [252243.513954] iwlmvm btbcm btintel mac80211 hid_multitouch uvcvideo joydev input_leds dell_smbios_wmi snd_seq_device dell_wmi bluetooth serio_raw snd_timer videobuf2_vmalloc videobuf2_memops videobuf2_v4l2 dell_smbios videobuf2_core iwlwifi sparse_keymap ecdh_generic snd wmi_bmof dell_wmi_descriptor videodev cfg80211 media soundcore rtsx_pci_ms memstick shpchp mei_me mei processor_thermal_device intel_pch_thermal intel_soc_dts_iosf int3400_thermal acpi_thermal_rel dell_rbtn mac_hid acpi_pad int3403_thermal int340x_thermal_zone tpm_crb sch_fq_codel cuse parport_pc ppdev nfsd lp parport auth_rpcgss nfs_acl lockd grace sunrpc ip_tables x_tables autofs4 btrfs zstd_compress algif_skcipher af_alg dm_crypt raid10 raid456 async_raid6_recov async_memcpy async_pq async_xor async_tx xor raid6_pq libcrc32c raid1 [252243.513989] raid0 multipath linear dm_mirror dm_region_hash dm_log usbhid hid crct10dif_pclmul crc32_pclmul ghash_clmulni_intel pcbc i915 rtsx_pci_sdmmc i2c_algo_bit drm_kms_helper e1000e syscopyarea sysfillrect sysimgblt fb_sys_fops ptp aesni_intel psmouse drm pps_core rtsx_pci aes_x86_64 ahci crypto_simd glue_helper libahci wmi cryptd video [252243.514007] CPU: 2 PID: 31613 Comm: kworker/2:1 Tainted: G U W 4.15.0-13-generic #14-Ubuntu [252243.514008] Hardware name: Dell Inc. Latitude E7470/0T6HHJ, BIOS 1.18.5 12/11/2017 [252243.514012] Workqueue: pm pm_runtime_work [252243.514014] RIP: 0010:check_root_hub_suspended+0x10/0x60 [252243.514016] RSP: 0018:ffffa61207057cb0 EFLAGS: 00010286 [252243.514017] RAX: 0000000000000000 RBX: ffff9356fcc250a0 RCX: 0000000000000000 [252243.514019] RDX: ffffffffa99d52c0 RSI: 0000000000000001 RDI: ffff9356fcc250a0 [252243.514020] RBP: ffffa61207057cb0 R08: 0000000000000000 R09: ffffa61207057db8 [252243.514021] R10: 0000000000000000 R11: 0000000000000274 R12: 0000000000000001 [252243.514022] R13: ffffffffa92ec040 R14: 0000000000000000 R15: ffffffffa88ec000 [252243.514024] FS: 0000000000000000(0000) GS:ffff93570fd00000(0000) knlGS:0000000000000000 [252243.514025] CS: 0010 DS: 0000 ES: 0000 CR0: 0000000080050033 [252243.514026] CR2: 0000000000000128 CR3: 000000009ac0a003 CR4: 00000000003626e0 [252243.514028] DR0: 0000000000000000 DR1: 0000000000000000 DR2: 0000000000000000 [252243.514029] DR3: 0000000000000000 DR6: 00000000fffe0ff0 DR7: 0000000000000400 [252243.514030] Call Trace: [252243.514033] suspend_common+0x22/0x160 [252243.514035] hcd_pci_runtime_suspend+0x1b/0x50 [252243.514038] pci_pm_runtime_suspend+0x64/0x180 [252243.514040] ? pci_pm_runtime_resume+0xa0/0xa0 [252243.514042] __rpm_callback+0xca/0x210 [252243.514045] ? __switch_to_asm+0x34/0x70 [252243.514047] ? __switch_to_asm+0x40/0x70 [252243.514050] rpm_callback+0x24/0x80 [252243.514051] ? pci_pm_runtime_resume+0xa0/0xa0 [252243.514053] rpm_suspend+0x137/0x640 [252243.514056] rpm_idle+0x58/0x2a0 [252243.514058] pm_runtime_work+0x92/0xa0 [252243.514061] process_one_work+0x1de/0x410 [252243.514062] worker_thread+0x32/0x410 [252243.514065] kthread+0x121/0x140 [252243.514067] ? process_one_work+0x410/0x410 [252243.514069] ? kthread_create_worker_on_cpu+0x70/0x70 [252243.514072] ? do_syscall_64+0x73/0x130 [252243.514074] ? SyS_exit_group+0x14/0x20 [252243.514076] ret_from_fork+0x35/0x40 [252243.514077] Code: 48 8d b2 a0 00 00 00 48 81 c7 a0 00 00 00 48 89 e5 e8 65 a0 f1 ff 5d c3 0f 1f 00 0f 1f 44 00 00 48 8b 87 98 00 00 00 55 48 89 e5 80 28 01 00 00 20 75 2c 48 8b 90 f8 01 00 00 31 c0 48 85 d2 [252243.514103] RIP: check_root_hub_suspended+0x10/0x60 RSP: ffffa61207057cb0 [252243.514104] CR2: 0000000000000128 [252243.514106] ---[ end trace abf3a4d94dd3a5a9 ]--- [252243.533589] xhci_hcd 0000:00:14.0: xHCI Host Controller [252243.533600] xhci_hcd 0000:00:14.0: new USB bus registered, assigned bus number 1 [252243.534713] xhci_hcd 0000:00:14.0: hcc params 0x200077c1 hci version 0x100 quirks 0x00109810 [252243.534721] xhci_hcd 0000:00:14.0: cache line size of 64 is not supported [252243.534892] usb usb1: runtime PM trying to activate child device usb1 but parent (0000:00:14.0) is not active This is a plain linux-image-extra-4.15.0-13-generic kernel on Ubuntu 18.04 running on a Dell Latitude E7470. For completeness sake: ╰─▶ lsb_release -rd Description: Ubuntu Bionic Beaver (development branch) Release: 18.04 ╰─▶ uname -a Linux regan 4.15.0-13-generic #14-Ubuntu SMP Sat Mar 17 13:44:27 UTC 2018 x86_64 x86_64 x86_64 GNU/Linux ╰─▶ dpkg -l linux-image-\*|cat Desired=Unknown/Install/Remove/Purge/Hold | Status=Not/Inst/Conf-files/Unpacked/halF-conf/Half-inst/trig-aWait/Trig-pend |/ Err?=(none)/Reinst-required (Status,Err: uppercase=bad) ||/ Name Version Architecture Description +++-===================================-============-============-=============================================================== ii linux-image-4.14.0-16-generic 4.14.0-16.19 amd64 Linux kernel image for version 4.14.0 on 64 bit x86 SMP ii linux-image-4.15.0-12-generic 4.15.0-12.13 amd64 Linux kernel image for version 4.15.0 on 64 bit x86 SMP ii linux-image-4.15.0-13-generic 4.15.0-13.14 amd64 Linux kernel image for version 4.15.0 on 64 bit x86 SMP ii linux-image-extra-4.14.0-16-generic 4.14.0-16.19 amd64 Linux kernel extra modules for version 4.14.0 on 64 bit x86 SMP ii linux-image-extra-4.15.0-12-generic 4.15.0-12.13 amd64 Linux kernel extra modules for version 4.15.0 on 64 bit x86 SMP ii linux-image-extra-4.15.0-13-generic 4.15.0-13.14 amd64 Linux kernel extra modules for version 4.15.0 on 64 bit x86 SMP ii linux-image-generic 4.15.0.13.14 amd64 Generic Linux kernel image ╰─▶ cat /proc/version_signature Ubuntu 4.15.0-13.14-generic 4.15.10 ╰─▶ cat /proc/cmdline BOOT_IMAGE=/vmlinuz-4.15.0-13-generic root=/dev/mapper/regan-root ro nosplash acpi_backlight=vendor intel_iommu=off