2009-08-05 09:56:56 +00:00
|
|
|
<!-- A Relax NG schema for the libvirt capabilities XML format -->
|
2009-01-27 15:29:53 +00:00
|
|
|
<grammar xmlns="http://relaxng.org/ns/structure/1.0"
|
|
|
|
datatypeLibrary="http://www.w3.org/2001/XMLSchema-datatypes">
|
|
|
|
<start>
|
|
|
|
<ref name='capabilities'/>
|
|
|
|
</start>
|
|
|
|
|
|
|
|
|
|
|
|
<define name='capabilities'>
|
|
|
|
<element name='capabilities'>
|
|
|
|
<ref name='hostcaps'/>
|
|
|
|
|
|
|
|
<zeroOrMore>
|
2010-03-01 19:09:26 +00:00
|
|
|
<ref name='guestcaps'/>
|
2009-01-27 15:29:53 +00:00
|
|
|
</zeroOrMore>
|
|
|
|
</element>
|
|
|
|
</define>
|
|
|
|
|
|
|
|
<define name='hostcaps'>
|
|
|
|
<element name='host'>
|
2010-05-25 14:33:51 +00:00
|
|
|
<optional>
|
|
|
|
<element name='uuid'>
|
|
|
|
<ref name='UUID'/>
|
|
|
|
</element>
|
|
|
|
</optional>
|
2009-01-27 15:29:53 +00:00
|
|
|
<element name='cpu'>
|
2010-03-01 19:09:26 +00:00
|
|
|
<element name='arch'>
|
|
|
|
<ref name='archnames'/>
|
|
|
|
</element>
|
|
|
|
<optional>
|
|
|
|
<ref name='cpufeatures'/>
|
|
|
|
</optional>
|
|
|
|
<optional>
|
|
|
|
<ref name='cpuspec'/>
|
|
|
|
</optional>
|
2009-01-27 15:29:53 +00:00
|
|
|
</element>
|
|
|
|
<optional>
|
2010-03-01 19:09:26 +00:00
|
|
|
<ref name='migration'/>
|
2009-01-27 15:29:53 +00:00
|
|
|
</optional>
|
|
|
|
<optional>
|
2010-03-01 19:09:26 +00:00
|
|
|
<ref name='topology'/>
|
2009-01-27 15:29:53 +00:00
|
|
|
</optional>
|
2009-03-03 09:44:41 +00:00
|
|
|
<optional>
|
2010-03-01 19:09:26 +00:00
|
|
|
<ref name='secmodel'/>
|
2009-03-03 09:44:41 +00:00
|
|
|
</optional>
|
|
|
|
</element>
|
|
|
|
</define>
|
|
|
|
|
|
|
|
<define name='secmodel'>
|
|
|
|
<element name='secmodel'>
|
|
|
|
<element name='model'>
|
|
|
|
<text/>
|
|
|
|
</element>
|
|
|
|
<element name='doi'>
|
|
|
|
<text/>
|
|
|
|
</element>
|
2009-01-27 15:29:53 +00:00
|
|
|
</element>
|
|
|
|
</define>
|
|
|
|
|
2009-03-03 09:44:41 +00:00
|
|
|
|
2009-01-27 15:29:53 +00:00
|
|
|
<define name='cpufeatures'>
|
|
|
|
<element name='features'>
|
|
|
|
<optional>
|
2010-03-01 19:09:26 +00:00
|
|
|
<element name='pae'><empty/></element>
|
2009-01-27 15:29:53 +00:00
|
|
|
</optional>
|
|
|
|
<optional>
|
2010-03-01 19:09:26 +00:00
|
|
|
<element name='nonpae'><empty/></element>
|
2009-01-27 15:29:53 +00:00
|
|
|
</optional>
|
|
|
|
<optional>
|
2010-03-01 19:09:26 +00:00
|
|
|
<element name='vmx'><empty/></element>
|
2009-01-27 15:29:53 +00:00
|
|
|
</optional>
|
|
|
|
<optional>
|
2010-03-01 19:09:26 +00:00
|
|
|
<element name='svm'><empty/></element>
|
2009-01-27 15:29:53 +00:00
|
|
|
</optional>
|
|
|
|
</element>
|
|
|
|
</define>
|
|
|
|
|
2009-12-18 13:37:09 +00:00
|
|
|
<define name='cpuspec'>
|
|
|
|
<element name='model'>
|
|
|
|
<text/>
|
|
|
|
</element>
|
2010-07-02 15:51:59 +00:00
|
|
|
<optional>
|
|
|
|
<element name='vendor'>
|
|
|
|
<text/>
|
|
|
|
</element>
|
|
|
|
</optional>
|
2009-12-18 13:37:09 +00:00
|
|
|
<element name='topology'>
|
|
|
|
<attribute name='sockets'>
|
|
|
|
<ref name='positiveInteger'/>
|
|
|
|
</attribute>
|
|
|
|
<attribute name='cores'>
|
|
|
|
<ref name='positiveInteger'/>
|
|
|
|
</attribute>
|
|
|
|
<attribute name='threads'>
|
|
|
|
<ref name='positiveInteger'/>
|
|
|
|
</attribute>
|
|
|
|
</element>
|
|
|
|
<zeroOrMore>
|
|
|
|
<element name='feature'>
|
|
|
|
<attribute name='name'>
|
|
|
|
<ref name='featureName'/>
|
|
|
|
</attribute>
|
|
|
|
<empty/>
|
|
|
|
</element>
|
|
|
|
</zeroOrMore>
|
|
|
|
</define>
|
|
|
|
|
2009-01-27 15:29:53 +00:00
|
|
|
<define name='migration'>
|
|
|
|
<element name='migration_features'>
|
|
|
|
<optional>
|
2010-03-01 19:09:26 +00:00
|
|
|
<element name='live'>
|
|
|
|
<empty/>
|
|
|
|
</element>
|
2009-01-27 15:29:53 +00:00
|
|
|
</optional>
|
|
|
|
<optional>
|
2010-03-01 19:09:26 +00:00
|
|
|
<element name='uri_transports'>
|
|
|
|
<oneOrMore>
|
|
|
|
<element name='uri_transport'>
|
|
|
|
<choice>
|
|
|
|
<value>esx</value>
|
|
|
|
<value>tcp</value>
|
|
|
|
<value>xenmigr</value>
|
|
|
|
</choice>
|
|
|
|
</element>
|
|
|
|
</oneOrMore>
|
|
|
|
</element>
|
2009-01-27 15:29:53 +00:00
|
|
|
</optional>
|
|
|
|
</element>
|
|
|
|
</define>
|
|
|
|
|
|
|
|
<define name='topology'>
|
|
|
|
<element name='topology'>
|
|
|
|
<element name='cells'>
|
2010-03-01 19:09:26 +00:00
|
|
|
<attribute name='num'>
|
|
|
|
<ref name='uint'/>
|
|
|
|
</attribute>
|
|
|
|
<oneOrMore>
|
|
|
|
<ref name='cell'/>
|
|
|
|
</oneOrMore>
|
2009-01-27 15:29:53 +00:00
|
|
|
</element>
|
|
|
|
</element>
|
|
|
|
</define>
|
|
|
|
|
|
|
|
<define name='cell'>
|
|
|
|
<element name='cell'>
|
|
|
|
<attribute name='id'>
|
2010-03-01 19:09:26 +00:00
|
|
|
<ref name='uint'/>
|
2009-01-27 15:29:53 +00:00
|
|
|
</attribute>
|
|
|
|
|
|
|
|
<optional>
|
2010-03-01 19:09:26 +00:00
|
|
|
<element name='cpus'>
|
|
|
|
<attribute name='num'>
|
|
|
|
<ref name='uint'/>
|
|
|
|
</attribute>
|
|
|
|
<oneOrMore>
|
|
|
|
<ref name='cpu'/>
|
|
|
|
</oneOrMore>
|
|
|
|
</element>
|
2009-01-27 15:29:53 +00:00
|
|
|
</optional>
|
|
|
|
</element>
|
|
|
|
</define>
|
|
|
|
|
|
|
|
<define name='cpu'>
|
|
|
|
<element name='cpu'>
|
|
|
|
<attribute name='id'>
|
2010-03-01 19:09:26 +00:00
|
|
|
<ref name='uint'/>
|
2009-01-27 15:29:53 +00:00
|
|
|
</attribute>
|
|
|
|
</element>
|
|
|
|
</define>
|
|
|
|
|
|
|
|
<define name='guestcaps'>
|
|
|
|
<element name='guest'>
|
|
|
|
<ref name='ostype'/>
|
|
|
|
<ref name='arch'/>
|
|
|
|
<optional>
|
2010-03-01 19:09:26 +00:00
|
|
|
<ref name='features'/>
|
2009-01-27 15:29:53 +00:00
|
|
|
</optional>
|
|
|
|
</element>
|
|
|
|
</define>
|
|
|
|
|
|
|
|
<define name='ostype'>
|
|
|
|
<element name='os_type'>
|
|
|
|
<choice>
|
2010-03-01 19:09:26 +00:00
|
|
|
<value>xen</value> <!-- Xen 3.0 pv -->
|
|
|
|
<value>linux</value> <!-- same as 'xen' - legacy -->
|
|
|
|
<value>hvm</value> <!-- unmodified OS -->
|
|
|
|
<value>exe</value> <!-- For container based virt -->
|
|
|
|
<value>uml</value> <!-- user mode linux -->
|
2009-01-27 15:29:53 +00:00
|
|
|
</choice>
|
|
|
|
</element>
|
|
|
|
</define>
|
|
|
|
|
|
|
|
<define name='arch'>
|
|
|
|
<element name='arch'>
|
|
|
|
<attribute name='name'>
|
2010-03-01 19:09:26 +00:00
|
|
|
<ref name='archnames'/>
|
2009-01-27 15:29:53 +00:00
|
|
|
</attribute>
|
|
|
|
<ref name='wordsize'/>
|
|
|
|
<optional>
|
2010-03-01 19:09:26 +00:00
|
|
|
<ref name='emulator'/>
|
2009-01-27 15:29:53 +00:00
|
|
|
</optional>
|
|
|
|
<optional>
|
2010-03-01 19:09:26 +00:00
|
|
|
<ref name='loader'/>
|
2009-01-27 15:29:53 +00:00
|
|
|
</optional>
|
|
|
|
<zeroOrMore>
|
2010-03-01 19:09:26 +00:00
|
|
|
<ref name='machine'/>
|
2009-01-27 15:29:53 +00:00
|
|
|
</zeroOrMore>
|
|
|
|
<oneOrMore>
|
2010-03-01 19:09:26 +00:00
|
|
|
<ref name='domain'/>
|
2009-01-27 15:29:53 +00:00
|
|
|
</oneOrMore>
|
|
|
|
</element>
|
|
|
|
</define>
|
|
|
|
|
|
|
|
<define name='emulator'>
|
|
|
|
<element name='emulator'>
|
|
|
|
<ref name='path'/>
|
|
|
|
</element>
|
|
|
|
</define>
|
|
|
|
|
|
|
|
<define name='loader'>
|
|
|
|
<element name='loader'>
|
|
|
|
<ref name='path'/>
|
|
|
|
</element>
|
|
|
|
</define>
|
|
|
|
|
|
|
|
<define name='wordsize'>
|
|
|
|
<element name='wordsize'>
|
|
|
|
<choice>
|
2010-03-01 19:09:26 +00:00
|
|
|
<value>31</value>
|
|
|
|
<value>32</value>
|
|
|
|
<value>64</value>
|
2009-01-27 15:29:53 +00:00
|
|
|
</choice>
|
|
|
|
</element>
|
|
|
|
</define>
|
|
|
|
|
|
|
|
<define name='machine'>
|
|
|
|
<element name='machine'>
|
2009-07-23 17:31:35 +00:00
|
|
|
<optional>
|
|
|
|
<attribute name='canonical'>
|
|
|
|
<text/>
|
|
|
|
</attribute>
|
|
|
|
</optional>
|
2009-01-27 15:29:53 +00:00
|
|
|
<text/>
|
|
|
|
</element>
|
|
|
|
</define>
|
|
|
|
|
|
|
|
<define name='domain'>
|
|
|
|
<element name='domain'>
|
|
|
|
<attribute name='type'>
|
2010-03-01 19:09:26 +00:00
|
|
|
<choice>
|
|
|
|
<value>qemu</value>
|
|
|
|
<value>kqemu</value>
|
|
|
|
<value>kvm</value>
|
|
|
|
<value>xen</value>
|
|
|
|
<value>uml</value>
|
|
|
|
<value>lxc</value>
|
|
|
|
<value>openvz</value>
|
|
|
|
<value>test</value>
|
|
|
|
</choice>
|
2009-01-27 15:29:53 +00:00
|
|
|
</attribute>
|
|
|
|
|
|
|
|
<optional>
|
2010-03-01 19:09:26 +00:00
|
|
|
<ref name='emulator'/>
|
2009-01-27 15:29:53 +00:00
|
|
|
</optional>
|
2009-09-10 08:47:57 +00:00
|
|
|
<zeroOrMore>
|
2010-03-01 19:09:26 +00:00
|
|
|
<ref name='machine'/>
|
2009-09-10 08:47:57 +00:00
|
|
|
</zeroOrMore>
|
2009-01-27 15:29:53 +00:00
|
|
|
</element>
|
|
|
|
</define>
|
|
|
|
|
|
|
|
<define name='features'>
|
|
|
|
<element name='features'>
|
|
|
|
<optional>
|
2010-03-01 19:09:26 +00:00
|
|
|
<element name='pae'>
|
|
|
|
<empty/>
|
|
|
|
</element>
|
2009-01-27 15:29:53 +00:00
|
|
|
</optional>
|
|
|
|
<optional>
|
2010-03-01 19:09:26 +00:00
|
|
|
<element name='nonpae'>
|
|
|
|
<empty/>
|
|
|
|
</element>
|
2009-01-27 15:29:53 +00:00
|
|
|
</optional>
|
|
|
|
<optional>
|
2010-03-01 19:09:26 +00:00
|
|
|
<element name='ia64_be'>
|
|
|
|
<empty/>
|
|
|
|
</element>
|
2009-01-27 15:29:53 +00:00
|
|
|
</optional>
|
|
|
|
<optional>
|
2010-03-01 19:09:26 +00:00
|
|
|
<element name='acpi'>
|
|
|
|
<ref name='featuretoggle'/>
|
|
|
|
<empty/>
|
|
|
|
</element>
|
2009-01-27 15:29:53 +00:00
|
|
|
</optional>
|
|
|
|
<optional>
|
2010-03-01 19:09:26 +00:00
|
|
|
<element name='apic'>
|
|
|
|
<ref name='featuretoggle'/>
|
|
|
|
<empty/>
|
|
|
|
</element>
|
2009-01-27 15:29:53 +00:00
|
|
|
</optional>
|
2009-12-18 13:37:09 +00:00
|
|
|
<optional>
|
|
|
|
<element name='cpuselection'>
|
|
|
|
<empty/>
|
|
|
|
</element>
|
|
|
|
</optional>
|
2009-01-27 15:29:53 +00:00
|
|
|
</element>
|
|
|
|
</define>
|
|
|
|
|
|
|
|
<define name='featuretoggle'>
|
|
|
|
<attribute name='toggle'>
|
|
|
|
<choice>
|
2010-03-01 19:09:26 +00:00
|
|
|
<value>yes</value>
|
|
|
|
<value>no</value>
|
2009-01-27 15:29:53 +00:00
|
|
|
</choice>
|
|
|
|
</attribute>
|
|
|
|
<attribute name='default'>
|
|
|
|
<choice>
|
2010-03-01 19:09:26 +00:00
|
|
|
<value>on</value>
|
|
|
|
<value>off</value>
|
2009-01-27 15:29:53 +00:00
|
|
|
</choice>
|
|
|
|
</attribute>
|
|
|
|
</define>
|
|
|
|
|
|
|
|
<define name='archnames'>
|
|
|
|
<choice>
|
2009-09-10 08:51:23 +00:00
|
|
|
<value>arm</value>
|
2009-01-27 15:29:53 +00:00
|
|
|
<value>i686</value>
|
|
|
|
<value>ia64</value>
|
|
|
|
<value>mips</value>
|
|
|
|
<value>mipsel</value>
|
2009-09-10 08:51:23 +00:00
|
|
|
<value>ppc64</value>
|
|
|
|
<value>ppc</value>
|
|
|
|
<value>s390</value>
|
2009-01-27 15:29:53 +00:00
|
|
|
<value>sparc</value>
|
2009-09-10 08:51:23 +00:00
|
|
|
<value>x86_64</value>
|
2009-01-27 15:29:53 +00:00
|
|
|
</choice>
|
|
|
|
</define>
|
|
|
|
|
|
|
|
|
2009-12-18 13:37:09 +00:00
|
|
|
<define name='positiveInteger'>
|
|
|
|
<data type='positiveInteger'>
|
|
|
|
<param name="pattern">[0-9]+</param>
|
|
|
|
</data>
|
|
|
|
</define>
|
|
|
|
|
2009-01-27 15:29:53 +00:00
|
|
|
<define name='uint'>
|
2009-12-18 13:37:09 +00:00
|
|
|
<data type='unsignedInt'>
|
2009-01-27 15:29:53 +00:00
|
|
|
<param name="pattern">[0-9]+</param>
|
|
|
|
</data>
|
|
|
|
</define>
|
|
|
|
|
|
|
|
<define name='path'>
|
|
|
|
<data type='string'>
|
|
|
|
<param name="pattern">/[a-zA-Z0-9_\+\-/%]+</param>
|
|
|
|
</data>
|
|
|
|
</define>
|
|
|
|
|
2009-12-18 13:37:09 +00:00
|
|
|
<define name='featureName'>
|
|
|
|
<data type='string'>
|
|
|
|
<param name='pattern'>[a-zA-Z0-9\-_]+</param>
|
|
|
|
</data>
|
|
|
|
</define>
|
2010-05-25 14:33:51 +00:00
|
|
|
|
|
|
|
<define name="UUID">
|
|
|
|
<choice>
|
|
|
|
<data type="string">
|
|
|
|
<param name="pattern">[a-fA-F0-9]{32}</param>
|
|
|
|
</data>
|
|
|
|
<data type="string">
|
|
|
|
<param name="pattern">[a-fA-F0-9]{8}\-([a-fA-F0-9]{4}\-){3}[a-fA-F0-9]{12}</param>
|
|
|
|
</data>
|
|
|
|
</choice>
|
|
|
|
</define>
|
2009-01-27 15:29:53 +00:00
|
|
|
</grammar>
|