diff mbox

[v2,11/13] piix: Move pc-0.13 virtio-9p-pci compat to PC_COMPAT_0_13

Message ID 1431629590-25181-12-git-send-email-ehabkost@redhat.com
State New
Headers show

Commit Message

Eduardo Habkost May 14, 2015, 6:53 p.m. UTC
The compat property was added by commit
9dbcca5aa13cb9ab40788ac4c56bc227d94ca920, and the pc-0.12 and older
machine-types were not changed because virtio-9p-pci was introduced on QEMU
0.13 (commit 9f10751365b26b13b8a9b67e0e90536ae3d282df). The only problem is
that this breaks the PC_COMPAT_* nesting pattern we currently use.

So, move the property to PC_COMPAT_0_13. This make pc-0.12 and older inherit
it, but that shouldn't be an issue as QEMU 0.12 didn't have virtio-9p-pci.

Cc: Gerd Hoffmann <kraxel@redhat.com>
Cc: Aneesh Kumar K.V <aneesh.kumar@linux.vnet.ibm.com>
Signed-off-by: Eduardo Habkost <ehabkost@redhat.com>
---
 hw/i386/pc_piix.c | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)

Comments

Gerd Hoffmann May 18, 2015, 7:36 a.m. UTC | #1
On Do, 2015-05-14 at 15:53 -0300, Eduardo Habkost wrote:
> The compat property was added by commit
> 9dbcca5aa13cb9ab40788ac4c56bc227d94ca920, and the pc-0.12 and older
> machine-types were not changed because virtio-9p-pci was introduced on
> QEMU
> 0.13 (commit 9f10751365b26b13b8a9b67e0e90536ae3d282df). The only
> problem is
> that this breaks the PC_COMPAT_* nesting pattern we currently use.
> 
> So, move the property to PC_COMPAT_0_13. This make pc-0.12 and older
> inherit
> it, but that shouldn't be an issue as QEMU 0.12 didn't have
> virtio-9p-pci.

Reviewed-by: Gerd Hoffmann <kraxel@redhat.com>
diff mbox

Patch

diff --git a/hw/i386/pc_piix.c b/hw/i386/pc_piix.c
index eb0c11f..9d12c93 100644
--- a/hw/i386/pc_piix.c
+++ b/hw/i386/pc_piix.c
@@ -838,6 +838,10 @@  static QEMUMachine pc_machine_v0_14 = {
             .driver   = "AC97",\
             .property = "use_broken_id",\
             .value    = stringify(1),\
+        },{\
+            .driver   = "virtio-9p-pci",\
+            .property = "vectors",\
+            .value    = stringify(0),\
         },
 
 #define PC_I440FX_0_13_MACHINE_OPTIONS \
@@ -850,10 +854,6 @@  static QEMUMachine pc_machine_v0_13 = {
     .compat_props = (GlobalProperty[]) {
         PC_COMPAT_0_13
         {
-            .driver   = "virtio-9p-pci",
-            .property = "vectors",
-            .value    = stringify(0),
-        },{
             .driver   = "VGA",
             .property = "rombar",
             .value    = stringify(0),