Re: [virtio-spec PATCH 0/5] Receiving Used Buffers example code: cleanups and an extra mb()

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

 



On 06/17/13 04:17, Rusty Russell wrote:
> Stefan Hajnoczi <stefanha@xxxxxxxxx> writes:
>> On Sat, Jun 8, 2013 at 7:39 PM, Laszlo Ersek <lersek@xxxxxxxxxx> wrote:
>>> Patches before the last are small cleanups.
>>>
>>> In the last patch I'm trying to extract / generalize an idea from Stefan
>>> Hajnoczi's review of my virtio-net driver for OVMF.
> 
> How about a single patch which just replaces the completely broken
> example? :)

Do you want me to squash the series into one patch and repost?

>>>   Receiving Used Buffers: prevent speculative load when not
>>>     sequentially consistent
> 
> Yes, though this only needs to be a rmb().

Probably, but the spec never qualifies the memory barriers it
recommends. (Maybe their read/write types should be obvious to the
reader. I didn't give their types much thought because in edk2/OVMF
there's only MemoryFence().)

In any case I'll take this as your approval of the 5/5 patch. Thanks!

> In the OASIS 1.0 spec, I'd like an appendix with tested code for doing
> these operations (probably based on a simplifeid version of vringh.c).

(
I assume the tested code should come from one of the more sophisticated
drivers (that also have a unix-y coding style). Also, I've been actively
avoiding reading other virtio code (qemu, kernel, SeaBIOS, iPXE etc)
except when I was stuck with an OVMF driver and (a) it looked like there
was some silent requirement/assumption in qemu that had not been spelled
out in the spec, (b) I was being dyslexic.

Thus I can't really suggest code for the appendix (although the OVMF
drivers do work).
)

Thanks,
Laszlo
_______________________________________________
Virtualization mailing list
Virtualization@xxxxxxxxxxxxxxxxxxxxxxxxxx
https://lists.linuxfoundation.org/mailman/listinfo/virtualization




[Index of Archives]     [KVM Development]     [Libvirt Development]     [Libvirt Users]     [CentOS Virtualization]     [Netdev]     [Ethernet Bridging]     [Linux Wireless]     [Kernel Newbies]     [Security]     [Linux for Hams]     [Netfilter]     [Bugtraq]     [Yosemite Forum]     [MIPS Linux]     [ARM Linux]     [Linux RAID]     [Linux Admin]     [Samba]

  Powered by Linux