diff options
Diffstat (limited to 'include/sysemu/blockdev.h')
-rw-r--r-- | include/sysemu/blockdev.h | 14 |
1 files changed, 6 insertions, 8 deletions
diff --git a/include/sysemu/blockdev.h b/include/sysemu/blockdev.h index 09716de809..09d1e30b34 100644 --- a/include/sysemu/blockdev.h +++ b/include/sysemu/blockdev.h @@ -14,8 +14,8 @@ #include "qapi/error.h" #include "qemu/queue.h" -void blockdev_mark_auto_del(BlockDriverState *bs); -void blockdev_auto_del(BlockDriverState *bs); +void blockdev_mark_auto_del(BlockBackend *blk); +void blockdev_auto_del(BlockBackend *blk); typedef enum { IF_DEFAULT = -1, /* for use with drive_add() only */ @@ -30,14 +30,11 @@ typedef enum { } BlockInterfaceType; struct DriveInfo { - BlockDriverState *bdrv; - char *id; const char *devaddr; BlockInterfaceType type; int bus; int unit; int auto_del; /* see blockdev_mark_auto_del() */ - bool enable_auto_del; /* Only for legacy drive_new() */ bool is_default; /* Added by default_drive() ? */ int media_cd; int cyls, heads, secs, trans; @@ -46,6 +43,10 @@ struct DriveInfo { QTAILQ_ENTRY(DriveInfo) next; }; +DriveInfo *blk_legacy_dinfo(BlockBackend *blk); +DriveInfo *blk_set_legacy_dinfo(BlockBackend *blk, DriveInfo *dinfo); +BlockBackend *blk_by_legacy_dinfo(DriveInfo *dinfo); + void override_max_devs(BlockInterfaceType type, int max_devs); DriveInfo *drive_get(BlockInterfaceType type, int bus, int unit); @@ -54,14 +55,11 @@ DriveInfo *drive_get_by_index(BlockInterfaceType type, int index); int drive_get_max_bus(BlockInterfaceType type); int drive_get_max_devs(BlockInterfaceType type); DriveInfo *drive_get_next(BlockInterfaceType type); -DriveInfo *drive_get_by_blockdev(BlockDriverState *bs); QemuOpts *drive_def(const char *optstr); QemuOpts *drive_add(BlockInterfaceType type, int index, const char *file, const char *optstr); DriveInfo *drive_new(QemuOpts *arg, BlockInterfaceType block_default_type); -void drive_del(DriveInfo *dinfo); -void drive_info_del(DriveInfo *dinfo); /* device-hotplug */ |