* [Qemu-devel] [PATCH 0/6] pci/isa: QOMify
@ 2015-05-13 0:43 arei.gonglei
2015-05-13 0:43 ` [Qemu-devel] [PATCH 1/6] pci-assign: QOMify arei.gonglei
` (6 more replies)
0 siblings, 7 replies; 17+ messages in thread
From: arei.gonglei @ 2015-05-13 0:43 UTC (permalink / raw)
To: qemu-devel; +Cc: pbonzini, Gonglei, peter.huangpeng, mst
From: Gonglei <arei.gonglei@huawei.com>
Because DO_UPCAST() is long deprecated, let me do
some cleanup work.
Please review,
thanks
Cc: Michael S. Tsirkin <mst@redhat.com>
Cc: Paolo Bonzini <pbonzini@redhat.com>
Gonglei (6):
pci-assign: QOMify
piix: piix3 QOMify
piix4: QOMify
wdt_i6300esb: QOMify
xen_pt: QOMify
vt82c686: QOMify
hw/i386/kvm/pci-assign.c | 39 ++++++++++++++++---------------
hw/isa/piix4.c | 8 +++++--
hw/isa/vt82c686.c | 47 ++++++++++++++++++++++++++------------
hw/pci-host/piix.c | 57 +++++++++++++++++++++++++---------------------
hw/watchdog/wdt_i6300esb.c | 14 ++++++++----
hw/xen/xen_pt.c | 10 ++++----
hw/xen/xen_pt.h | 4 ++++
7 files changed, 108 insertions(+), 71 deletions(-)
--
1.7.12.4
^ permalink raw reply [flat|nested] 17+ messages in thread
* [Qemu-devel] [PATCH 1/6] pci-assign: QOMify
2015-05-13 0:43 [Qemu-devel] [PATCH 0/6] pci/isa: QOMify arei.gonglei
@ 2015-05-13 0:43 ` arei.gonglei
2015-05-13 0:43 ` [Qemu-devel] [PATCH 2/6] piix: piix3 QOMify arei.gonglei
` (5 subsequent siblings)
6 siblings, 0 replies; 17+ messages in thread
From: arei.gonglei @ 2015-05-13 0:43 UTC (permalink / raw)
To: qemu-devel; +Cc: pbonzini, Gonglei, peter.huangpeng, mst
From: Gonglei <arei.gonglei@huawei.com>
Signed-off-by: Gonglei <arei.gonglei@huawei.com>
---
hw/i386/kvm/pci-assign.c | 39 +++++++++++++++++++++------------------
1 file changed, 21 insertions(+), 18 deletions(-)
diff --git a/hw/i386/kvm/pci-assign.c b/hw/i386/kvm/pci-assign.c
index 9db7c77..74d22f4 100644
--- a/hw/i386/kvm/pci-assign.c
+++ b/hw/i386/kvm/pci-assign.c
@@ -141,6 +141,9 @@ typedef struct AssignedDevice {
int32_t bootindex;
} AssignedDevice;
+#define TYPE_PCI_ASSIGN "kvm-pci-assign"
+#define PCI_ASSIGN(obj) OBJECT_CHECK(AssignedDevice, (obj), TYPE_PCI_ASSIGN)
+
static void assigned_dev_update_irq_routing(PCIDevice *dev);
static void assigned_dev_load_option_rom(AssignedDevice *dev);
@@ -257,7 +260,7 @@ static const MemoryRegionOps slow_bar_ops = {
static void assigned_dev_iomem_setup(PCIDevice *pci_dev, int region_num,
pcibus_t e_size)
{
- AssignedDevice *r_dev = DO_UPCAST(AssignedDevice, dev, pci_dev);
+ AssignedDevice *r_dev = PCI_ASSIGN(pci_dev);
AssignedDevRegion *region = &r_dev->v_addrs[region_num];
PCIRegion *real_region = &r_dev->real_device.regions[region_num];
@@ -289,7 +292,7 @@ static const MemoryRegionOps assigned_dev_ioport_ops = {
static void assigned_dev_ioport_setup(PCIDevice *pci_dev, int region_num,
pcibus_t size)
{
- AssignedDevice *r_dev = DO_UPCAST(AssignedDevice, dev, pci_dev);
+ AssignedDevice *r_dev = PCI_ASSIGN(pci_dev);
AssignedDevRegion *region = &r_dev->v_addrs[region_num];
region->e_size = size;
@@ -303,7 +306,7 @@ static void assigned_dev_ioport_setup(PCIDevice *pci_dev, int region_num,
static uint32_t assigned_dev_pci_read(PCIDevice *d, int pos, int len)
{
- AssignedDevice *pci_dev = DO_UPCAST(AssignedDevice, dev, d);
+ AssignedDevice *pci_dev = PCI_ASSIGN(d);
uint32_t val;
ssize_t ret;
int fd = pci_dev->real_device.config_fd;
@@ -328,7 +331,7 @@ static uint8_t assigned_dev_pci_read_byte(PCIDevice *d, int pos)
static void assigned_dev_pci_write(PCIDevice *d, int pos, uint32_t val, int len)
{
- AssignedDevice *pci_dev = DO_UPCAST(AssignedDevice, dev, d);
+ AssignedDevice *pci_dev = PCI_ASSIGN(d);
ssize_t ret;
int fd = pci_dev->real_device.config_fd;
@@ -946,7 +949,7 @@ static void deassign_device(AssignedDevice *dev)
*/
static void assigned_dev_update_irq_routing(PCIDevice *dev)
{
- AssignedDevice *assigned_dev = DO_UPCAST(AssignedDevice, dev, dev);
+ AssignedDevice *assigned_dev = PCI_ASSIGN(dev);
Error *err = NULL;
int r;
@@ -961,7 +964,7 @@ static void assigned_dev_update_irq_routing(PCIDevice *dev)
static void assigned_dev_update_msi(PCIDevice *pci_dev)
{
- AssignedDevice *assigned_dev = DO_UPCAST(AssignedDevice, dev, pci_dev);
+ AssignedDevice *assigned_dev = PCI_ASSIGN(pci_dev);
uint8_t ctrl_byte = pci_get_byte(pci_dev->config + pci_dev->msi_cap +
PCI_MSI_FLAGS);
int r;
@@ -1015,7 +1018,7 @@ static void assigned_dev_update_msi(PCIDevice *pci_dev)
static void assigned_dev_update_msi_msg(PCIDevice *pci_dev)
{
- AssignedDevice *assigned_dev = DO_UPCAST(AssignedDevice, dev, pci_dev);
+ AssignedDevice *assigned_dev = PCI_ASSIGN(pci_dev);
uint8_t ctrl_byte = pci_get_byte(pci_dev->config + pci_dev->msi_cap +
PCI_MSI_FLAGS);
@@ -1048,7 +1051,7 @@ static bool assigned_dev_msix_skipped(MSIXTableEntry *entry)
static int assigned_dev_update_msix_mmio(PCIDevice *pci_dev)
{
- AssignedDevice *adev = DO_UPCAST(AssignedDevice, dev, pci_dev);
+ AssignedDevice *adev = PCI_ASSIGN(pci_dev);
uint16_t entries_nr = 0;
int i, r = 0;
MSIXTableEntry *entry = adev->msix_table;
@@ -1113,7 +1116,7 @@ static int assigned_dev_update_msix_mmio(PCIDevice *pci_dev)
static void assigned_dev_update_msix(PCIDevice *pci_dev)
{
- AssignedDevice *assigned_dev = DO_UPCAST(AssignedDevice, dev, pci_dev);
+ AssignedDevice *assigned_dev = PCI_ASSIGN(pci_dev);
uint16_t ctrl_word = pci_get_word(pci_dev->config + pci_dev->msix_cap +
PCI_MSIX_FLAGS);
int r;
@@ -1163,7 +1166,7 @@ static void assigned_dev_update_msix(PCIDevice *pci_dev)
static uint32_t assigned_dev_pci_read_config(PCIDevice *pci_dev,
uint32_t address, int len)
{
- AssignedDevice *assigned_dev = DO_UPCAST(AssignedDevice, dev, pci_dev);
+ AssignedDevice *assigned_dev = PCI_ASSIGN(pci_dev);
uint32_t virt_val = pci_default_read_config(pci_dev, address, len);
uint32_t real_val, emulate_mask, full_emulation_mask;
@@ -1184,7 +1187,7 @@ static uint32_t assigned_dev_pci_read_config(PCIDevice *pci_dev,
static void assigned_dev_pci_write_config(PCIDevice *pci_dev, uint32_t address,
uint32_t val, int len)
{
- AssignedDevice *assigned_dev = DO_UPCAST(AssignedDevice, dev, pci_dev);
+ AssignedDevice *assigned_dev = PCI_ASSIGN(pci_dev);
uint16_t old_cmd = pci_get_word(pci_dev->config + PCI_COMMAND);
uint32_t emulate_mask, full_emulation_mask;
int ret;
@@ -1244,7 +1247,7 @@ static void assigned_dev_setup_cap_read(AssignedDevice *dev, uint32_t offset,
static int assigned_device_pci_cap_init(PCIDevice *pci_dev, Error **errp)
{
- AssignedDevice *dev = DO_UPCAST(AssignedDevice, dev, pci_dev);
+ AssignedDevice *dev = PCI_ASSIGN(pci_dev);
PCIRegion *pci_region = dev->real_device.regions;
int ret, pos;
Error *local_err = NULL;
@@ -1684,8 +1687,8 @@ static const VMStateDescription vmstate_assigned_device = {
static void reset_assigned_device(DeviceState *dev)
{
- PCIDevice *pci_dev = DO_UPCAST(PCIDevice, qdev, dev);
- AssignedDevice *adev = DO_UPCAST(AssignedDevice, dev, pci_dev);
+ PCIDevice *pci_dev = PCI_DEVICE(dev);
+ AssignedDevice *adev = PCI_ASSIGN(pci_dev);
char reset_file[64];
const char reset[] = "1";
int fd, ret;
@@ -1740,7 +1743,7 @@ static void reset_assigned_device(DeviceState *dev)
static void assigned_realize(struct PCIDevice *pci_dev, Error **errp)
{
- AssignedDevice *dev = DO_UPCAST(AssignedDevice, dev, pci_dev);
+ AssignedDevice *dev = PCI_ASSIGN(pci_dev);
uint8_t e_intx;
int r;
Error *local_err = NULL;
@@ -1836,7 +1839,7 @@ exit_with_error:
static void assigned_exitfn(struct PCIDevice *pci_dev)
{
- AssignedDevice *dev = DO_UPCAST(AssignedDevice, dev, pci_dev);
+ AssignedDevice *dev = PCI_ASSIGN(pci_dev);
deassign_device(dev);
free_assigned_device(dev);
@@ -1845,7 +1848,7 @@ static void assigned_exitfn(struct PCIDevice *pci_dev)
static void assigned_dev_instance_init(Object *obj)
{
PCIDevice *pci_dev = PCI_DEVICE(obj);
- AssignedDevice *d = DO_UPCAST(AssignedDevice, dev, PCI_DEVICE(obj));
+ AssignedDevice *d = PCI_ASSIGN(pci_dev);
device_add_bootindex_property(obj, &d->bootindex,
"bootindex", NULL,
@@ -1879,7 +1882,7 @@ static void assign_class_init(ObjectClass *klass, void *data)
}
static const TypeInfo assign_info = {
- .name = "kvm-pci-assign",
+ .name = TYPE_PCI_ASSIGN,
.parent = TYPE_PCI_DEVICE,
.instance_size = sizeof(AssignedDevice),
.class_init = assign_class_init,
--
1.7.12.4
^ permalink raw reply related [flat|nested] 17+ messages in thread
* [Qemu-devel] [PATCH 2/6] piix: piix3 QOMify
2015-05-13 0:43 [Qemu-devel] [PATCH 0/6] pci/isa: QOMify arei.gonglei
2015-05-13 0:43 ` [Qemu-devel] [PATCH 1/6] pci-assign: QOMify arei.gonglei
@ 2015-05-13 0:43 ` arei.gonglei
2015-05-13 0:43 ` [Qemu-devel] [PATCH 3/6] piix4: QOMify arei.gonglei
` (4 subsequent siblings)
6 siblings, 0 replies; 17+ messages in thread
From: arei.gonglei @ 2015-05-13 0:43 UTC (permalink / raw)
To: qemu-devel; +Cc: pbonzini, Gonglei, peter.huangpeng, mst
From: Gonglei <arei.gonglei@huawei.com>
Signed-off-by: Gonglei <arei.gonglei@huawei.com>
---
hw/pci-host/piix.c | 57 +++++++++++++++++++++++++++++-------------------------
1 file changed, 31 insertions(+), 26 deletions(-)
diff --git a/hw/pci-host/piix.c b/hw/pci-host/piix.c
index 723836f..f0fe4a1 100644
--- a/hw/pci-host/piix.c
+++ b/hw/pci-host/piix.c
@@ -91,6 +91,10 @@ typedef struct PIIX3State {
MemoryRegion rcr_mem;
} PIIX3State;
+#define TYPE_PIIX3_PCI_DEVICE "pci-piix3"
+#define PIIX3_PCI_DEVICE(obj) \
+ OBJECT_CHECK(PIIX3State, (obj), TYPE_PIIX3_PCI_DEVICE)
+
#define TYPE_I440FX_PCI_DEVICE "i440FX"
#define I440FX_PCI_DEVICE(obj) \
OBJECT_CHECK(PCII440FXState, (obj), TYPE_I440FX_PCI_DEVICE)
@@ -364,13 +368,15 @@ PCIBus *i440fx_init(PCII440FXState **pi440fx_state,
* connected to the IOAPIC directly.
* These additional routes can be discovered through ACPI. */
if (xen_enabled()) {
- piix3 = DO_UPCAST(PIIX3State, dev,
- pci_create_simple_multifunction(b, -1, true, "PIIX3-xen"));
+ PCIDevice *pci_dev = pci_create_simple_multifunction(b,
+ -1, true, "PIIX3-xen");
+ piix3 = PIIX3_PCI_DEVICE(pci_dev);
pci_bus_irqs(b, xen_piix3_set_irq, xen_pci_slot_get_pirq,
piix3, XEN_PIIX_NUM_PIRQS);
} else {
- piix3 = DO_UPCAST(PIIX3State, dev,
- pci_create_simple_multifunction(b, -1, true, "PIIX3"));
+ PCIDevice *pci_dev = pci_create_simple_multifunction(b,
+ -1, true, "PIIX3");
+ piix3 = PIIX3_PCI_DEVICE(pci_dev);
pci_bus_irqs(b, piix3_set_irq, pci_slot_get_pirq, piix3,
PIIX_NUM_PIRQS);
pci_bus_set_route_irq_fn(b, piix3_route_intx_pin_to_irq);
@@ -476,7 +482,7 @@ static void piix3_write_config(PCIDevice *dev,
{
pci_default_write_config(dev, address, val, len);
if (ranges_overlap(address, len, PIIX_PIRQC, 4)) {
- PIIX3State *piix3 = DO_UPCAST(PIIX3State, dev, dev);
+ PIIX3State *piix3 = PIIX3_PCI_DEVICE(dev);
int pic_irq;
pci_bus_fire_intx_routing_notifier(piix3->dev.bus);
@@ -632,7 +638,7 @@ static const MemoryRegionOps rcr_ops = {
static void piix3_realize(PCIDevice *dev, Error **errp)
{
- PIIX3State *d = DO_UPCAST(PIIX3State, dev, dev);
+ PIIX3State *d = PIIX3_PCI_DEVICE(dev);
isa_bus_new(DEVICE(d), get_system_memory(),
pci_address_space_io(dev));
@@ -645,7 +651,7 @@ static void piix3_realize(PCIDevice *dev, Error **errp)
qemu_register_reset(piix3_reset, d);
}
-static void piix3_class_init(ObjectClass *klass, void *data)
+static void pci_piix3_class_init(ObjectClass *klass, void *data)
{
DeviceClass *dc = DEVICE_CLASS(klass);
PCIDeviceClass *k = PCI_DEVICE_CLASS(klass);
@@ -654,7 +660,6 @@ static void piix3_class_init(ObjectClass *klass, void *data)
dc->vmsd = &vmstate_piix3;
dc->hotpluggable = false;
k->realize = piix3_realize;
- k->config_write = piix3_write_config;
k->vendor_id = PCI_VENDOR_ID_INTEL;
/* 82371SB PIIX3 PCI-to-ISA bridge (Step A1) */
k->device_id = PCI_DEVICE_ID_INTEL_82371SB_0;
@@ -666,38 +671,37 @@ static void piix3_class_init(ObjectClass *klass, void *data)
dc->cannot_instantiate_with_device_add_yet = true;
}
+static const TypeInfo piix3_pci_type_info = {
+ .name = TYPE_PIIX3_PCI_DEVICE,
+ .parent = TYPE_PCI_DEVICE,
+ .instance_size = sizeof(PIIX3State),
+ .abstract = true,
+ .class_init = pci_piix3_class_init,
+};
+
+static void piix3_class_init(ObjectClass *klass, void *data)
+{
+ PCIDeviceClass *k = PCI_DEVICE_CLASS(klass);
+
+ k->config_write = piix3_write_config;
+}
+
static const TypeInfo piix3_info = {
.name = "PIIX3",
- .parent = TYPE_PCI_DEVICE,
- .instance_size = sizeof(PIIX3State),
+ .parent = TYPE_PIIX3_PCI_DEVICE,
.class_init = piix3_class_init,
};
static void piix3_xen_class_init(ObjectClass *klass, void *data)
{
- DeviceClass *dc = DEVICE_CLASS(klass);
PCIDeviceClass *k = PCI_DEVICE_CLASS(klass);
- dc->desc = "ISA bridge";
- dc->vmsd = &vmstate_piix3;
- dc->hotpluggable = false;
- k->realize = piix3_realize;
k->config_write = piix3_write_config_xen;
- k->vendor_id = PCI_VENDOR_ID_INTEL;
- /* 82371SB PIIX3 PCI-to-ISA bridge (Step A1) */
- k->device_id = PCI_DEVICE_ID_INTEL_82371SB_0;
- k->class_id = PCI_CLASS_BRIDGE_ISA;
- /*
- * Reason: part of PIIX3 southbridge, needs to be wired up by
- * pc_piix.c's pc_init1()
- */
- dc->cannot_instantiate_with_device_add_yet = true;
};
static const TypeInfo piix3_xen_info = {
.name = "PIIX3-xen",
- .parent = TYPE_PCI_DEVICE,
- .instance_size = sizeof(PIIX3State),
+ .parent = TYPE_PIIX3_PCI_DEVICE,
.class_init = piix3_xen_class_init,
};
@@ -770,6 +774,7 @@ static const TypeInfo i440fx_pcihost_info = {
static void i440fx_register_types(void)
{
type_register_static(&i440fx_info);
+ type_register_static(&piix3_pci_type_info);
type_register_static(&piix3_info);
type_register_static(&piix3_xen_info);
type_register_static(&i440fx_pcihost_info);
--
1.7.12.4
^ permalink raw reply related [flat|nested] 17+ messages in thread
* [Qemu-devel] [PATCH 3/6] piix4: QOMify
2015-05-13 0:43 [Qemu-devel] [PATCH 0/6] pci/isa: QOMify arei.gonglei
2015-05-13 0:43 ` [Qemu-devel] [PATCH 1/6] pci-assign: QOMify arei.gonglei
2015-05-13 0:43 ` [Qemu-devel] [PATCH 2/6] piix: piix3 QOMify arei.gonglei
@ 2015-05-13 0:43 ` arei.gonglei
2015-05-13 0:43 ` [Qemu-devel] [PATCH 4/6] wdt_i6300esb: QOMify arei.gonglei
` (3 subsequent siblings)
6 siblings, 0 replies; 17+ messages in thread
From: arei.gonglei @ 2015-05-13 0:43 UTC (permalink / raw)
To: qemu-devel; +Cc: pbonzini, Gonglei, peter.huangpeng, mst
From: Gonglei <arei.gonglei@huawei.com>
Signed-off-by: Gonglei <arei.gonglei@huawei.com>
---
hw/isa/piix4.c | 8 ++++++--
1 file changed, 6 insertions(+), 2 deletions(-)
diff --git a/hw/isa/piix4.c b/hw/isa/piix4.c
index d9522b1..2c59e91 100644
--- a/hw/isa/piix4.c
+++ b/hw/isa/piix4.c
@@ -34,6 +34,10 @@ typedef struct PIIX4State {
PCIDevice dev;
} PIIX4State;
+#define TYPE_PIIX4_PCI_DEVICE "PIIX4"
+#define PIIX4_PCI_DEVICE(obj) \
+ OBJECT_CHECK(PIIX4State, (obj), TYPE_PIIX4_PCI_DEVICE)
+
static void piix4_reset(void *opaque)
{
PIIX4State *d = opaque;
@@ -84,7 +88,7 @@ static const VMStateDescription vmstate_piix4 = {
static void piix4_realize(PCIDevice *dev, Error **errp)
{
- PIIX4State *d = DO_UPCAST(PIIX4State, dev, dev);
+ PIIX4State *d = PIIX4_PCI_DEVICE(dev);
isa_bus_new(DEVICE(d), pci_address_space(dev),
pci_address_space_io(dev));
@@ -121,7 +125,7 @@ static void piix4_class_init(ObjectClass *klass, void *data)
}
static const TypeInfo piix4_info = {
- .name = "PIIX4",
+ .name = TYPE_PIIX4_PCI_DEVICE,
.parent = TYPE_PCI_DEVICE,
.instance_size = sizeof(PIIX4State),
.class_init = piix4_class_init,
--
1.7.12.4
^ permalink raw reply related [flat|nested] 17+ messages in thread
* [Qemu-devel] [PATCH 4/6] wdt_i6300esb: QOMify
2015-05-13 0:43 [Qemu-devel] [PATCH 0/6] pci/isa: QOMify arei.gonglei
` (2 preceding siblings ...)
2015-05-13 0:43 ` [Qemu-devel] [PATCH 3/6] piix4: QOMify arei.gonglei
@ 2015-05-13 0:43 ` arei.gonglei
2015-05-13 0:43 ` [Qemu-devel] [PATCH 5/6] xen_pt: QOMify arei.gonglei
` (2 subsequent siblings)
6 siblings, 0 replies; 17+ messages in thread
From: arei.gonglei @ 2015-05-13 0:43 UTC (permalink / raw)
To: qemu-devel; +Cc: pbonzini, Gonglei, peter.huangpeng, mst
From: Gonglei <arei.gonglei@huawei.com>
Signed-off-by: Gonglei <arei.gonglei@huawei.com>
---
hw/watchdog/wdt_i6300esb.c | 14 +++++++++-----
1 file changed, 9 insertions(+), 5 deletions(-)
diff --git a/hw/watchdog/wdt_i6300esb.c b/hw/watchdog/wdt_i6300esb.c
index 4ebdbb8..cfa2b1b 100644
--- a/hw/watchdog/wdt_i6300esb.c
+++ b/hw/watchdog/wdt_i6300esb.c
@@ -103,6 +103,10 @@ struct I6300State {
typedef struct I6300State I6300State;
+#define TYPE_WATCHDOG_I6300ESB_DEVICE "i6300esb"
+#define WATCHDOG_I6300ESB_DEVICE(obj) \
+ OBJECT_CHECK(I6300State, (obj), TYPE_WATCHDOG_I6300ESB_DEVICE)
+
/* This function is called when the watchdog has either been enabled
* (hence it starts counting down) or has been keep-alived.
*/
@@ -150,7 +154,7 @@ static void i6300esb_disable_timer(I6300State *d)
static void i6300esb_reset(DeviceState *dev)
{
PCIDevice *pdev = PCI_DEVICE(dev);
- I6300State *d = DO_UPCAST(I6300State, dev, pdev);
+ I6300State *d = WATCHDOG_I6300ESB_DEVICE(pdev);
i6300esb_debug("I6300State = %p\n", d);
@@ -213,7 +217,7 @@ static void i6300esb_timer_expired(void *vp)
static void i6300esb_config_write(PCIDevice *dev, uint32_t addr,
uint32_t data, int len)
{
- I6300State *d = DO_UPCAST(I6300State, dev, dev);
+ I6300State *d = WATCHDOG_I6300ESB_DEVICE(dev);
int old;
i6300esb_debug("addr = %x, data = %x, len = %d\n", addr, data, len);
@@ -241,7 +245,7 @@ static void i6300esb_config_write(PCIDevice *dev, uint32_t addr,
static uint32_t i6300esb_config_read(PCIDevice *dev, uint32_t addr, int len)
{
- I6300State *d = DO_UPCAST(I6300State, dev, dev);
+ I6300State *d = WATCHDOG_I6300ESB_DEVICE(dev);
uint32_t data;
i6300esb_debug ("addr = %x, len = %d\n", addr, len);
@@ -416,7 +420,7 @@ static const VMStateDescription vmstate_i6300esb = {
static void i6300esb_realize(PCIDevice *dev, Error **errp)
{
- I6300State *d = DO_UPCAST(I6300State, dev, dev);
+ I6300State *d = WATCHDOG_I6300ESB_DEVICE(dev);
i6300esb_debug("I6300State = %p\n", d);
@@ -451,7 +455,7 @@ static void i6300esb_class_init(ObjectClass *klass, void *data)
}
static const TypeInfo i6300esb_info = {
- .name = "i6300esb",
+ .name = TYPE_WATCHDOG_I6300ESB_DEVICE,
.parent = TYPE_PCI_DEVICE,
.instance_size = sizeof(I6300State),
.class_init = i6300esb_class_init,
--
1.7.12.4
^ permalink raw reply related [flat|nested] 17+ messages in thread
* [Qemu-devel] [PATCH 5/6] xen_pt: QOMify
2015-05-13 0:43 [Qemu-devel] [PATCH 0/6] pci/isa: QOMify arei.gonglei
` (3 preceding siblings ...)
2015-05-13 0:43 ` [Qemu-devel] [PATCH 4/6] wdt_i6300esb: QOMify arei.gonglei
@ 2015-05-13 0:43 ` arei.gonglei
2015-05-13 11:46 ` Stefano Stabellini
2015-05-13 0:43 ` [Qemu-devel] [PATCH 6/6] vt82c686: QOMify arei.gonglei
2015-05-19 7:45 ` [Qemu-devel] [PATCH 0/6] pci/isa: QOMify Gonglei
6 siblings, 1 reply; 17+ messages in thread
From: arei.gonglei @ 2015-05-13 0:43 UTC (permalink / raw)
To: qemu-devel; +Cc: pbonzini, Gonglei, peter.huangpeng, Stefano Stabellini, mst
From: Gonglei <arei.gonglei@huawei.com>
Cc: Stefano Stabellini <stefano.stabellini@eu.citrix.com>
Signed-off-by: Gonglei <arei.gonglei@huawei.com>
---
hw/xen/xen_pt.c | 10 +++++-----
hw/xen/xen_pt.h | 4 ++++
2 files changed, 9 insertions(+), 5 deletions(-)
diff --git a/hw/xen/xen_pt.c b/hw/xen/xen_pt.c
index d095c08..6674974 100644
--- a/hw/xen/xen_pt.c
+++ b/hw/xen/xen_pt.c
@@ -125,7 +125,7 @@ int xen_pt_bar_offset_to_index(uint32_t offset)
static uint32_t xen_pt_pci_read_config(PCIDevice *d, uint32_t addr, int len)
{
- XenPCIPassthroughState *s = DO_UPCAST(XenPCIPassthroughState, dev, d);
+ XenPCIPassthroughState *s = XEN_PT_DEVICE(d);
uint32_t val = 0;
XenPTRegGroup *reg_grp_entry = NULL;
XenPTReg *reg_entry = NULL;
@@ -230,7 +230,7 @@ exit:
static void xen_pt_pci_write_config(PCIDevice *d, uint32_t addr,
uint32_t val, int len)
{
- XenPCIPassthroughState *s = DO_UPCAST(XenPCIPassthroughState, dev, d);
+ XenPCIPassthroughState *s = XEN_PT_DEVICE(d);
int index = 0;
XenPTRegGroup *reg_grp_entry = NULL;
int rc = 0;
@@ -637,7 +637,7 @@ static const MemoryListener xen_pt_io_listener = {
static int xen_pt_initfn(PCIDevice *d)
{
- XenPCIPassthroughState *s = DO_UPCAST(XenPCIPassthroughState, dev, d);
+ XenPCIPassthroughState *s = XEN_PT_DEVICE(d);
int rc = 0;
uint8_t machine_irq = 0;
uint16_t cmd = 0;
@@ -755,7 +755,7 @@ out:
static void xen_pt_unregister_device(PCIDevice *d)
{
- XenPCIPassthroughState *s = DO_UPCAST(XenPCIPassthroughState, dev, d);
+ XenPCIPassthroughState *s = XEN_PT_DEVICE(d);
uint8_t machine_irq = s->machine_irq;
uint8_t intx = xen_pt_pci_intx(s);
int rc;
@@ -825,7 +825,7 @@ static void xen_pci_passthrough_class_init(ObjectClass *klass, void *data)
};
static const TypeInfo xen_pci_passthrough_info = {
- .name = "xen-pci-passthrough",
+ .name = TYPE_XEN_PT_DEVICE,
.parent = TYPE_PCI_DEVICE,
.instance_size = sizeof(XenPCIPassthroughState),
.class_init = xen_pci_passthrough_class_init,
diff --git a/hw/xen/xen_pt.h b/hw/xen/xen_pt.h
index 942dc60..e744a3c 100644
--- a/hw/xen/xen_pt.h
+++ b/hw/xen/xen_pt.h
@@ -36,6 +36,10 @@ typedef struct XenPTReg XenPTReg;
typedef struct XenPCIPassthroughState XenPCIPassthroughState;
+#define TYPE_XEN_PT_DEVICE "xen-pci-passthrough"
+#define XEN_PT_DEVICE(obj) \
+ OBJECT_CHECK(XenPCIPassthroughState, (obj), TYPE_XEN_PT_DEVICE)
+
/* function type for config reg */
typedef int (*xen_pt_conf_reg_init)
(XenPCIPassthroughState *, XenPTRegInfo *, uint32_t real_offset,
--
1.7.12.4
^ permalink raw reply related [flat|nested] 17+ messages in thread
* [Qemu-devel] [PATCH 6/6] vt82c686: QOMify
2015-05-13 0:43 [Qemu-devel] [PATCH 0/6] pci/isa: QOMify arei.gonglei
` (4 preceding siblings ...)
2015-05-13 0:43 ` [Qemu-devel] [PATCH 5/6] xen_pt: QOMify arei.gonglei
@ 2015-05-13 0:43 ` arei.gonglei
2015-05-19 7:45 ` [Qemu-devel] [PATCH 0/6] pci/isa: QOMify Gonglei
6 siblings, 0 replies; 17+ messages in thread
From: arei.gonglei @ 2015-05-13 0:43 UTC (permalink / raw)
To: qemu-devel; +Cc: pbonzini, Gonglei, peter.huangpeng, mst
From: Gonglei <arei.gonglei@huawei.com>
Signed-off-by: Gonglei <arei.gonglei@huawei.com>
---
hw/isa/vt82c686.c | 47 ++++++++++++++++++++++++++++++++---------------
1 file changed, 32 insertions(+), 15 deletions(-)
diff --git a/hw/isa/vt82c686.c b/hw/isa/vt82c686.c
index b8197b1..bb6f6df 100644
--- a/hw/isa/vt82c686.c
+++ b/hw/isa/vt82c686.c
@@ -47,6 +47,10 @@ typedef struct VT82C686BState {
SuperIOConfig superio_conf;
} VT82C686BState;
+#define TYPE_VT82C686B_DEVICE "VT82C686B"
+#define VT82C686B_DEVICE(obj) \
+ OBJECT_CHECK(VT82C686BState, (obj), TYPE_VT82C686B_DEVICE)
+
static void superio_ioport_writeb(void *opaque, hwaddr addr, uint64_t data,
unsigned size)
{
@@ -114,7 +118,7 @@ static void vt82c686b_reset(void * opaque)
{
PCIDevice *d = opaque;
uint8_t *pci_conf = d->config;
- VT82C686BState *vt82c = DO_UPCAST(VT82C686BState, dev, d);
+ VT82C686BState *vt82c = VT82C686B_DEVICE(d);
pci_set_long(pci_conf + PCI_CAPABILITY_LIST, 0x000000c0);
pci_set_word(pci_conf + PCI_COMMAND, PCI_COMMAND_IO | PCI_COMMAND_MEMORY |
@@ -142,7 +146,7 @@ static void vt82c686b_reset(void * opaque)
static void vt82c686b_write_config(PCIDevice * d, uint32_t address,
uint32_t val, int len)
{
- VT82C686BState *vt686 = DO_UPCAST(VT82C686BState, dev, d);
+ VT82C686BState *vt686 = VT82C686B_DEVICE(d);
DPRINTF("vt82c686b_write_config address 0x%x val 0x%x len 0x%x\n",
address, val, len);
@@ -172,6 +176,18 @@ typedef struct VT686MC97State {
PCIDevice dev;
} VT686MC97State;
+#define TYPE_VT82C686B_PM_DEVICE "VT82C686B_PM"
+#define VT82C686B_PM_DEVICE(obj) \
+ OBJECT_CHECK(VT686PMState, (obj), TYPE_VT82C686B_PM_DEVICE)
+
+#define TYPE_VT82C686B_MC97_DEVICE "VT82C686B_MC97"
+#define VT82C686B_MC97_DEVICE(obj) \
+ OBJECT_CHECK(VT686MC97State, (obj), TYPE_VT82C686B_MC97_DEVICE)
+
+#define TYPE_VT82C686B_AC97_DEVICE "VT82C686B_AC97"
+#define VT82C686B_AC97_DEVICE(obj) \
+ OBJECT_CHECK(VT686AC97State, (obj), TYPE_VT82C686B_AC97_DEVICE)
+
static void pm_update_sci(VT686PMState *s)
{
int sci_level, pmsts;
@@ -247,7 +263,7 @@ static const VMStateDescription vmstate_acpi = {
static void vt82c686b_ac97_realize(PCIDevice *dev, Error **errp)
{
- VT686AC97State *s = DO_UPCAST(VT686AC97State, dev, dev);
+ VT686AC97State *s = VT82C686B_AC97_DEVICE(dev);
uint8_t *pci_conf = s->dev.config;
pci_set_word(pci_conf + PCI_COMMAND, PCI_COMMAND_INVALIDATE |
@@ -261,7 +277,7 @@ void vt82c686b_ac97_init(PCIBus *bus, int devfn)
{
PCIDevice *dev;
- dev = pci_create(bus, devfn, "VT82C686B_AC97");
+ dev = pci_create(bus, devfn, TYPE_VT82C686B_AC97_DEVICE);
qdev_init_nofail(&dev->qdev);
}
@@ -280,7 +296,7 @@ static void via_ac97_class_init(ObjectClass *klass, void *data)
}
static const TypeInfo via_ac97_info = {
- .name = "VT82C686B_AC97",
+ .name = TYPE_VT82C686B_AC97_DEVICE,
.parent = TYPE_PCI_DEVICE,
.instance_size = sizeof(VT686AC97State),
.class_init = via_ac97_class_init,
@@ -288,7 +304,7 @@ static const TypeInfo via_ac97_info = {
static void vt82c686b_mc97_realize(PCIDevice *dev, Error **errp)
{
- VT686MC97State *s = DO_UPCAST(VT686MC97State, dev, dev);
+ VT686MC97State *s = VT82C686B_MC97_DEVICE(dev);
uint8_t *pci_conf = s->dev.config;
pci_set_word(pci_conf + PCI_COMMAND, PCI_COMMAND_INVALIDATE |
@@ -301,7 +317,7 @@ void vt82c686b_mc97_init(PCIBus *bus, int devfn)
{
PCIDevice *dev;
- dev = pci_create(bus, devfn, "VT82C686B_MC97");
+ dev = pci_create(bus, devfn, TYPE_VT82C686B_MC97_DEVICE);
qdev_init_nofail(&dev->qdev);
}
@@ -320,7 +336,7 @@ static void via_mc97_class_init(ObjectClass *klass, void *data)
}
static const TypeInfo via_mc97_info = {
- .name = "VT82C686B_MC97",
+ .name = TYPE_VT82C686B_MC97_DEVICE,
.parent = TYPE_PCI_DEVICE,
.instance_size = sizeof(VT686MC97State),
.class_init = via_mc97_class_init,
@@ -329,7 +345,7 @@ static const TypeInfo via_mc97_info = {
/* vt82c686 pm init */
static void vt82c686b_pm_realize(PCIDevice *dev, Error **errp)
{
- VT686PMState *s = DO_UPCAST(VT686PMState, dev, dev);
+ VT686PMState *s = VT82C686B_PM_DEVICE(dev);
uint8_t *pci_conf;
pci_conf = s->dev.config;
@@ -365,10 +381,10 @@ I2CBus *vt82c686b_pm_init(PCIBus *bus, int devfn, uint32_t smb_io_base,
PCIDevice *dev;
VT686PMState *s;
- dev = pci_create(bus, devfn, "VT82C686B_PM");
+ dev = pci_create(bus, devfn, TYPE_VT82C686B_PM_DEVICE);
qdev_prop_set_uint32(&dev->qdev, "smb_io_base", smb_io_base);
- s = DO_UPCAST(VT686PMState, dev, dev);
+ s = VT82C686B_PM_DEVICE(dev);
qdev_init_nofail(&dev->qdev);
@@ -398,7 +414,7 @@ static void via_pm_class_init(ObjectClass *klass, void *data)
}
static const TypeInfo via_pm_info = {
- .name = "VT82C686B_PM",
+ .name = TYPE_VT82C686B_PM_DEVICE,
.parent = TYPE_PCI_DEVICE,
.instance_size = sizeof(VT686PMState),
.class_init = via_pm_class_init,
@@ -417,7 +433,7 @@ static const VMStateDescription vmstate_via = {
/* init the PCI-to-ISA bridge */
static void vt82c686b_realize(PCIDevice *d, Error **errp)
{
- VT82C686BState *vt82c = DO_UPCAST(VT82C686BState, dev, d);
+ VT82C686BState *vt82c = VT82C686B_DEVICE(d);
uint8_t *pci_conf;
ISABus *isa_bus;
uint8_t *wmask;
@@ -451,7 +467,8 @@ ISABus *vt82c686b_init(PCIBus *bus, int devfn)
{
PCIDevice *d;
- d = pci_create_simple_multifunction(bus, devfn, true, "VT82C686B");
+ d = pci_create_simple_multifunction(bus, devfn, true,
+ TYPE_VT82C686B_DEVICE);
return ISA_BUS(qdev_get_child_bus(DEVICE(d), "isa.0"));
}
@@ -477,7 +494,7 @@ static void via_class_init(ObjectClass *klass, void *data)
}
static const TypeInfo via_info = {
- .name = "VT82C686B",
+ .name = TYPE_VT82C686B_DEVICE,
.parent = TYPE_PCI_DEVICE,
.instance_size = sizeof(VT82C686BState),
.class_init = via_class_init,
--
1.7.12.4
^ permalink raw reply related [flat|nested] 17+ messages in thread
* Re: [Qemu-devel] [PATCH 5/6] xen_pt: QOMify
2015-05-13 0:43 ` [Qemu-devel] [PATCH 5/6] xen_pt: QOMify arei.gonglei
@ 2015-05-13 11:46 ` Stefano Stabellini
0 siblings, 0 replies; 17+ messages in thread
From: Stefano Stabellini @ 2015-05-13 11:46 UTC (permalink / raw)
To: Gonglei; +Cc: pbonzini, mst, qemu-devel, Stefano Stabellini, peter.huangpeng
On Wed, 13 May 2015, arei.gonglei@huawei.com wrote:
> From: Gonglei <arei.gonglei@huawei.com>
>
> Cc: Stefano Stabellini <stefano.stabellini@eu.citrix.com>
> Signed-off-by: Gonglei <arei.gonglei@huawei.com>
Tested-by: Stefano Stabellini <stefano.stabellini@eu.citrix.com>
> hw/xen/xen_pt.c | 10 +++++-----
> hw/xen/xen_pt.h | 4 ++++
> 2 files changed, 9 insertions(+), 5 deletions(-)
>
> diff --git a/hw/xen/xen_pt.c b/hw/xen/xen_pt.c
> index d095c08..6674974 100644
> --- a/hw/xen/xen_pt.c
> +++ b/hw/xen/xen_pt.c
> @@ -125,7 +125,7 @@ int xen_pt_bar_offset_to_index(uint32_t offset)
>
> static uint32_t xen_pt_pci_read_config(PCIDevice *d, uint32_t addr, int len)
> {
> - XenPCIPassthroughState *s = DO_UPCAST(XenPCIPassthroughState, dev, d);
> + XenPCIPassthroughState *s = XEN_PT_DEVICE(d);
> uint32_t val = 0;
> XenPTRegGroup *reg_grp_entry = NULL;
> XenPTReg *reg_entry = NULL;
> @@ -230,7 +230,7 @@ exit:
> static void xen_pt_pci_write_config(PCIDevice *d, uint32_t addr,
> uint32_t val, int len)
> {
> - XenPCIPassthroughState *s = DO_UPCAST(XenPCIPassthroughState, dev, d);
> + XenPCIPassthroughState *s = XEN_PT_DEVICE(d);
> int index = 0;
> XenPTRegGroup *reg_grp_entry = NULL;
> int rc = 0;
> @@ -637,7 +637,7 @@ static const MemoryListener xen_pt_io_listener = {
>
> static int xen_pt_initfn(PCIDevice *d)
> {
> - XenPCIPassthroughState *s = DO_UPCAST(XenPCIPassthroughState, dev, d);
> + XenPCIPassthroughState *s = XEN_PT_DEVICE(d);
> int rc = 0;
> uint8_t machine_irq = 0;
> uint16_t cmd = 0;
> @@ -755,7 +755,7 @@ out:
>
> static void xen_pt_unregister_device(PCIDevice *d)
> {
> - XenPCIPassthroughState *s = DO_UPCAST(XenPCIPassthroughState, dev, d);
> + XenPCIPassthroughState *s = XEN_PT_DEVICE(d);
> uint8_t machine_irq = s->machine_irq;
> uint8_t intx = xen_pt_pci_intx(s);
> int rc;
> @@ -825,7 +825,7 @@ static void xen_pci_passthrough_class_init(ObjectClass *klass, void *data)
> };
>
> static const TypeInfo xen_pci_passthrough_info = {
> - .name = "xen-pci-passthrough",
> + .name = TYPE_XEN_PT_DEVICE,
> .parent = TYPE_PCI_DEVICE,
> .instance_size = sizeof(XenPCIPassthroughState),
> .class_init = xen_pci_passthrough_class_init,
> diff --git a/hw/xen/xen_pt.h b/hw/xen/xen_pt.h
> index 942dc60..e744a3c 100644
> --- a/hw/xen/xen_pt.h
> +++ b/hw/xen/xen_pt.h
> @@ -36,6 +36,10 @@ typedef struct XenPTReg XenPTReg;
>
> typedef struct XenPCIPassthroughState XenPCIPassthroughState;
>
> +#define TYPE_XEN_PT_DEVICE "xen-pci-passthrough"
> +#define XEN_PT_DEVICE(obj) \
> + OBJECT_CHECK(XenPCIPassthroughState, (obj), TYPE_XEN_PT_DEVICE)
> +
> /* function type for config reg */
> typedef int (*xen_pt_conf_reg_init)
> (XenPCIPassthroughState *, XenPTRegInfo *, uint32_t real_offset,
> --
> 1.7.12.4
>
>
^ permalink raw reply [flat|nested] 17+ messages in thread
* Re: [Qemu-devel] [PATCH 0/6] pci/isa: QOMify
2015-05-13 0:43 [Qemu-devel] [PATCH 0/6] pci/isa: QOMify arei.gonglei
` (5 preceding siblings ...)
2015-05-13 0:43 ` [Qemu-devel] [PATCH 6/6] vt82c686: QOMify arei.gonglei
@ 2015-05-19 7:45 ` Gonglei
2015-06-01 7:36 ` Gonglei
6 siblings, 1 reply; 17+ messages in thread
From: Gonglei @ 2015-05-19 7:45 UTC (permalink / raw)
To: qemu-devel; +Cc: pbonzini, peter.huangpeng, mst
On 2015/5/13 8:43, arei.gonglei@huawei.com wrote:
> From: Gonglei <arei.gonglei@huawei.com>
>
> Because DO_UPCAST() is long deprecated, let me do
> some cleanup work.
>
> Please review,
> thanks
>
> Cc: Michael S. Tsirkin <mst@redhat.com>
> Cc: Paolo Bonzini <pbonzini@redhat.com>
>
> Gonglei (6):
> pci-assign: QOMify
> piix: piix3 QOMify
> piix4: QOMify
> wdt_i6300esb: QOMify
> xen_pt: QOMify
> vt82c686: QOMify
>
> hw/i386/kvm/pci-assign.c | 39 ++++++++++++++++---------------
> hw/isa/piix4.c | 8 +++++--
> hw/isa/vt82c686.c | 47 ++++++++++++++++++++++++++------------
> hw/pci-host/piix.c | 57 +++++++++++++++++++++++++---------------------
> hw/watchdog/wdt_i6300esb.c | 14 ++++++++----
> hw/xen/xen_pt.c | 10 ++++----
> hw/xen/xen_pt.h | 4 ++++
> 7 files changed, 108 insertions(+), 71 deletions(-)
>
Ping...
^ permalink raw reply [flat|nested] 17+ messages in thread
* Re: [Qemu-devel] [PATCH 0/6] pci/isa: QOMify
2015-05-19 7:45 ` [Qemu-devel] [PATCH 0/6] pci/isa: QOMify Gonglei
@ 2015-06-01 7:36 ` Gonglei
2015-06-01 10:25 ` Michael S. Tsirkin
0 siblings, 1 reply; 17+ messages in thread
From: Gonglei @ 2015-06-01 7:36 UTC (permalink / raw)
To: qemu-devel; +Cc: pbonzini, peter.huangpeng, mst
On 2015/5/19 15:45, Gonglei wrote:
> On 2015/5/13 8:43, arei.gonglei@huawei.com wrote:
>> From: Gonglei <arei.gonglei@huawei.com>
>>
>> Because DO_UPCAST() is long deprecated, let me do
>> some cleanup work.
>>
>> Please review,
>> thanks
>>
>> Cc: Michael S. Tsirkin <mst@redhat.com>
>> Cc: Paolo Bonzini <pbonzini@redhat.com>
>>
>> Gonglei (6):
>> pci-assign: QOMify
>> piix: piix3 QOMify
>> piix4: QOMify
>> wdt_i6300esb: QOMify
>> xen_pt: QOMify
>> vt82c686: QOMify
>>
>> hw/i386/kvm/pci-assign.c | 39 ++++++++++++++++---------------
>> hw/isa/piix4.c | 8 +++++--
>> hw/isa/vt82c686.c | 47 ++++++++++++++++++++++++++------------
>> hw/pci-host/piix.c | 57 +++++++++++++++++++++++++---------------------
>> hw/watchdog/wdt_i6300esb.c | 14 ++++++++----
>> hw/xen/xen_pt.c | 10 ++++----
>> hw/xen/xen_pt.h | 4 ++++
>> 7 files changed, 108 insertions(+), 71 deletions(-)
>>
>
> Ping...
>
Hi, Michael, Paolo
Can you please ack or review those patches?
Regards,
-Gonglei
^ permalink raw reply [flat|nested] 17+ messages in thread
* Re: [Qemu-devel] [PATCH 0/6] pci/isa: QOMify
2015-06-01 7:36 ` Gonglei
@ 2015-06-01 10:25 ` Michael S. Tsirkin
2015-06-01 11:31 ` Paolo Bonzini
0 siblings, 1 reply; 17+ messages in thread
From: Michael S. Tsirkin @ 2015-06-01 10:25 UTC (permalink / raw)
To: Gonglei; +Cc: pbonzini, qemu-devel, peter.huangpeng
On Mon, Jun 01, 2015 at 03:36:26PM +0800, Gonglei wrote:
> On 2015/5/19 15:45, Gonglei wrote:
> > On 2015/5/13 8:43, arei.gonglei@huawei.com wrote:
> >> From: Gonglei <arei.gonglei@huawei.com>
> >>
> >> Because DO_UPCAST() is long deprecated, let me do
> >> some cleanup work.
> >>
> >> Please review,
> >> thanks
> >>
> >> Cc: Michael S. Tsirkin <mst@redhat.com>
> >> Cc: Paolo Bonzini <pbonzini@redhat.com>
> >>
> >> Gonglei (6):
> >> pci-assign: QOMify
> >> piix: piix3 QOMify
> >> piix4: QOMify
> >> wdt_i6300esb: QOMify
> >> xen_pt: QOMify
> >> vt82c686: QOMify
> >>
> >> hw/i386/kvm/pci-assign.c | 39 ++++++++++++++++---------------
> >> hw/isa/piix4.c | 8 +++++--
> >> hw/isa/vt82c686.c | 47 ++++++++++++++++++++++++++------------
> >> hw/pci-host/piix.c | 57 +++++++++++++++++++++++++---------------------
> >> hw/watchdog/wdt_i6300esb.c | 14 ++++++++----
> >> hw/xen/xen_pt.c | 10 ++++----
> >> hw/xen/xen_pt.h | 4 ++++
> >> 7 files changed, 108 insertions(+), 71 deletions(-)
> >>
> >
> > Ping...
> >
> Hi, Michael, Paolo
>
> Can you please ack or review those patches?
>
> Regards,
> -Gonglei
I think this belongs in the QOM tree, not mine.
--
MST
^ permalink raw reply [flat|nested] 17+ messages in thread
* Re: [Qemu-devel] [PATCH 0/6] pci/isa: QOMify
2015-06-01 10:25 ` Michael S. Tsirkin
@ 2015-06-01 11:31 ` Paolo Bonzini
2015-06-09 1:34 ` Gonglei
0 siblings, 1 reply; 17+ messages in thread
From: Paolo Bonzini @ 2015-06-01 11:31 UTC (permalink / raw)
To: Michael S. Tsirkin, Gonglei; +Cc: qemu-trivial, qemu-devel, peter.huangpeng
On 01/06/2015 12:25, Michael S. Tsirkin wrote:
>> > Hi, Michael, Paolo
>> >
>> > Can you please ack or review those patches?
>> >
>> > Regards,
>> > -Gonglei
> I think this belongs in the QOM tree, not mine.
Recently Gerd at least has taken similar patches, so I guess it belongs
all over the place, including Xen, KVM and PC trees.
Let's say it belongs in qemu-trivial (CCed)...
Paolo
^ permalink raw reply [flat|nested] 17+ messages in thread
* Re: [Qemu-devel] [PATCH 0/6] pci/isa: QOMify
2015-06-01 11:31 ` Paolo Bonzini
@ 2015-06-09 1:34 ` Gonglei
2015-06-09 11:00 ` Michael Tokarev
0 siblings, 1 reply; 17+ messages in thread
From: Gonglei @ 2015-06-09 1:34 UTC (permalink / raw)
To: Paolo Bonzini, Michael S. Tsirkin
Cc: qemu-trivial, mjt@tls.msk.ru >> Michael Tokarev,
qemu-devel, peter.huangpeng
On 2015/6/1 19:31, Paolo Bonzini wrote:
>
>
> On 01/06/2015 12:25, Michael S. Tsirkin wrote:
>>>> Hi, Michael, Paolo
>>>>
>>>> Can you please ack or review those patches?
>>>>
>>>> Regards,
>>>> -Gonglei
>> I think this belongs in the QOM tree, not mine.
>
> Recently Gerd at least has taken similar patches, so I guess it belongs
> all over the place, including Xen, KVM and PC trees.
>
> Let's say it belongs in qemu-trivial (CCed)...
>
OK.
/mjt, what's your opinion? Thanks
Regards,
-Gonglei
^ permalink raw reply [flat|nested] 17+ messages in thread
* Re: [Qemu-devel] [PATCH 0/6] pci/isa: QOMify
2015-06-09 1:34 ` Gonglei
@ 2015-06-09 11:00 ` Michael Tokarev
2015-06-09 11:24 ` Gonglei
0 siblings, 1 reply; 17+ messages in thread
From: Michael Tokarev @ 2015-06-09 11:00 UTC (permalink / raw)
To: Gonglei, Paolo Bonzini, Michael S. Tsirkin
Cc: qemu-trivial, qemu-devel, peter.huangpeng
09.06.2015 04:34, Gonglei wrote:
> /mjt, what's your opinion? Thanks
Somehow I thought it is a single patch, and tried to find
it @patchwork. But it is a series of 6 patches (which I
deleted from my inbox due to routine cleanup procedure).
> Gonglei (6):
> pci-assign: QOMify
> piix: piix3 QOMify
> piix4: QOMify
> wdt_i6300esb: QOMify
> xen_pt: QOMify
> vt82c686: QOMify
Do we care about pci-assign?
Maybe it's better to drop this code completely instead of
fixing it?
Other than that, I think it's okay to apply this series
to -trivial.
Thanks,
/mjt
^ permalink raw reply [flat|nested] 17+ messages in thread
* Re: [Qemu-devel] [PATCH 0/6] pci/isa: QOMify
2015-06-09 11:00 ` Michael Tokarev
@ 2015-06-09 11:24 ` Gonglei
2015-06-09 11:36 ` Michael Tokarev
0 siblings, 1 reply; 17+ messages in thread
From: Gonglei @ 2015-06-09 11:24 UTC (permalink / raw)
To: Michael Tokarev, Paolo Bonzini, Michael S. Tsirkin
Cc: qemu-trivial, qemu-devel, peter.huangpeng
On 2015/6/9 19:00, Michael Tokarev wrote:
> 09.06.2015 04:34, Gonglei wrote:
>> /mjt, what's your opinion? Thanks
>
> Somehow I thought it is a single patch, and tried to find
> it @patchwork. But it is a series of 6 patches (which I
> deleted from my inbox due to routine cleanup procedure).
>
It's okay.
I can resend this series to qemu-trivial adding some acks tag.
>> Gonglei (6):
>> pci-assign: QOMify
>> piix: piix3 QOMify
>> piix4: QOMify
>> wdt_i6300esb: QOMify
>> xen_pt: QOMify
>> vt82c686: QOMify
>
> Do we care about pci-assign?
> Maybe it's better to drop this code completely instead of
> fixing it?
>
IIRC, supporting vfio needs the host kernel is above 3.10,
but this condition is harsh. On the other hand, pci-assign is
simple to use, for testing purpose.
> Other than that, I think it's okay to apply this series
> to -trivial.
>
Thanks.
Regards,
-Gonglei
^ permalink raw reply [flat|nested] 17+ messages in thread
* Re: [Qemu-devel] [PATCH 0/6] pci/isa: QOMify
2015-06-09 11:24 ` Gonglei
@ 2015-06-09 11:36 ` Michael Tokarev
2015-06-09 12:11 ` Gonglei
0 siblings, 1 reply; 17+ messages in thread
From: Michael Tokarev @ 2015-06-09 11:36 UTC (permalink / raw)
To: Gonglei, Paolo Bonzini, Michael S. Tsirkin
Cc: qemu-trivial, qemu-devel, peter.huangpeng
09.06.2015 14:24, Gonglei wrote:
> On 2015/6/9 19:00, Michael Tokarev wrote:
>> 09.06.2015 04:34, Gonglei wrote:
>>> /mjt, what's your opinion? Thanks
>>
>> Somehow I thought it is a single patch, and tried to find
>> it @patchwork. But it is a series of 6 patches (which I
>> deleted from my inbox due to routine cleanup procedure).
>>
> It's okay.
> I can resend this series to qemu-trivial adding some acks tag.
Which ACKs do you mean? I don't see any ACK in the whole series,
maybe you collected some in private?
I found and applied all 6 patches to -trivial.
>> Do we care about pci-assign?
>> Maybe it's better to drop this code completely instead of
>> fixing it?
>>
> IIRC, supporting vfio needs the host kernel is above 3.10,
> but this condition is harsh. On the other hand, pci-assign is
> simple to use, for testing purpose.
Fair enough.
Thanks,
/mjt
^ permalink raw reply [flat|nested] 17+ messages in thread
* Re: [Qemu-devel] [PATCH 0/6] pci/isa: QOMify
2015-06-09 11:36 ` Michael Tokarev
@ 2015-06-09 12:11 ` Gonglei
0 siblings, 0 replies; 17+ messages in thread
From: Gonglei @ 2015-06-09 12:11 UTC (permalink / raw)
To: Michael Tokarev, Paolo Bonzini, Michael S. Tsirkin
Cc: qemu-trivial, qemu-devel, peter.huangpeng
On 2015/6/9 19:36, Michael Tokarev wrote:
> 09.06.2015 14:24, Gonglei wrote:
>> On 2015/6/9 19:00, Michael Tokarev wrote:
>>> 09.06.2015 04:34, Gonglei wrote:
>>>> /mjt, what's your opinion? Thanks
>>>
>>> Somehow I thought it is a single patch, and tried to find
>>> it @patchwork. But it is a series of 6 patches (which I
>>> deleted from my inbox due to routine cleanup procedure).
>>>
>> It's okay.
>> I can resend this series to qemu-trivial adding some acks tag.
>
> Which ACKs do you mean? I don't see any ACK in the whole series,
> maybe you collected some in private?
>
Oh, sorry, it's not a ack, but Stefano's tested-by tag on patch 5. :)
On Wed, 13 May 2015, arei.gonglei@huawei.com wrote:
> From: Gonglei <arei.gonglei@huawei.com>
>
> Cc: Stefano Stabellini <stefano.stabellini@eu.citrix.com>
> Signed-off-by: Gonglei <arei.gonglei@huawei.com>
Tested-by: Stefano Stabellini <stefano.stabellini@eu.citrix.com>
> I found and applied all 6 patches to -trivial.
>
OK, thanks.
Regards,
-Gonglei
>>> Do we care about pci-assign?
>>> Maybe it's better to drop this code completely instead of
>>> fixing it?
>>>
>> IIRC, supporting vfio needs the host kernel is above 3.10,
>> but this condition is harsh. On the other hand, pci-assign is
>> simple to use, for testing purpose.
>
> Fair enough.
>
> Thanks,
>
> /mjt
>
^ permalink raw reply [flat|nested] 17+ messages in thread
end of thread, other threads:[~2015-06-09 12:23 UTC | newest]
Thread overview: 17+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2015-05-13 0:43 [Qemu-devel] [PATCH 0/6] pci/isa: QOMify arei.gonglei
2015-05-13 0:43 ` [Qemu-devel] [PATCH 1/6] pci-assign: QOMify arei.gonglei
2015-05-13 0:43 ` [Qemu-devel] [PATCH 2/6] piix: piix3 QOMify arei.gonglei
2015-05-13 0:43 ` [Qemu-devel] [PATCH 3/6] piix4: QOMify arei.gonglei
2015-05-13 0:43 ` [Qemu-devel] [PATCH 4/6] wdt_i6300esb: QOMify arei.gonglei
2015-05-13 0:43 ` [Qemu-devel] [PATCH 5/6] xen_pt: QOMify arei.gonglei
2015-05-13 11:46 ` Stefano Stabellini
2015-05-13 0:43 ` [Qemu-devel] [PATCH 6/6] vt82c686: QOMify arei.gonglei
2015-05-19 7:45 ` [Qemu-devel] [PATCH 0/6] pci/isa: QOMify Gonglei
2015-06-01 7:36 ` Gonglei
2015-06-01 10:25 ` Michael S. Tsirkin
2015-06-01 11:31 ` Paolo Bonzini
2015-06-09 1:34 ` Gonglei
2015-06-09 11:00 ` Michael Tokarev
2015-06-09 11:24 ` Gonglei
2015-06-09 11:36 ` Michael Tokarev
2015-06-09 12:11 ` Gonglei
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.