mirror of
https://gitlab.com/libvirt/libvirt.git
synced 2024-12-22 05:35:25 +00:00
schemas: Update nodedev schema to match reality
There were few things done in the nodedev code but we were lacking tests for it. And because of that we missed that the schema was not updated either. Fix the schema and add various test files to show the schema is correct. Signed-off-by: Martin Kletzander <mkletzan@redhat.com>
This commit is contained in:
parent
88c8be67d4
commit
9840761fb4
@ -143,8 +143,13 @@
|
||||
<value>virt_functions</value>
|
||||
</attribute>
|
||||
<optional>
|
||||
<ref name='address'/>
|
||||
<attribute name='maxCount'>
|
||||
<ref name='unsignedInt'/>
|
||||
</attribute>
|
||||
</optional>
|
||||
<zeroOrMore>
|
||||
<ref name='address'/>
|
||||
</zeroOrMore>
|
||||
</element>
|
||||
</optional>
|
||||
|
||||
|
23
tests/nodedevschemadata/pci_0000_02_10_7_sriov.xml
Normal file
23
tests/nodedevschemadata/pci_0000_02_10_7_sriov.xml
Normal file
@ -0,0 +1,23 @@
|
||||
<device>
|
||||
<name>pci_0000_02_10_7</name>
|
||||
<parent>pci_0000_00_04_0</parent>
|
||||
<capability type='pci'>
|
||||
<domain>0</domain>
|
||||
<bus>2</bus>
|
||||
<slot>16</slot>
|
||||
<function>7</function>
|
||||
<product id='0x10ca'>82576 Virtual Function</product>
|
||||
<vendor id='0x8086'>Intel Corporation</vendor>
|
||||
<capability type='phys_function'>
|
||||
<address domain='0x0000' bus='0x02' slot='0x00' function='0x1'/>
|
||||
</capability>
|
||||
<iommuGroup number='31'>
|
||||
<address domain='0x0000' bus='0x02' slot='0x10' function='0x7'/>
|
||||
</iommuGroup>
|
||||
<numa node='0'/>
|
||||
<pci-express>
|
||||
<link validity='cap' port='0' speed='2.5' width='4'/>
|
||||
<link validity='sta' width='0'/>
|
||||
</pci-express>
|
||||
</capability>
|
||||
</device>
|
@ -0,0 +1,29 @@
|
||||
<device>
|
||||
<name>pci_0000_02_10_7</name>
|
||||
<parent>pci_0000_00_04_0</parent>
|
||||
<capability type='pci'>
|
||||
<domain>0</domain>
|
||||
<bus>2</bus>
|
||||
<slot>16</slot>
|
||||
<function>7</function>
|
||||
<product id='0x10ca'>82576 Virtual Function</product>
|
||||
<vendor id='0x8086'>Intel Corporation</vendor>
|
||||
<capability type='phys_function'>
|
||||
<address domain='0x0000' bus='0x02' slot='0x00' function='0x1'/>
|
||||
</capability>
|
||||
<capability type='virt_functions' maxCount='7'>
|
||||
<address domain='0x0000' bus='0x02' slot='0x00' function='0x2'/>
|
||||
<address domain='0x0000' bus='0x02' slot='0x00' function='0x3'/>
|
||||
<address domain='0x0000' bus='0x02' slot='0x00' function='0x4'/>
|
||||
<address domain='0x0000' bus='0x02' slot='0x00' function='0x5'/>
|
||||
</capability>
|
||||
<iommuGroup number='31'>
|
||||
<address domain='0x0000' bus='0x02' slot='0x10' function='0x7'/>
|
||||
</iommuGroup>
|
||||
<numa node='0'/>
|
||||
<pci-express>
|
||||
<link validity='cap' port='0' speed='2.5' width='4'/>
|
||||
<link validity='sta' width='0'/>
|
||||
</pci-express>
|
||||
</capability>
|
||||
</device>
|
@ -0,0 +1,30 @@
|
||||
<device>
|
||||
<name>pci_0000_02_10_7</name>
|
||||
<parent>pci_0000_00_04_0</parent>
|
||||
<capability type='pci'>
|
||||
<domain>0</domain>
|
||||
<bus>2</bus>
|
||||
<slot>16</slot>
|
||||
<function>7</function>
|
||||
<product id='0x10ca'>82576 Virtual Function</product>
|
||||
<vendor id='0x8086'>Intel Corporation</vendor>
|
||||
<capability type='phys_function'>
|
||||
<address domain='0x0000' bus='0x02' slot='0x00' function='0x1'/>
|
||||
</capability>
|
||||
<capability type='virt_functions' maxCount='7'>
|
||||
<address domain='0x0000' bus='0x02' slot='0x00' function='0x2'/>
|
||||
<address domain='0x0000' bus='0x02' slot='0x00' function='0x3'/>
|
||||
<address domain='0x0000' bus='0x02' slot='0x00' function='0x4'/>
|
||||
<address domain='0x0000' bus='0x02' slot='0x00' function='0x5'/>
|
||||
</capability>
|
||||
<capability type='pci-bridge'/>
|
||||
<iommuGroup number='31'>
|
||||
<address domain='0x0000' bus='0x02' slot='0x10' function='0x7'/>
|
||||
</iommuGroup>
|
||||
<numa node='0'/>
|
||||
<pci-express>
|
||||
<link validity='cap' port='0' speed='2.5' width='4'/>
|
||||
<link validity='sta' width='0'/>
|
||||
</pci-express>
|
||||
</capability>
|
||||
</device>
|
26
tests/nodedevschemadata/pci_0000_02_10_7_sriov_vfs.xml
Normal file
26
tests/nodedevschemadata/pci_0000_02_10_7_sriov_vfs.xml
Normal file
@ -0,0 +1,26 @@
|
||||
<device>
|
||||
<name>pci_0000_02_10_7</name>
|
||||
<parent>pci_0000_00_04_0</parent>
|
||||
<capability type='pci'>
|
||||
<domain>0</domain>
|
||||
<bus>2</bus>
|
||||
<slot>16</slot>
|
||||
<function>7</function>
|
||||
<product id='0x10ca'>82576 Virtual Function</product>
|
||||
<vendor id='0x8086'>Intel Corporation</vendor>
|
||||
<capability type='virt_functions'>
|
||||
<address domain='0x0000' bus='0x02' slot='0x00' function='0x2'/>
|
||||
<address domain='0x0000' bus='0x02' slot='0x00' function='0x3'/>
|
||||
<address domain='0x0000' bus='0x02' slot='0x00' function='0x4'/>
|
||||
<address domain='0x0000' bus='0x02' slot='0x00' function='0x5'/>
|
||||
</capability>
|
||||
<iommuGroup number='31'>
|
||||
<address domain='0x0000' bus='0x02' slot='0x10' function='0x7'/>
|
||||
</iommuGroup>
|
||||
<numa node='0'/>
|
||||
<pci-express>
|
||||
<link validity='cap' port='0' speed='2.5' width='4'/>
|
||||
<link validity='sta' width='0'/>
|
||||
</pci-express>
|
||||
</capability>
|
||||
</device>
|
@ -0,0 +1,21 @@
|
||||
<device>
|
||||
<name>pci_0000_02_10_7</name>
|
||||
<parent>pci_0000_00_04_0</parent>
|
||||
<capability type='pci'>
|
||||
<domain>0</domain>
|
||||
<bus>2</bus>
|
||||
<slot>16</slot>
|
||||
<function>7</function>
|
||||
<product id='0x10ca'>82576 Virtual Function</product>
|
||||
<vendor id='0x8086'>Intel Corporation</vendor>
|
||||
<capability type='virt_functions' maxCount='3'/>
|
||||
<iommuGroup number='31'>
|
||||
<address domain='0x0000' bus='0x02' slot='0x10' function='0x7'/>
|
||||
</iommuGroup>
|
||||
<numa node='0'/>
|
||||
<pci-express>
|
||||
<link validity='cap' port='0' speed='2.5' width='4'/>
|
||||
<link validity='sta' width='0'/>
|
||||
</pci-express>
|
||||
</capability>
|
||||
</device>
|
Loading…
Reference in New Issue
Block a user