diff mbox

[v2,18/21] blkdebug: Enable reopen

Message ID 1448294400-476-19-git-send-email-kwolf@redhat.com
State New
Headers show

Commit Message

Kevin Wolf Nov. 23, 2015, 3:59 p.m. UTC
Just reopening the children (as block.c does now) is enough.

Signed-off-by: Kevin Wolf <kwolf@redhat.com>
---
 block/blkdebug.c | 7 +++++++
 1 file changed, 7 insertions(+)

Comments

Max Reitz Nov. 27, 2015, 7:57 p.m. UTC | #1
On 23.11.2015 16:59, Kevin Wolf wrote:
> Just reopening the children (as block.c does now) is enough.
> 
> Signed-off-by: Kevin Wolf <kwolf@redhat.com>
> ---
>  block/blkdebug.c | 7 +++++++
>  1 file changed, 7 insertions(+)

Reviewed-by: Max Reitz <mreitz@redhat.com>
Alberto Garcia Dec. 2, 2015, 2:38 p.m. UTC | #2
On Mon 23 Nov 2015 04:59:57 PM CET, Kevin Wolf wrote:
> Just reopening the children (as block.c does now) is enough.
>
> Signed-off-by: Kevin Wolf <kwolf@redhat.com>

Reviewed-by: Alberto Garcia <berto@igalia.com>

Berto
diff mbox

Patch

diff --git a/block/blkdebug.c b/block/blkdebug.c
index bc0f041..459a3d9 100644
--- a/block/blkdebug.c
+++ b/block/blkdebug.c
@@ -770,6 +770,12 @@  static void blkdebug_refresh_filename(BlockDriverState *bs, QDict *options)
     bs->full_open_options = opts;
 }
 
+static int blkdebug_reopen_prepare(BDRVReopenState *reopen_state,
+                                   BlockReopenQueue *queue, Error **errp)
+{
+    return 0;
+}
+
 static BlockDriver bdrv_blkdebug = {
     .format_name            = "blkdebug",
     .protocol_name          = "blkdebug",
@@ -778,6 +784,7 @@  static BlockDriver bdrv_blkdebug = {
     .bdrv_parse_filename    = blkdebug_parse_filename,
     .bdrv_file_open         = blkdebug_open,
     .bdrv_close             = blkdebug_close,
+    .bdrv_reopen_prepare    = blkdebug_reopen_prepare,
     .bdrv_getlength         = blkdebug_getlength,
     .bdrv_truncate          = blkdebug_truncate,
     .bdrv_refresh_filename  = blkdebug_refresh_filename,