qemu-devel
[Top][All Lists]
Advanced

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

Re: [Qemu-devel] Is cache=writeback safe yet?


From: Peter Maydell
Subject: Re: [Qemu-devel] Is cache=writeback safe yet?
Date: Mon, 20 Feb 2012 15:29:43 +0000

On 20 February 2012 15:20, Kevin Wolf <address@hidden> wrote:
> Am 20.02.2012 15:18, schrieb Virtbie:
>> Qemu manpage still says cache=writeback isn't safe, but I seem to find
>> some discordant information reading around.
>>
>> Is the WCE+volatile flag exposed to the guest already? I am logging into
>> a 2.6.38 guest and trying to find an indicator of disk cache in
>> /sys/block/vda/device but I am not able to. There is an obscure very
>> long "features" bitmask which I don't know what it shows. I think this
>> mode is not safe until WBC is exposed, AFAIU, right?
>
> qemu exposes the WCE flag and if your guest handles it correctly (i.e.
> it sends flush requests where needed), cache=writeback is safe. This is
> true for recent Linux versions.

The thing that confuses me when this subject comes up is that "cache=writeback"
is a property of the block layer, but the WCE flag is a SCSI parameter,
right? How does this work on non-SCSI disks? Is there something that
eg hw/sd.c should be doing to tell the block layer "writeback cache is
safe/unsafe" ?

-- PMM



reply via email to

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