block: Add 'active' field to BlockDeviceInfo
authorKevin Wolf <kwolf@redhat.com>
Tue, 4 Feb 2025 21:13:52 +0000 (22:13 +0100)
committerKevin Wolf <kwolf@redhat.com>
Thu, 6 Feb 2025 13:26:50 +0000 (14:26 +0100)
commitaec81049c2daa8a97b89e59f03733b21ae0f8c2d
tree3c0bc2cdf864e1b4325a72db74557a14e125ce84
parent107c551de0d7bc3aa8e926c557b66b9549616f42
block: Add 'active' field to BlockDeviceInfo

This allows querying from QMP (and also HMP) whether an image is
currently active or inactive (in the sense of BDRV_O_INACTIVE).

Signed-off-by: Kevin Wolf <kwolf@redhat.com>
Acked-by: Fabiano Rosas <farosas@suse.de>
Reviewed-by: Eric Blake <eblake@redhat.com>
Reviewed-by: Stefan Hajnoczi <stefanha@redhat.com>
Message-ID: <20250204211407.381505-2-kwolf@redhat.com>
Signed-off-by: Kevin Wolf <kwolf@redhat.com>
block.c
block/monitor/block-hmp-cmds.c
block/qapi.c
include/block/block-global-state.h
qapi/block-core.json
tests/qemu-iotests/184.out
tests/qemu-iotests/191.out
tests/qemu-iotests/273.out