]> xenbits.xensource.com Git - libvirt.git/commitdiff
Set default disk controller/bus/unit props
authorDaniel P. Berrange <berrange@redhat.com>
Tue, 22 Dec 2009 16:53:20 +0000 (16:53 +0000)
committerDaniel P. Berrange <berrange@redhat.com>
Fri, 15 Jan 2010 16:38:29 +0000 (16:38 +0000)
When parsing the <disk> element specification, if no <address>
is provided for the disk, then automatically assign one based on
the <target dev='sdXX'/> device name. This provides for backwards
compatability with existing applications using libvirt, while also
allowing new apps to have complete fine grained control.

* src/conf/domain_conf.h, src/conf/domain_conf.c,
  src/libvirt_private.syms: Add virDomainDiskDefAssignAddress()
  for assigning a controller/bus/unit address based on disk target
* src/qemu/qemu_conf.c: Call virDomainDiskDefAssignAddress() after
  generating XML from ARGV
* tests/qemuxml2argvdata/*.xml: Add in drive address information
  to all XML files

81 files changed:
src/conf/domain_conf.c
src/conf/domain_conf.h
src/libvirt_private.syms
src/qemu/qemu_conf.c
tests/qemuxml2argvdata/qemuxml2argv-boot-cdrom.xml
tests/qemuxml2argvdata/qemuxml2argv-boot-floppy.xml
tests/qemuxml2argvdata/qemuxml2argv-boot-network.xml
tests/qemuxml2argvdata/qemuxml2argv-bootloader.xml
tests/qemuxml2argvdata/qemuxml2argv-channel-guestfwd.xml
tests/qemuxml2argvdata/qemuxml2argv-clock-localtime.xml
tests/qemuxml2argvdata/qemuxml2argv-clock-utc.xml
tests/qemuxml2argvdata/qemuxml2argv-console-compat-chardev.xml
tests/qemuxml2argvdata/qemuxml2argv-console-compat.xml
tests/qemuxml2argvdata/qemuxml2argv-disk-cdrom-empty.xml
tests/qemuxml2argvdata/qemuxml2argv-disk-cdrom.xml
tests/qemuxml2argvdata/qemuxml2argv-disk-drive-boot-cdrom.xml
tests/qemuxml2argvdata/qemuxml2argv-disk-drive-boot-disk.xml
tests/qemuxml2argvdata/qemuxml2argv-disk-drive-cache-v1-none.xml
tests/qemuxml2argvdata/qemuxml2argv-disk-drive-cache-v1-wb.xml
tests/qemuxml2argvdata/qemuxml2argv-disk-drive-cache-v1-wt.xml
tests/qemuxml2argvdata/qemuxml2argv-disk-drive-cache-v2-none.xml
tests/qemuxml2argvdata/qemuxml2argv-disk-drive-cache-v2-wb.xml
tests/qemuxml2argvdata/qemuxml2argv-disk-drive-cache-v2-wt.xml
tests/qemuxml2argvdata/qemuxml2argv-disk-drive-fat.xml
tests/qemuxml2argvdata/qemuxml2argv-disk-drive-fmt-qcow.xml
tests/qemuxml2argvdata/qemuxml2argv-disk-drive-shared.xml
tests/qemuxml2argvdata/qemuxml2argv-disk-floppy.xml
tests/qemuxml2argvdata/qemuxml2argv-disk-many.xml
tests/qemuxml2argvdata/qemuxml2argv-disk-usb.xml
tests/qemuxml2argvdata/qemuxml2argv-disk-virtio.xml
tests/qemuxml2argvdata/qemuxml2argv-disk-xenvbd.xml
tests/qemuxml2argvdata/qemuxml2argv-floppy-drive-fat.xml
tests/qemuxml2argvdata/qemuxml2argv-graphics-sdl-fullscreen.xml
tests/qemuxml2argvdata/qemuxml2argv-graphics-sdl.xml
tests/qemuxml2argvdata/qemuxml2argv-graphics-vnc-sasl.xml
tests/qemuxml2argvdata/qemuxml2argv-graphics-vnc-tls.xml
tests/qemuxml2argvdata/qemuxml2argv-graphics-vnc.xml
tests/qemuxml2argvdata/qemuxml2argv-hostdev-pci-address.xml
tests/qemuxml2argvdata/qemuxml2argv-hostdev-usb-address.xml
tests/qemuxml2argvdata/qemuxml2argv-hostdev-usb-product.xml
tests/qemuxml2argvdata/qemuxml2argv-hugepages.xml
tests/qemuxml2argvdata/qemuxml2argv-input-usbmouse.xml
tests/qemuxml2argvdata/qemuxml2argv-input-usbtablet.xml
tests/qemuxml2argvdata/qemuxml2argv-input-xen.xml
tests/qemuxml2argvdata/qemuxml2argv-machine-aliases1.xml
tests/qemuxml2argvdata/qemuxml2argv-machine-aliases2.xml
tests/qemuxml2argvdata/qemuxml2argv-migrate.xml
tests/qemuxml2argvdata/qemuxml2argv-minimal.xml
tests/qemuxml2argvdata/qemuxml2argv-misc-acpi.xml
tests/qemuxml2argvdata/qemuxml2argv-misc-no-reboot.xml
tests/qemuxml2argvdata/qemuxml2argv-misc-uuid.xml
tests/qemuxml2argvdata/qemuxml2argv-net-eth-ifname.xml
tests/qemuxml2argvdata/qemuxml2argv-net-eth-names.xml
tests/qemuxml2argvdata/qemuxml2argv-net-eth.xml
tests/qemuxml2argvdata/qemuxml2argv-net-user.xml
tests/qemuxml2argvdata/qemuxml2argv-net-virtio.xml
tests/qemuxml2argvdata/qemuxml2argv-parallel-tcp-chardev.xml
tests/qemuxml2argvdata/qemuxml2argv-parallel-tcp.xml
tests/qemuxml2argvdata/qemuxml2argv-restore-v1.xml
tests/qemuxml2argvdata/qemuxml2argv-restore-v2.xml
tests/qemuxml2argvdata/qemuxml2argv-serial-dev-chardev.xml
tests/qemuxml2argvdata/qemuxml2argv-serial-dev.xml
tests/qemuxml2argvdata/qemuxml2argv-serial-file-chardev.xml
tests/qemuxml2argvdata/qemuxml2argv-serial-file.xml
tests/qemuxml2argvdata/qemuxml2argv-serial-many-chardev.xml
tests/qemuxml2argvdata/qemuxml2argv-serial-many.xml
tests/qemuxml2argvdata/qemuxml2argv-serial-pty-chardev.xml
tests/qemuxml2argvdata/qemuxml2argv-serial-pty.xml
tests/qemuxml2argvdata/qemuxml2argv-serial-tcp-chardev.xml
tests/qemuxml2argvdata/qemuxml2argv-serial-tcp-telnet-chardev.xml
tests/qemuxml2argvdata/qemuxml2argv-serial-tcp-telnet.xml
tests/qemuxml2argvdata/qemuxml2argv-serial-tcp.xml
tests/qemuxml2argvdata/qemuxml2argv-serial-udp-chardev.xml
tests/qemuxml2argvdata/qemuxml2argv-serial-udp.xml
tests/qemuxml2argvdata/qemuxml2argv-serial-unix-chardev.xml
tests/qemuxml2argvdata/qemuxml2argv-serial-unix.xml
tests/qemuxml2argvdata/qemuxml2argv-serial-vc-chardev.xml
tests/qemuxml2argvdata/qemuxml2argv-serial-vc.xml
tests/qemuxml2argvdata/qemuxml2argv-sound.xml
tests/qemuxml2argvdata/qemuxml2argv-watchdog.xml
tests/qemuxml2xmltest.c

index 27d06137f7089f6d4751c9fdaf7f2e881c529d04..662ff810eb01d66389c5be672a112c7a93ed4d43 100644 (file)
@@ -1025,7 +1025,7 @@ virDomainDeviceInfoParseXML(virConnectPtr conn,
         break;
 
     case VIR_DOMAIN_DEVICE_ADDRESS_TYPE_DRIVE:
-        if (virDomainDeviceDriveAddressParseXML(conn, node, &info->addr.drive) < 0)
+        if (virDomainDeviceDriveAddressParseXML(conn, address, &info->addr.drive) < 0)
             goto cleanup;
         break;
 
@@ -1044,6 +1044,45 @@ cleanup:
 }
 
 
+void
+virDomainDiskDefAssignAddress(virDomainDiskDefPtr def)
+{
+    int idx = virDiskNameToIndex(def->dst);
+
+    switch (def->bus) {
+    case VIR_DOMAIN_DISK_BUS_SCSI:
+        /* For SCSI we define the default mapping to be 7 units
+         * per bus, 1 bus per controller, many controllers */
+        def->info.type = VIR_DOMAIN_DEVICE_ADDRESS_TYPE_DRIVE;
+        def->info.addr.drive.controller = idx / 7;
+        def->info.addr.drive.bus = 0;
+        def->info.addr.drive.unit = idx % 7;
+        break;
+
+    case VIR_DOMAIN_DISK_BUS_IDE:
+        /* For IDE we define the default mapping to be 2 units
+         * per bus, 2 bus per controller, many controllers */
+        def->info.type = VIR_DOMAIN_DEVICE_ADDRESS_TYPE_DRIVE;
+        def->info.addr.drive.controller = idx / 4;
+        def->info.addr.drive.bus = (idx % 4) / 2;
+        def->info.addr.drive.unit = (idx % 2);
+        break;
+
+    case VIR_DOMAIN_DISK_BUS_FDC:
+        /* For FDC we define the default mapping to be 2 units
+         * per bus, 1 bus per controller, many controllers */
+        def->info.type = VIR_DOMAIN_DEVICE_ADDRESS_TYPE_DRIVE;
+        def->info.addr.drive.controller = idx / 2;
+        def->info.addr.drive.bus = 0;
+        def->info.addr.drive.unit = idx % 2;
+        break;
+
+    default:
+        /* Other disk bus's aren't controller based */
+        break;
+    }
+}
+
 /* Parse the XML definition for a disk
  * @param node XML nodeset to parse for disk definition
  */
