[libvirt] [PATCH v3] domain.rng vs. formatdomain.html#elementsUSB
Eric Blake
eblake at redhat.com
Fri Mar 11 17:45:17 UTC 2011
On 03/01/2011 03:23 AM, Philipp Hahn wrote:
> The Relax-NG schema for domains regarding <hostdev> doesn't match what's
> implemented in src/conf/domain_conf.c#virDomainHostdevDefFormat(): The
> implementation only requires @type, but the schema currently either
> required none or all three attributes (@mode, @type, and @managed) to be
> defined together, because they are declared in the same
> <optional)-section. (@managed is currently even undocumented on
> <http://libvirt.org/formatdomain.html#elementsUSB>).
Thanks again for taking this on (and sorry for my review backlog delay -
it's been a couple weeks of chasing down nasty crashers, which stole my
time).
>
> The schema is changed to match the current implementation:
> 1. @mode is optional (which defaults to 'subsystem')
> 2. @type is required
> 3. @managed is optional (which defaults to 'no')
>
> The documnetation is updated to mention @managed.
s/documnetation/documentation/
> @@ -967,8 +967,9 @@
> <dd>The <code>hostdev</code> element is the main container for describing
> host devices. For usb device passthrough <code>mode</code> is always
> "subsystem" and <code>type</code> is "usb" for an USB device and "pci"
As long as we're touching this - English is screwy, and the acronym USB
is pronounced "you-ess-bee", the pronounced 'y' therefore matches with
"a" rather than "an".
> - for a PCI device..
> - <dt><code>source</code></dt>
> + for a PCI device. When <code>managed</code> is "yes" for a PIC device, it
> + is detached from the host before being passed on to the guest.</dd>
> + <dt><code>source</code></dt>
Spurious whitespace change on that last line; worse, the TABs are now
caught by 'make syntax-check'.
> +++ b/docs/schemas/domain.rng
> @@ -1731,12 +1731,14 @@
> <value>capabilities</value>
> </choice>
> </attribute>
> - <attribute name="type">
> - <choice>
> - <value>usb</value>
> - <value>pci</value>
> - </choice>
> - </attribute>
> + </optional>
> + <attribute name="type">
> + <choice>
> + <value>usb</value>
> + <value>pci</value>
> + </choice>
> + </attribute>
> + <optional>
> <attribute name="managed">
ACK with nits addressed, so I pushed it.
--
Eric Blake eblake at redhat.com +1-801-349-2682
Libvirt virtualization library http://libvirt.org
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 619 bytes
Desc: OpenPGP digital signature
URL: <http://listman.redhat.com/archives/libvir-list/attachments/20110311/64f16bca/attachment-0001.sig>
More information about the libvir-list
mailing list