libvirt/tests/xmconfigdata
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
..
sexpr2xml-pv-bootloader.cfg
sexpr2xml-pv-bootloader.xml xml: output memory unit for clarity 2012-03-07 18:24:43 -07:00
test-escape-paths.cfg
test-escape-paths.xml xml: output memory unit for clarity 2012-03-07 18:24:43 -07:00
test-fullvirt-force-hpet.cfg
test-fullvirt-force-hpet.xml xml: output memory unit for clarity 2012-03-07 18:24:43 -07:00
test-fullvirt-force-nohpet.cfg
test-fullvirt-force-nohpet.xml xml: output memory unit for clarity 2012-03-07 18:24:43 -07:00
test-fullvirt-localtime.cfg
test-fullvirt-localtime.xml xml: output memory unit for clarity 2012-03-07 18:24:43 -07:00
test-fullvirt-net-ioemu.cfg
test-fullvirt-net-ioemu.xml xml: output memory unit for clarity 2012-03-07 18:24:43 -07:00
test-fullvirt-net-netfront.cfg
test-fullvirt-net-netfront.xml xml: output memory unit for clarity 2012-03-07 18:24:43 -07:00
test-fullvirt-new-cdrom.cfg
test-fullvirt-new-cdrom.xml xml: output memory unit for clarity 2012-03-07 18:24:43 -07:00
test-fullvirt-old-cdrom.cfg
test-fullvirt-old-cdrom.xml xml: output memory unit for clarity 2012-03-07 18:24:43 -07:00
test-fullvirt-parallel-tcp.cfg
test-fullvirt-parallel-tcp.xml xml: output memory unit for clarity 2012-03-07 18:24:43 -07:00
test-fullvirt-serial-dev-2-ports.cfg
test-fullvirt-serial-dev-2-ports.xml xml: output memory unit for clarity 2012-03-07 18:24:43 -07:00
test-fullvirt-serial-dev-2nd-port.cfg
test-fullvirt-serial-dev-2nd-port.xml xml: output memory unit for clarity 2012-03-07 18:24:43 -07:00
test-fullvirt-serial-file.cfg
test-fullvirt-serial-file.xml xml: output memory unit for clarity 2012-03-07 18:24:43 -07:00
test-fullvirt-serial-null.cfg
test-fullvirt-serial-null.xml xml: output memory unit for clarity 2012-03-07 18:24:43 -07:00
test-fullvirt-serial-pipe.cfg
test-fullvirt-serial-pipe.xml xml: output memory unit for clarity 2012-03-07 18:24:43 -07:00
test-fullvirt-serial-pty.cfg
test-fullvirt-serial-pty.xml xml: output memory unit for clarity 2012-03-07 18:24:43 -07:00
test-fullvirt-serial-stdio.cfg
test-fullvirt-serial-stdio.xml xml: output memory unit for clarity 2012-03-07 18:24:43 -07:00
test-fullvirt-serial-tcp-telnet.cfg
test-fullvirt-serial-tcp-telnet.xml xml: output memory unit for clarity 2012-03-07 18:24:43 -07:00
test-fullvirt-serial-tcp.cfg
test-fullvirt-serial-tcp.xml xml: output memory unit for clarity 2012-03-07 18:24:43 -07:00
test-fullvirt-serial-udp.cfg
test-fullvirt-serial-udp.xml xml: output memory unit for clarity 2012-03-07 18:24:43 -07:00
test-fullvirt-serial-unix.cfg
test-fullvirt-serial-unix.xml xml: output memory unit for clarity 2012-03-07 18:24:43 -07:00
test-fullvirt-sound.cfg
test-fullvirt-sound.xml xml: output memory unit for clarity 2012-03-07 18:24:43 -07:00
test-fullvirt-usbmouse.cfg
test-fullvirt-usbmouse.xml xml: output memory unit for clarity 2012-03-07 18:24:43 -07:00
test-fullvirt-usbtablet-no-bus.xml xml: output memory unit for clarity 2012-03-07 18:24:43 -07:00
test-fullvirt-usbtablet.cfg
test-fullvirt-usbtablet.xml xml: output memory unit for clarity 2012-03-07 18:24:43 -07:00
test-fullvirt-utc.cfg
test-fullvirt-utc.xml xml: output memory unit for clarity 2012-03-07 18:24:43 -07:00
test-no-source-cdrom.cfg
test-no-source-cdrom.xml xml: output memory unit for clarity 2012-03-07 18:24:43 -07:00
test-paravirt-net-e1000.cfg
test-paravirt-net-e1000.xml xml: output memory unit for clarity 2012-03-07 18:24:43 -07:00
test-paravirt-net-vifname.cfg
test-paravirt-net-vifname.xml xml: output memory unit for clarity 2012-03-07 18:24:43 -07:00
test-paravirt-new-pvfb-vncdisplay.cfg
test-paravirt-new-pvfb-vncdisplay.xml xml: output memory unit for clarity 2012-03-07 18:24:43 -07:00
test-paravirt-new-pvfb.cfg
test-paravirt-new-pvfb.xml xml: output memory unit for clarity 2012-03-07 18:24:43 -07:00
test-paravirt-old-pvfb-vncdisplay.cfg
test-paravirt-old-pvfb-vncdisplay.xml xml: output memory unit for clarity 2012-03-07 18:24:43 -07:00
test-paravirt-old-pvfb.cfg
test-paravirt-old-pvfb.xml xml: output memory unit for clarity 2012-03-07 18:24:43 -07:00
test-paravirt-vcpu.cfg
test-paravirt-vcpu.xml xml: output memory unit for clarity 2012-03-07 18:24:43 -07:00
test-pci-devs.cfg
test-pci-devs.xml xml: output memory unit for clarity 2012-03-07 18:24:43 -07:00