From 316a7af35029d52c971f5df044eb69901d6f16ff Mon Sep 17 00:00:00 2001 From: Christoph Hellwig Date: Sun, 12 Sep 2010 23:43:39 +0200 Subject: [PATCH] virtio-blk: propagate the required alignment Signed-off-by: Christoph Hellwig Signed-off-by: Kevin Wolf --- hw/virtio-blk.c | 1 + 1 file changed, 1 insertion(+) diff --git a/hw/virtio-blk.c b/hw/virtio-blk.c index bd6bbe6b14..a1df26dbcf 100644 --- a/hw/virtio-blk.c +++ b/hw/virtio-blk.c @@ -540,6 +540,7 @@ VirtIODevice *virtio_blk_init(DeviceState *dev, BlockConf *conf) register_savevm(dev, "virtio-blk", virtio_blk_id++, 2, virtio_blk_save, virtio_blk_load, s); bdrv_set_removable(s->bs, 0); + s->bs->buffer_alignment = conf->logical_block_size; return &s->vdev; } -- GitLab