aboutsummaryrefslogtreecommitdiffstats
path: root/arch/ppc64/kernel/iSeries_vio.c
diff options
context:
space:
mode:
authorStephen Rothwell <sfr@canb.auug.org.au>2005-07-12 17:45:27 +1000
committerPaul Mackerras <paulus@samba.org>2005-08-29 10:53:32 +1000
commit6312236fe82bbd3b0e1dee60b3eb3b270a2f6aeb (patch)
treecf23f21d9d423e7999270cb4d7050697c72ea80b /arch/ppc64/kernel/iSeries_vio.c
parent[PATCH] ppc64: move iSeries vio iommu init (diff)
downloadlinux-dev-6312236fe82bbd3b0e1dee60b3eb3b270a2f6aeb.tar.xz
linux-dev-6312236fe82bbd3b0e1dee60b3eb3b270a2f6aeb.zip
[PATCH] ppc64: make the bus matching function platform specific
This patch allows us to have a different bus if matching function for each platform. Signed-off-by: Stephen Rothwell <sfr@canb.auug.org.au> Signed-off-by: Paul Mackerras <paulus@samba.org>
Diffstat (limited to 'arch/ppc64/kernel/iSeries_vio.c')
-rw-r--r--arch/ppc64/kernel/iSeries_vio.c12
1 files changed, 11 insertions, 1 deletions
diff --git a/arch/ppc64/kernel/iSeries_vio.c b/arch/ppc64/kernel/iSeries_vio.c
index 48f0ebf4405d..2656b1ca834d 100644
--- a/arch/ppc64/kernel/iSeries_vio.c
+++ b/arch/ppc64/kernel/iSeries_vio.c
@@ -115,13 +115,23 @@ void __init probe_bus_iseries(void)
}
/**
+ * vio_match_device_iseries: - Tell if a iSeries VIO device matches a
+ * vio_device_id
+ */
+static int vio_match_device_iseries(const struct vio_device_id *id,
+ const struct vio_dev *dev)
+{
+ return strncmp(dev->type, id->type, strlen(id->type)) == 0;
+}
+
+/**
* vio_bus_init_iseries: - Initialize the iSeries virtual IO bus
*/
static int __init vio_bus_init_iseries(void)
{
int err;
- err = vio_bus_init();
+ err = vio_bus_init(vio_match_device_iseries);
if (err == 0) {
iommu_vio_init();
vio_bus_device.iommu_table = &vio_iommu_table;