From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:54917) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1VjKD1-0007ZR-6r for qemu-devel@nongnu.org; Wed, 20 Nov 2013 21:41:41 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1VjKCv-0004Am-78 for qemu-devel@nongnu.org; Wed, 20 Nov 2013 21:41:35 -0500 Received: from mx1.redhat.com ([209.132.183.28]:33189) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1VjKCu-0004AB-T7 for qemu-devel@nongnu.org; Wed, 20 Nov 2013 21:41:29 -0500 From: Igor Mammedov Date: Thu, 21 Nov 2013 03:38:41 +0100 Message-Id: <1385001528-12003-21-git-send-email-imammedo@redhat.com> In-Reply-To: <1385001528-12003-1-git-send-email-imammedo@redhat.com> References: <1385001528-12003-1-git-send-email-imammedo@redhat.com> Subject: [Qemu-devel] [PATCH 20/27] pc: piix: make PCII440FXState type public List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: qemu-devel@nongnu.org Cc: peter.maydell@linaro.org, stefanha@redhat.com, mst@redhat.com, chegu_vinod@hp.com, stefanb@linux.vnet.ibm.com, mjt@tls.msk.ru, mdroth@linux.vnet.ibm.com, armbru@redhat.com, vasilis.liaskovitis@profitbricks.com, quintela@redhat.com, kraxel@redhat.com, aliguori@amazon.com, hutao@cn.fujitsu.com, pbonzini@redhat.com, marcel.a@redhat.com, lcapitulino@redhat.com, afaerber@suse.de Signed-off-by: Igor Mammedov --- hw/pci-host/piix.c | 22 +--------------------- include/hw/pci-host/piix.h | 27 +++++++++++++++++++++++++++ 2 files changed, 28 insertions(+), 21 deletions(-) create mode 100644 include/hw/pci-host/piix.h diff --git a/hw/pci-host/piix.c b/hw/pci-host/piix.c index 615ab0d..8351430 100644 --- a/hw/pci-host/piix.c +++ b/hw/pci-host/piix.c @@ -22,15 +22,13 @@ * THE SOFTWARE. */ +#include "hw/pci-host/piix.h" #include "hw/hw.h" #include "hw/i386/pc.h" -#include "hw/pci/pci.h" -#include "hw/pci/pci_host.h" #include "hw/isa/isa.h" #include "hw/sysbus.h" #include "qemu/range.h" #include "hw/xen/xen.h" -#include "hw/pci-host/pam.h" #include "sysemu/sysemu.h" #include "hw/i386/ioapic.h" #include "qapi/visitor.h" @@ -91,24 +89,6 @@ typedef struct PIIX3State { MemoryRegion rcr_mem; } PIIX3State; -#define TYPE_I440FX_PCI_DEVICE "i440FX" -#define I440FX_PCI_DEVICE(obj) \ - OBJECT_CHECK(PCII440FXState, (obj), TYPE_I440FX_PCI_DEVICE) - -struct PCII440FXState { - /*< private >*/ - PCIDevice parent_obj; - /*< public >*/ - - MemoryRegion *system_memory; - MemoryRegion *pci_address_space; - MemoryRegion *ram_memory; - PAMMemoryRegion pam_regions[13]; - MemoryRegion smram_region; - uint8_t smm_enabled; -}; - - #define I440FX_PAM 0x59 #define I440FX_PAM_SIZE 7 #define I440FX_SMRAM 0x72 diff --git a/include/hw/pci-host/piix.h b/include/hw/pci-host/piix.h new file mode 100644 index 0000000..1155996 --- /dev/null +++ b/include/hw/pci-host/piix.h @@ -0,0 +1,27 @@ +#ifndef HW_PCIHOST_PIIX_H +#define HW_PCIHOST_PIIX_H + +#include "exec/memory.h" +#include "hw/qdev.h" +#include "hw/pci/pci.h" +#include "hw/pci/pci_host.h" +#include "hw/pci-host/pam.h" + +#define TYPE_I440FX_PCI_DEVICE "i440FX" +#define I440FX_PCI_DEVICE(obj) \ + OBJECT_CHECK(PCII440FXState, (obj), TYPE_I440FX_PCI_DEVICE) + +struct PCII440FXState { + /*< private >*/ + PCIDevice parent_obj; + /*< public >*/ + + MemoryRegion *system_memory; + MemoryRegion *pci_address_space; + MemoryRegion *ram_memory; + PAMMemoryRegion pam_regions[13]; + MemoryRegion smram_region; + uint8_t smm_enabled; +}; + +#endif -- 1.7.1