diff options
author | Kevin Wolf <kwolf@redhat.com> | 2016-03-21 11:30:57 +0100 |
---|---|---|
committer | Kevin Wolf <kwolf@redhat.com> | 2016-05-19 16:45:29 +0200 |
commit | 31dce3ccca98bc9f9eb57f8b08b008edd07661ba (patch) | |
tree | dc0e381967d0135f1bc11beae16efc6b1391c31c /block/io.c | |
parent | f2cd875d54e95f87a4c994cfef082f09b4953aa9 (diff) | |
download | qemu-31dce3ccca98bc9f9eb57f8b08b008edd07661ba.tar.gz qemu-31dce3ccca98bc9f9eb57f8b08b008edd07661ba.tar.bz2 qemu-31dce3ccca98bc9f9eb57f8b08b008edd07661ba.zip |
block: throttle-groups: Use BlockBackend pointers internally
As a first step towards moving I/O throttling to the BlockBackend level,
this patch changes all pointers in struct ThrottleGroup from referencing
a BlockDriverState to referencing a BlockBackend.
This change is valid because we made sure that throttling can only be
enabled on BDSes which have a BB attached.
Signed-off-by: Kevin Wolf <kwolf@redhat.com>
Reviewed-by: Alberto Garcia <berto@igalia.com>
Acked-by: Stefan Hajnoczi <stefanha@redhat.com>
Diffstat (limited to 'block/io.c')
-rw-r--r-- | block/io.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/block/io.c b/block/io.c index cd6d71a503..ede74c5c03 100644 --- a/block/io.c +++ b/block/io.c @@ -70,7 +70,7 @@ void bdrv_io_limits_disable(BlockDriverState *bs) { assert(bs->throttle_state); bdrv_no_throttling_begin(bs); - throttle_group_unregister_bs(bs); + throttle_group_unregister_blk(bs->blk); bdrv_no_throttling_end(bs); } @@ -78,7 +78,7 @@ void bdrv_io_limits_disable(BlockDriverState *bs) void bdrv_io_limits_enable(BlockDriverState *bs, const char *group) { assert(!bs->throttle_state); - throttle_group_register_bs(bs, group); + throttle_group_register_blk(bs->blk, group); } void bdrv_io_limits_update_group(BlockDriverState *bs, const char *group) |