From: Alexander Graf <agraf@suse.de>
To: qemu-ppc Mailing List <qemu-ppc@nongnu.org>
Cc: Blue Swirl <blauwirbel@gmail.com>,
Li Zhang <zhlcindy@linux.vnet.ibm.com>,
"zhlcindy@gmail.com" <zhlcindy@gmail.com>,
qemu-devel qemu-devel <qemu-devel@nongnu.org>,
Aurelien Jarno <aurelien@aurel32.net>
Subject: [Qemu-devel] [PATCH 09/24] Add one new file vga-pci.h and cleanup on all platforms
Date: Wed, 15 Aug 2012 11:58:47 +0200 [thread overview]
Message-ID: <1345024742-18394-10-git-send-email-agraf@suse.de> (raw)
In-Reply-To: <1345024742-18394-1-git-send-email-agraf@suse.de>
From: zhlcindy@gmail.com <zhlcindy@gmail.com>
Functions pci_vga_init() and pci_cirrus_vga_init() are declared
in pc.h. That prevents other platforms (e.g. sPAPR) to use them.
This patch is to create one new file vga-pci.h and move the
declarations to vga-pci.h, so that they can be shared by
all platforms. This patch also cleans up on all platforms.
Signed-off-by: Li Zhang <zhlcindy@linux.vnet.ibm.com>
Signed-off-by: Alexander Graf <agraf@suse.de>
---
hw/alpha_pci.c | 1 +
hw/cirrus_vga.c | 2 +-
hw/mips_malta.c | 1 +
hw/pc.c | 1 +
hw/pc.h | 4 ----
hw/ppc_newworld.c | 2 +-
hw/ppc_oldworld.c | 2 +-
hw/ppc_prep.c | 1 +
hw/sun4u.c | 1 +
hw/vga-pci.c | 2 +-
hw/vga-pci.h | 12 ++++++++++++
11 files changed, 21 insertions(+), 8 deletions(-)
create mode 100644 hw/vga-pci.h
diff --git a/hw/alpha_pci.c b/hw/alpha_pci.c
index 6735577..ea546f8 100644
--- a/hw/alpha_pci.c
+++ b/hw/alpha_pci.c
@@ -11,6 +11,7 @@
#include "qemu-log.h"
#include "sysemu.h"
#include "vmware_vga.h"
+#include "vga-pci.h"
/* PCI IO reads/writes, to byte-word addressable memory. */
diff --git a/hw/cirrus_vga.c b/hw/cirrus_vga.c
index 623dd68..e8dcc6b 100644
--- a/hw/cirrus_vga.c
+++ b/hw/cirrus_vga.c
@@ -27,8 +27,8 @@
* available at http://home.worldonline.dk/~finth/
*/
#include "hw.h"
-#include "pc.h"
#include "pci.h"
+#include "vga-pci.h"
#include "console.h"
#include "vga_int.h"
#include "loader.h"
diff --git a/hw/mips_malta.c b/hw/mips_malta.c
index 351c88e..ad23f26 100644
--- a/hw/mips_malta.c
+++ b/hw/mips_malta.c
@@ -48,6 +48,7 @@
#include "blockdev.h"
#include "exec-memory.h"
#include "sysbus.h" /* SysBusDevice */
+#include "vga-pci.h"
//#define DEBUG_BOARD_INIT
diff --git a/hw/pc.c b/hw/pc.c
index e8bcfc0..3ed1a3c 100644
--- a/hw/pc.c
+++ b/hw/pc.c
@@ -51,6 +51,7 @@
#include "exec-memory.h"
#include "arch_init.h"
#include "bitmap.h"
+#include "vga-pci.h"
/* output Bochs bios info messages */
//#define DEBUG_BIOS
diff --git a/hw/pc.h b/hw/pc.h
index 31ccb6f..e4db071 100644
--- a/hw/pc.h
+++ b/hw/pc.h
@@ -189,14 +189,10 @@ static inline DeviceState *isa_vga_init(ISABus *bus)
return &dev->qdev;
}
-DeviceState *pci_vga_init(PCIBus *bus);
int isa_vga_mm_init(target_phys_addr_t vram_base,
target_phys_addr_t ctrl_base, int it_shift,
MemoryRegion *address_space);
-/* cirrus_vga.c */
-DeviceState *pci_cirrus_vga_init(PCIBus *bus);
-
/* ne2000.c */
static inline bool isa_ne2000_init(ISABus *bus, int base, int irq, NICInfo *nd)
{
diff --git a/hw/ppc_newworld.c b/hw/ppc_newworld.c
index 4e2a6e6..e95cfe8 100644
--- a/hw/ppc_newworld.c
+++ b/hw/ppc_newworld.c
@@ -52,7 +52,6 @@
#include "adb.h"
#include "mac_dbdma.h"
#include "nvram.h"
-#include "pc.h"
#include "pci.h"
#include "net.h"
#include "sysemu.h"
@@ -68,6 +67,7 @@
#include "hw/usb.h"
#include "blockdev.h"
#include "exec-memory.h"
+#include "vga-pci.h"
#define MAX_IDE_BUS 2
#define CFG_ADDR 0xf0000510
diff --git a/hw/ppc_oldworld.c b/hw/ppc_oldworld.c
index f2c6908..1dcd8a6 100644
--- a/hw/ppc_oldworld.c
+++ b/hw/ppc_oldworld.c
@@ -29,7 +29,6 @@
#include "adb.h"
#include "mac_dbdma.h"
#include "nvram.h"
-#include "pc.h"
#include "sysemu.h"
#include "net.h"
#include "isa.h"
@@ -44,6 +43,7 @@
#include "kvm_ppc.h"
#include "blockdev.h"
#include "exec-memory.h"
+#include "vga-pci.h"
#define MAX_IDE_BUS 2
#define CFG_ADDR 0xf0000510
diff --git a/hw/ppc_prep.c b/hw/ppc_prep.c
index be2b268..7a87616 100644
--- a/hw/ppc_prep.c
+++ b/hw/ppc_prep.c
@@ -39,6 +39,7 @@
#include "blockdev.h"
#include "arch_init.h"
#include "exec-memory.h"
+#include "vga-pci.h"
//#define HARD_DEBUG_PPC_IO
//#define DEBUG_PPC_IO
diff --git a/hw/sun4u.c b/hw/sun4u.c
index 137a7c6..07cd042 100644
--- a/hw/sun4u.c
+++ b/hw/sun4u.c
@@ -39,6 +39,7 @@
#include "elf.h"
#include "blockdev.h"
#include "exec-memory.h"
+#include "vga-pci.h"
//#define DEBUG_IRQ
//#define DEBUG_EBUS
diff --git a/hw/vga-pci.c b/hw/vga-pci.c
index 37dc019..9abbada 100644
--- a/hw/vga-pci.c
+++ b/hw/vga-pci.c
@@ -23,8 +23,8 @@
*/
#include "hw.h"
#include "console.h"
-#include "pc.h"
#include "pci.h"
+#include "vga-pci.h"
#include "vga_int.h"
#include "pixel_ops.h"
#include "qemu-timer.h"
diff --git a/hw/vga-pci.h b/hw/vga-pci.h
new file mode 100644
index 0000000..49abf13
--- /dev/null
+++ b/hw/vga-pci.h
@@ -0,0 +1,12 @@
+#ifndef VGA_PCI_H
+#define VGA_PCI_H
+
+#include "qemu-common.h"
+
+/* vga-pci.c */
+DeviceState *pci_vga_init(PCIBus *bus);
+
+/* cirrus_vga.c */
+DeviceState *pci_cirrus_vga_init(PCIBus *bus);
+
+#endif
--
1.6.0.2
next prev parent reply other threads:[~2012-08-15 9:59 UTC|newest]
Thread overview: 29+ messages / expand[flat|nested] mbox.gz Atom feed top
2012-08-15 9:58 [Qemu-devel] [PULL 00/24] ppc patch queue 2012-08-15 Alexander Graf
2012-08-15 9:58 ` [Qemu-devel] [PATCH 01/24] pseries pci: removed redundant busdev Alexander Graf
2012-08-15 10:17 ` Andreas Färber
2012-08-15 9:58 ` [Qemu-devel] [PATCH 02/24] pseries pci: spapr_populate_pci_devices renamed to spapr_populate_pci_dt Alexander Graf
2012-08-15 9:58 ` [Qemu-devel] [PATCH 03/24] PPC: e500: rename mpc8544ds into generic file Alexander Graf
2012-08-15 9:58 ` [Qemu-devel] [PATCH 04/24] PPC: e500: change internal references away from mpc8544ds Alexander Graf
2012-08-15 9:58 ` [Qemu-devel] [PATCH 05/24] PPC: e500: split mpc8544ds machine from generic e500 code Alexander Graf
2012-08-15 9:58 ` [Qemu-devel] [PATCH 06/24] PPC: e500: add generic e500 platform Alexander Graf
2012-08-15 9:58 ` [Qemu-devel] [PATCH 07/24] ppc: Fix bug in handling of PAPR hypercall exits Alexander Graf
2012-08-15 9:58 ` [Qemu-devel] [PATCH 08/24] Revert "PPC: e500: Use new MPIC dt format" Alexander Graf
2012-08-15 9:58 ` Alexander Graf [this message]
2012-08-15 9:58 ` [Qemu-devel] [PATCH 10/24] spapr: Add support for -vga option Alexander Graf
2012-08-15 9:58 ` [Qemu-devel] [PATCH 11/24] xbzrle: fix compilation on ppc32 Alexander Graf
2012-08-15 9:58 ` [Qemu-devel] [PATCH 12/24] PPC: spapr: Rework VGA select logic Alexander Graf
2012-08-15 9:58 ` [Qemu-devel] [PATCH 13/24] PPC: spapr: Remove global variable Alexander Graf
2012-08-15 9:58 ` [Qemu-devel] [PATCH 14/24] pseries: Update SLOF Alexander Graf
2012-08-15 9:58 ` [Qemu-devel] [PATCH 15/24] pseries: Remove extraneous prints Alexander Graf
2012-08-15 9:58 ` [Qemu-devel] [PATCH 16/24] pseries: Rework irq assignment to avoid carrying qemu_irqs around Alexander Graf
2012-08-15 9:58 ` [Qemu-devel] [PATCH 17/24] pseries: Separate PCI RTAS setup from common from emulation specific PCI setup Alexander Graf
2012-08-15 9:58 ` [Qemu-devel] [PATCH 18/24] pseries: added allocator for a block of IRQs Alexander Graf
2012-08-15 9:58 ` [Qemu-devel] [PATCH 19/24] pseries: Export find_phb() utility function for PCI code Alexander Graf
2012-08-15 9:58 ` [Qemu-devel] [PATCH 20/24] pseries: Add trace event for PCI irqs Alexander Graf
2012-08-15 9:58 ` [Qemu-devel] [PATCH 21/24] pseries: Add PCI MSI/MSI-X support Alexander Graf
2012-08-15 17:19 ` Andreas Färber
2012-08-15 17:46 ` Alexander Graf
2012-08-15 9:59 ` [Qemu-devel] [PATCH 22/24] pseries dma: DMA window params added to PHB and DT population changed Alexander Graf
2012-08-15 9:59 ` [Qemu-devel] [PATCH 23/24] pseries: Update SLOF firmware image Alexander Graf
2012-08-15 9:59 ` [Qemu-devel] [PATCH 24/24] openpic: Added BRR1 register Alexander Graf
2012-08-15 21:14 ` [Qemu-devel] [PULL 00/24] ppc patch queue 2012-08-15 Anthony Liguori
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=1345024742-18394-10-git-send-email-agraf@suse.de \
--to=agraf@suse.de \
--cc=aurelien@aurel32.net \
--cc=blauwirbel@gmail.com \
--cc=qemu-devel@nongnu.org \
--cc=qemu-ppc@nongnu.org \
--cc=zhlcindy@gmail.com \
--cc=zhlcindy@linux.vnet.ibm.com \
/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).