From: Peter Lieven <p...@kamp.de> the opt_transfer_length has nothing to do with logical block provisioning stuff so always copy it from the block limits VPD page.
Reported-By: Benoit Canet <ben...@irqsave.net> Signed-off-by: Peter Lieven <p...@kamp.de> Reviewed-by: Benoit Canet <ben...@irqsave.net> Signed-off-by: Kevin Wolf <kw...@redhat.com> --- block/iscsi.c | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/block/iscsi.c b/block/iscsi.c index 6f4af72..8d0f966 100644 --- a/block/iscsi.c +++ b/block/iscsi.c @@ -1330,10 +1330,9 @@ static int iscsi_refresh_limits(BlockDriverState *bs) } bs->bl.write_zeroes_alignment = sector_lun2qemu(iscsilun->bl.opt_unmap_gran, iscsilun); - - bs->bl.opt_transfer_length = sector_lun2qemu(iscsilun->bl.opt_xfer_len, - iscsilun); } + bs->bl.opt_transfer_length = sector_lun2qemu(iscsilun->bl.opt_xfer_len, + iscsilun); return 0; } -- 1.8.1.4