mirror of
https://github.com/Motorhead1991/qemu.git
synced 2025-08-05 16:53:55 -06:00
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>
This commit is contained in:
parent
d9e0dfa246
commit
a5b8dd2ce8
12 changed files with 39 additions and 35 deletions
|
@ -1705,7 +1705,7 @@ static void iscsi_refresh_limits(BlockDriverState *bs, Error **errp)
|
|||
IscsiLun *iscsilun = bs->opaque;
|
||||
uint64_t max_xfer_len = iscsilun->use_16_for_rw ? 0xffffffff : 0xffff;
|
||||
|
||||
bs->request_alignment = iscsilun->block_size;
|
||||
bs->bl.request_alignment = iscsilun->block_size;
|
||||
|
||||
if (iscsilun->bl.max_xfer_len) {
|
||||
max_xfer_len = MIN(max_xfer_len, iscsilun->bl.max_xfer_len);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue