WSL2-Linux-Kernel/drivers/pci/pcie
Matthew Garrett c9651e70ad ASPM: Fix pcie devices with non-pcie children
Since 3.2.12 and 3.3, some systems are failing to boot with a BUG_ON.
Some other systems using the pata_jmicron driver fail to boot because no
disks are detected.  Passing pcie_aspm=force on the kernel command line
works around it.

The cause: commit 4949be1682 ("PCI: ignore pre-1.1 ASPM quirking when
ASPM is disabled") changed the behaviour of pcie_aspm_sanity_check() to
always return 0 if aspm is disabled, in order to avoid cases where we
changed ASPM state on pre-PCIe 1.1 devices.

This skipped the secondary function of pcie_aspm_sanity_check which was
to avoid us enabling ASPM on devices that had non-PCIe children, causing
trouble later on.  Move the aspm_disabled check so we continue to honour
that scenario.

Addresses https://bugzilla.kernel.org/show_bug.cgi?id=42979 and
          http://bugs.debian.org/665420

Reported-by: Romain Francoise <romain@orebokech.com> # kernel panic
Reported-by: Chris Holland <bandidoirlandes@gmail.com> # disk detection trouble
Signed-off-by: Matthew Garrett <mjg@redhat.com>
Cc: stable@vger.kernel.org
Tested-by: Hatem Masmoudi <hatem.masmoudi@gmail.com> # Dell Latitude E5520
Tested-by: janek <jan0x6c@gmail.com> # pata_jmicron with JMB362/JMB363
[jn: with more symptoms in log message]
Signed-off-by: Jonathan Nieder <jrnieder@gmail.com>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2012-03-31 12:49:56 -07:00
..
aer module_param: make bool parameters really bool (drivers & misc) 2012-01-13 09:32:20 +10:30
Kconfig PCI: pcie: Add support for setting default ASPM policy 2012-02-17 09:22:03 -08:00
Makefile PCI: PCIe: Move PCIe PME code to the pcie directory 2010-08-24 13:47:48 -07:00
aspm.c ASPM: Fix pcie devices with non-pcie children 2012-03-31 12:49:56 -07:00
pme.c PCI / PM: Extend PME polling to all PCI devices 2011-10-14 09:05:31 -07:00
portdrv.h PCI: Add pcie_hp=nomsi to disable MSI/MSI-X for pciehp driver 2012-02-23 12:29:35 -08:00
portdrv_acpi.c PCI/ACPI: Request _OSC control once for each root bridge (v3) 2011-01-14 08:55:41 -08:00
portdrv_bus.c PCI: portdrv: remove unnecessary struct pcie_port_data 2009-12-04 15:56:19 -08:00
portdrv_core.c PCI: Add pcie_hp=nomsi to disable MSI/MSI-X for pciehp driver 2012-02-23 12:29:35 -08:00
portdrv_pci.c PCI/PCIe: Clear Root PME Status bits early during system resume 2010-12-23 12:54:03 -08:00