qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
From: Eduardo Habkost <ehabkost@redhat.com>
To: qemu-devel@nongnu.org
Cc: Alexander Graf <agraf@suse.de>, "Michael S. Tsirkin" <mst@redhat.com>
Subject: [Qemu-devel] [PATCH 03/13] pc: Move commas inside PC_COMPAT_* macros
Date: Mon, 11 May 2015 17:55:46 -0300	[thread overview]
Message-ID: <1431377756-19579-4-git-send-email-ehabkost@redhat.com> (raw)
In-Reply-To: <1431377756-19579-1-git-send-email-ehabkost@redhat.com>

Changing the convention to include commas inside the macros will allow
macros containing empty lists to be defined and used without compilation
errors.

Signed-off-by: Eduardo Habkost <ehabkost@redhat.com>
---
 hw/i386/pc_piix.c    | 62 ++++++++++++++++++++++++++--------------------------
 hw/i386/pc_q35.c     | 10 ++++-----
 include/hw/i386/pc.h | 18 +++++++--------
 3 files changed, 45 insertions(+), 45 deletions(-)

diff --git a/hw/i386/pc_piix.c b/hw/i386/pc_piix.c
index 0536056..cba341b 100644
--- a/hw/i386/pc_piix.c
+++ b/hw/i386/pc_piix.c
@@ -554,7 +554,7 @@ static QEMUMachine pc_i440fx_machine_v2_0 = {
     .name = "pc-i440fx-2.0",
     .init = pc_init_pci_2_0,
     .compat_props = (GlobalProperty[]) {
-        PC_COMPAT_2_0,
+        PC_COMPAT_2_0
         { /* end of list */ }
     },
 };
@@ -566,7 +566,7 @@ static QEMUMachine pc_i440fx_machine_v1_7 = {
     .name = "pc-i440fx-1.7",
     .init = pc_init_pci_1_7,
     .compat_props = (GlobalProperty[]) {
-        PC_COMPAT_1_7,
+        PC_COMPAT_1_7
         { /* end of list */ }
     },
 };
@@ -578,7 +578,7 @@ static QEMUMachine pc_i440fx_machine_v1_6 = {
     .name = "pc-i440fx-1.6",
     .init = pc_init_pci_1_6,
     .compat_props = (GlobalProperty[]) {
-        PC_COMPAT_1_6,
+        PC_COMPAT_1_6
         { /* end of list */ }
     },
 };
@@ -588,7 +588,7 @@ static QEMUMachine pc_i440fx_machine_v1_5 = {
     .name = "pc-i440fx-1.5",
     .init = pc_init_pci_1_5,
     .compat_props = (GlobalProperty[]) {
-        PC_COMPAT_1_5,
+        PC_COMPAT_1_5
         { /* end of list */ }
     },
 };
@@ -602,13 +602,13 @@ static QEMUMachine pc_i440fx_machine_v1_4 = {
     .name = "pc-i440fx-1.4",
     .init = pc_init_pci_1_4,
     .compat_props = (GlobalProperty[]) {
-        PC_COMPAT_1_4,
+        PC_COMPAT_1_4
         { /* end of list */ }
     },
 };
 
 #define PC_COMPAT_1_3 \
-        PC_COMPAT_1_4, \
+        PC_COMPAT_1_4 \
         {\
             .driver   = "usb-tablet",\
             .property = "usb_version",\
@@ -625,20 +625,20 @@ static QEMUMachine pc_i440fx_machine_v1_4 = {
             .driver   = "e1000",\
             .property = "autonegotiation",\
             .value    = "off",\
-        }
+        },
 
 static QEMUMachine pc_machine_v1_3 = {
     PC_I440FX_1_4_MACHINE_OPTIONS,
     .name = "pc-1.3",
     .init = pc_init_pci_1_3,
     .compat_props = (GlobalProperty[]) {
-        PC_COMPAT_1_3,
+        PC_COMPAT_1_3
         { /* end of list */ }
     },
 };
 
 #define PC_COMPAT_1_2 \
-        PC_COMPAT_1_3,\
+        PC_COMPAT_1_3 \
         {\
             .driver   = "nec-usb-xhci",\
             .property = "msi",\
@@ -663,7 +663,7 @@ static QEMUMachine pc_machine_v1_3 = {
             .driver   = "VGA",\
             .property = "mmio",\
             .value    = "off",\
-        }
+        },
 
 #define PC_I440FX_1_2_MACHINE_OPTIONS \
     PC_I440FX_1_4_MACHINE_OPTIONS, \
