aboutsummaryrefslogtreecommitdiffstats
path: root/arch/sparc64/kernel/vio.c
diff options
context:
space:
mode:
Diffstat (limited to 'arch/sparc64/kernel/vio.c')
-rw-r--r--arch/sparc64/kernel/vio.c29
1 files changed, 27 insertions, 2 deletions
diff --git a/arch/sparc64/kernel/vio.c b/arch/sparc64/kernel/vio.c
index 1550ac5673da..0c1ee619d814 100644
--- a/arch/sparc64/kernel/vio.c
+++ b/arch/sparc64/kernel/vio.c
@@ -292,7 +292,7 @@ static struct vio_dev *vio_create_one(struct mdesc_handle *hp, u64 mp,
292 } 292 }
293 vdev->dp = dp; 293 vdev->dp = dp;
294 294
295 printk(KERN_ERR "VIO: Adding device %s\n", vdev->dev.bus_id); 295 printk(KERN_INFO "VIO: Adding device %s\n", vdev->dev.bus_id);
296 296
297 err = device_register(&vdev->dev); 297 err = device_register(&vdev->dev);
298 if (err) { 298 if (err) {
@@ -342,8 +342,33 @@ static struct mdesc_notifier_client vio_device_notifier = {
342 .node_name = "virtual-device-port", 342 .node_name = "virtual-device-port",
343}; 343};
344 344
345/* We are only interested in domain service ports under the
346 * "domain-services" node. On control nodes there is another port
347 * under "openboot" that we should not mess with as aparently that is
348 * reserved exclusively for OBP use.
349 */
350static void vio_add_ds(struct mdesc_handle *hp, u64 node)
351{
352 int found;
353 u64 a;
354
355 found = 0;
356 mdesc_for_each_arc(a, hp, node, MDESC_ARC_TYPE_BACK) {
357 u64 target = mdesc_arc_target(hp, a);
358 const char *name = mdesc_node_name(hp, target);
359
360 if (!strcmp(name, "domain-services")) {
361 found = 1;
362 break;
363 }
364 }
365
366 if (found)
367 (void) vio_create_one(hp, node, &root_vdev->dev);
368}
369
345static struct mdesc_notifier_client vio_ds_notifier = { 370static struct mdesc_notifier_client vio_ds_notifier = {
346 .add = vio_add, 371 .add = vio_add_ds,
347 .remove = vio_remove, 372 .remove = vio_remove,
348 .node_name = "domain-services-port", 373 .node_name = "domain-services-port",
349}; 374};