qemu-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Qemu-devel] [PATCH 3/3] virtio-blk: note optional features


From: Michael S. Tsirkin
Subject: Re: [Qemu-devel] [PATCH 3/3] virtio-blk: note optional features
Date: Tue, 6 Mar 2012 16:53:20 +0200
User-agent: Mutt/1.5.21 (2010-09-15)

On Tue, Mar 06, 2012 at 01:22:07PM +0100, Paolo Bonzini wrote:
> The guest must already be prepared to see SG_IO support
> disappear from under its feet, for example if migration
> refers to a block device on the source and file-based
> storage on the destination; or more likely, if the source
> kernel allows (gasp) SG_IO on a partition and the destination
> does not.  So, we can migrate safely even if the source
> had VIRTIO_BLK_F_SCSI and the destination does not.
> 
> Signed-off-by: Paolo Bonzini <address@hidden>

My first reaction is you want a new non guest
visible flag to control whether SG_IO fails on host.
guest visible ones must be consistent across migration.

> ---
>  hw/virtio-blk.c |    2 +-
>  1 files changed, 1 insertions(+), 1 deletions(-)
> 
> diff --git a/hw/virtio-blk.c b/hw/virtio-blk.c
> index c95f8fc..9a4158a 100644
> --- a/hw/virtio-blk.c
> +++ b/hw/virtio-blk.c
> @@ -542,7 +542,7 @@ static int virtio_blk_load(QEMUFile *f, void *opaque, int 
> version_id)
>      if (version_id != 2)
>          return -EINVAL;
>  
> -    ret = virtio_load(&s->vdev, f, 0);
> +    ret = virtio_load(&s->vdev, f, VIRTIO_BLK_F_SCSI);
>      if (ret) {
>          return ret;
>      }
> -- 
> 1.7.7.6



reply via email to

[Prev in Thread] Current Thread [Next in Thread]