@@ -673,13 +673,13 @@ static QEMUMachine pc_machine_v1_2 = {
     PC_I440FX_1_2_MACHINE_OPTIONS,
     .name = "pc-1.2",
     .compat_props = (GlobalProperty[]) {
-        PC_COMPAT_1_2,
+        PC_COMPAT_1_2
         { /* end of list */ }
     },
 };
 
 #define PC_COMPAT_1_1 \
-        PC_COMPAT_1_2,\
+        PC_COMPAT_1_2 \
         {\
             .driver   = "virtio-scsi-pci",\
             .property = "hotplug",\
@@ -708,19 +708,19 @@ static QEMUMachine pc_machine_v1_2 = {
             .driver   = "virtio-blk-pci",\
             .property = "config-wce",\
             .value    = "off",\
-        }
+        },
 
 static QEMUMachine pc_machine_v1_1 = {
     PC_I440FX_1_2_MACHINE_OPTIONS,
     .name = "pc-1.1",
     .compat_props = (GlobalProperty[]) {
-        PC_COMPAT_1_1,
+        PC_COMPAT_1_1
         { /* end of list */ }
     },
 };
 
 #define PC_COMPAT_1_0 \
-        PC_COMPAT_1_1,\
+        PC_COMPAT_1_1 \
         {\
             .driver   = TYPE_ISA_FDC,\
             .property = "check_media_rate",\
@@ -737,13 +737,13 @@ static QEMUMachine pc_machine_v1_1 = {
             .driver   = TYPE_USB_DEVICE,\
             .property = "full-path",\
             .value    = "no",\
-        }
+        },
 
 static QEMUMachine pc_machine_v1_0 = {
     PC_I440FX_1_2_MACHINE_OPTIONS,
     .name = "pc-1.0",
     .compat_props = (GlobalProperty[]) {
-        PC_COMPAT_1_0,
+        PC_COMPAT_1_0
         { /* end of list */ }
     },
     .hw_version = "1.0",
@@ -756,14 +756,14 @@ static QEMUMachine pc_machine_v0_15 = {
     PC_I440FX_1_2_MACHINE_OPTIONS,
     .name = "pc-0.15",
     .compat_props = (GlobalProperty[]) {
-        PC_COMPAT_0_15,
+        PC_COMPAT_0_15
         { /* end of list */ }
     },
     .hw_version = "0.15",
 };
 
 #define PC_COMPAT_0_14 \
-        PC_COMPAT_0_15,\
+        PC_COMPAT_0_15 \
         {\
             .driver   = "virtio-blk-pci",\
             .property = "event_idx",\
@@ -780,13 +780,13 @@ static QEMUMachine pc_machine_v0_15 = {
             .driver   = "virtio-balloon-pci",\
             .property = "event_idx",\
             .value    = "off",\
-        }
+        },
 
 static QEMUMachine pc_machine_v0_14 = {
     PC_I440FX_1_2_MACHINE_OPTIONS,
     .name = "pc-0.14",
     .compat_props = (GlobalProperty[]) {
-        PC_COMPAT_0_14, 
+        PC_COMPAT_0_14
         {
             .driver   = "qxl",
             .property = "revision",
@@ -802,7 +802,7 @@ static QEMUMachine pc_machine_v0_14 = {
 };
 
 #define PC_COMPAT_0_13 \
-        PC_COMPAT_0_14,\
+        PC_COMPAT_0_14 \
         {\
             .driver   = TYPE_PCI_DEVICE,\
             .property = "command_serr_enable",\
@@ -811,7 +811,7 @@ static QEMUMachine pc_machine_v0_14 = {
             .driver   = "AC97",\
             .property = "use_broken_id",\
             .value    = stringify(1),\
-        }
+        },
 
 #define PC_I440FX_0_13_MACHINE_OPTIONS \
     PC_I440FX_1_2_MACHINE_OPTIONS, \
@@ -821,7 +821,7 @@ static QEMUMachine pc_machine_v0_13 = {
     PC_I440FX_0_13_MACHINE_OPTIONS,
     .name = "pc-0.13",
     .compat_props = (GlobalProperty[]) {
-        PC_COMPAT_0_13,
+        PC_COMPAT_0_13
         {
             .driver   = "virtio-9p-pci",
             .property = "vectors",
@@ -841,7 +841,7 @@ static QEMUMachine pc_machine_v0_13 = {
 };
 
 #define PC_COMPAT_0_12 \
-        PC_COMPAT_0_13,\
+        PC_COMPAT_0_13 \
         {\
             .driver   = "virtio-serial-pci",\
             .property = "max_ports",\
@@ -862,13 +862,13 @@ static QEMUMachine pc_machine_v0_13 = {
             .driver   = "usb-kbd",\
             .property = "serial",\
             .value    = "1",\
-        }
+        },
 
 static QEMUMachine pc_machine_v0_12 = {
     PC_I440FX_0_13_MACHINE_OPTIONS,
     .name = "pc-0.12",
     .compat_props = (GlobalProperty[]) {
-        PC_COMPAT_0_12,
+        PC_COMPAT_0_12
         {
             .driver   = "VGA",
             .property = "rombar",
@@ -884,7 +884,7 @@ static QEMUMachine pc_machine_v0_12 = {
 };
 
 #define PC_COMPAT_0_11 \
-        PC_COMPAT_0_12,\
+        PC_COMPAT_0_12 \
         {\
             .driver   = "virtio-blk-pci",\
             .property = "vectors",\
@@ -893,13 +893,13 @@ static QEMUMachine pc_machine_v0_12 = {
             .driver   = TYPE_PCI_DEVICE,\
             .property = "rombar",\
             .value    = stringify(0),\
-        }
+        },
 
 static QEMUMachine pc_machine_v0_11 = {
     PC_I440FX_0_13_MACHINE_OPTIONS,
     .name = "pc-0.11",
     .compat_props = (GlobalProperty[]) {
-        PC_COMPAT_0_11,
+        PC_COMPAT_0_11
         {
             .driver   = "ide-drive",
             .property = "ver",
@@ -918,7 +918,7 @@ static QEMUMachine pc_machine_v0_10 = {
     PC_I440FX_0_13_MACHINE_OPTIONS,
     .name = "pc-0.10",
     .compat_props = (GlobalProperty[]) {
-        PC_COMPAT_0_11,
+        PC_COMPAT_0_11
         {
             .driver   = "virtio-blk-pci",
             .property = "class",
diff --git a/hw/i386/pc_q35.c b/hw/i386/pc_q35.c
index 0248357..b308575 100644
--- a/hw/i386/pc_q35.c
+++ b/hw/i386/pc_q35.c
@@ -451,7 +451,7 @@ static QEMUMachine pc_q35_machine_v2_0 = {
     .name = "pc-q35-2.0",
     .init = pc_q35_init_2_0,
     .compat_props = (GlobalProperty[]) {
-        PC_COMPAT_2_0,
+        PC_COMPAT_2_0
         { /* end of list */ }
     },
 };
@@ -463,7 +463,7 @@ static QEMUMachine pc_q35_machine_v1_7 = {
     .name = "pc-q35-1.7",
     .init = pc_q35_init_1_7,
     .compat_props = (GlobalProperty[]) {
-        PC_COMPAT_1_7,
+        PC_COMPAT_1_7
         { /* end of list */ }
     },
 };
@@ -475,7 +475,7 @@ static QEMUMachine pc_q35_machine_v1_6 = {
     .name = "pc-q35-1.6",
     .init = pc_q35_init_1_6,
     .compat_props = (GlobalProperty[]) {
-        PC_COMPAT_1_6,
+        PC_COMPAT_1_6
         { /* end of list */ }
     },
 };
@@ -485,7 +485,7 @@ static QEMUMachine pc_q35_machine_v1_5 = {
     .name = "pc-q35-1.5",
     .init = pc_q35_init_1_5,
     .compat_props = (GlobalProperty[]) {
-        PC_COMPAT_1_5,
+        PC_COMPAT_1_5
         { /* end of list */ }
     },
 };
@@ -499,7 +499,7 @@ static QEMUMachine pc_q35_machine_v1_4 = {
     .name = "pc-q35-1.4",
     .init = pc_q35_init_1_4,
     .compat_props = (GlobalProperty[]) {
-        PC_COMPAT_1_4,
+        PC_COMPAT_1_4
         { /* end of list */ }
     },
 };
diff --git a/include/hw/i386/pc.h b/include/hw/i386/pc.h
index 7673a4d..ab862e3 100644
--- a/include/hw/i386/pc.h
+++ b/include/hw/i386/pc.h
@@ -353,10 +353,10 @@ bool e820_get_entry(int, uint32_t, uint64_t *, uint64_t *);
             .driver   = "ioh3420",\
             .property = COMPAT_PROP_PCP,\
             .value    = "off",\
-        }
+        },
 
 #define PC_COMPAT_1_7 \
-        PC_COMPAT_2_0, \
+        PC_COMPAT_2_0 \
         {\
             .driver   = TYPE_USB_DEVICE,\
             .property = "msos-desc",\
@@ -371,10 +371,10 @@ bool e820_get_entry(int, uint32_t, uint64_t *, uint64_t *);
             .driver   = "hpet",\
             .property = HPET_INTCAP,\
             .value    = stringify(4),\
-        }
+        },
 
 #define PC_COMPAT_1_6 \
-        PC_COMPAT_1_7, \
+        PC_COMPAT_1_7 \
         {\
             .driver   = "e1000",\
             .property = "mitigation",\
@@ -395,10 +395,10 @@ bool e820_get_entry(int, uint32_t, uint64_t *, uint64_t *);
             .driver   = "q35-pcihost",\
             .property = "short_root_bus",\
             .value    = stringify(1),\
-        }
+        },
 
 #define PC_COMPAT_1_5 \
-        PC_COMPAT_1_6, \
+        PC_COMPAT_1_6 \
         {\
             .driver   = "Conroe-" TYPE_X86_CPU,\
             .property = "model",\
@@ -439,10 +439,10 @@ bool e820_get_entry(int, uint32_t, uint64_t *, uint64_t *);
             .driver   = "q35-pcihost",\
             .property = "short_root_bus",\
             .value    = stringify(0),\
-        }
+        },
 
 #define PC_COMPAT_1_4 \
-        PC_COMPAT_1_5, \
+        PC_COMPAT_1_5 \
         {\
             .driver   = "scsi-hd",\
             .property = "discard_granularity",\
@@ -504,7 +504,7 @@ bool e820_get_entry(int, uint32_t, uint64_t *, uint64_t *);
             .driver   = "486-" TYPE_X86_CPU,\
             .property = "model",\
             .value    = stringify(0),\
-        }
+        },
 
 #define PC_COMMON_MACHINE_OPTIONS \
     .default_boot_order = "cad"
-- 
2.1.0

  parent reply	other threads:[~2015-05-11 20:56 UTC|newest]

Thread overview: 14+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-05-11 20:55 [Qemu-devel] [PATCH 00/13] pc, hw, spapr: Cleanup of {HW, PC, SPAPR}_COMPAT_* macros Eduardo Habkost
2015-05-11 20:55 ` [Qemu-devel] [PATCH 01/13] pc: Replace tab with spaces Eduardo Habkost
2015-05-11 20:55 ` [Qemu-devel] [PATCH 02/13] hw: Move commas inside HW_COMPAT_2_1 macro Eduardo Habkost
2015-05-11 20:55 ` Eduardo Habkost [this message]
2015-05-11 20:55 ` [Qemu-devel] [PATCH 04/13] spapr: Move commas inside SPAPR_COMPAT_* macros Eduardo Habkost
2015-05-11 20:55 ` [Qemu-devel] [PATCH 05/13] hw: Define empty HW_COMPAT_2_[23] macros Eduardo Habkost
2015-05-11 20:55 ` [Qemu-devel] [PATCH 06/13] pc: Define PC_COMPAT_2_[123] macros Eduardo Habkost
2015-05-11 20:55 ` [Qemu-devel] [PATCH 07/13] spapr: Use HW_COMPAT_* inside SPAPR_COMPAT_* macros Eduardo Habkost
2015-05-11 20:55 ` [Qemu-devel] [PATCH 08/13] spapr: define SPAPR_COMPAT_2_3 Eduardo Habkost
2015-05-11 20:55 ` [Qemu-devel] [PATCH 09/13] piix: Move pc-0.14 qxl compat properties to PC_COMPAT_0_14 Eduardo Habkost
2015-05-11 20:55 ` [Qemu-devel] [PATCH 10/13] piix: Move pc-0.11 drive version compat props to PC_COMPAT_0_11 Eduardo Habkost
2015-05-11 20:55 ` [Qemu-devel] [PATCH 11/13] piix: Move pc-0.13 virtio-9p-pci compat to PC_COMPAT_0_13 Eduardo Habkost
2015-05-11 20:55 ` [Qemu-devel] [PATCH 12/13] piix: Move pc-0.1[23] rombar compat props " Eduardo Habkost
2015-05-11 20:55 ` [Qemu-devel] [PATCH 13/13] pc_piix: Define PC_COMPAT_0_10 Eduardo Habkost

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1431377756-19579-4-git-send-email-ehabkost@redhat.com \
    --to=ehabkost@redhat.com \
    --cc=agraf@suse.de \
    --cc=mst@redhat.com \
    --cc=qemu-devel@nongnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).