PCI D3 wakeup failure on Lynx Point xHCI
Hi Rafael,
I'm running into some issues with PCI D3 wakeup on the latest version of the Lynx Point chipset. I can give you the stepping and BIOS version privately if you need it.
Basically, I think PMEs are being lost somewhere in the ACPI or PCI stack. I'm not sure how to further debug this issue, so I'm hoping you have some pointers.
This is reproduced on the 3.7.1, 3.7.7, and 3.8.0 kernels.
First, I go into powertop and basically change all the 'Bad' entries to 'Good', which turns on runtime PM for all PCI devices, bridges, and rootports. I have no USB devices plugged into the xHCI host, and I wait until the host is suspended, and the PCI device is in D3.
Then I run:
watch -n 1 'sudo lspci -vvv -s 00:14.0'
When I plug in a USB 2.0 device to a USB 2.0 port, the hotplug event is lost. I can see from the lspci output that the Status line under the PM capabilities changes when I plug in the device. The PME- changes to PME+, which I assume means a PME happened. But the USB core's PCI resume functions are never called.
Wakeup from D3 works fine on the previous generation chipset (Panther Point) on my Lenovo x230 laptop, so this makes me suspicious that it's a hardware or BIOS issue. I'll try updating my BIOS and seeing if that helps.
Sarah Sharp
--
To unsubscribe from this list: send the line "unsubscribe linux-usb" in the body of a message to [email protected] More majordomo info at http://vger.kernel.org/majordomo-info.html
Quoted 1 line · Sarah Sharp
Hi Rafael,
Hi,
Quoted 1 line
I'm running into some issues with PCI D3
Do you mean D3hot?
Quoted 24 lines
wakeup on the latest version of the Lynx Point chipset. I can give you the stepping and BIOS version privately if you need it.
Basically, I think PMEs are being lost somewhere in the ACPI or PCI stack. I'm not sure how to further debug this issue, so I'm hoping you have some pointers.
This is reproduced on the 3.7.1, 3.7.7, and 3.8.0 kernels.
First, I go into powertop and basically change all the 'Bad' entries to 'Good', which turns on runtime PM for all PCI devices, bridges, and rootports. I have no USB devices plugged into the xHCI host, and I wait until the host is suspended, and the PCI device is in D3.
Then I run:
watch -n 1 'sudo lspci -vvv -s 00:14.0'
When I plug in a USB 2.0 device to a USB 2.0 port, the hotplug event is lost. I can see from the lspci output that the Status line under the PM capabilities changes when I plug in the device. The PME- changes to PME+, which I assume means a PME happened. But the USB core's PCI resume functions are never called.
Quoted 4 lines
Wakeup from D3 works fine on the previous generation chipset (Panther Point) on my Lenovo x230 laptop, so this makes me suspicious that it's a hardware or BIOS issue. I'll try updating my BIOS and seeing if that helps.
In addition to that you can see if the number of ACPI interrupts (in /proc/interrupts) grows when you plug the USB device in and if so, whether or not any of the numbers in /sys/firmware/acpi/interrupts/gpe* grows at the same time.
Thanks,
Rafael
Signature · 2 lines
I speak only for myself. Rafael J. Wysocki, Intel Open Source Technology Center.
A message that is not in the archive (sent off-list or not yet received): 20130221235211.GC32050@xanatos
Quoted 59 lines · Sarah Sharp
Quoted 8 lines · Rafael J. Wysocki
Quoted 1 line · Sarah Sharp
Hi Rafael,
Hi,
Quoted 1 line
I'm running into some issues with PCI D3
Do you mean D3hot?
I don't think this PCI device supports D3cold. At least that's what the hardware folks tell me. However, the lspci output wasn't clear which state the PCI device was in. If I cat /sys/bus/pci/devices/0000:00:14.0/d3cold_allowed, it says '1', however I don't see any output in dmesg that says the device was put in D3cold.
Quoted 4 lines
In addition to that you can see if the number of ACPI interrupts (in
/proc/interrupts) grows when you plug the USB device in and if so, whether or not any of the numbers in/sys/firmware/acpi/interrupts/gpe*grows at the same time.In
/proc/interrupts, the xHCI MSI line does not change when I plug in a device while the PCI device is in D3:CPU0 CPU1 CPU2 CPU3 CPU4 CPU5 CPU6 CPU7
0: 70 0 0 0 0 0 0 0 IR-IO-APIC-edge timer 1: 5424 0 0 0 0 0 0 0 IR-IO-APIC-edge i8042 8: 1 0 0 0 0 0 0 0 IR-IO-APIC-edge rtc0 9: 1745 544 0 0 0 0 0 0 IR-IO-APIC-fasteoi acpi 12: 22823 0 0 0 0 0 0 0 IR-IO-APIC-edge i8042 16: 1009 0 0 0 0 0 0 0 IR-IO-APIC-fasteoi ehci_hcd:usb3, nouveau 17: 299 0 0 0 0 0 0 0 IR-IO-APIC-fasteoi snd_hda_intel 19: 26 0 9 0 0 0 0 0 IR-IO-APIC-fasteoi 23: 956 99 0 0 0 0 0 0 IR-IO-APIC-fasteoi ehci_hcd:usb4 40: 0 0 0 0 0 0 0 0 DMAR_MSI-edge dmar0 41: 0 0 0 0 0 0 0 0 IR-PCI-MSI-edge PCIe PME 42: 0 0 0 0 0 0 0 0 IR-PCI-MSI-edge PCIe PME 43: 0 0 0 0 0 0 0 0 IR-PCI-MSI-edge PCIe PME, pciehp 44: 27450 0 0 0 0 0 0 0 IR-PCI-MSI-edge ahci 45: 38 0 0 0 0 0 0 0 IR-PCI-MSI-edge xhci_hcd 46: 6065 0 0 0 0 0 0 0 IR-PCI-MSI-edge eth5 47: 26 0 0 0 0 0 0 0 IR-PCI-MSI-edge mei 48: 246 0 0 59 0 0 0 0 IR-PCI-MSI-edge snd_hda_intel NMI: 14 6 13 9 2 2 3 4 Non-maskable interrupts LOC: 130457 125777 99012 92995 39437 36596 28275 30074 Local timer interrupts SPU: 0 0 0 0 0 0 0 0 Spurious interrupts PMI: 14 6 13 9 2 2 3 4 Performance monitoring interrupts IWI: 1 1 1 1 0 0 0 0 IRQ work interrupts RTR: 0 0 0 0 0 0 0 0 APIC ICR read retries RES: 25303 11329 1532 782 513 432 427 350 Rescheduling interrupts CAL: 542 693 748 672 762 767 803 754 Function call interrupts TLB: 908 783 781 817 1087 1530 1355 1261 TLB shootdowns TRM: 0 0 0 0 0 0 0 0 Thermal event interrupts THR: 0 0 0 0 0 0 0 0 Threshold APIC interrupts MCE: 0 0 0 0 0 0 0 0 Machine check exceptions MCP: 7 7 7 7 7 7 7 7 Machine check polls ERR: 0 MIS: 0
Quoted 3 lines
However,
/sys/firmware/acpi/interrupts/gpe0Dchanges. The file seems to indicate the GPE is enabled (it reads as "5 enabled" after some hotplug tests).
It looks like the event is signaled, then.
Quoted 1 line
ACPI tables are attached.
Thanks, I'll have a look at that tomorrow.
Rafael
Signature · 2 lines
I speak only for myself. Rafael J. Wysocki, Intel Open Source Technology Center.