patch-2.3.16 linux/include/asm-alpha/pci.h

Next file: linux/include/asm-alpha/smp.h
Previous file: linux/include/asm-alpha/machvec.h
Back to the patch index
Back to the overall index

diff -u --recursive --new-file v2.3.15/linux/include/asm-alpha/pci.h linux/include/asm-alpha/pci.h
@@ -1,48 +1,31 @@
 #ifndef __ALPHA_PCI_H
 #define __ALPHA_PCI_H
 
-#include <linux/config.h>
-#include <linux/pci.h>
-
-
 /*
  * The following structure is used to manage multiple PCI busses.
- *
- * XXX: We should solve this problem in an architecture independent
- * way, rather than hacking something up here.
  */
 
-struct linux_hose_info {
-        struct pci_bus                  pci_bus;
-	struct linux_hose_info         *next;
-	unsigned long                   pci_io_space;
-	unsigned long                   pci_mem_space;
-	unsigned long                   pci_config_space;
-	unsigned long                   pci_sparse_space;
-        unsigned int                    pci_first_busno;
-        unsigned int                    pci_last_busno;
-	unsigned int                    pci_hose_index;
-};
-
-/* This is indexed by a pseudo- PCI bus number to obtain the real deal.  */
-extern struct linux_hose_info *bus2hose[256];
-
-/* Create a handle that is OR-ed into the reported I/O space address
-   for a device.  We use this later to find the bus a device lives on.  */
+struct pci_bus;
+struct resource;
 
-#if defined(CONFIG_ALPHA_GENERIC) \
-    || defined(CONFIG_ALPHA_MCPCIA) \
-    || defined(CONFIG_ALPHA_TSUNAMI)
-
-#define PCI_HANDLE(bus)   ((bus2hose[bus]->pci_hose_index & 3UL) << 32)
-#define DEV_IS_ON_PRIMARY(dev) \
-  (bus2hose[(dev)->bus->number]->pci_first_busno == (dev)->bus->number)
-
-#else
+struct pci_controler {
+	/* Mandated.  */
+	struct pci_controler *next;
+        struct pci_bus *bus;
+	struct resource *io_space;
+	struct resource *mem_space;
+
+	/* Alpha specific.  */
+	unsigned long config_space;
+	unsigned int index;
+	unsigned int first_busno;
+	unsigned int last_busno;
+};
 
-#define PCI_HANDLE(bus)         0
-#define DEV_IS_ON_PRIMARY(dev)  ((dev)->bus->number == 0)
+/* Override the logic in pci_scan_bus for skipping already-configured
+   bus numbers.  */
 
-#endif /* Multiple busses */
+#define pcibios_assign_all_busses()	1
 
 #endif /* __ALPHA_PCI_H */
+

FUNET's LINUX-ADM group, linux-adm@nic.funet.fi
TCL-scripts by Sam Shen (who was at: slshen@lbl.gov)