This patch teaches testutil how to read multi-line input files with
backspace-newline line continuation markers.
The patch also breaks up all the single-line arguments test input files into
multi-line files with lines shorter than 80 characters.
The current code for using -drive simply sets the -drive 'index'
parameter. QEMU internally converts this to bus/unit depending
on the type of drive. This does not give us precise control over
the bus/unit assignment though. This change switches over to make
libvirt explicitly calculate the bus/unit number.
In addition bus/unit/index are actually irrelevant for VirtIO
disks, since each virtio disk is a separate PCI device. No disk
controller is involved.
Doing the conversion to bus/unit in libvirt allows us to correctly
attach SCSI controllers when required.
* src/qemu/qemu_conf.c: Specify bus/unit instead of index for
disks
* tests/qemuxml2argvdata/qemuxml2argv-disk*.args: Switch over from
using index=NNNN, to bus=NN, unit=NN for SCSI/IDE/Floppy disks
We keep support for the pty based monitor so that we can re-connect
to VMs started by older versions of libvirtd.
* src/domain_conf.c: handle formatting and parsing unix monitors
* src/qemu_driver.c: add qemudOpenMonitorUnix(), remove the monitor
pty path searching from qemudFindCharDevicePTYs(), switch
qemudStartVMDaemon() and qemuDomainXMLToNative() to using a unix
monitor
* tests/qemuxml2argvtest.c: switch to using a unix monitor
* tests/qemuxml2argvdata/qemuxml2argv-*.args: update test data
virExec will write out the pid of the daemonized process only. Use this
in the QEMU driver, rather than QEMU's pidfile, so we can catch errors we
might miss if the emulator bails early.
* tests/qemuxml2argvtest.c (testCompareXMLToArgvFiles): Adjust the
code that creates "actual" output, so that it too produces a
newline-terminated buffer.
* tests/qemuxml2argvdata/*.args: Append a newline to each, via:
for i in $(find|grep '\.args$'); do echo >> $i;done