@@ -1271,6 +1310,9 @@ virDomainDiskDefParseXML(virConnectPtr conn,
     def->serial = serial;
     serial = NULL;
 
+    if (def->info.type == VIR_DOMAIN_DEVICE_ADDRESS_TYPE_NONE)
+        virDomainDiskDefAssignAddress(def);
+
 cleanup:
     VIR_FREE(bus);
     VIR_FREE(type);
index 0f68864087f11841dc361fc40f49165698d34da4..a05835adf4660c559fd885c22f755016257c4839 100644 (file)
@@ -773,6 +773,7 @@ int virDomainDiskInsert(virDomainDefPtr def,
                         virDomainDiskDefPtr disk);
 void virDomainDiskInsertPreAlloced(virDomainDefPtr def,
                                    virDomainDiskDefPtr disk);
+void virDomainDiskDefAssignAddress(virDomainDiskDefPtr def);
 
 int virDomainSaveXML(virConnectPtr conn,
                      const char *configDir,
index 2f6d465b4d9c2028a5bdec0afd457d143770a4e3..4969296fee2eb947c966ee06e2cc11cbf9462adb 100644 (file)
@@ -129,6 +129,7 @@ virDomainDiskDefFree;
 virDomainDiskDeviceTypeToString;
 virDomainDiskInsert;
 virDomainDiskInsertPreAlloced;
+virDomainDiskDefAssignAddress;
 virDomainFindByID;
 virDomainFindByName;
 virDomainFindByUUID;
index d3da7768d282a4c59d69796a7d4907708a6c461f..369dc31b99c07bef0846f758e55fbb89a4038953 100644 (file)
@@ -3271,6 +3271,8 @@ qemuParseCommandLineDisk(virConnectPtr conn,
     else
         def->dst[2] = 'a' + idx;
 
+    virDomainDiskDefAssignAddress(def);
+
 cleanup:
     for (i = 0 ; i < nkeywords ; i++) {
         VIR_FREE(keywords[i]);
@@ -4000,6 +4002,8 @@ virDomainDefPtr qemuParseCommandLine(virConnectPtr conn,
                 goto no_memory;
             }
 
+            virDomainDiskDefAssignAddress(disk);
+
             if (VIR_REALLOC_N(def->disks, def->ndisks+1) < 0) {
                 virDomainDiskDefFree(disk);
                 goto no_memory;
index 5211d0ce4cf84c70ba39ebfd1aa54eb68d85fb59..6915145bb94a3b83830331f0ae079f39aa976738 100644 (file)
@@ -18,6 +18,7 @@
       <source dev='/dev/cdrom'/>
       <target dev='hdc' bus='ide'/>
       <readonly/>
+      <address type='drive' controller='0' bus='1' unit='0'/>
     </disk>
   </devices>
 </domain>
index ad33b536ffd82374129f98a835ff9b54f3790efb..0b6b084b218d7ca6df0996784bb343db8c16545f 100644 (file)
     <disk type='block' device='disk'>
       <source dev='/dev/HostVG/QEMUGuest1'/>
       <target dev='hda' bus='ide'/>
+      <address type='drive' controller='0' bus='0' unit='0'/>
     </disk>
     <disk type='file' device='floppy'>
       <source file='/tmp/firmware.img'/>
       <target dev='fda' bus='fdc'/>
+      <address type='drive' controller='0' bus='0' unit='0'/>
     </disk>
   </devices>
 </domain>
index 8d510a9fd54c9093c4f84b477ed8eff3f57506d1..4de216e50e48ea7c359c43705d9ea427bf3eb595 100644 (file)
@@ -17,6 +17,7 @@
     <disk type='block' device='disk'>
       <source dev='/dev/HostVG/QEMUGuest1'/>
       <target dev='hda' bus='ide'/>
+      <address type='drive' controller='0' bus='0' unit='0'/>
     </disk>
   </devices>
 </domain>
index e28709e1b189bd1d65d328c5f70747761ad52ca1..0501fd42d4aded93496894204e80cd6537de9938 100644 (file)
@@ -18,6 +18,7 @@
       <source dev='/dev/cdrom'/>
       <target dev='hdc' bus='ide'/>
       <readonly/>
+      <address type='drive' controller='0' bus='1' unit='0'/>
     </disk>
   </devices>
 </domain>
index 51a0c1e06fb00b804b78eefebf5bf7a23ae28135..aeba5be1cebaca71b5eca440aa29d76c2c4b9791 100644 (file)
@@ -17,6 +17,7 @@
     <disk type='block' device='disk'>
       <source dev='/dev/HostVG/QEMUGuest1'/>
       <target dev='hda' bus='ide'/>
+      <address type='drive' controller='0' bus='0' unit='0'/>
     </disk>
     <channel type='pipe'>
       <source path='/tmp/guestfwd'/>
index dc1ae32fb24e543973fb841f43b1086f117c0ec8..1db0d02eac3177251e9c6862526117858249e329 100644 (file)
@@ -17,6 +17,7 @@
     <disk type='block' device='disk'>
       <source dev='/dev/HostVG/QEMUGuest1'/>
       <target dev='hda' bus='ide'/>
+      <address type='drive' controller='0' bus='0' unit='0'/>
     </disk>
   </devices>
 </domain>
index 26c9b259431d75a0720cc8b2f1b2e3056ac72965..9e9153f4658049851b4747c6eee4b5e10b944793 100644 (file)
@@ -17,6 +17,7 @@
     <disk type='block' device='disk'>
       <source dev='/dev/HostVG/QEMUGuest1'/>
       <target dev='hda' bus='ide'/>
+      <address type='drive' controller='0' bus='0' unit='0'/>
     </disk>
   </devices>
 </domain>
index c16ae07f3af50aeb7dd766f889a748554901bff8..1f8f1267b94b0376a189bb726bd5c17bdc408b8e 100644 (file)
@@ -17,6 +17,7 @@
     <disk type='block' device='disk'>
       <source dev='/dev/HostVG/QEMUGuest1'/>
       <target dev='hda' bus='ide'/>
+      <address type='drive' controller='0' bus='0' unit='0'/>
     </disk>
     <serial type='pty'>
       <target port='0'/>
index c16ae07f3af50aeb7dd766f889a748554901bff8..1f8f1267b94b0376a189bb726bd5c17bdc408b8e 100644 (file)
@@ -17,6 +17,7 @@
     <disk type='block' device='disk'>
       <source dev='/dev/HostVG/QEMUGuest1'/>
       <target dev='hda' bus='ide'/>
+      <address type='drive' controller='0' bus='0' unit='0'/>
     </disk>
     <serial type='pty'>
       <target port='0'/>
index d5341b395f0bd4b77509839307d7f2dffe28da7a..ff315e117df2bf6705a09c665db8af12fae90b70 100644 (file)
     <disk type='block' device='disk'>
       <source dev='/dev/HostVG/QEMUGuest1'/>
       <target dev='hda' bus='ide'/>
+      <address type='drive' controller='0' bus='0' unit='0'/>
     </disk>
     <disk type='file' device='cdrom'>
       <target dev='hdc' bus='ide'/>
       <readonly/>
+      <address type='drive' controller='0' bus='1' unit='0'/>
     </disk>
   </devices>
 </domain>
index 550136db1858978961c98e90c45e015c152c24a9..097d3dd8563adb65b3b003186677132d7b60f989 100644 (file)
     <disk type='block' device='disk'>
       <source dev='/dev/HostVG/QEMUGuest1'/>
       <target dev='hda' bus='ide'/>
+      <address type='drive' controller='0' bus='0' unit='0'/>
     </disk>
     <disk type='file' device='cdrom'>
       <source file='/root/boot.iso'/>
       <target dev='hdc' bus='ide'/>
       <readonly/>
+      <address type='drive' controller='0' bus='1' unit='0'/>
     </disk>
   </devices>
 </domain>
index fdbf2b8039427942ef9577094786e316ef650251..743e996483083b06c2bf3b2a4f2b787b9877eb47 100644 (file)
     <disk type='block' device='disk'>
       <source dev='/dev/HostVG/QEMUGuest1'/>
       <target dev='hda' bus='ide'/>
+      <address type='drive' controller='0' bus='0' unit='0'/>
     </disk>
     <disk type='block' device='cdrom'>
       <source dev='/dev/HostVG/QEMUGuest2'/>
       <target dev='hdc' bus='ide'/>
+      <address type='drive' controller='0' bus='1' unit='0'/>
     </disk>
   </devices>
 </domain>
index b8ff06a7b0e022d2102698c64fa08dddb1da3a2d..c1d3f4a75e83f1c36683dbe542bb4d96a355cfd0 100644 (file)
     <disk type='block' device='disk'>
       <source dev='/dev/HostVG/QEMUGuest1'/>
       <target dev='hda' bus='ide'/>
+      <address type='drive' controller='0' bus='0' unit='0'/>
     </disk>
     <disk type='block' device='cdrom'>
       <source dev='/dev/HostVG/QEMUGuest2'/>
       <target dev='hdc' bus='ide'/>
+      <address type='drive' controller='0' bus='1' unit='0'/>
     </disk>
   </devices>
 </domain>
index 4603ce5fcd02ca15741ce2c469e45fb725715ff7..706b6e25f9cb43553837b7f3e27d22394a185879 100644 (file)
       <driver name='qemu' type='qcow2' cache='none'/>
       <source dev='/dev/HostVG/QEMUGuest1'/>
       <target dev='hda' bus='ide'/>
+      <address type='drive' controller='0' bus='0' unit='0'/>
     </disk>
     <disk type='block' device='cdrom'>
       <driver name='qemu' type='raw'/>
       <source dev='/dev/HostVG/QEMUGuest2'/>
       <target dev='hdc' bus='ide'/>
       <readonly/>
+      <address type='drive' controller='0' bus='1' unit='0'/>
     </disk>
   </devices>
 </domain>
index 97fc09ef820aac96988d3a395108e1ea871800f5..4d3fb0c49f74b640ee91252ddb3e2334d818ef05 100644 (file)
       <driver name='qemu' type='qcow2' cache='writeback'/>
       <source dev='/dev/HostVG/QEMUGuest1'/>
       <target dev='hda' bus='ide'/>
+      <address type='drive' controller='0' bus='0' unit='0'/>
     </disk>
     <disk type='block' device='cdrom'>
       <driver name='qemu' type='raw'/>
       <source dev='/dev/HostVG/QEMUGuest2'/>
       <target dev='hdc' bus='ide'/>
       <readonly/>
+      <address type='drive' controller='0' bus='1' unit='0'/>
     </disk>
   </devices>
 </domain>
index d26005f883b5bf31827026bb994c3f4e3eb221b7..b81f1a4dd02996ead29a8bb7242ab36c2995683e 100644 (file)
       <driver name='qemu' type='qcow2' cache='writethrough'/>
       <source dev='/dev/HostVG/QEMUGuest1'/>
       <target dev='hda' bus='ide'/>
+      <address type='drive' controller='0' bus='0' unit='0'/>
     </disk>
     <disk type='block' device='cdrom'>
       <driver name='qemu' type='raw'/>
       <source dev='/dev/HostVG/QEMUGuest2'/>
       <target dev='hdc' bus='ide'/>
       <readonly/>
+      <address type='drive' controller='0' bus='1' unit='0'/>
     </disk>
   </devices>
 </domain>
index 4603ce5fcd02ca15741ce2c469e45fb725715ff7..706b6e25f9cb43553837b7f3e27d22394a185879 100644 (file)
       <driver name='qemu' type='qcow2' cache='none'/>
       <source dev='/dev/HostVG/QEMUGuest1'/>
       <target dev='hda' bus='ide'/>
+      <address type='drive' controller='0' bus='0' unit='0'/>
     </disk>
     <disk type='block' device='cdrom'>
       <driver name='qemu' type='raw'/>
       <source dev='/dev/HostVG/QEMUGuest2'/>
       <target dev='hdc' bus='ide'/>
       <readonly/>
+      <address type='drive' controller='0' bus='1' unit='0'/>
     </disk>
   </devices>
 </domain>
index 97fc09ef820aac96988d3a395108e1ea871800f5..4d3fb0c49f74b640ee91252ddb3e2334d818ef05 100644 (file)
       <driver name='qemu' type='qcow2' cache='writeback'/>
       <source dev='/dev/HostVG/QEMUGuest1'/>
       <target dev='hda' bus='ide'/>
+      <address type='drive' controller='0' bus='0' unit='0'/>
     </disk>
     <disk type='block' device='cdrom'>
       <driver name='qemu' type='raw'/>
       <source dev='/dev/HostVG/QEMUGuest2'/>
       <target dev='hdc' bus='ide'/>
       <readonly/>
+      <address type='drive' controller='0' bus='1' unit='0'/>
     </disk>
   </devices>
 </domain>
index d26005f883b5bf31827026bb994c3f4e3eb221b7..b81f1a4dd02996ead29a8bb7242ab36c2995683e 100644 (file)
       <driver name='qemu' type='qcow2' cache='writethrough'/>
       <source dev='/dev/HostVG/QEMUGuest1'/>
       <target dev='hda' bus='ide'/>
+      <address type='drive' controller='0' bus='0' unit='0'/>
     </disk>
     <disk type='block' device='cdrom'>
       <driver name='qemu' type='raw'/>
       <source dev='/dev/HostVG/QEMUGuest2'/>
       <target dev='hdc' bus='ide'/>
       <readonly/>
+      <address type='drive' controller='0' bus='1' unit='0'/>
     </disk>
   </devices>
 </domain>
index 818ca93bf8346f90f2cc7bb71ca049fad0da7a4f..0a13d191c18e814a16eb18188a4a684765168041 100644 (file)
@@ -19,6 +19,7 @@
       <source dir='/var/somefiles'/>
       <target dev='hda' bus='ide'/>
       <readonly/>
+      <address type='drive' controller='0' bus='0' unit='0'/>
     </disk>
   </devices>
 </domain>
index 2537da61047df874e646ac4104944f74ba44cdb1..5c1d4563ad6970bd913f54c073ede1d9e2d197ce 100644 (file)
       <driver name='qemu' type='qcow2'/>
       <source dev='/dev/HostVG/QEMUGuest1'/>
       <target dev='hda' bus='ide'/>
+      <address type='drive' controller='0' bus='0' unit='0'/>
     </disk>
     <disk type='block' device='cdrom'>
       <driver name='qemu' type='raw'/>
       <source dev='/dev/HostVG/QEMUGuest2'/>
       <target dev='hdc' bus='ide'/>
       <readonly/>
+      <address type='drive' controller='0' bus='1' unit='0'/>
     </disk>
   </devices>
 </domain>
index c4e47348eda5e7f24ba16d87100df9ee90f3fb93..774decd3d0722d29dd2f6de48070223e3cb8ff73 100644 (file)
       <target dev='hda' bus='ide'/>
       <shareable/>
       <serial>XYZXYZXYZYXXYZYZYXYZY</serial>
+      <address type='drive' controller='0' bus='0' unit='0'/>
     </disk>
     <disk type='block' device='cdrom'>
       <driver name='qemu' type='raw'/>
       <source dev='/dev/HostVG/QEMUGuest2'/>
       <target dev='hdc' bus='ide'/>
       <readonly/>
+      <address type='drive' controller='0' bus='1' unit='0'/>
     </disk>
   </devices>
 </domain>
index 9debdf4fcf8659f2e22068829bbf0aa3166394c9..37d178d38bb5662a6324bf22ab07220037ca922c 100644 (file)
     <disk type='block' device='disk'>
       <source dev='/dev/HostVG/QEMUGuest1'/>
       <target dev='hda' bus='ide'/>
+      <address type='drive' controller='0' bus='0' unit='0'/>
     </disk>
     <disk type='block' device='floppy'>
       <source dev='/dev/fd0'/>
       <target dev='fda' bus='fdc'/>
+      <address type='drive' controller='0' bus='0' unit='0'/>
     </disk>
     <disk type='file' device='floppy'>
       <source file='/tmp/firmware.img'/>
       <target dev='fdb' bus='fdc'/>
+      <address type='drive' controller='0' bus='0' unit='1'/>
     </disk>
   </devices>
 </domain>
index 4abe88348bb5d647fb96a6526eeb31ad7d1be140..6f9b70510ed6d5650b6a8e3271d02ab132ce2d49 100644 (file)
     <disk type='block' device='disk'>
       <source dev='/dev/HostVG/QEMUGuest1'/>
       <target dev='hda' bus='ide'/>
+      <address type='drive' controller='0' bus='0' unit='0'/>
     </disk>
     <disk type='block' device='disk'>
       <source dev='/dev/HostVG/QEMUGuest2'/>
       <target dev='hdb' bus='ide'/>
+      <address type='drive' controller='0' bus='0' unit='1'/>
     </disk>
     <disk type='file' device='disk'>
       <source file='/tmp/data.img'/>
       <target dev='hdc' bus='ide'/>
+      <address type='drive' controller='0' bus='1' unit='0'/>
     </disk>
     <disk type='file' device='disk'>
       <source file='/tmp/logs.img'/>
       <target dev='hdd' bus='ide'/>
+      <address type='drive' controller='0' bus='1' unit='1'/>
     </disk>
   </devices>
 </domain>
index d59e1c0a27d0d786997d5219c47a5ea3c9ae033f..3b86a114fc3fb209c8d3733508dafb1dff91473c 100644 (file)
@@ -17,6 +17,7 @@
     <disk type='block' device='disk'>
       <source dev='/dev/HostVG/QEMUGuest1'/>
       <target dev='hda' bus='ide'/>
+      <address type='drive' controller='0' bus='0' unit='0'/>
     </disk>
     <disk type='file' device='disk'>
       <source file='/tmp/usbdisk.img'/>
index bda44552a7001fbd52d0ea4c0d7087ac4f11ef67..e506d9f11a03c15c1d6c68c70ab3e581d719cea6 100644 (file)
     <disk type='block' device='disk'>
       <source dev='/dev/HostVG/QEMUGuest1'/>
       <target dev='hda' bus='ide'/>
+      <address type='drive' controller='0' bus='0' unit='0'/>
     </disk>
     <disk type='block' device='cdrom'>
       <source dev='/dev/HostVG/QEMUGuest2'/>
       <target dev='hdc' bus='ide'/>
+      <readonly/>
+      <address type='drive' controller='0' bus='1' unit='0'/>
     </disk>
     <disk type='file' device='disk'>
       <source file='/tmp/data.img'/>
index c42404a5cf1a0c81171b0b30dc7fabbb4074b5ea..17cc4080967be4aad6adaa96097e955aca2f5761 100644 (file)
     <disk type='block' device='disk'>
       <source dev='/dev/HostVG/QEMUGuest1'/>
       <target dev='hda' bus='ide'/>
+      <address type='drive' controller='0' bus='0' unit='0'/>
     </disk>
     <disk type='block' device='cdrom'>
       <source dev='/dev/HostVG/QEMUGuest2'/>
       <target dev='hdc' bus='ide'/>
       <readonly/>
+      <address type='drive' controller='0' bus='1' unit='0'/>
     </disk>
     <disk type='file' device='disk'>
       <source file='/tmp/data.img'/>
index 9e32b68a5754269273ffd1d9c431f96a4c27e10c..7bc09fa836dcf1c0d180215da0bb025c93f8ac23 100644 (file)
@@ -19,6 +19,7 @@
       <source dir='/var/somefiles'/>
       <target dev='fda' bus='fdc'/>
       <readonly/>
+      <address type='drive' controller='0' bus='0' unit='0'/>
     </disk>
   </devices>
 </domain>
index f3fc5889e2a03fdbb0468f18405823a5de1e9c2e..8508be593d86e92c1ca6b37df2809d87b094bfcb 100644 (file)
@@ -17,6 +17,7 @@
     <disk type='block' device='disk'>
       <source dev='/dev/HostVG/QEMUGuest1'/>
       <target dev='hda' bus='ide'/>
+      <address type='drive' controller='0' bus='0' unit='0'/>
     </disk>
     <input type='mouse' bus='ps2'/>
     <graphics type='sdl' display=':0.1' xauth='/root/.Xauthority' fullscreen='yes'/>
index 431c3c98b2c2da8b951fb48ad6244fba71660443..c83587b6d3b4874c585f90c3a7d3e2b9580620c3 100644 (file)
@@ -17,6 +17,7 @@
     <disk type='block' device='disk'>
       <source dev='/dev/HostVG/QEMUGuest1'/>
       <target dev='hda' bus='ide'/>
+      <address type='drive' controller='0' bus='0' unit='0'/>
     </disk>
     <input type='mouse' bus='ps2'/>
     <graphics type='sdl' display=':0.1' xauth='/root/.Xauthority'/>
index b6f99d327bfa7b592ba2f3f29f1c50cbd64e945e..15b561f29c21928a121a567401ccac6357f5d5a4 100644 (file)
@@ -17,6 +17,7 @@
     <disk type='block' device='disk'>
       <source dev='/dev/HostVG/QEMUGuest1'/>
       <target dev='hda' bus='ide'/>
+      <address type='drive' controller='0' bus='0' unit='0'/>
     </disk>
     <input type='mouse' bus='ps2'/>
     <graphics type='vnc' port='5903' autoport='no' listen='127.0.0.1'/>
index b6f99d327bfa7b592ba2f3f29f1c50cbd64e945e..15b561f29c21928a121a567401ccac6357f5d5a4 100644 (file)
@@ -17,6 +17,7 @@
     <disk type='block' device='disk'>
       <source dev='/dev/HostVG/QEMUGuest1'/>
       <target dev='hda' bus='ide'/>
+      <address type='drive' controller='0' bus='0' unit='0'/>
     </disk>
     <input type='mouse' bus='ps2'/>
     <graphics type='vnc' port='5903' autoport='no' listen='127.0.0.1'/>
index b6f99d327bfa7b592ba2f3f29f1c50cbd64e945e..15b561f29c21928a121a567401ccac6357f5d5a4 100644 (file)
@@ -17,6 +17,7 @@
     <disk type='block' device='disk'>
       <source dev='/dev/HostVG/QEMUGuest1'/>
       <target dev='hda' bus='ide'/>
+      <address type='drive' controller='0' bus='0' unit='0'/>
     </disk>
     <input type='mouse' bus='ps2'/>
     <graphics type='vnc' port='5903' autoport='no' listen='127.0.0.1'/>
index ac5ad47ecaa10cd59158840d7b2f353367913aa0..7c7e5486269323924f67667d865b8a07b99fd006 100644 (file)
@@ -17,6 +17,7 @@
     <disk type='block' device='disk'>
       <source dev='/dev/HostVG/QEMUGuest2'/>
       <target dev='hda' bus='ide'/>
+      <address type='drive' controller='0' bus='0' unit='0'/>
     </disk>
     <hostdev mode='subsystem' type='pci' managed='yes'>
       <source>
index 61bb2a2b2a137403bcb4fe9c18d51b4ea2a0d1a1..08d78e6f8ca93fccf54bb1259bdb413dab791459 100644 (file)
@@ -17,6 +17,7 @@
     <disk type='block' device='disk'>
       <source dev='/dev/HostVG/QEMUGuest1'/>
       <target dev='hda' bus='ide'/>
+      <address type='drive' controller='0' bus='0' unit='0'/>
     </disk>
     <hostdev mode='subsystem' type='usb' managed='no'>
       <source>
index 6cb1ba18ff5010852d21beb662e690897d1a65e5..85a822b0a325504f3f24e3211ae57916949b832a 100644 (file)
@@ -17,6 +17,7 @@
     <disk type='block' device='disk'>
       <source dev='/dev/HostVG/QEMUGuest1'/>
       <target dev='hda' bus='ide'/>
+      <address type='drive' controller='0' bus='0' unit='0'/>
     </disk>
     <hostdev mode='subsystem' type='usb' managed='no'>
       <source>
index e25286feee2d6e9e42edeab3906cc345f211d738..92f2c47e2e544b0ac0eb4028e05c861c17f9559b 100644 (file)
@@ -20,6 +20,7 @@
     <disk type='block' device='disk'>
       <source dev='/dev/HostVG/QEMUGuest1'/>
       <target dev='hda' bus='ide'/>
+      <address type='drive' controller='0' bus='0' unit='0'/>
     </disk>
   </devices>
 </domain>
index 573015b4b84dedc2ca5fec5e2dbf0ce1817f43e4..d036eb4d60b53ebf7af90878f412e47dad2a240b 100644 (file)
@@ -17,6 +17,7 @@
     <disk type='block' device='disk'>
       <source dev='/dev/HostVG/QEMUGuest1'/>
       <target dev='hda' bus='ide'/>
+      <address type='drive' controller='0' bus='0' unit='0'/>
     </disk>
     <input type='mouse' bus='usb'/>
   </devices>
index ea5769ad9584d56f280557e1cbabc609ea48cf3c..82fd363ac7be5e6b848e3d79d6389429f326ca56 100644 (file)
@@ -17,6 +17,7 @@
     <disk type='block' device='disk'>
       <source dev='/dev/HostVG/QEMUGuest1'/>
       <target dev='hda' bus='ide'/>
+      <address type='drive' controller='0' bus='0' unit='0'/>
     </disk>
     <input type='tablet' bus='usb'/>
   </devices>
index fea7f8edd206719228a7eacc45bd0e4a84beb21b..9976a56ed2aae27ef8c010504e304ac9b0bd1688 100644 (file)
@@ -17,6 +17,7 @@
     <disk type='block' device='disk'>
       <source dev='/dev/HostVG/QEMUGuest1'/>
       <target dev='hda' bus='ide'/>
+      <address type='drive' controller='0' bus='0' unit='0'/>
     </disk>
     <input type='mouse' bus='xen'/>
     <graphics type='vnc' port='5903' autoport='no' listen='127.0.0.1'/>
index 039abfd6d3667befeba9637556c75cae0c686b05..eca3a6ffeafad9e21097be7dda66495424f9f0b7 100644 (file)
@@ -17,6 +17,7 @@
     <disk type='block' device='disk'>
       <source dev='/dev/HostVG/QEMUGuest1'/>
       <target dev='hda' bus='ide'/>
+      <address type='drive' controller='0' bus='0' unit='0'/>
     </disk>
   </devices>
 </domain>
index a2c62541512ea310921ab755daa35e1018af7a54..b50e409d3724fad7183d566c8ddd5b76262fc58e 100644 (file)
@@ -17,6 +17,7 @@
     <disk type='block' device='disk'>
       <source dev='/dev/HostVG/QEMUGuest1'/>
       <target dev='hda' bus='ide'/>
+      <address type='drive' controller='0' bus='0' unit='0'/>
     </disk>
   </devices>
 </domain>
index 26c9b259431d75a0720cc8b2f1b2e3056ac72965..9e9153f4658049851b4747c6eee4b5e10b944793 100644 (file)
@@ -17,6 +17,7 @@
     <disk type='block' device='disk'>
       <source dev='/dev/HostVG/QEMUGuest1'/>
       <target dev='hda' bus='ide'/>
+      <address type='drive' controller='0' bus='0' unit='0'/>
     </disk>
   </devices>
 </domain>
index 566a4ad982de66f0cb9382581f2e51dc5ddbb9f5..78b578b277f4bd9c0c7662b1bebafced65f18fd2 100644 (file)
@@ -17,6 +17,7 @@
     <disk type='block' device='disk'>
       <source dev='/dev/HostVG/QEMUGuest1'/>
       <target dev='hda' bus='ide'/>
+      <address type='drive' controller='0' bus='0' unit='0'/>
     </disk>
   </devices>
 </domain>
index 1b37bdc6f21614e3de543280e89163d023caf633..fe0a00e3d9b143a34e7e08ca3fbab322cdd1704b 100644 (file)
@@ -20,6 +20,7 @@
     <disk type='block' device='disk'>
       <source dev='/dev/HostVG/QEMUGuest1'/>
       <target dev='hda' bus='ide'/>
+      <address type='drive' controller='0' bus='0' unit='0'/>
     </disk>
   </devices>
 </domain>
index dc6193dd8e322013a8203a26d767c34793c97260..2c5307899477f2741defe677c2dde67f9390e82a 100644 (file)
@@ -17,6 +17,7 @@
     <disk type='block' device='disk'>
       <source dev='/dev/HostVG/QEMUGuest1'/>
       <target dev='hda' bus='ide'/>
+      <address type='drive' controller='0' bus='0' unit='0'/>
     </disk>
   </devices>
 </domain>
index 1b37bdc6f21614e3de543280e89163d023caf633..fe0a00e3d9b143a34e7e08ca3fbab322cdd1704b 100644 (file)
@@ -20,6 +20,7 @@
     <disk type='block' device='disk'>
       <source dev='/dev/HostVG/QEMUGuest1'/>
       <target dev='hda' bus='ide'/>
+      <address type='drive' controller='0' bus='0' unit='0'/>
     </disk>
   </devices>
 </domain>
index 9ca429586645eb5a0edac861ad2ce9f339bd532e..08aaa358fe9673ea46b13e1affbe7bc22795c5c2 100644 (file)
@@ -17,6 +17,7 @@
     <disk type='block' device='disk'>
       <source dev='/dev/HostVG/QEMUGuest1'/>
       <target dev='hda' bus='ide'/>
+      <address type='drive' controller='0' bus='0' unit='0'/>
     </disk>
     <interface type='ethernet'>
       <mac address='00:11:22:33:44:55'/>
index 8aae26996c0e65745e2c908bdff44f8327d6f02c..c52d55bbdbcbc8c0893967f7eb1b3a86b657dad6 100644 (file)
@@ -17,6 +17,7 @@
     <disk type='block' device='disk'>
       <source dev='/dev/HostVG/QEMUGuest1'/>
       <target dev='hda' bus='ide'/>
+      <address type='drive' controller='0' bus='0' unit='0'/>
     </disk>
     <interface type='ethernet'>
       <mac address='00:11:22:33:44:55'/>
index 5856c3d52a5515f6862e5d9185db788b20557315..9aba26eefca7ddca9506d8d63c99fd336ff9fbd7 100644 (file)
@@ -17,6 +17,7 @@
     <disk type='block' device='disk'>
       <source dev='/dev/HostVG/QEMUGuest1'/>
       <target dev='hda' bus='ide'/>
+      <address type='drive' controller='0' bus='0' unit='0'/>
     </disk>
     <interface type='ethernet'>
       <mac address='00:11:22:33:44:55'/>
index 630673a7681341d6ea97db3b0f98c9c92952e217..3abda1c31fa7afb3b22689ff382f617f67bc1d14 100644 (file)
@@ -17,6 +17,7 @@
     <disk type='block' device='disk'>
       <source dev='/dev/HostVG/QEMUGuest1'/>
       <target dev='hda' bus='ide'/>
+      <address type='drive' controller='0' bus='0' unit='0'/>
     </disk>
     <interface type='user'>
       <mac address='00:11:22:33:44:55'/>
index 5d34bd492c73df8625a6f15fb728c5702fbd6dfe..4eac6866cbb79ff6f671c84c187f62d37d60fbca 100644 (file)
@@ -17,6 +17,7 @@
     <disk type='block' device='disk'>
       <source dev='/dev/HostVG/QEMUGuest1'/>
       <target dev='hda' bus='ide'/>
+      <address type='drive' controller='0' bus='0' unit='0'/>
     </disk>
     <interface type='user'>
       <mac address='00:11:22:33:44:55'/>
index 08176f1c6536b30f17c38d9538d2dc3c1484e266..ab675b6d14a6b9481da0bcb359ccd8051484155b 100644 (file)
@@ -17,6 +17,7 @@
     <disk type='block' device='disk'>
       <source dev='/dev/HostVG/QEMUGuest1'/>
       <target dev='hda' bus='ide'/>
+      <address type='drive' controller='0' bus='0' unit='0'/>
     </disk>
     <parallel type='tcp'>
       <source mode='bind' host='127.0.0.1' service='9999'/>
index 08176f1c6536b30f17c38d9538d2dc3c1484e266..ab675b6d14a6b9481da0bcb359ccd8051484155b 100644 (file)
@@ -17,6 +17,7 @@
     <disk type='block' device='disk'>
       <source dev='/dev/HostVG/QEMUGuest1'/>
       <target dev='hda' bus='ide'/>
+      <address type='drive' controller='0' bus='0' unit='0'/>
     </disk>
     <parallel type='tcp'>
       <source mode='bind' host='127.0.0.1' service='9999'/>
index 26c9b259431d75a0720cc8b2f1b2e3056ac72965..9e9153f4658049851b4747c6eee4b5e10b944793 100644 (file)
@@ -17,6 +17,7 @@
     <disk type='block' device='disk'>
       <source dev='/dev/HostVG/QEMUGuest1'/>
       <target dev='hda' bus='ide'/>
+      <address type='drive' controller='0' bus='0' unit='0'/>
     </disk>
   </devices>
 </domain>
index 26c9b259431d75a0720cc8b2f1b2e3056ac72965..9e9153f4658049851b4747c6eee4b5e10b944793 100644 (file)
@@ -17,6 +17,7 @@
     <disk type='block' device='disk'>
       <source dev='/dev/HostVG/QEMUGuest1'/>
       <target dev='hda' bus='ide'/>
+      <address type='drive' controller='0' bus='0' unit='0'/>
     </disk>
   </devices>
 </domain>
index 2b8ef5afb1cea16087f16f3ee21e1a8e90f95658..06c40e8c6dab1524aabbf6aebc1b10fbb3d6e35a 100644 (file)
@@ -17,6 +17,7 @@
     <disk type='block' device='disk'>
       <source dev='/dev/HostVG/QEMUGuest1'/>
       <target dev='hda' bus='ide'/>
+      <address type='drive' controller='0' bus='0' unit='0'/>
     </disk>
     <serial type='dev'>
       <source path='/dev/ttyS2'/>
index 2b8ef5afb1cea16087f16f3ee21e1a8e90f95658..06c40e8c6dab1524aabbf6aebc1b10fbb3d6e35a 100644 (file)
@@ -17,6 +17,7 @@
     <disk type='block' device='disk'>
       <source dev='/dev/HostVG/QEMUGuest1'/>
       <target dev='hda' bus='ide'/>
+      <address type='drive' controller='0' bus='0' unit='0'/>
     </disk>
     <serial type='dev'>
       <source path='/dev/ttyS2'/>
index 3726816bde59f44e915322faeb8a8557f49d0078..7c2cc030627dde8743e7371db660255205d612a2 100644 (file)
@@ -17,6 +17,7 @@
     <disk type='block' device='disk'>
       <source dev='/dev/HostVG/QEMUGuest1'/>
       <target dev='hda' bus='ide'/>
+      <address type='drive' controller='0' bus='0' unit='0'/>
     </disk>
     <serial type='file'>
       <source path='/tmp/serial.log'/>
index 3726816bde59f44e915322faeb8a8557f49d0078..7c2cc030627dde8743e7371db660255205d612a2 100644 (file)
@@ -17,6 +17,7 @@
     <disk type='block' device='disk'>
       <source dev='/dev/HostVG/QEMUGuest1'/>
       <target dev='hda' bus='ide'/>
+      <address type='drive' controller='0' bus='0' unit='0'/>
     </disk>
     <serial type='file'>
       <source path='/tmp/serial.log'/>
index 444e85b56dadba8f53128fddf6e79e8444a4cb37..4021129ce54d8acb9e2c413c41f6b20785a24202 100644 (file)
@@ -17,6 +17,7 @@
     <disk type='block' device='disk'>
       <source dev='/dev/HostVG/QEMUGuest1'/>
       <target dev='hda' bus='ide'/>
+      <address type='drive' controller='0' bus='0' unit='0'/>
     </disk>
     <serial type='pty'>
       <target port='0'/>
index 444e85b56dadba8f53128fddf6e79e8444a4cb37..4021129ce54d8acb9e2c413c41f6b20785a24202 100644 (file)
@@ -17,6 +17,7 @@
     <disk type='block' device='disk'>
       <source dev='/dev/HostVG/QEMUGuest1'/>
       <target dev='hda' bus='ide'/>
+      <address type='drive' controller='0' bus='0' unit='0'/>
     </disk>
     <serial type='pty'>
       <target port='0'/>
index c16ae07f3af50aeb7dd766f889a748554901bff8..1f8f1267b94b0376a189bb726bd5c17bdc408b8e 100644 (file)
@@ -17,6 +17,7 @@
     <disk type='block' device='disk'>
       <source dev='/dev/HostVG/QEMUGuest1'/>
       <target dev='hda' bus='ide'/>
+      <address type='drive' controller='0' bus='0' unit='0'/>
     </disk>
     <serial type='pty'>
       <target port='0'/>
index c16ae07f3af50aeb7dd766f889a748554901bff8..1f8f1267b94b0376a189bb726bd5c17bdc408b8e 100644 (file)
@@ -17,6 +17,7 @@
     <disk type='block' device='disk'>
       <source dev='/dev/HostVG/QEMUGuest1'/>
       <target dev='hda' bus='ide'/>
+      <address type='drive' controller='0' bus='0' unit='0'/>
     </disk>
     <serial type='pty'>
       <target port='0'/>
index 3bcf62da9a94c525a1a01211c5c91b538f712e34..5d14515eda2f0c5499b24909bfaadf15e0931d42 100644 (file)
@@ -17,6 +17,7 @@
     <disk type='block' device='disk'>
       <source dev='/dev/HostVG/QEMUGuest1'/>
       <target dev='hda' bus='ide'/>
+      <address type='drive' controller='0' bus='0' unit='0'/>
     </disk>
     <serial type='tcp'>
       <source mode='connect' host='127.0.0.1' service='9999'/>
index bea4306edcd5dabc4c1036609d05309b6f6f46fa..1f940db9859b6bb0c600a31b2764bf15b4f135ca 100644 (file)
@@ -17,6 +17,7 @@
     <disk type='block' device='disk'>
       <source dev='/dev/HostVG/QEMUGuest1'/>
       <target dev='hda' bus='ide'/>
+      <address type='drive' controller='0' bus='0' unit='0'/>
     </disk>
     <serial type='tcp'>
       <source mode='bind' host='127.0.0.1' service='9999'/>
index bea4306edcd5dabc4c1036609d05309b6f6f46fa..1f940db9859b6bb0c600a31b2764bf15b4f135ca 100644 (file)
@@ -17,6 +17,7 @@
     <disk type='block' device='disk'>
       <source dev='/dev/HostVG/QEMUGuest1'/>
       <target dev='hda' bus='ide'/>
+      <address type='drive' controller='0' bus='0' unit='0'/>
     </disk>
     <serial type='tcp'>
       <source mode='bind' host='127.0.0.1' service='9999'/>
index 3bcf62da9a94c525a1a01211c5c91b538f712e34..5d14515eda2f0c5499b24909bfaadf15e0931d42 100644 (file)
@@ -17,6 +17,7 @@
     <disk type='block' device='disk'>
       <source dev='/dev/HostVG/QEMUGuest1'/>
       <target dev='hda' bus='ide'/>
+      <address type='drive' controller='0' bus='0' unit='0'/>
     </disk>
     <serial type='tcp'>
       <source mode='connect' host='127.0.0.1' service='9999'/>
index 115166d4c8c14b68e3134f038c194d099da29793..addf09372b3718520aee6d7f367f29f1729c2fd8 100644 (file)
@@ -17,6 +17,7 @@
     <disk type='block' device='disk'>
       <source dev='/dev/HostVG/QEMUGuest1'/>
       <target dev='hda' bus='ide'/>
+      <address type='drive' controller='0' bus='0' unit='0'/>
     </disk>
     <serial type='udp'>
       <source mode='bind' host='127.0.0.1' service='9999'/>
index 115166d4c8c14b68e3134f038c194d099da29793..addf09372b3718520aee6d7f367f29f1729c2fd8 100644 (file)
@@ -17,6 +17,7 @@
     <disk type='block' device='disk'>
       <source dev='/dev/HostVG/QEMUGuest1'/>
       <target dev='hda' bus='ide'/>
+      <address type='drive' controller='0' bus='0' unit='0'/>
     </disk>
     <serial type='udp'>
       <source mode='bind' host='127.0.0.1' service='9999'/>
index 4236b4c9ed345b6eb2c1f03a0a6d40c2742f2bbe..81884a1225032839bbcb0c39d73d5f97b66a2baf 100644 (file)
@@ -17,6 +17,7 @@
     <disk type='block' device='disk'>
       <source dev='/dev/HostVG/QEMUGuest1'/>
       <target dev='hda' bus='ide'/>
+      <address type='drive' controller='0' bus='0' unit='0'/>
     </disk>
     <serial type='unix'>
       <source mode='connect' path='/tmp/serial.sock'/>
index 4236b4c9ed345b6eb2c1f03a0a6d40c2742f2bbe..81884a1225032839bbcb0c39d73d5f97b66a2baf 100644 (file)
@@ -17,6 +17,7 @@
     <disk type='block' device='disk'>
       <source dev='/dev/HostVG/QEMUGuest1'/>
       <target dev='hda' bus='ide'/>
+      <address type='drive' controller='0' bus='0' unit='0'/>
     </disk>
     <serial type='unix'>
       <source mode='connect' path='/tmp/serial.sock'/>
index 1e5de8f125d41742ea53e8fa3647f47c583b0e61..0a1980cfd8c6a50780aa3ea14e70154b775701e3 100644 (file)
@@ -17,6 +17,7 @@
     <disk type='block' device='disk'>
       <source dev='/dev/HostVG/QEMUGuest1'/>
       <target dev='hda' bus='ide'/>
+      <address type='drive' controller='0' bus='0' unit='0'/>
     </disk>
     <serial type='vc'>
       <target port='0'/>
index 1e5de8f125d41742ea53e8fa3647f47c583b0e61..0a1980cfd8c6a50780aa3ea14e70154b775701e3 100644 (file)
@@ -17,6 +17,7 @@
     <disk type='block' device='disk'>
       <source dev='/dev/HostVG/QEMUGuest1'/>
       <target dev='hda' bus='ide'/>
+      <address type='drive' controller='0' bus='0' unit='0'/>
     </disk>
     <serial type='vc'>
       <target port='0'/>
index 8c33e6c90af1298fa7687d2af592684c669a1071..3327c19acf1ffc35a91df75c8f4643f96ddf1ee9 100644 (file)
@@ -17,6 +17,7 @@
     <disk type='block' device='disk'>
       <source dev='/dev/HostVG/QEMUGuest1'/>
       <target dev='hda' bus='ide'/>
+      <address type='drive' controller='0' bus='0' unit='0'/>
     </disk>
     <sound model='pcspk'/>
     <sound model='es1370'/>
index 9b2ffdf8b246d03ced025011f2cfb4037c582bde..52ff1177c0563bfafadfbdf907cdd9444f1e5027 100644 (file)
@@ -17,6 +17,7 @@
     <disk type='block' device='disk'>
       <source dev='/dev/HostVG/QEMUGuest1'/>
       <target dev='hda' bus='ide'/>
+      <address type='drive' controller='0' bus='0' unit='0'/>
     </disk>
     <watchdog model='ib700' action='poweroff'/>
   </devices>
index e5900a2c7473155552e597a63beb4de3f6dd4029..03026960dc7a323892803373c75c7a9a90a335c0 100644 (file)
@@ -98,6 +98,7 @@ mymain(int argc, char **argv)
     DO_TEST("disk-many");
     DO_TEST("disk-xenvbd");
     DO_TEST("disk-usb");
+    DO_TEST("disk-virtio");
     DO_TEST("floppy-drive-fat");
     DO_TEST("disk-drive-fat");
     DO_TEST("disk-drive-fmt-qcow");