aboutsummaryrefslogtreecommitdiff
path: root/block/throttle-groups.c
diff options
context:
space:
mode:
authorPaolo Bonzini <pbonzini@redhat.com>2017-06-05 14:38:52 +0200
committerFam Zheng <famz@redhat.com>2017-06-16 07:55:00 +0800
commitd993b85804b7ec099d4e1d377161ac8af398d855 (patch)
tree4884e4e48d1403d720a08a8080c0a35041b82d40 /block/throttle-groups.c
parent414c2ec3585408a5c7b458664db180e91480bb03 (diff)
block: access io_limits_disabled with atomic ops
Reviewed-by: Stefan Hajnoczi <stefanha@redhat.com> Reviewed-by: Alberto Garcia <berto@igalia.com> Signed-off-by: Paolo Bonzini <pbonzini@redhat.com> Message-Id: <20170605123908.18777-4-pbonzini@redhat.com> Signed-off-by: Fam Zheng <famz@redhat.com>
Diffstat (limited to 'block/throttle-groups.c')
-rw-r--r--block/throttle-groups.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/block/throttle-groups.c b/block/throttle-groups.c
index b73e7a800b..69bfbd44d9 100644
--- a/block/throttle-groups.c
+++ b/block/throttle-groups.c
@@ -240,7 +240,7 @@ static bool throttle_group_schedule_timer(BlockBackend *blk, bool is_write)
ThrottleGroup *tg = container_of(ts, ThrottleGroup, ts);
bool must_wait;
- if (blkp->io_limits_disabled) {
+ if (atomic_read(&blkp->io_limits_disabled)) {
return false;
}