[Kernel-packages] [Bug 1763594] Re: xhci hangs; reset results in NULL pointer dereference
I reproduced the same(?) issue by passing by passing an usb controller to kvm.(https://www.redhat.com/archives/vfio- users/2018-February/msg00030.html) When I shut down the virtual machine and try to start again it always fails. Tested your kernel and still the same issue. Hope this helps. ** Attachment added: "before.log" https://bugs.launchpad.net/ubuntu/+source/linux/+bug/1763594/+attachment/5157190/+files/before.log -- You received this bug notification because you are a member of Kernel Packages, which is subscribed to linux in Ubuntu. https://bugs.launchpad.net/bugs/1763594 Title: xhci hangs; reset results in NULL pointer dereference Status in linux package in Ubuntu: Incomplete Status in linux source package in Bionic: Incomplete Bug description: Now and then, my xhci bus will hang, resulting in these kinds of messages in dmesg: [252220.002102] xhci_hcd :00:14.0: xHC is not running. [252220.037491] xhci_hcd :00:14.0: xHCI host controller not responding, assume dead [252220.037500] xhci_hcd :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 :00:14.0: remove, state 4 [252243.401887] usb usb2: USB disconnect, device number 1 [252243.470365] xhci_hcd :00:14.0: USB bus 2 deregistered [252243.470378] xhci_hcd :00:14.0: remove, state 4 [252243.470383] usb usb1: USB disconnect, device number 1 [252243.470831] xhci_hcd :00:14.0: Host halt failed, -19 [252243.470837] xhci_hcd :00:14.0: Host not accessible, reset failed. [252243.475918] xhci_hcd :00:14.0: USB bus 1 deregistered [252243.475938] [ cut here ] [252243.475939] xhci_hcd :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_
[Kernel-packages] [Bug 1763594] Re: xhci hangs; reset results in NULL pointer dereference
** Attachment added: "after.log" https://bugs.launchpad.net/ubuntu/+source/linux/+bug/1763594/+attachment/5157191/+files/after.log -- You received this bug notification because you are a member of Kernel Packages, which is subscribed to linux in Ubuntu. https://bugs.launchpad.net/bugs/1763594 Title: xhci hangs; reset results in NULL pointer dereference Status in linux package in Ubuntu: Incomplete Status in linux source package in Bionic: Incomplete Bug description: Now and then, my xhci bus will hang, resulting in these kinds of messages in dmesg: [252220.002102] xhci_hcd :00:14.0: xHC is not running. [252220.037491] xhci_hcd :00:14.0: xHCI host controller not responding, assume dead [252220.037500] xhci_hcd :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 :00:14.0: remove, state 4 [252243.401887] usb usb2: USB disconnect, device number 1 [252243.470365] xhci_hcd :00:14.0: USB bus 2 deregistered [252243.470378] xhci_hcd :00:14.0: remove, state 4 [252243.470383] usb usb1: USB disconnect, device number 1 [252243.470831] xhci_hcd :00:14.0: Host halt failed, -19 [252243.470837] xhci_hcd :00:14.0: Host not accessible, reset failed. [252243.475918] xhci_hcd :00:14.0: USB bus 1 deregistered [252243.475938] [ cut here ] [252243.475939] xhci_hcd :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