[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Qemu-ppc] [PATCH v3 3/9] spapr_pci: Introduce a finish_realize() ca
From: |
Alexander Graf |
Subject: |
Re: [Qemu-ppc] [PATCH v3 3/9] spapr_pci: Introduce a finish_realize() callback |
Date: |
Wed, 28 May 2014 17:11:38 +0200 |
User-agent: |
Mozilla/5.0 (Macintosh; Intel Mac OS X 10.9; rv:24.0) Gecko/20100101 Thunderbird/24.5.0 |
On 27.05.14 07:36, Alexey Kardashevskiy wrote:
The spapr-pci PHB initializes IOMMU for emulated devices only.
The upcoming VFIO support will do it different. However both emulated
and VFIO PHB types share most of the initialization code.
For the type specific things a new finish_realize() callback is
introduced.
This introduces sPAPRPHBClass derived from PCIHostBridgeClass and
adds the callback pointer.
This implements finish_realize() for emulated devices.
Signed-off-by: Alexey Kardashevskiy <address@hidden>
This patch breaks compilation on some of my test hosts:
05/28 12:41:34 ERROR| utils:0144| [stderr] In file included from
/usr/local/autotest/tmp/virt/src/qemu/hw/ppc/spapr.c:45:
05/28 12:41:34 ERROR| utils:0144| [stderr]
/usr/local/autotest/tmp/virt/src/qemu/include/hw/pci-host/spapr.h:77: error:
redefinition of typedef ‘sPAPRPHBState’
05/28 12:41:34 ERROR| utils:0144| [stderr]
/usr/local/autotest/tmp/virt/src/qemu/include/hw/pci-host/spapr.h:43: error:
previous declaration of ‘sPAPRPHBState’ was here
05/28 12:41:34 ERROR| utils:0144| [stderr] make[1]: *** [hw/ppc/spapr.o]
Error 1
05/28 12:41:34 ERROR| utils:0144| [stderr] make: *** [subdir-ppc64-softmmu]
Error 2
I've squashed the following patch into this one to make it compile:
diff --git a/include/hw/pci-host/spapr.h b/include/hw/pci-host/spapr.h
index ab29281..0f428a1 100644
--- a/include/hw/pci-host/spapr.h
+++ b/include/hw/pci-host/spapr.h
@@ -48,7 +48,7 @@ struct sPAPRPHBClass {
void (*finish_realize)(sPAPRPHBState *sphb, Error **errp);
};
-typedef struct sPAPRPHBState {
+struct sPAPRPHBState {
PCIHostState parent_obj;
int32_t index;
@@ -76,7 +76,7 @@ typedef struct sPAPRPHBState {
} msi_table[SPAPR_MSIX_MAX_DEVS];
QLIST_ENTRY(sPAPRPHBState) list;
-} sPAPRPHBState;
+};
#define SPAPR_PCI_BASE_BUID 0x800000020000000ULL
Alex
- [Qemu-ppc] [PATCH v3 0/9] spapr_pci: Prepare for VFIO, Alexey Kardashevskiy, 2014/05/27
- [Qemu-ppc] [PATCH v3 2/9] spapr_iommu: Enable multiple TCE requests, Alexey Kardashevskiy, 2014/05/27
- [Qemu-ppc] [PATCH v3 5/9] spapr_pci: Allow multiple TCE tables per PHB, Alexey Kardashevskiy, 2014/05/27
- [Qemu-ppc] [PATCH v3 6/9] spapr_iommu: Convert old qdev_init_nofail() to object_property_set_bool, Alexey Kardashevskiy, 2014/05/27
- [Qemu-ppc] [PATCH v3 8/9] spapr_iommu: Introduce page_shift in sPAPRTCETable, Alexey Kardashevskiy, 2014/05/27
- [Qemu-ppc] [PATCH v3 1/9] spapr: Enable dynamic change of the supported hypercalls list, Alexey Kardashevskiy, 2014/05/27
- [Qemu-ppc] [PATCH v3 4/9] spapr_pci: spapr_iommu: Make DMA window a subregion, Alexey Kardashevskiy, 2014/05/27
- [Qemu-ppc] [PATCH v3 7/9] spapr_iommu: Get rid of window_size in sPAPRTCETable, Alexey Kardashevskiy, 2014/05/27
- [Qemu-ppc] [PATCH v3 9/9] spapr_iommu: Introduce bus_offset in sPAPRTCETable, Alexey Kardashevskiy, 2014/05/27