summaryrefslogtreecommitdiff
path: root/block.c
diff options
context:
space:
mode:
authorEric Blake <eblake@redhat.com>2016-06-23 16:37:24 -0600
committerKevin Wolf <kwolf@redhat.com>2016-07-05 16:46:26 +0200
commita5b8dd2ce83208cd7d6eb4562339ecf5aae13574 (patch)
treeeea17f09c6a183d2526f90798c6f6097db506195 /block.c
parentd9e0dfa2462e32cc5c6c49401ad7bff36453f75c (diff)
downloadqemu-a5b8dd2ce83208cd7d6eb4562339ecf5aae13574.tar.gz
block: Move request_alignment into BlockLimit
It makes more sense to have ALL block size limit constraints in the same struct. Improve the documentation while at it. Simplify a couple of conditionals, now that we have audited and documented that request_alignment is always non-zero. Signed-off-by: Eric Blake <eblake@redhat.com> Reviewed-by: Fam Zheng <famz@redhat.com> Signed-off-by: Kevin Wolf <kwolf@redhat.com>
Diffstat (limited to 'block.c')
-rw-r--r--block.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/block.c b/block.c
index c2fbf069fc..34894ad42e 100644
--- a/block.c
+++ b/block.c
@@ -1016,7 +1016,7 @@ static int bdrv_open_common(BlockDriverState *bs, BdrvChild *file,
assert(bdrv_opt_mem_align(bs) != 0);
assert(bdrv_min_mem_align(bs) != 0);
- assert(is_power_of_2(bs->request_alignment) || bdrv_is_sg(bs));
+ assert(is_power_of_2(bs->bl.request_alignment));
qemu_opts_del(opts);
return 0;