Commit c907ed24 authored by Russell King's avatar Russell King

[PCI] pci-12: Add #defines for cardbus specifics

Pull out the bits of cardbus configuration - the secondary latency
timer, and the number of bus numbers we reserve.
parent b65c581a
...@@ -15,6 +15,9 @@ ...@@ -15,6 +15,9 @@
#define DBG(x...) #define DBG(x...)
#endif #endif
#define CARDBUS_LATENCY_TIMER 176 /* secondary latency timer */
#define CARDBUS_RESERVE_BUSNR 3
LIST_HEAD(pci_root_buses); LIST_HEAD(pci_root_buses);
LIST_HEAD(pci_devices); LIST_HEAD(pci_devices);
...@@ -336,8 +339,10 @@ int __devinit pci_scan_bridge(struct pci_bus *bus, struct pci_dev * dev, int max ...@@ -336,8 +339,10 @@ int __devinit pci_scan_bridge(struct pci_bus *bus, struct pci_dev * dev, int max
* yenta.c forces a secondary latency timer of 176. * yenta.c forces a secondary latency timer of 176.
* Copy that behaviour here. * Copy that behaviour here.
*/ */
if (is_cardbus) if (is_cardbus) {
buses = (buses & 0x00ffffff) | (176 << 24); buses &= ~0xff000000;
buses |= CARDBUS_LATENCY_TIMER << 24;
}
/* /*
* We need to blast all three values with a single write. * We need to blast all three values with a single write.
...@@ -353,7 +358,7 @@ int __devinit pci_scan_bridge(struct pci_bus *bus, struct pci_dev * dev, int max ...@@ -353,7 +358,7 @@ int __devinit pci_scan_bridge(struct pci_bus *bus, struct pci_dev * dev, int max
* as cards with a PCI-to-PCI bridge can be * as cards with a PCI-to-PCI bridge can be
* inserted later. * inserted later.
*/ */
max += 3; max += CARDBUS_RESERVE_BUSNR;
} }
/* /*
* Set the subordinate bus number to its real value. * Set the subordinate bus number to its real value.
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment