Skip to content

Commit

Permalink
powerpc/vio: Separate vio bus probe and device probe
Browse files Browse the repository at this point in the history
Similar to PCI, separate the bus probe from device probe. This allows
us to attach bus notifiers for DMA debug and IOMMU fault injection
before devices have been probed.

Signed-off-by: Anton Blanchard <anton@samba.org>
Signed-off-by: Benjamin Herrenschmidt <benh@kernel.crashing.org>
  • Loading branch information
Anton Blanchard authored and Benjamin Herrenschmidt committed Jul 10, 2012
1 parent 62761d1 commit 44b372d
Showing 1 changed file with 7 additions and 1 deletion.
8 changes: 7 additions & 1 deletion arch/powerpc/kernel/vio.c
Original file line number Diff line number Diff line change
Expand Up @@ -1497,12 +1497,18 @@ static int __init vio_bus_init(void)
if (firmware_has_feature(FW_FEATURE_CMO))
vio_cmo_bus_init();

return 0;
}
postcore_initcall(vio_bus_init);

static int __init vio_device_init(void)
{
vio_bus_scan_register_devices("vdevice");
vio_bus_scan_register_devices("ibm,platform-facilities");

return 0;
}
__initcall(vio_bus_init);
device_initcall(vio_device_init);

static ssize_t name_show(struct device *dev,
struct device_attribute *attr, char *buf)
Expand Down

0 comments on commit 44b372d

Please sign in to comment.