mirror of
https://github.com/mii443/qemu.git
synced 2025-12-16 17:18:49 +00:00
block: Use bdrv_get_backing_file_depth()
Use the dedicated counting function in qmp_query_block in order to propagate the backing file depth to HMP and add backing_file_depth to qmp-commands.hx Signed-off-by: Benoit Canet <benoit@irqsave.net> Reviewed-by: Eric Blake <eblake@redhat.com> Signed-off-by: Luiz Capitulino <lcapitulino@redhat.com>
This commit is contained in:
committed by
Luiz Capitulino
parent
f198fd1c9a
commit
2e3e331710
3
block.c
3
block.c
@@ -2450,6 +2450,9 @@ BlockInfoList *qmp_query_block(Error **errp)
|
||||
info->value->inserted->backing_file = g_strdup(bs->backing_file);
|
||||
}
|
||||
|
||||
info->value->inserted->backing_file_depth =
|
||||
bdrv_get_backing_file_depth(bs);
|
||||
|
||||
if (bs->io_limits_enabled) {
|
||||
info->value->inserted->bps =
|
||||
bs->io_limits.bps[BLOCK_IO_LIMIT_TOTAL];
|
||||
|
||||
Reference in New Issue
Block a user