aboutsummaryrefslogtreecommitdiff
path: root/block/qapi.c
diff options
context:
space:
mode:
authorKevin Wolf <kwolf@redhat.com>2016-03-21 12:56:44 +0100
committerKevin Wolf <kwolf@redhat.com>2016-05-19 16:45:30 +0200
commit27ccdd52598290f0f8b58be56e235aff7aebfaf3 (patch)
tree3eae4aa48f08ad96ad0a9461ea52cf1ef160d0fc /block/qapi.c
parent49d2165d7d6b589d1ea28b15a8874c417bdc55ed (diff)
block: Move throttling fields from BDS to BB
This patch changes where the throttling state is stored (used to be the BlockDriverState, now it is the BlockBackend), but it doesn't actually make it a BB level feature yet. For example, throttling is still disabled when the BDS is detached from the BB. Signed-off-by: Kevin Wolf <kwolf@redhat.com> Acked-by: Stefan Hajnoczi <stefanha@redhat.com>
Diffstat (limited to 'block/qapi.c')
-rw-r--r--block/qapi.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/block/qapi.c b/block/qapi.c
index a3e514d89b..1e4bb8a0a5 100644
--- a/block/qapi.c
+++ b/block/qapi.c
@@ -67,7 +67,7 @@ BlockDeviceInfo *bdrv_block_device_info(BlockBackend *blk,
info->backing_file_depth = bdrv_get_backing_file_depth(bs);
info->detect_zeroes = bs->detect_zeroes;
- if (bs->throttle_state) {
+ if (bs->blk && blk_get_public(bs->blk)->throttle_state) {
ThrottleConfig cfg;
throttle_group_get_config(bs, &cfg);