mirror of
https://github.com/torvalds/linux.git
synced 2024-11-15 08:31:55 +00:00
x86/mrst/pci: assign d3_delay to 0 for Langwell devices
Langwell devices are not true pci devices, they are not subject to the 10 ms d3 to d0 delay required by pci spec. This patch assigns d3_delay to 0 for all langwell pci devices. We can also power off devices that are not really used by the OS Signed-off-by: Jacob Pan <jacob.jun.pan@linux.intel.com> Signed-off-by: Alan Cox <alan@linux.intel.com> Signed-off-by: Jesse Barnes <jbarnes@virtuousgeek.org>
This commit is contained in:
parent
7570a333d8
commit
990a30c50c
@ -239,6 +239,30 @@ int __init pci_mrst_init(void)
|
||||
return 1;
|
||||
}
|
||||
|
||||
/* Langwell devices are not true pci devices, they are not subject to 10 ms
|
||||
* d3 to d0 delay required by pci spec.
|
||||
*/
|
||||
static void __devinit pci_d3delay_fixup(struct pci_dev *dev)
|
||||
{
|
||||
/* true pci devices in lincroft should allow type 1 access, the rest
|
||||
* are langwell fake pci devices.
|
||||
*/
|
||||
if (type1_access_ok(dev->bus->number, dev->devfn, PCI_DEVICE_ID))
|
||||
return;
|
||||
dev->d3_delay = 0;
|
||||
}
|
||||
DECLARE_PCI_FIXUP_FINAL(PCI_VENDOR_ID_INTEL, PCI_ANY_ID, pci_d3delay_fixup);
|
||||
|
||||
static void __devinit mrst_power_off_unused_dev(struct pci_dev *dev)
|
||||
{
|
||||
pci_set_power_state(dev, PCI_D3cold);
|
||||
}
|
||||
DECLARE_PCI_FIXUP_FINAL(PCI_VENDOR_ID_INTEL, 0x0801, mrst_power_off_unused_dev);
|
||||
DECLARE_PCI_FIXUP_FINAL(PCI_VENDOR_ID_INTEL, 0x0809, mrst_power_off_unused_dev);
|
||||
DECLARE_PCI_FIXUP_FINAL(PCI_VENDOR_ID_INTEL, 0x080C, mrst_power_off_unused_dev);
|
||||
DECLARE_PCI_FIXUP_FINAL(PCI_VENDOR_ID_INTEL, 0x0812, mrst_power_off_unused_dev);
|
||||
DECLARE_PCI_FIXUP_FINAL(PCI_VENDOR_ID_INTEL, 0x0815, mrst_power_off_unused_dev);
|
||||
|
||||
/*
|
||||
* Langwell devices reside at fixed offsets, don't try to move them.
|
||||
*/
|
||||
|
Loading…
Reference in New Issue
Block a user