libvirt/tests/xml2vmxdata
Eric Blake 265457845f xml: output memory unit for clarity
Make it obvious to 'dumpxml' readers what unit we are using,
since our default of KiB for memory (1024) differs from qemu's
default of MiB; and differs from our use of bytes for storage.

Tests were updated via:

$ find tests/*data tests/*out -name '*.xml' | \
  xargs sed -i 's/<\(memory\|currentMemory\|hard_limit\|soft_limit\|min_guarantee\|swap_hard_limit\)>/<\1 unit='"'KiB'>/"
$ find tests/*data tests/*out -name '*.xml' | \
  xargs sed -i 's/<\(capacity\|allocation\|available\)>/<\1 unit='"'bytes'>/"

followed by a few fixes for the stragglers.

Note that with this patch, the RNG for <memory> still forbids
validation of anything except unit='KiB', since the code silently
ignores the attribute; a later patch will expand <memory> to allow
scaled input in the code and update the RNG to match.

* docs/schemas/basictypes.rng (unit): Add 'bytes'.
(scaledInteger): New define.
* docs/schemas/storagevol.rng (sizing): Use it.
* docs/schemas/storagepool.rng (sizing): Likewise.
* docs/schemas/domaincommon.rng (memoryKBElement): New define; use
for memory elements.
* src/conf/storage_conf.c (virStoragePoolDefFormat)
(virStorageVolDefFormat): Likewise.
* src/conf/domain_conf.h (_virDomainDef): Document unit used
internally.
* src/conf/storage_conf.h (_virStoragePoolDef, _virStorageVolDef):
Likewise.
* tests/*data/*.xml: Update all tests.
* tests/*out/*.xml: Likewise.
* tests/define-dev-segfault: Likewise.
* tests/openvzutilstest.c (testReadNetworkConf): Likewise.
* tests/qemuargv2xmltest.c (blankProblemElements): Likewise.
2012-03-07 18:24:43 -07:00
..
xml2vmx-annotation.vmx esx: Explictly declare VMX file content as UTF-8 2010-10-15 17:51:28 +02:00
xml2vmx-annotation.xml xml: output memory unit for clarity 2012-03-07 18:24:43 -07:00
xml2vmx-cdrom-ide-device.vmx esx: Explictly declare VMX file content as UTF-8 2010-10-15 17:51:28 +02:00
xml2vmx-cdrom-ide-device.xml xml: output memory unit for clarity 2012-03-07 18:24:43 -07:00
xml2vmx-cdrom-ide-file.vmx esx: Explictly declare VMX file content as UTF-8 2010-10-15 17:51:28 +02:00
xml2vmx-cdrom-ide-file.xml xml: output memory unit for clarity 2012-03-07 18:24:43 -07:00
xml2vmx-cdrom-scsi-device.vmx esx: Explictly declare VMX file content as UTF-8 2010-10-15 17:51:28 +02:00
xml2vmx-cdrom-scsi-device.xml xml: output memory unit for clarity 2012-03-07 18:24:43 -07:00
xml2vmx-cdrom-scsi-file.vmx esx: Explictly declare VMX file content as UTF-8 2010-10-15 17:51:28 +02:00
xml2vmx-cdrom-scsi-file.xml xml: output memory unit for clarity 2012-03-07 18:24:43 -07:00
xml2vmx-esx-in-the-wild-1.vmx vmx: Support persistent CPU shares 2011-04-05 08:40:57 +02:00
xml2vmx-esx-in-the-wild-1.xml xml: output memory unit for clarity 2012-03-07 18:24:43 -07:00
xml2vmx-esx-in-the-wild-2.vmx esx: Explictly declare VMX file content as UTF-8 2010-10-15 17:51:28 +02:00
xml2vmx-esx-in-the-wild-2.xml xml: output memory unit for clarity 2012-03-07 18:24:43 -07:00
xml2vmx-esx-in-the-wild-3.vmx esx: Explictly declare VMX file content as UTF-8 2010-10-15 17:51:28 +02:00
xml2vmx-esx-in-the-wild-3.xml xml: output memory unit for clarity 2012-03-07 18:24:43 -07:00
xml2vmx-esx-in-the-wild-4.vmx vmx: Support persistent CPU shares 2011-04-05 08:40:57 +02:00
xml2vmx-esx-in-the-wild-4.xml xml: output memory unit for clarity 2012-03-07 18:24:43 -07:00
xml2vmx-esx-in-the-wild-5.vmx vmx: Support persistent CPU shares 2011-04-05 08:40:57 +02:00
xml2vmx-esx-in-the-wild-5.xml xml: output memory unit for clarity 2012-03-07 18:24:43 -07:00
xml2vmx-esx-in-the-wild-6.vmx esx: Fix regression in absolute file name handling 2011-05-26 23:32:44 +02:00
xml2vmx-esx-in-the-wild-6.xml xml: output memory unit for clarity 2012-03-07 18:24:43 -07:00
xml2vmx-ethernet-bridged.vmx esx: Explictly declare VMX file content as UTF-8 2010-10-15 17:51:28 +02:00
xml2vmx-ethernet-bridged.xml xml: output memory unit for clarity 2012-03-07 18:24:43 -07:00
xml2vmx-ethernet-custom.vmx esx: Explictly declare VMX file content as UTF-8 2010-10-15 17:51:28 +02:00
xml2vmx-ethernet-custom.xml xml: output memory unit for clarity 2012-03-07 18:24:43 -07:00
xml2vmx-ethernet-e1000.vmx esx: Explictly declare VMX file content as UTF-8 2010-10-15 17:51:28 +02:00
xml2vmx-ethernet-e1000.xml xml: output memory unit for clarity 2012-03-07 18:24:43 -07:00
xml2vmx-ethernet-generated.vmx esx: Explictly declare VMX file content as UTF-8 2010-10-15 17:51:28 +02:00
xml2vmx-ethernet-generated.xml xml: output memory unit for clarity 2012-03-07 18:24:43 -07:00
xml2vmx-ethernet-nat.vmx vmx: Better Workstation vmx handling 2012-02-24 11:53:23 +01:00
xml2vmx-ethernet-nat.xml vmx: Better Workstation vmx handling 2012-02-24 11:53:23 +01:00
xml2vmx-ethernet-other.vmx esx: Explictly declare VMX file content as UTF-8 2010-10-15 17:51:28 +02:00
xml2vmx-ethernet-other.xml xml: output memory unit for clarity 2012-03-07 18:24:43 -07:00
xml2vmx-ethernet-static.vmx esx: Explictly declare VMX file content as UTF-8 2010-10-15 17:51:28 +02:00
xml2vmx-ethernet-static.xml xml: output memory unit for clarity 2012-03-07 18:24:43 -07:00
xml2vmx-ethernet-vmxnet2.vmx esx: Explictly declare VMX file content as UTF-8 2010-10-15 17:51:28 +02:00
xml2vmx-ethernet-vmxnet2.xml xml: output memory unit for clarity 2012-03-07 18:24:43 -07:00
xml2vmx-ethernet-vpx.vmx esx: Explictly declare VMX file content as UTF-8 2010-10-15 17:51:28 +02:00
xml2vmx-ethernet-vpx.xml xml: output memory unit for clarity 2012-03-07 18:24:43 -07:00
xml2vmx-floppy-device.vmx esx: Explictly declare VMX file content as UTF-8 2010-10-15 17:51:28 +02:00
xml2vmx-floppy-device.xml xml: output memory unit for clarity 2012-03-07 18:24:43 -07:00
xml2vmx-floppy-file.vmx esx: Explictly declare VMX file content as UTF-8 2010-10-15 17:51:28 +02:00
xml2vmx-floppy-file.xml xml: output memory unit for clarity 2012-03-07 18:24:43 -07:00
xml2vmx-graphics-vnc.vmx vmx: Add support for video device VRAM size 2011-01-06 18:18:35 +01:00
xml2vmx-graphics-vnc.xml xml: output memory unit for clarity 2012-03-07 18:24:43 -07:00
xml2vmx-gsx-in-the-wild-1.vmx esx: Explictly declare VMX file content as UTF-8 2010-10-15 17:51:28 +02:00
xml2vmx-gsx-in-the-wild-1.xml xml: output memory unit for clarity 2012-03-07 18:24:43 -07:00
xml2vmx-gsx-in-the-wild-2.vmx esx: Explictly declare VMX file content as UTF-8 2010-10-15 17:51:28 +02:00
xml2vmx-gsx-in-the-wild-2.xml xml: output memory unit for clarity 2012-03-07 18:24:43 -07:00
xml2vmx-gsx-in-the-wild-3.vmx esx: Explictly declare VMX file content as UTF-8 2010-10-15 17:51:28 +02:00
xml2vmx-gsx-in-the-wild-3.xml xml: output memory unit for clarity 2012-03-07 18:24:43 -07:00
xml2vmx-gsx-in-the-wild-4.vmx esx: Explictly declare VMX file content as UTF-8 2010-10-15 17:51:28 +02:00
xml2vmx-gsx-in-the-wild-4.xml xml: output memory unit for clarity 2012-03-07 18:24:43 -07:00
xml2vmx-harddisk-ide-file.vmx esx: Explictly declare VMX file content as UTF-8 2010-10-15 17:51:28 +02:00
xml2vmx-harddisk-ide-file.xml xml: output memory unit for clarity 2012-03-07 18:24:43 -07:00
xml2vmx-harddisk-scsi-file.vmx esx: Explictly declare VMX file content as UTF-8 2010-10-15 17:51:28 +02:00
xml2vmx-harddisk-scsi-file.xml xml: output memory unit for clarity 2012-03-07 18:24:43 -07:00
xml2vmx-minimal-64bit.vmx esx: Explictly declare VMX file content as UTF-8 2010-10-15 17:51:28 +02:00
xml2vmx-minimal-64bit.xml xml: output memory unit for clarity 2012-03-07 18:24:43 -07:00
xml2vmx-minimal.vmx esx: Explictly declare VMX file content as UTF-8 2010-10-15 17:51:28 +02:00
xml2vmx-minimal.xml xml: output memory unit for clarity 2012-03-07 18:24:43 -07:00
xml2vmx-parallel-device.vmx esx: Explictly declare VMX file content as UTF-8 2010-10-15 17:51:28 +02:00
xml2vmx-parallel-device.xml xml: output memory unit for clarity 2012-03-07 18:24:43 -07:00
xml2vmx-parallel-file.vmx esx: Explictly declare VMX file content as UTF-8 2010-10-15 17:51:28 +02:00
xml2vmx-parallel-file.xml xml: output memory unit for clarity 2012-03-07 18:24:43 -07:00
xml2vmx-scsi-driver.vmx esx: Explictly declare VMX file content as UTF-8 2010-10-15 17:51:28 +02:00
xml2vmx-scsi-driver.xml xml: output memory unit for clarity 2012-03-07 18:24:43 -07:00
xml2vmx-scsi-writethrough.vmx esx: Explictly declare VMX file content as UTF-8 2010-10-15 17:51:28 +02:00
xml2vmx-scsi-writethrough.xml xml: output memory unit for clarity 2012-03-07 18:24:43 -07:00
xml2vmx-serial-device.vmx esx: Explictly declare VMX file content as UTF-8 2010-10-15 17:51:28 +02:00
xml2vmx-serial-device.xml xml: output memory unit for clarity 2012-03-07 18:24:43 -07:00
xml2vmx-serial-file.vmx esx: Explictly declare VMX file content as UTF-8 2010-10-15 17:51:28 +02:00
xml2vmx-serial-file.xml xml: output memory unit for clarity 2012-03-07 18:24:43 -07:00
xml2vmx-serial-network-client.vmx esx: Explictly declare VMX file content as UTF-8 2010-10-15 17:51:28 +02:00
xml2vmx-serial-network-client.xml xml: output memory unit for clarity 2012-03-07 18:24:43 -07:00
xml2vmx-serial-network-server.vmx esx: Explictly declare VMX file content as UTF-8 2010-10-15 17:51:28 +02:00
xml2vmx-serial-network-server.xml xml: output memory unit for clarity 2012-03-07 18:24:43 -07:00
xml2vmx-serial-pipe.vmx esx: Explictly declare VMX file content as UTF-8 2010-10-15 17:51:28 +02:00
xml2vmx-serial-pipe.xml xml: output memory unit for clarity 2012-03-07 18:24:43 -07:00
xml2vmx-smbios.vmx esx: Support SMBIOS host mode 2010-11-11 19:18:19 +01:00
xml2vmx-smbios.xml xml: output memory unit for clarity 2012-03-07 18:24:43 -07:00
xml2vmx-svga.vmx vmx: Add support for video device VRAM size 2011-01-06 18:18:35 +01:00
xml2vmx-svga.xml xml: output memory unit for clarity 2012-03-07 18:24:43 -07:00
xml2vmx-ws-in-the-wild-1.vmx vmx: Better Workstation vmx handling 2012-02-24 11:53:23 +01:00
xml2vmx-ws-in-the-wild-1.xml vmx: Better Workstation vmx handling 2012-02-24 11:53:23 +01:00
xml2vmx-ws-in-the-wild-2.vmx vmx: Better Workstation vmx handling 2012-02-24 11:53:23 +01:00
xml2vmx-ws-in-the-wild-2.xml vmx: Better Workstation vmx handling 2012-02-24 11:53:23 +01:00