aboutsummaryrefslogtreecommitdiff
path: root/block.c
diff options
context:
space:
mode:
Diffstat (limited to 'block.c')
-rw-r--r--block.c7
1 files changed, 7 insertions, 0 deletions
diff --git a/block.c b/block.c
index 9bb236c..5c30c9d 100644
--- a/block.c
+++ b/block.c
@@ -816,6 +816,13 @@ bool bdrv_dev_has_removable_media(BlockDriverState *bs)
return !bs->dev || (bs->dev_ops && bs->dev_ops->change_media_cb);
}
+void bdrv_dev_eject_request(BlockDriverState *bs, bool force)
+{
+ if (bs->dev_ops && bs->dev_ops->eject_request_cb) {
+ bs->dev_ops->eject_request_cb(bs->dev_opaque, force);
+ }
+}
+
bool bdrv_dev_is_tray_open(BlockDriverState *bs)
{
if (bs->dev_ops && bs->dev_ops->is_tray_open) {