aboutsummaryrefslogtreecommitdiff
path: root/include
diff options
context:
space:
mode:
authorStephen Rothwell <sfr@canb.auug.org.au>2005-09-28 14:40:40 +1000
committerStephen Rothwell <sfr@canb.auug.org.au>2005-09-28 14:40:40 +1000
commit252e75a51d40757928d692b3d339e66838294b4b (patch)
tree6ae6e08ae69f54320da58ac369cb98bdf097a7c2 /include
parentc111d0bda8437d146ccf5101970801fe4ff23ed8 (diff)
ppc64 iSeries: use device_node instead of iSeries_Device_node
There needs to be more cleanup after this. Signed-off-by: Stephen Rothwell <sfr@canb.auug.org.au>
Diffstat (limited to 'include')
-rw-r--r--include/asm-ppc64/iSeries/iSeries_pci.h30
-rw-r--r--include/asm-ppc64/iommu.h4
-rw-r--r--include/asm-ppc64/pci-bridge.h10
-rw-r--r--include/asm-ppc64/prom.h3
4 files changed, 21 insertions, 26 deletions
diff --git a/include/asm-ppc64/iSeries/iSeries_pci.h b/include/asm-ppc64/iSeries/iSeries_pci.h
index 575f611f8b3..a4d88b49fd9 100644
--- a/include/asm-ppc64/iSeries/iSeries_pci.h
+++ b/include/asm-ppc64/iSeries/iSeries_pci.h
@@ -30,21 +30,19 @@
* End Change Activity
*/
-#include <asm/iSeries/HvCallPci.h>
#include <asm/abs_addr.h>
+#include <asm/prom.h>
+#include <asm/pci-bridge.h>
struct pci_dev; /* For Forward Reference */
-struct iSeries_Device_Node;
/*
- * Gets iSeries Bus, SubBus, DevFn using iSeries_Device_Node structure
+ * Gets iSeries Bus, SubBus, DevFn using device_node structure
*/
-#define ISERIES_BUS(DevPtr) DevPtr->DsaAddr.Dsa.busNumber
-#define ISERIES_SUBBUS(DevPtr) DevPtr->DsaAddr.Dsa.subBusNumber
-#define ISERIES_DEVICE(DevPtr) DevPtr->DsaAddr.Dsa.deviceId
-#define ISERIES_DSA(DevPtr) DevPtr->DsaAddr.DsaAddr
-#define ISERIES_DEVNODE(PciDev) ((struct iSeries_Device_Node *)PciDev->sysdata)
+#define ISERIES_BUS(DevPtr) PCI_DN(DevPtr)->DsaAddr.Dsa.busNumber
+#define ISERIES_SUBBUS(DevPtr) PCI_DN(DevPtr)->DsaAddr.Dsa.subBusNumber
+#define ISERIES_DEVNODE(PciDev) ((struct device_node *)PciDev->sysdata)
#define EADsMaxAgents 7
@@ -67,22 +65,6 @@ struct iSeries_Device_Node;
#define ISERIES_HV_ADDR(virtaddr) \
(0x8000000000000000 | virt_to_abs(virtaddr))
-/*
- * iSeries Device Information
- */
-struct iSeries_Device_Node {
- struct list_head Device_List;
- struct pci_dev *PciDev;
- union HvDsaMap DsaAddr; /* Direct Select Address */
- /* busNumber, subBusNumber, */
- /* deviceId, barNumber */
- int DevFn; /* Linux devfn */
- int Irq; /* Assigned IRQ */
- int Flags; /* Possible flags(disable/bist)*/
- u8 LogicalSlot; /* Hv Slot Index for Tces */
- struct iommu_table *iommu_table;/* Device TCE Table */
-};
-
extern void iSeries_Device_Information(struct pci_dev*, int);
#endif /* _ISERIES_64_PCI_H */
diff --git a/include/asm-ppc64/iommu.h b/include/asm-ppc64/iommu.h
index a6a173d4950..d096faf4191 100644
--- a/include/asm-ppc64/iommu.h
+++ b/include/asm-ppc64/iommu.h
@@ -49,6 +49,7 @@ struct iommu_table {
};
struct scatterlist;
+struct device_node;
#ifdef CONFIG_PPC_MULTIPLATFORM
@@ -70,9 +71,8 @@ extern void iommu_devnode_init_pSeries(struct device_node *dn);
#ifdef CONFIG_PPC_ISERIES
-struct iSeries_Device_Node;
/* Creates table for an individual device node */
-extern void iommu_devnode_init_iSeries(struct iSeries_Device_Node *dn);
+extern void iommu_devnode_init_iSeries(struct device_node *dn);
#endif /* CONFIG_PPC_ISERIES */
diff --git a/include/asm-ppc64/pci-bridge.h b/include/asm-ppc64/pci-bridge.h
index d8991389ab3..8ca5fce626b 100644
--- a/include/asm-ppc64/pci-bridge.h
+++ b/include/asm-ppc64/pci-bridge.h
@@ -4,6 +4,8 @@
#include <linux/pci.h>
+#include <asm/iSeries/HvCallPci.h>
+
/*
* This program is free software; you can redistribute it and/or
* modify it under the terms of the GNU General Public License
@@ -71,6 +73,14 @@ struct pci_dn {
struct iommu_table *iommu_table; /* for phb's or bridges */
struct pci_dev *pcidev; /* back-pointer to the pci device */
struct device_node *node; /* back-pointer to the device_node */
+#ifdef CONFIG_PPC_ISERIES
+ union HvDsaMap DsaAddr; /* Direct Select Address */
+ /* busNumber, subBusNumber, */
+ /* deviceId, barNumber */
+ int Irq; /* Assigned IRQ */
+ int Flags; /* Possible flags(disable/bist)*/
+ u8 LogicalSlot; /* Hv Slot Index for Tces */
+#endif
u32 config_space[16]; /* saved PCI config space */
};
diff --git a/include/asm-ppc64/prom.h b/include/asm-ppc64/prom.h
index c02ec1d6b90..cf0284e081e 100644
--- a/include/asm-ppc64/prom.h
+++ b/include/asm-ppc64/prom.h
@@ -137,6 +137,9 @@ struct device_node {
struct kref kref;
unsigned long _flags;
void *data;
+#ifdef CONFIG_PPC_ISERIES
+ struct list_head Device_List;
+#endif
};
extern struct device_node *of_chosen;