mirror of https://gitee.com/openkylin/qemu.git
qdev: export qdev_find_recursive() for later use
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>
This commit is contained in:
parent
b3a29fd560
commit
a2ee6b4fcb
|
@ -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;
|
||||
|
|
|
@ -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);
|
||||
|
|
Loading…
Reference in New Issue