The iSCSI backend already gets the block size from the READ CAPACITY
command it sends.  Save it so that the generic block layer gets it
too.

Signed-off-by: Paolo Bonzini <pbonz...@redhat.com>
---
 block/iscsi.c |    1 +
 1 files changed, 1 insertions(+), 0 deletions(-)

diff --git a/block/iscsi.c b/block/iscsi.c
index 55f52c4..cc7a379 100644
--- a/block/iscsi.c
+++ b/block/iscsi.c
@@ -663,6 +663,7 @@ static int iscsi_open(BlockDriverState *bs, const char 
*filename, int flags)
     if (iscsi_url != NULL) {
         iscsi_destroy_url(iscsi_url);
     }
+    bs->host_block_size = iscsilun->block_size;
     return 0;
 
 failed:
-- 
1.7.7.6



Reply via email to