render / rpms / qemu

Forked from rpms/qemu 9 months ago
Clone

Blame 0046-pc-Add-backward-compatibility-options-for-virtio-ser.patch

Justin M. Forbes eff942
From f32e21e2828cf7a8aba2fb27945dc46ca2debe09 Mon Sep 17 00:00:00 2001
Justin M. Forbes eff942
From: Amit Shah <amit.shah@redhat.com>
Justin M. Forbes eff942
Date: Thu, 25 Feb 2010 18:41:14 +0530
Justin M. Forbes eff942
Subject: [PATCH] pc: Add backward compatibility options for virtio-serial
Justin M. Forbes eff942
Justin M. Forbes eff942
virtio-serial-pci can support multiple ports in the current F-13
Justin M. Forbes eff942
version that will become upstream version 0.13. Add compatibility options
Justin M. Forbes eff942
for the 0.12, 0.11 and 0.10 pc machine types.
Justin M. Forbes eff942
Justin M. Forbes eff942
Based on upstream commit 8bfbde6d35c82cc376681289dae2de5e18a087a4
Justin M. Forbes eff942
Justin M. Forbes eff942
Signed-off-by: Amit Shah <amit.shah@redhat.com>
Justin M. Forbes eff942
---
Justin M. Forbes eff942
 hw/pc.c |   28 ++++++++++++++++++++++++++++
Justin M. Forbes eff942
 1 files changed, 28 insertions(+), 0 deletions(-)
Justin M. Forbes eff942
Justin M. Forbes eff942
diff --git a/hw/pc.c b/hw/pc.c
Justin M. Forbes eff942
index 26c65c1..90bbfe8 100644
Justin M. Forbes eff942
--- a/hw/pc.c
Justin M. Forbes eff942
+++ b/hw/pc.c
Justin M. Forbes eff942
@@ -1330,6 +1330,18 @@ static QEMUMachine pc_machine = {
Justin M. Forbes eff942
     .desc = "Standard PC",
Justin M. Forbes eff942
     .init = pc_init_pci,
Justin M. Forbes eff942
     .max_cpus = 255,
Justin M. Forbes eff942
+    .compat_props = (GlobalProperty[]) {
Justin M. Forbes eff942
+        {
Justin M. Forbes eff942
+            .driver   = "virtio-serial-pci",
Justin M. Forbes eff942
+            .property = "max_nr_ports",
Justin M. Forbes eff942
+            .value    = stringify(1),
Justin M. Forbes eff942
+        },{
Justin M. Forbes eff942
+            .driver   = "virtio-serial-pci",
Justin M. Forbes eff942
+            .property = "vectors",
Justin M. Forbes eff942
+            .value    = stringify(0),
Justin M. Forbes eff942
+        },
Justin M. Forbes eff942
+        { /* end of list */ }
Justin M. Forbes eff942
+    }
Justin M. Forbes eff942
 };
Justin M. Forbes eff942
Justin M. Forbes eff942
 static QEMUMachine pc_machine_v0_11 = {
Justin M. Forbes eff942
@@ -1351,6 +1363,14 @@ static QEMUMachine pc_machine_v0_11 = {
Justin M. Forbes eff942
             .property = "ver",
Justin M. Forbes eff942
             .value    = "0.11",
Justin M. Forbes eff942
         },{
Justin M. Forbes eff942
+            .driver   = "virtio-serial-pci",
Justin M. Forbes eff942
+            .property = "max_nr_ports",
Justin M. Forbes eff942
+            .value    = stringify(1),
Justin M. Forbes eff942
+        },{
Justin M. Forbes eff942
+            .driver   = "virtio-serial-pci",
Justin M. Forbes eff942
+            .property = "vectors",
Justin M. Forbes eff942
+            .value    = stringify(0),
Justin M. Forbes eff942
+        },{
Justin M. Forbes eff942
             .driver   = "PCI",
Justin M. Forbes eff942
             .property = "rombar",
Justin M. Forbes eff942
             .value    = stringify(0),
Justin M. Forbes eff942
@@ -1374,6 +1394,14 @@ static QEMUMachine pc_machine_v0_10 = {
Justin M. Forbes eff942
             .property = "class",
Justin M. Forbes eff942
             .value    = stringify(PCI_CLASS_DISPLAY_OTHER),
Justin M. Forbes eff942
         },{
Justin M. Forbes eff942
+            .driver   = "virtio-serial-pci",
Justin M. Forbes eff942
+            .property = "max_nr_ports",
Justin M. Forbes eff942
+            .value    = stringify(1),
Justin M. Forbes eff942
+        },{
Justin M. Forbes eff942
+            .driver   = "virtio-serial-pci",
Justin M. Forbes eff942
+            .property = "vectors",
Justin M. Forbes eff942
+            .value    = stringify(0),
Justin M. Forbes eff942
+        },{
Justin M. Forbes eff942
             .driver   = "virtio-net-pci",
Justin M. Forbes eff942
             .property = "vectors",
Justin M. Forbes eff942
             .value    = stringify(0),
Justin M. Forbes eff942
-- 
Justin M. Forbes eff942
1.6.6.1
Justin M. Forbes eff942