qdev: export qdev_find_recursive() for later use
authorIsaku Yamahata <yamahata@valinux.co.jp>
Fri, 24 Dec 2010 03:14:12 +0000 (12:14 +0900)
committerMichael S. Tsirkin <mst@redhat.com>
Fri, 24 Dec 2010 08:35:27 +0000 (10:35 +0200)
This patch exports qdev_find_recursive() for later use.

Signed-off-by: Isaku Yamahata <yamahata@valinux.co.jp>
Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
hw/qdev.c
hw/qdev.h

index 4747c67..31eb464 100644 (file)
--- a/hw/qdev.c
+++ b/hw/qdev.c
@@ -548,7 +548,7 @@ static BusState *qbus_find_recursive(BusState *bus, const char *name,
     return NULL;
 }
 
-static DeviceState *qdev_find_recursive(BusState *bus, const char *id)
+DeviceState *qdev_find_recursive(BusState *bus, const char *id)
 {
     DeviceState *dev, *ret;
     BusState *child;
index 5f5a319..2be775f 100644 (file)
--- a/hw/qdev.h
+++ b/hw/qdev.h
@@ -183,6 +183,8 @@ BusState *qdev_get_parent_bus(DeviceState *dev);
 
 /*** BUS API. ***/
 
+DeviceState *qdev_find_recursive(BusState *bus, const char *id);
+
 /* Returns 0 to walk children, > 0 to skip walk, < 0 to terminate walk. */
 typedef int (qbus_walkerfn)(BusState *bus, void *opaque);
 typedef int (qdev_walkerfn)(DeviceState *dev, void *opaque);