Re: [RFC 7/11] virtio_pci: new, capability-aware driver.

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

 



On Wed, 2012-01-11 at 17:12 +0200, Michael S. Tsirkin wrote:

> This is similar to what we have now. But it's still buggy: e.g. if guest
> updates MAC byte by byte, we have no way to know when it's done doing
> so. 

Do like real HW, there's plenty of options:

 - (better) Have a command "update MAC" sent to a ring. A command ring
would be generally useful and could replace anything you do via writing
to config space today. The advantage of having a read-only config space
is that you significantly remove the need for synchronization. You could
also have an event ring and avoid the seqlock for reading. It's MUCH
better to have a fine granularity of what actually changed that having a
generic "something is changing in the config space".

With a new ring format allowing direct data in the ring descriptor that
would be trivial.

 - If you really don't like a command ring, you can have a command
"register", write the new MAC and send a command to make it "apply", but
that's not fantastic as there's going to be a possible discrepancy
between what's in the config and what's actually used.

 - Have a separate "MAC write" register set with the "hot" byte beeing
the low order byte. writing to it updates the MAC. 

Etc etc...

Cheers,
Ben.


_______________________________________________
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