* [Qemu-devel] [PATCH v2 00/12] another SysBusDevice::init to Device::realize cleanup
@ 2018-10-02 21:25 Philippe Mathieu-Daudé
2018-10-02 21:25 ` [Qemu-devel] [PATCH v2 01/12] trace-events: Fix copy/paste typo Philippe Mathieu-Daudé
` (12 more replies)
0 siblings, 13 replies; 17+ messages in thread
From: Philippe Mathieu-Daudé @ 2018-10-02 21:25 UTC (permalink / raw)
To: Peter Maydell, Cédric Le Goater
Cc: Philippe Mathieu-Daudé, qemu-devel, Eduardo Habkost
Peter suggested [1] another crusade for this merge window,
then Cédric jumped on his horse [2]. My turn on my dromedary.
since v1:
- let the empty_slot
- sh4_pci and bonito use DeviceState::realize instead of PCIDevice::realize
- reword niagara-iob commit message
v1: https://lists.gnu.org/archive/html/qemu-devel/2018-10/msg00220.html
- convert few devices to DeviceState::realize,
- kill the empty_slot device,
- remove unuseful class_init() code [RFC, do we want to keep this?]
- few other minor fixes catched while editing
Regards,
Phil.
[1] https://lists.gnu.org/archive/html/qemu-devel/2018-09/msg03605.html
[2] https://lists.gnu.org/archive/html/qemu-devel/2018-10/msg00001.html
001/12:[----] [--] 'trace-events: Fix copy/paste typo'
002/12:[----] [--] 'hw/timer/sun4v-rtc: Convert from DPRINTF() macro to trace events'
003/12:[----] [--] 'hw/timer/sun4v-rtc: Use DeviceState::realize rather than SysBusDevice::init'
004/12:[----] [--] 'hw/ssi/xilinx_spi: Use DeviceState::realize rather than SysBusDevice::init'
005/12:[0006] [FC] 'hw/sh4/sh_pci: Use DeviceState::realize rather than SysBusDevice::init'
006/12:[0006] [FC] 'hw/pci-host/bonito: Use DeviceState::realize rather than SysBusDevice::init'
007/12:[----] [--] 'hw/mips/gt64xxx_pci: Convert gt64120_reset() function into Device reset method'
008/12:[----] [--] 'hw/mips/gt64xxx_pci: Mark as bridge device'
009/12:[----] [--] 'hw/sparc64/niagara: Model the I/O Bridge with the 'unimplemented_device''
010/12:[----] [--] 'hw/alpha/typhoon: Remove unuseful code'
011/12:[----] [--] 'hw/hppa/dino: Remove unuseful code'
012/12:[----] [--] 'hw/mips/malta: Remove unuseful code'
Philippe Mathieu-Daudé (12):
trace-events: Fix copy/paste typo
hw/timer/sun4v-rtc: Convert from DPRINTF() macro to trace events
hw/timer/sun4v-rtc: Use DeviceState::realize rather than
SysBusDevice::init
hw/ssi/xilinx_spi: Use DeviceState::realize rather than
SysBusDevice::init
hw/sh4/sh_pci: Use DeviceState::realize rather than SysBusDevice::init
hw/pci-host/bonito: Use DeviceState::realize rather than
SysBusDevice::init
hw/mips/gt64xxx_pci: Convert gt64120_reset() function into Device
reset method
hw/mips/gt64xxx_pci: Mark as bridge device
hw/sparc64/niagara: Model the I/O Bridge with the
'unimplemented_device'
hw/alpha/typhoon: Remove unuseful code
hw/hppa/dino: Remove unuseful code
hw/mips/malta: Remove unuseful code
default-configs/sparc64-softmmu.mak | 1 -
hw/alpha/typhoon.c | 13 -------------
hw/hppa/dino.c | 7 -------
hw/mips/gt64xxx_pci.c | 18 ++++--------------
hw/mips/mips_malta.c | 13 -------------
hw/pci-host/bonito.c | 9 +++------
hw/sh4/sh_pci.c | 20 +++++++++-----------
hw/sparc64/niagara.c | 4 ++--
hw/ssi/xilinx_spi.c | 9 +++------
hw/timer/sun4v-rtc.c | 23 ++++++++---------------
hw/timer/trace-events | 6 +++++-
11 files changed, 34 insertions(+), 89 deletions(-)
--
2.19.0
^ permalink raw reply [flat|nested] 17+ messages in thread
* [Qemu-devel] [PATCH v2 01/12] trace-events: Fix copy/paste typo
2018-10-02 21:25 [Qemu-devel] [PATCH v2 00/12] another SysBusDevice::init to Device::realize cleanup Philippe Mathieu-Daudé
@ 2018-10-02 21:25 ` Philippe Mathieu-Daudé
2018-10-02 21:25 ` [Qemu-devel] [PATCH v2 02/12] hw/timer/sun4v-rtc: Convert from DPRINTF() macro to trace events Philippe Mathieu-Daudé
` (11 subsequent siblings)
12 siblings, 0 replies; 17+ messages in thread
From: Philippe Mathieu-Daudé @ 2018-10-02 21:25 UTC (permalink / raw)
To: Peter Maydell, Cédric Le Goater
Cc: Philippe Mathieu-Daudé, qemu-devel, Eduardo Habkost
Missed while reviewing 5dd85b4b486.
Signed-off-by: Philippe Mathieu-Daudé <f4bug@amsat.org>
Reviewed-by: Peter Maydell <peter.maydell@linaro.org>
Reviewed-by: Cédric Le Goater <clg@kaod.org>
---
hw/timer/trace-events | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/hw/timer/trace-events b/hw/timer/trace-events
index fa4213df5b..ca9ad6321a 100644
--- a/hw/timer/trace-events
+++ b/hw/timer/trace-events
@@ -56,7 +56,7 @@ systick_timer_tick(void) "systick reload"
systick_read(uint64_t addr, uint32_t value, unsigned size) "systick read addr 0x%" PRIx64 " data 0x%" PRIx32 " size %u"
systick_write(uint64_t addr, uint32_t value, unsigned size) "systick write addr 0x%" PRIx64 " data 0x%" PRIx32 " size %u"
-# hw/char/cmsdk_apb_timer.c
+# hw/timer/cmsdk_apb_timer.c
cmsdk_apb_timer_read(uint64_t offset, uint64_t data, unsigned size) "CMSDK APB timer read: offset 0x%" PRIx64 " data 0x%" PRIx64 " size %u"
cmsdk_apb_timer_write(uint64_t offset, uint64_t data, unsigned size) "CMSDK APB timer write: offset 0x%" PRIx64 " data 0x%" PRIx64 " size %u"
cmsdk_apb_timer_reset(void) "CMSDK APB timer: reset"
--
2.19.0
^ permalink raw reply related [flat|nested] 17+ messages in thread
* [Qemu-devel] [PATCH v2 02/12] hw/timer/sun4v-rtc: Convert from DPRINTF() macro to trace events
2018-10-02 21:25 [Qemu-devel] [PATCH v2 00/12] another SysBusDevice::init to Device::realize cleanup Philippe Mathieu-Daudé
2018-10-02 21:25 ` [Qemu-devel] [PATCH v2 01/12] trace-events: Fix copy/paste typo Philippe Mathieu-Daudé
@ 2018-10-02 21:25 ` Philippe Mathieu-Daudé
2018-10-02 21:25 ` [Qemu-devel] [PATCH v2 03/12] hw/timer/sun4v-rtc: Use DeviceState::realize rather than SysBusDevice::init Philippe Mathieu-Daudé
` (10 subsequent siblings)
12 siblings, 0 replies; 17+ messages in thread
From: Philippe Mathieu-Daudé @ 2018-10-02 21:25 UTC (permalink / raw)
To: Peter Maydell, Cédric Le Goater
Cc: Philippe Mathieu-Daudé,
qemu-devel, Eduardo Habkost, Artyom Tarasenko
Signed-off-by: Philippe Mathieu-Daudé <f4bug@amsat.org>
Reviewed-by: Artyom Tarasenko <atar4qemu@gmail.com>
Reviewed-by: Cédric Le Goater <clg@kaod.org>
---
hw/timer/sun4v-rtc.c | 13 +++----------
hw/timer/trace-events | 4 ++++
2 files changed, 7 insertions(+), 10 deletions(-)
diff --git a/hw/timer/sun4v-rtc.c b/hw/timer/sun4v-rtc.c
index 310523225f..13be94f8da 100644
--- a/hw/timer/sun4v-rtc.c
+++ b/hw/timer/sun4v-rtc.c
@@ -14,15 +14,8 @@
#include "hw/sysbus.h"
#include "qemu/timer.h"
#include "hw/timer/sun4v-rtc.h"
+#include "trace.h"
-//#define DEBUG_SUN4V_RTC
-
-#ifdef DEBUG_SUN4V_RTC
-#define DPRINTF(fmt, ...) \
- do { printf("sun4v_rtc: " fmt , ## __VA_ARGS__); } while (0)
-#else
-#define DPRINTF(fmt, ...) do {} while (0)
-#endif
#define TYPE_SUN4V_RTC "sun4v_rtc"
#define SUN4V_RTC(obj) OBJECT_CHECK(Sun4vRtc, (obj), TYPE_SUN4V_RTC)
@@ -41,14 +34,14 @@ static uint64_t sun4v_rtc_read(void *opaque, hwaddr addr,
/* accessing the high 32 bits */
val >>= 32;
}
- DPRINTF("read from " TARGET_FMT_plx " val %lx\n", addr, val);
+ trace_sun4v_rtc_read(addr, val);
return val;
}
static void sun4v_rtc_write(void *opaque, hwaddr addr,
uint64_t val, unsigned size)
{
- DPRINTF("write 0x%x to " TARGET_FMT_plx "\n", (unsigned)val, addr);
+ trace_sun4v_rtc_read(addr, val);
}
static const MemoryRegionOps sun4v_rtc_ops = {
diff --git a/hw/timer/trace-events b/hw/timer/trace-events
index ca9ad6321a..75bd3b1042 100644
--- a/hw/timer/trace-events
+++ b/hw/timer/trace-events
@@ -66,5 +66,9 @@ cmsdk_apb_dualtimer_read(uint64_t offset, uint64_t data, unsigned size) "CMSDK A
cmsdk_apb_dualtimer_write(uint64_t offset, uint64_t data, unsigned size) "CMSDK APB dualtimer write: offset 0x%" PRIx64 " data 0x%" PRIx64 " size %u"
cmsdk_apb_dualtimer_reset(void) "CMSDK APB dualtimer: reset"
+# hw/timer/sun4v-rtc.c
+sun4v_rtc_read(uint64_t addr, uint64_t value) "read: addr 0x%" PRIx64 " value 0x%" PRIx64
+sun4v_rtc_write(uint64_t addr, uint64_t value) "write: addr 0x%" PRIx64 " value 0x%" PRIx64
+
# hw/timer/xlnx-zynqmp-rtc.c
xlnx_zynqmp_rtc_gettime(int year, int month, int day, int hour, int min, int sec) "Get time from host: %d-%d-%d %2d:%02d:%02d"
--
2.19.0
^ permalink raw reply related [flat|nested] 17+ messages in thread
* [Qemu-devel] [PATCH v2 03/12] hw/timer/sun4v-rtc: Use DeviceState::realize rather than SysBusDevice::init
2018-10-02 21:25 [Qemu-devel] [PATCH v2 00/12] another SysBusDevice::init to Device::realize cleanup Philippe Mathieu-Daudé
2018-10-02 21:25 ` [Qemu-devel] [PATCH v2 01/12] trace-events: Fix copy/paste typo Philippe Mathieu-Daudé
2018-10-02 21:25 ` [Qemu-devel] [PATCH v2 02/12] hw/timer/sun4v-rtc: Convert from DPRINTF() macro to trace events Philippe Mathieu-Daudé
@ 2018-10-02 21:25 ` Philippe Mathieu-Daudé
2018-10-02 21:25 ` [Qemu-devel] [PATCH v2 04/12] hw/ssi/xilinx_spi: " Philippe Mathieu-Daudé
` (9 subsequent siblings)
12 siblings, 0 replies; 17+ messages in thread
From: Philippe Mathieu-Daudé @ 2018-10-02 21:25 UTC (permalink / raw)
To: Peter Maydell, Cédric Le Goater
Cc: Philippe Mathieu-Daudé,
qemu-devel, Eduardo Habkost, Artyom Tarasenko
Move from the legacy SysBusDevice::init method to using DeviceState::realize.
Signed-off-by: Philippe Mathieu-Daudé <f4bug@amsat.org>
Reviewed-by: Thomas Huth <thuth@redhat.com>
Reviewed-by: Cédric Le Goater <clg@kaod.org>
---
hw/timer/sun4v-rtc.c | 10 +++++-----
1 file changed, 5 insertions(+), 5 deletions(-)
diff --git a/hw/timer/sun4v-rtc.c b/hw/timer/sun4v-rtc.c
index 13be94f8da..4e7f6a1eff 100644
--- a/hw/timer/sun4v-rtc.c
+++ b/hw/timer/sun4v-rtc.c
@@ -63,21 +63,21 @@ void sun4v_rtc_init(hwaddr addr)
sysbus_mmio_map(s, 0, addr);
}
-static int sun4v_rtc_init1(SysBusDevice *dev)
+static void sun4v_rtc_realize(DeviceState *dev, Error **errp)
{
+ SysBusDevice *sbd = SYS_BUS_DEVICE(dev);
Sun4vRtc *s = SUN4V_RTC(dev);
memory_region_init_io(&s->iomem, OBJECT(s), &sun4v_rtc_ops, s,
"sun4v-rtc", 0x08ULL);
- sysbus_init_mmio(dev, &s->iomem);
- return 0;
+ sysbus_init_mmio(sbd, &s->iomem);
}
static void sun4v_rtc_class_init(ObjectClass *klass, void *data)
{
- SysBusDeviceClass *k = SYS_BUS_DEVICE_CLASS(klass);
+ DeviceClass *dc = DEVICE_CLASS(klass);
- k->init = sun4v_rtc_init1;
+ dc->realize = sun4v_rtc_realize;
}
static const TypeInfo sun4v_rtc_info = {
--
2.19.0
^ permalink raw reply related [flat|nested] 17+ messages in thread
* [Qemu-devel] [PATCH v2 04/12] hw/ssi/xilinx_spi: Use DeviceState::realize rather than SysBusDevice::init
2018-10-02 21:25 [Qemu-devel] [PATCH v2 00/12] another SysBusDevice::init to Device::realize cleanup Philippe Mathieu-Daudé
` (2 preceding siblings ...)
2018-10-02 21:25 ` [Qemu-devel] [PATCH v2 03/12] hw/timer/sun4v-rtc: Use DeviceState::realize rather than SysBusDevice::init Philippe Mathieu-Daudé
@ 2018-10-02 21:25 ` Philippe Mathieu-Daudé
2018-10-02 21:25 ` [Qemu-devel] [PATCH v2 05/12] hw/sh4/sh_pci: " Philippe Mathieu-Daudé
` (8 subsequent siblings)
12 siblings, 0 replies; 17+ messages in thread
From: Philippe Mathieu-Daudé @ 2018-10-02 21:25 UTC (permalink / raw)
To: Peter Maydell, Cédric Le Goater
Cc: Philippe Mathieu-Daudé,
qemu-devel, Eduardo Habkost, Alistair Francis, Peter Crosthwaite
Move from the legacy SysBusDevice::init method to using DeviceState::realize.
Signed-off-by: Philippe Mathieu-Daudé <f4bug@amsat.org>
Reviewed-by: Thomas Huth <thuth@redhat.com>
Reviewed-by: Cédric Le Goater <clg@kaod.org>
---
hw/ssi/xilinx_spi.c | 9 +++------
1 file changed, 3 insertions(+), 6 deletions(-)
diff --git a/hw/ssi/xilinx_spi.c b/hw/ssi/xilinx_spi.c
index 83585bc8b2..3dae303d5b 100644
--- a/hw/ssi/xilinx_spi.c
+++ b/hw/ssi/xilinx_spi.c
@@ -319,9 +319,9 @@ static const MemoryRegionOps spi_ops = {
}
};
-static int xilinx_spi_init(SysBusDevice *sbd)
+static void xilinx_spi_realize(DeviceState *dev, Error **errp)
{
- DeviceState *dev = DEVICE(sbd);
+ SysBusDevice *sbd = SYS_BUS_DEVICE(dev);
XilinxSPI *s = XILINX_SPI(dev);
int i;
@@ -344,8 +344,6 @@ static int xilinx_spi_init(SysBusDevice *sbd)
fifo8_create(&s->tx_fifo, FIFO_CAPACITY);
fifo8_create(&s->rx_fifo, FIFO_CAPACITY);
-
- return 0;
}
static const VMStateDescription vmstate_xilinx_spi = {
@@ -368,9 +366,8 @@ static Property xilinx_spi_properties[] = {
static void xilinx_spi_class_init(ObjectClass *klass, void *data)
{
DeviceClass *dc = DEVICE_CLASS(klass);
- SysBusDeviceClass *k = SYS_BUS_DEVICE_CLASS(klass);
- k->init = xilinx_spi_init;
+ dc->realize = xilinx_spi_realize;
dc->reset = xlx_spi_reset;
dc->props = xilinx_spi_properties;
dc->vmsd = &vmstate_xilinx_spi;
--
2.19.0
^ permalink raw reply related [flat|nested] 17+ messages in thread
* [Qemu-devel] [PATCH v2 05/12] hw/sh4/sh_pci: Use DeviceState::realize rather than SysBusDevice::init
2018-10-02 21:25 [Qemu-devel] [PATCH v2 00/12] another SysBusDevice::init to Device::realize cleanup Philippe Mathieu-Daudé
` (3 preceding siblings ...)
2018-10-02 21:25 ` [Qemu-devel] [PATCH v2 04/12] hw/ssi/xilinx_spi: " Philippe Mathieu-Daudé
@ 2018-10-02 21:25 ` Philippe Mathieu-Daudé
2018-10-05 12:12 ` Peter Maydell
2018-10-02 21:25 ` [Qemu-devel] [PATCH v2 06/12] hw/pci-host/bonito: " Philippe Mathieu-Daudé
` (7 subsequent siblings)
12 siblings, 1 reply; 17+ messages in thread
From: Philippe Mathieu-Daudé @ 2018-10-02 21:25 UTC (permalink / raw)
To: Peter Maydell, Cédric Le Goater
Cc: Philippe Mathieu-Daudé, qemu-devel, Eduardo Habkost, Aurelien Jarno
Move from the legacy SysBusDevice::init method to using DeviceState::realize.
Signed-off-by: Philippe Mathieu-Daudé <f4bug@amsat.org>
---
hw/sh4/sh_pci.c | 20 +++++++++-----------
1 file changed, 9 insertions(+), 11 deletions(-)
diff --git a/hw/sh4/sh_pci.c b/hw/sh4/sh_pci.c
index 4ec2e35500..379d0685ed 100644
--- a/hw/sh4/sh_pci.c
+++ b/hw/sh4/sh_pci.c
@@ -120,16 +120,15 @@ static void sh_pci_set_irq(void *opaque, int irq_num, int level)
qemu_set_irq(pic[irq_num], level);
}
-static int sh_pci_device_init(SysBusDevice *dev)
+static void sh_pci_device_realize(DeviceState *dev, Error **errp)
{
- PCIHostState *phb;
- SHPCIState *s;
+ SysBusDevice *sbd = SYS_BUS_DEVICE(dev);
+ SHPCIState *s = SH_PCI_HOST_BRIDGE(dev);
+ PCIHostState *phb = PCI_HOST_BRIDGE(s);
int i;
- s = SH_PCI_HOST_BRIDGE(dev);
- phb = PCI_HOST_BRIDGE(s);
for (i = 0; i < 4; i++) {
- sysbus_init_irq(dev, &s->irq[i]);
+ sysbus_init_irq(sbd, &s->irq[i]);
}
phb->bus = pci_register_root_bus(DEVICE(dev), "pci",
sh_pci_set_irq, sh_pci_map_irq,
@@ -143,13 +142,12 @@ static int sh_pci_device_init(SysBusDevice *dev)
&s->memconfig_p4, 0, 0x224);
memory_region_init_alias(&s->isa, OBJECT(s), "sh_pci.isa",
get_system_io(), 0, 0x40000);
- sysbus_init_mmio(dev, &s->memconfig_p4);
- sysbus_init_mmio(dev, &s->memconfig_a7);
+ sysbus_init_mmio(sbd, &s->memconfig_p4);
+ sysbus_init_mmio(sbd, &s->memconfig_a7);
s->iobr = 0xfe240000;
memory_region_add_subregion(get_system_memory(), s->iobr, &s->isa);
s->dev = pci_create_simple(phb->bus, PCI_DEVFN(0, 0), "sh_pci_host");
- return 0;
}
static void sh_pci_host_realize(PCIDevice *d, Error **errp)
@@ -187,9 +185,9 @@ static const TypeInfo sh_pci_host_info = {
static void sh_pci_device_class_init(ObjectClass *klass, void *data)
{
- SysBusDeviceClass *sdc = SYS_BUS_DEVICE_CLASS(klass);
+ DeviceClass *dc = DEVICE_CLASS(klass);
- sdc->init = sh_pci_device_init;
+ dc->realize = sh_pci_device_realize;
}
static const TypeInfo sh_pci_device_info = {
--
2.19.0
^ permalink raw reply related [flat|nested] 17+ messages in thread
* [Qemu-devel] [PATCH v2 06/12] hw/pci-host/bonito: Use DeviceState::realize rather than SysBusDevice::init
2018-10-02 21:25 [Qemu-devel] [PATCH v2 00/12] another SysBusDevice::init to Device::realize cleanup Philippe Mathieu-Daudé
` (4 preceding siblings ...)
2018-10-02 21:25 ` [Qemu-devel] [PATCH v2 05/12] hw/sh4/sh_pci: " Philippe Mathieu-Daudé
@ 2018-10-02 21:25 ` Philippe Mathieu-Daudé
2018-10-05 12:22 ` Peter Maydell
2018-10-02 21:25 ` [Qemu-devel] [PATCH v2 07/12] hw/mips/gt64xxx_pci: Convert gt64120_reset() function into Device reset method Philippe Mathieu-Daudé
` (6 subsequent siblings)
12 siblings, 1 reply; 17+ messages in thread
From: Philippe Mathieu-Daudé @ 2018-10-02 21:25 UTC (permalink / raw)
To: Peter Maydell, Cédric Le Goater
Cc: Philippe Mathieu-Daudé, qemu-devel, Eduardo Habkost
Move from the legacy SysBusDevice::init method to using DeviceState::realize.
Signed-off-by: Philippe Mathieu-Daudé <f4bug@amsat.org>
---
hw/pci-host/bonito.c | 9 +++------
1 file changed, 3 insertions(+), 6 deletions(-)
diff --git a/hw/pci-host/bonito.c b/hw/pci-host/bonito.c
index 9868e2eccc..9f33582706 100644
--- a/hw/pci-host/bonito.c
+++ b/hw/pci-host/bonito.c
@@ -595,7 +595,7 @@ static const VMStateDescription vmstate_bonito = {
}
};
-static int bonito_pcihost_initfn(SysBusDevice *dev)
+static void bonito_pcihost_realize(DeviceState *dev, Error **errp)
{
PCIHostState *phb = PCI_HOST_BRIDGE(dev);
@@ -603,8 +603,6 @@ static int bonito_pcihost_initfn(SysBusDevice *dev)
pci_bonito_set_irq, pci_bonito_map_irq,
dev, get_system_memory(), get_system_io(),
0x28, 32, TYPE_PCI_BUS);
-
- return 0;
}
static void bonito_realize(PCIDevice *dev, Error **errp)
@@ -684,7 +682,6 @@ PCIBus *bonito_init(qemu_irq *pic)
pcihost->pic = pic;
qdev_init_nofail(dev);
- /* set the pcihost pointer before bonito_initfn is called */
d = pci_create(phb->bus, PCI_DEVFN(0, 0), TYPE_PCI_BONITO);
s = PCI_BONITO(d);
s->pcihost = pcihost;
@@ -726,9 +723,9 @@ static const TypeInfo bonito_info = {
static void bonito_pcihost_class_init(ObjectClass *klass, void *data)
{
- SysBusDeviceClass *k = SYS_BUS_DEVICE_CLASS(klass);
+ DeviceClass *dc = DEVICE_CLASS(klass);
- k->init = bonito_pcihost_initfn;
+ dc->realize = bonito_pcihost_realize;
}
static const TypeInfo bonito_pcihost_info = {
--
2.19.0
^ permalink raw reply related [flat|nested] 17+ messages in thread
* [Qemu-devel] [PATCH v2 07/12] hw/mips/gt64xxx_pci: Convert gt64120_reset() function into Device reset method
2018-10-02 21:25 [Qemu-devel] [PATCH v2 00/12] another SysBusDevice::init to Device::realize cleanup Philippe Mathieu-Daudé
` (5 preceding siblings ...)
2018-10-02 21:25 ` [Qemu-devel] [PATCH v2 06/12] hw/pci-host/bonito: " Philippe Mathieu-Daudé
@ 2018-10-02 21:25 ` Philippe Mathieu-Daudé
2018-10-02 21:25 ` [Qemu-devel] [PATCH v2 08/12] hw/mips/gt64xxx_pci: Mark as bridge device Philippe Mathieu-Daudé
` (5 subsequent siblings)
12 siblings, 0 replies; 17+ messages in thread
From: Philippe Mathieu-Daudé @ 2018-10-02 21:25 UTC (permalink / raw)
To: Peter Maydell, Cédric Le Goater
Cc: Philippe Mathieu-Daudé,
qemu-devel, Eduardo Habkost, Aurelien Jarno, Aleksandar Markovic
Convert the gt64120_reset() function into a proper Device reset method.
Signed-off-by: Philippe Mathieu-Daudé <f4bug@amsat.org>
Reviewed-by: Peter Maydell <peter.maydell@linaro.org>
Reviewed-by: Cédric Le Goater <clg@kaod.org>
---
hw/mips/gt64xxx_pci.c | 17 +++--------------
1 file changed, 3 insertions(+), 14 deletions(-)
diff --git a/hw/mips/gt64xxx_pci.c b/hw/mips/gt64xxx_pci.c
index 24ad0ad024..dcd1a66329 100644
--- a/hw/mips/gt64xxx_pci.c
+++ b/hw/mips/gt64xxx_pci.c
@@ -992,9 +992,9 @@ static void gt64120_pci_set_irq(void *opaque, int irq_num, int level)
}
-static void gt64120_reset(void *opaque)
+static void gt64120_reset(DeviceState *dev)
{
- GT64120State *s = opaque;
+ GT64120State *s = GT64120_PCI_HOST_BRIDGE(dev);
/* FIXME: Malta specific hw assumptions ahead */
@@ -1184,16 +1184,6 @@ PCIBus *gt64120_register(qemu_irq *pic)
return phb->bus;
}
-static int gt64120_init(SysBusDevice *dev)
-{
- GT64120State *s;
-
- s = GT64120_PCI_HOST_BRIDGE(dev);
-
- qemu_register_reset(gt64120_reset, s);
- return 0;
-}
-
static void gt64120_pci_realize(PCIDevice *d, Error **errp)
{
/* FIXME: Malta specific hw assumptions ahead */
@@ -1241,9 +1231,8 @@ static const TypeInfo gt64120_pci_info = {
static void gt64120_class_init(ObjectClass *klass, void *data)
{
DeviceClass *dc = DEVICE_CLASS(klass);
- SysBusDeviceClass *sdc = SYS_BUS_DEVICE_CLASS(klass);
- sdc->init = gt64120_init;
+ dc->reset = gt64120_reset;
dc->vmsd = &vmstate_gt64120;
}
--
2.19.0
^ permalink raw reply related [flat|nested] 17+ messages in thread
* [Qemu-devel] [PATCH v2 08/12] hw/mips/gt64xxx_pci: Mark as bridge device
2018-10-02 21:25 [Qemu-devel] [PATCH v2 00/12] another SysBusDevice::init to Device::realize cleanup Philippe Mathieu-Daudé
` (6 preceding siblings ...)
2018-10-02 21:25 ` [Qemu-devel] [PATCH v2 07/12] hw/mips/gt64xxx_pci: Convert gt64120_reset() function into Device reset method Philippe Mathieu-Daudé
@ 2018-10-02 21:25 ` Philippe Mathieu-Daudé
2018-10-02 21:25 ` [Qemu-devel] [PATCH v2 09/12] hw/sparc64/niagara: Model the I/O Bridge with the 'unimplemented_device' Philippe Mathieu-Daudé
` (4 subsequent siblings)
12 siblings, 0 replies; 17+ messages in thread
From: Philippe Mathieu-Daudé @ 2018-10-02 21:25 UTC (permalink / raw)
To: Peter Maydell, Cédric Le Goater
Cc: Philippe Mathieu-Daudé,
qemu-devel, Eduardo Habkost, Aurelien Jarno, Aleksandar Markovic
The gt64120 is currently listed as uncategorized device.
Mark it as bridge device.
Signed-off-by: Philippe Mathieu-Daudé <f4bug@amsat.org>
Reviewed-by: Peter Maydell <peter.maydell@linaro.org>
Reviewed-by: Cédric Le Goater <clg@kaod.org>
---
hw/mips/gt64xxx_pci.c | 1 +
1 file changed, 1 insertion(+)
diff --git a/hw/mips/gt64xxx_pci.c b/hw/mips/gt64xxx_pci.c
index dcd1a66329..1cd8aac658 100644
--- a/hw/mips/gt64xxx_pci.c
+++ b/hw/mips/gt64xxx_pci.c
@@ -1232,6 +1232,7 @@ static void gt64120_class_init(ObjectClass *klass, void *data)
{
DeviceClass *dc = DEVICE_CLASS(klass);
+ set_bit(DEVICE_CATEGORY_BRIDGE, dc->categories);
dc->reset = gt64120_reset;
dc->vmsd = &vmstate_gt64120;
}
--
2.19.0
^ permalink raw reply related [flat|nested] 17+ messages in thread
* [Qemu-devel] [PATCH v2 09/12] hw/sparc64/niagara: Model the I/O Bridge with the 'unimplemented_device'
2018-10-02 21:25 [Qemu-devel] [PATCH v2 00/12] another SysBusDevice::init to Device::realize cleanup Philippe Mathieu-Daudé
` (7 preceding siblings ...)
2018-10-02 21:25 ` [Qemu-devel] [PATCH v2 08/12] hw/mips/gt64xxx_pci: Mark as bridge device Philippe Mathieu-Daudé
@ 2018-10-02 21:25 ` Philippe Mathieu-Daudé
2018-10-02 21:25 ` [Qemu-devel] [PATCH v2 10/12] hw/alpha/typhoon: Remove unuseful code Philippe Mathieu-Daudé
` (3 subsequent siblings)
12 siblings, 0 replies; 17+ messages in thread
From: Philippe Mathieu-Daudé @ 2018-10-02 21:25 UTC (permalink / raw)
To: Peter Maydell, Cédric Le Goater
Cc: Philippe Mathieu-Daudé,
qemu-devel, Eduardo Habkost, Artyom Tarasenko, Mark Cave-Ayland
Since the I/O Bridge device is not implemented, Use the
TYPE_UNIMPLEMENTED_DEVICE which suits better: if the user
asks for 'unimp' warnings via the -d option then all accesses
will generate logging.
Signed-off-by: Philippe Mathieu-Daudé <f4bug@amsat.org>
Reviewed-by: Artyom Tarasenko <atar4qemu@gmail.com>
---
default-configs/sparc64-softmmu.mak | 1 -
hw/sparc64/niagara.c | 4 ++--
2 files changed, 2 insertions(+), 3 deletions(-)
diff --git a/default-configs/sparc64-softmmu.mak b/default-configs/sparc64-softmmu.mak
index 52edafe547..ce63d47046 100644
--- a/default-configs/sparc64-softmmu.mak
+++ b/default-configs/sparc64-softmmu.mak
@@ -16,5 +16,4 @@ CONFIG_SIMBA=y
CONFIG_SUNHME=y
CONFIG_MC146818RTC=y
CONFIG_ISA_TESTDEV=y
-CONFIG_EMPTY_SLOT=y
CONFIG_SUN4V_RTC=y
diff --git a/hw/sparc64/niagara.c b/hw/sparc64/niagara.c
index 4fa8cb2904..f8a856f611 100644
--- a/hw/sparc64/niagara.c
+++ b/hw/sparc64/niagara.c
@@ -29,7 +29,7 @@
#include "hw/hw.h"
#include "hw/boards.h"
#include "hw/char/serial.h"
-#include "hw/empty_slot.h"
+#include "hw/misc/unimp.h"
#include "hw/loader.h"
#include "hw/sparc/sparc64.h"
#include "hw/timer/sun4v-rtc.h"
@@ -161,7 +161,7 @@ static void niagara_init(MachineState *machine)
serial_mm_init(sysmem, NIAGARA_UART_BASE, 0, NULL, 115200,
serial_hd(0), DEVICE_BIG_ENDIAN);
}
- empty_slot_init(NIAGARA_IOBBASE, NIAGARA_IOBSIZE);
+ create_unimplemented_device("sun4v-iob", NIAGARA_IOBBASE, NIAGARA_IOBSIZE);
sun4v_rtc_init(NIAGARA_RTC_BASE);
}
--
2.19.0
^ permalink raw reply related [flat|nested] 17+ messages in thread
* [Qemu-devel] [PATCH v2 10/12] hw/alpha/typhoon: Remove unuseful code
2018-10-02 21:25 [Qemu-devel] [PATCH v2 00/12] another SysBusDevice::init to Device::realize cleanup Philippe Mathieu-Daudé
` (8 preceding siblings ...)
2018-10-02 21:25 ` [Qemu-devel] [PATCH v2 09/12] hw/sparc64/niagara: Model the I/O Bridge with the 'unimplemented_device' Philippe Mathieu-Daudé
@ 2018-10-02 21:25 ` Philippe Mathieu-Daudé
2018-10-02 21:25 ` [Qemu-devel] [PATCH v2 11/12] hw/hppa/dino: " Philippe Mathieu-Daudé
` (2 subsequent siblings)
12 siblings, 0 replies; 17+ messages in thread
From: Philippe Mathieu-Daudé @ 2018-10-02 21:25 UTC (permalink / raw)
To: Peter Maydell, Cédric Le Goater
Cc: Philippe Mathieu-Daudé,
qemu-devel, Eduardo Habkost, Richard Henderson
Signed-off-by: Philippe Mathieu-Daudé <f4bug@amsat.org>
Reviewed-by: Thomas Huth <thuth@redhat.com>
---
hw/alpha/typhoon.c | 13 -------------
1 file changed, 13 deletions(-)
diff --git a/hw/alpha/typhoon.c b/hw/alpha/typhoon.c
index d74b5b55e1..8004afe45b 100644
--- a/hw/alpha/typhoon.c
+++ b/hw/alpha/typhoon.c
@@ -932,23 +932,10 @@ PCIBus *typhoon_init(ram_addr_t ram_size, ISABus **isa_bus,
return b;
}
-static int typhoon_pcihost_init(SysBusDevice *dev)
-{
- return 0;
-}
-
-static void typhoon_pcihost_class_init(ObjectClass *klass, void *data)
-{
- SysBusDeviceClass *k = SYS_BUS_DEVICE_CLASS(klass);
-
- k->init = typhoon_pcihost_init;
-}
-
static const TypeInfo typhoon_pcihost_info = {
.name = TYPE_TYPHOON_PCI_HOST_BRIDGE,
.parent = TYPE_PCI_HOST_BRIDGE,
.instance_size = sizeof(TyphoonState),
- .class_init = typhoon_pcihost_class_init,
};
static void typhoon_iommu_memory_region_class_init(ObjectClass *klass,
--
2.19.0
^ permalink raw reply related [flat|nested] 17+ messages in thread
* [Qemu-devel] [PATCH v2 11/12] hw/hppa/dino: Remove unuseful code
2018-10-02 21:25 [Qemu-devel] [PATCH v2 00/12] another SysBusDevice::init to Device::realize cleanup Philippe Mathieu-Daudé
` (9 preceding siblings ...)
2018-10-02 21:25 ` [Qemu-devel] [PATCH v2 10/12] hw/alpha/typhoon: Remove unuseful code Philippe Mathieu-Daudé
@ 2018-10-02 21:25 ` Philippe Mathieu-Daudé
2018-10-02 21:25 ` [Qemu-devel] [PATCH v2 12/12] hw/mips/malta: " Philippe Mathieu-Daudé
2018-10-09 15:01 ` [Qemu-devel] [PATCH v2 00/12] another SysBusDevice::init to Device::realize cleanup Philippe Mathieu-Daudé
12 siblings, 0 replies; 17+ messages in thread
From: Philippe Mathieu-Daudé @ 2018-10-02 21:25 UTC (permalink / raw)
To: Peter Maydell, Cédric Le Goater
Cc: Philippe Mathieu-Daudé,
qemu-devel, Eduardo Habkost, Richard Henderson
Signed-off-by: Philippe Mathieu-Daudé <f4bug@amsat.org>
Reviewed-by: Thomas Huth <thuth@redhat.com>
---
hw/hppa/dino.c | 7 -------
1 file changed, 7 deletions(-)
diff --git a/hw/hppa/dino.c b/hw/hppa/dino.c
index 564b938e3a..31e09942b5 100644
--- a/hw/hppa/dino.c
+++ b/hw/hppa/dino.c
@@ -488,17 +488,10 @@ PCIBus *dino_init(MemoryRegion *addr_space,
return b;
}
-static int dino_pcihost_init(SysBusDevice *dev)
-{
- return 0;
-}
-
static void dino_pcihost_class_init(ObjectClass *klass, void *data)
{
- SysBusDeviceClass *k = SYS_BUS_DEVICE_CLASS(klass);
DeviceClass *dc = DEVICE_CLASS(klass);
- k->init = dino_pcihost_init;
dc->vmsd = &vmstate_dino;
}
--
2.19.0
^ permalink raw reply related [flat|nested] 17+ messages in thread
* [Qemu-devel] [PATCH v2 12/12] hw/mips/malta: Remove unuseful code
2018-10-02 21:25 [Qemu-devel] [PATCH v2 00/12] another SysBusDevice::init to Device::realize cleanup Philippe Mathieu-Daudé
` (10 preceding siblings ...)
2018-10-02 21:25 ` [Qemu-devel] [PATCH v2 11/12] hw/hppa/dino: " Philippe Mathieu-Daudé
@ 2018-10-02 21:25 ` Philippe Mathieu-Daudé
2018-10-09 15:01 ` [Qemu-devel] [PATCH v2 00/12] another SysBusDevice::init to Device::realize cleanup Philippe Mathieu-Daudé
12 siblings, 0 replies; 17+ messages in thread
From: Philippe Mathieu-Daudé @ 2018-10-02 21:25 UTC (permalink / raw)
To: Peter Maydell, Cédric Le Goater
Cc: Philippe Mathieu-Daudé,
qemu-devel, Eduardo Habkost, Aurelien Jarno, Aleksandar Markovic
Signed-off-by: Philippe Mathieu-Daudé <f4bug@amsat.org>
Reviewed-by: Thomas Huth <thuth@redhat.com>
---
hw/mips/mips_malta.c | 13 -------------
1 file changed, 13 deletions(-)
diff --git a/hw/mips/mips_malta.c b/hw/mips/mips_malta.c
index 40041d5ec0..89ca6db94b 100644
--- a/hw/mips/mips_malta.c
+++ b/hw/mips/mips_malta.c
@@ -1422,23 +1422,10 @@ void mips_malta_init(MachineState *machine)
pci_vga_init(pci_bus);
}
-static int mips_malta_sysbus_device_init(SysBusDevice *sysbusdev)
-{
- return 0;
-}
-
-static void mips_malta_class_init(ObjectClass *klass, void *data)
-{
- SysBusDeviceClass *k = SYS_BUS_DEVICE_CLASS(klass);
-
- k->init = mips_malta_sysbus_device_init;
-}
-
static const TypeInfo mips_malta_device = {
.name = TYPE_MIPS_MALTA,
.parent = TYPE_SYS_BUS_DEVICE,
.instance_size = sizeof(MaltaState),
- .class_init = mips_malta_class_init,
};
static void mips_malta_machine_init(MachineClass *mc)
--
2.19.0
^ permalink raw reply related [flat|nested] 17+ messages in thread
* Re: [Qemu-devel] [PATCH v2 05/12] hw/sh4/sh_pci: Use DeviceState::realize rather than SysBusDevice::init
2018-10-02 21:25 ` [Qemu-devel] [PATCH v2 05/12] hw/sh4/sh_pci: " Philippe Mathieu-Daudé
@ 2018-10-05 12:12 ` Peter Maydell
0 siblings, 0 replies; 17+ messages in thread
From: Peter Maydell @ 2018-10-05 12:12 UTC (permalink / raw)
To: Philippe Mathieu-Daudé
Cc: Cédric Le Goater, QEMU Developers, Eduardo Habkost, Aurelien Jarno
On 2 October 2018 at 22:25, Philippe Mathieu-Daudé <f4bug@amsat.org> wrote:
> Move from the legacy SysBusDevice::init method to using DeviceState::realize.
>
> Signed-off-by: Philippe Mathieu-Daudé <f4bug@amsat.org>
> ---
> hw/sh4/sh_pci.c | 20 +++++++++-----------
> 1 file changed, 9 insertions(+), 11 deletions(-)
>
> diff --git a/hw/sh4/sh_pci.c b/hw/sh4/sh_pci.c
> index 4ec2e35500..379d0685ed 100644
> --- a/hw/sh4/sh_pci.c
> +++ b/hw/sh4/sh_pci.c
> @@ -120,16 +120,15 @@ static void sh_pci_set_irq(void *opaque, int irq_num, int level)
> qemu_set_irq(pic[irq_num], level);
> }
>
> -static int sh_pci_device_init(SysBusDevice *dev)
> +static void sh_pci_device_realize(DeviceState *dev, Error **errp)
> {
> - PCIHostState *phb;
> - SHPCIState *s;
> + SysBusDevice *sbd = SYS_BUS_DEVICE(dev);
> + SHPCIState *s = SH_PCI_HOST_BRIDGE(dev);
> + PCIHostState *phb = PCI_HOST_BRIDGE(s);
> int i;
>
> - s = SH_PCI_HOST_BRIDGE(dev);
> - phb = PCI_HOST_BRIDGE(s);
> for (i = 0; i < 4; i++) {
> - sysbus_init_irq(dev, &s->irq[i]);
> + sysbus_init_irq(sbd, &s->irq[i]);
> }
> phb->bus = pci_register_root_bus(DEVICE(dev), "pci",
> sh_pci_set_irq, sh_pci_map_irq,
> @@ -143,13 +142,12 @@ static int sh_pci_device_init(SysBusDevice *dev)
> &s->memconfig_p4, 0, 0x224);
> memory_region_init_alias(&s->isa, OBJECT(s), "sh_pci.isa",
> get_system_io(), 0, 0x40000);
> - sysbus_init_mmio(dev, &s->memconfig_p4);
> - sysbus_init_mmio(dev, &s->memconfig_a7);
> + sysbus_init_mmio(sbd, &s->memconfig_p4);
> + sysbus_init_mmio(sbd, &s->memconfig_a7);
> s->iobr = 0xfe240000;
> memory_region_add_subregion(get_system_memory(), s->iobr, &s->isa);
>
> s->dev = pci_create_simple(phb->bus, PCI_DEVFN(0, 0), "sh_pci_host");
> - return 0;
> }
>
> static void sh_pci_host_realize(PCIDevice *d, Error **errp)
> @@ -187,9 +185,9 @@ static const TypeInfo sh_pci_host_info = {
>
> static void sh_pci_device_class_init(ObjectClass *klass, void *data)
> {
> - SysBusDeviceClass *sdc = SYS_BUS_DEVICE_CLASS(klass);
> + DeviceClass *dc = DEVICE_CLASS(klass);
>
> - sdc->init = sh_pci_device_init;
> + dc->realize = sh_pci_device_realize;
> }
>
> static const TypeInfo sh_pci_device_info = {
> --
Reviewed-by: Peter Maydell <peter.maydell@linaro.org>
thanks
-- PMM
^ permalink raw reply [flat|nested] 17+ messages in thread
* Re: [Qemu-devel] [PATCH v2 06/12] hw/pci-host/bonito: Use DeviceState::realize rather than SysBusDevice::init
2018-10-02 21:25 ` [Qemu-devel] [PATCH v2 06/12] hw/pci-host/bonito: " Philippe Mathieu-Daudé
@ 2018-10-05 12:22 ` Peter Maydell
0 siblings, 0 replies; 17+ messages in thread
From: Peter Maydell @ 2018-10-05 12:22 UTC (permalink / raw)
To: Philippe Mathieu-Daudé
Cc: Cédric Le Goater, QEMU Developers, Eduardo Habkost
On 2 October 2018 at 22:25, Philippe Mathieu-Daudé <f4bug@amsat.org> wrote:
> Move from the legacy SysBusDevice::init method to using DeviceState::realize.
>
> Signed-off-by: Philippe Mathieu-Daudé <f4bug@amsat.org>
> ---
> hw/pci-host/bonito.c | 9 +++------
> 1 file changed, 3 insertions(+), 6 deletions(-)
>
> diff --git a/hw/pci-host/bonito.c b/hw/pci-host/bonito.c
> index 9868e2eccc..9f33582706 100644
> --- a/hw/pci-host/bonito.c
> +++ b/hw/pci-host/bonito.c
> @@ -595,7 +595,7 @@ static const VMStateDescription vmstate_bonito = {
> }
> };
>
> -static int bonito_pcihost_initfn(SysBusDevice *dev)
> +static void bonito_pcihost_realize(DeviceState *dev, Error **errp)
> {
> PCIHostState *phb = PCI_HOST_BRIDGE(dev);
>
> @@ -603,8 +603,6 @@ static int bonito_pcihost_initfn(SysBusDevice *dev)
> pci_bonito_set_irq, pci_bonito_map_irq,
> dev, get_system_memory(), get_system_io(),
> 0x28, 32, TYPE_PCI_BUS);
> -
> - return 0;
> }
>
> static void bonito_realize(PCIDevice *dev, Error **errp)
> @@ -684,7 +682,6 @@ PCIBus *bonito_init(qemu_irq *pic)
> pcihost->pic = pic;
> qdev_init_nofail(dev);
>
> - /* set the pcihost pointer before bonito_initfn is called */
> d = pci_create(phb->bus, PCI_DEVFN(0, 0), TYPE_PCI_BONITO);
> s = PCI_BONITO(d);
> s->pcihost = pcihost;
> @@ -726,9 +723,9 @@ static const TypeInfo bonito_info = {
>
> static void bonito_pcihost_class_init(ObjectClass *klass, void *data)
> {
> - SysBusDeviceClass *k = SYS_BUS_DEVICE_CLASS(klass);
> + DeviceClass *dc = DEVICE_CLASS(klass);
>
> - k->init = bonito_pcihost_initfn;
> + dc->realize = bonito_pcihost_realize;
> }
>
> static const TypeInfo bonito_pcihost_info = {
> --
Reviewed-by: Peter Maydell <peter.maydell@linaro.org>
thanks
-- PMM
^ permalink raw reply [flat|nested] 17+ messages in thread
* Re: [Qemu-devel] [PATCH v2 00/12] another SysBusDevice::init to Device::realize cleanup
2018-10-02 21:25 [Qemu-devel] [PATCH v2 00/12] another SysBusDevice::init to Device::realize cleanup Philippe Mathieu-Daudé
` (11 preceding siblings ...)
2018-10-02 21:25 ` [Qemu-devel] [PATCH v2 12/12] hw/mips/malta: " Philippe Mathieu-Daudé
@ 2018-10-09 15:01 ` Philippe Mathieu-Daudé
2018-10-09 15:57 ` Eduardo Habkost
12 siblings, 1 reply; 17+ messages in thread
From: Philippe Mathieu-Daudé @ 2018-10-09 15:01 UTC (permalink / raw)
To: Eduardo Habkost; +Cc: Peter Maydell, Cédric Le Goater, qemu-devel
Hi Eduardo,
On 02/10/2018 23:25, Philippe Mathieu-Daudé wrote:
> Peter suggested [1] another crusade for this merge window,
> then Cédric jumped on his horse [2]. My turn on my dromedary.
>
> since v1:
> - let the empty_slot
> - sh4_pci and bonito use DeviceState::realize instead of PCIDevice::realize
> - reword niagara-iob commit message
>
> v1: https://lists.gnu.org/archive/html/qemu-devel/2018-10/msg00220.html
> - convert few devices to DeviceState::realize,
> - kill the empty_slot device,
> - remove unuseful class_init() code [RFC, do we want to keep this?]
> - few other minor fixes catched while editing
>
> Regards,
>
> Phil.
>
> [1] https://lists.gnu.org/archive/html/qemu-devel/2018-09/msg03605.html
> [2] https://lists.gnu.org/archive/html/qemu-devel/2018-10/msg00001.html
>
> 001/12:[----] [--] 'trace-events: Fix copy/paste typo'
> 002/12:[----] [--] 'hw/timer/sun4v-rtc: Convert from DPRINTF() macro to trace events'
> 003/12:[----] [--] 'hw/timer/sun4v-rtc: Use DeviceState::realize rather than SysBusDevice::init'
> 004/12:[----] [--] 'hw/ssi/xilinx_spi: Use DeviceState::realize rather than SysBusDevice::init'
> 005/12:[0006] [FC] 'hw/sh4/sh_pci: Use DeviceState::realize rather than SysBusDevice::init'
> 006/12:[0006] [FC] 'hw/pci-host/bonito: Use DeviceState::realize rather than SysBusDevice::init'
> 007/12:[----] [--] 'hw/mips/gt64xxx_pci: Convert gt64120_reset() function into Device reset method'
> 008/12:[----] [--] 'hw/mips/gt64xxx_pci: Mark as bridge device'
> 009/12:[----] [--] 'hw/sparc64/niagara: Model the I/O Bridge with the 'unimplemented_device''
> 010/12:[----] [--] 'hw/alpha/typhoon: Remove unuseful code'
> 011/12:[----] [--] 'hw/hppa/dino: Remove unuseful code'
> 012/12:[----] [--] 'hw/mips/malta: Remove unuseful code'
Can you take this via your machine-next tree?
Thanks,
Phil.
^ permalink raw reply [flat|nested] 17+ messages in thread
* Re: [Qemu-devel] [PATCH v2 00/12] another SysBusDevice::init to Device::realize cleanup
2018-10-09 15:01 ` [Qemu-devel] [PATCH v2 00/12] another SysBusDevice::init to Device::realize cleanup Philippe Mathieu-Daudé
@ 2018-10-09 15:57 ` Eduardo Habkost
0 siblings, 0 replies; 17+ messages in thread
From: Eduardo Habkost @ 2018-10-09 15:57 UTC (permalink / raw)
To: Philippe Mathieu-Daudé
Cc: Peter Maydell, Cédric Le Goater, qemu-devel
On Tue, Oct 09, 2018 at 05:01:49PM +0200, Philippe Mathieu-Daudé wrote:
> Hi Eduardo,
>
> On 02/10/2018 23:25, Philippe Mathieu-Daudé wrote:
> > Peter suggested [1] another crusade for this merge window,
> > then Cédric jumped on his horse [2]. My turn on my dromedary.
> >
> > since v1:
> > - let the empty_slot
> > - sh4_pci and bonito use DeviceState::realize instead of PCIDevice::realize
> > - reword niagara-iob commit message
> >
> > v1: https://lists.gnu.org/archive/html/qemu-devel/2018-10/msg00220.html
> > - convert few devices to DeviceState::realize,
> > - kill the empty_slot device,
> > - remove unuseful class_init() code [RFC, do we want to keep this?]
> > - few other minor fixes catched while editing
> >
> > Regards,
> >
> > Phil.
> >
> > [1] https://lists.gnu.org/archive/html/qemu-devel/2018-09/msg03605.html
> > [2] https://lists.gnu.org/archive/html/qemu-devel/2018-10/msg00001.html
> >
> > 001/12:[----] [--] 'trace-events: Fix copy/paste typo'
> > 002/12:[----] [--] 'hw/timer/sun4v-rtc: Convert from DPRINTF() macro to trace events'
> > 003/12:[----] [--] 'hw/timer/sun4v-rtc: Use DeviceState::realize rather than SysBusDevice::init'
> > 004/12:[----] [--] 'hw/ssi/xilinx_spi: Use DeviceState::realize rather than SysBusDevice::init'
> > 005/12:[0006] [FC] 'hw/sh4/sh_pci: Use DeviceState::realize rather than SysBusDevice::init'
> > 006/12:[0006] [FC] 'hw/pci-host/bonito: Use DeviceState::realize rather than SysBusDevice::init'
> > 007/12:[----] [--] 'hw/mips/gt64xxx_pci: Convert gt64120_reset() function into Device reset method'
> > 008/12:[----] [--] 'hw/mips/gt64xxx_pci: Mark as bridge device'
> > 009/12:[----] [--] 'hw/sparc64/niagara: Model the I/O Bridge with the 'unimplemented_device''
> > 010/12:[----] [--] 'hw/alpha/typhoon: Remove unuseful code'
> > 011/12:[----] [--] 'hw/hppa/dino: Remove unuseful code'
> > 012/12:[----] [--] 'hw/mips/malta: Remove unuseful code'
>
> Can you take this via your machine-next tree?
I'll do it. Thanks!
--
Eduardo
^ permalink raw reply [flat|nested] 17+ messages in thread
end of thread, other threads:[~2018-10-09 15:57 UTC | newest]
Thread overview: 17+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2018-10-02 21:25 [Qemu-devel] [PATCH v2 00/12] another SysBusDevice::init to Device::realize cleanup Philippe Mathieu-Daudé
2018-10-02 21:25 ` [Qemu-devel] [PATCH v2 01/12] trace-events: Fix copy/paste typo Philippe Mathieu-Daudé
2018-10-02 21:25 ` [Qemu-devel] [PATCH v2 02/12] hw/timer/sun4v-rtc: Convert from DPRINTF() macro to trace events Philippe Mathieu-Daudé
2018-10-02 21:25 ` [Qemu-devel] [PATCH v2 03/12] hw/timer/sun4v-rtc: Use DeviceState::realize rather than SysBusDevice::init Philippe Mathieu-Daudé
2018-10-02 21:25 ` [Qemu-devel] [PATCH v2 04/12] hw/ssi/xilinx_spi: " Philippe Mathieu-Daudé
2018-10-02 21:25 ` [Qemu-devel] [PATCH v2 05/12] hw/sh4/sh_pci: " Philippe Mathieu-Daudé
2018-10-05 12:12 ` Peter Maydell
2018-10-02 21:25 ` [Qemu-devel] [PATCH v2 06/12] hw/pci-host/bonito: " Philippe Mathieu-Daudé
2018-10-05 12:22 ` Peter Maydell
2018-10-02 21:25 ` [Qemu-devel] [PATCH v2 07/12] hw/mips/gt64xxx_pci: Convert gt64120_reset() function into Device reset method Philippe Mathieu-Daudé
2018-10-02 21:25 ` [Qemu-devel] [PATCH v2 08/12] hw/mips/gt64xxx_pci: Mark as bridge device Philippe Mathieu-Daudé
2018-10-02 21:25 ` [Qemu-devel] [PATCH v2 09/12] hw/sparc64/niagara: Model the I/O Bridge with the 'unimplemented_device' Philippe Mathieu-Daudé
2018-10-02 21:25 ` [Qemu-devel] [PATCH v2 10/12] hw/alpha/typhoon: Remove unuseful code Philippe Mathieu-Daudé
2018-10-02 21:25 ` [Qemu-devel] [PATCH v2 11/12] hw/hppa/dino: " Philippe Mathieu-Daudé
2018-10-02 21:25 ` [Qemu-devel] [PATCH v2 12/12] hw/mips/malta: " Philippe Mathieu-Daudé
2018-10-09 15:01 ` [Qemu-devel] [PATCH v2 00/12] another SysBusDevice::init to Device::realize cleanup Philippe Mathieu-Daudé
2018-10-09 15:57 ` Eduardo Habkost
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.