qemu-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Qemu-devel] finishing the transition away from SysBus init methods


From: Peter Maydell
Subject: [Qemu-devel] finishing the transition away from SysBus init methods
Date: Thu, 27 Sep 2018 09:11:07 +0100

I had a look at how many devices are still using the SysBus init
method (rather than the instance-init/realize pair), and it turns out
to be only 41, which I think is reasonably tractable for doing some
more conversions and completing this API transation.

The remaining devices are:

--- hw/display/g364fb.c
--- hw/intc/puv3_intc.c
--- hw/sh4/sh_pci.c
--- hw/net/lan9118.c
--- hw/net/lance.c
--- hw/net/xgmac.c
--- hw/net/smc91c111.c
--- hw/net/stellaris_enet.c
--- hw/net/mipsnet.c
--- hw/net/opencores_eth.c
--- hw/net/milkymist-minimac2.c
--- hw/net/etraxfs_eth.c
--- hw/alpha/typhoon.c
--- hw/gpio/puv3_gpio.c
--- hw/ppc/ppc4xx_pci.c
--- hw/ppc/ppc440_pcix.c
--- hw/core/empty_slot.c
--- hw/timer/sun4v-rtc.c
--- hw/timer/grlib_gptimer.c
--- hw/timer/etraxfs_timer.c
--- hw/timer/puv3_ost.c
--- hw/misc/puv3_pm.c
--- hw/misc/milkymist-hpdmc.c
--- hw/misc/milkymist-pfpu.c
--- hw/xen/xen_backend.c
--- hw/char/grlib_apbuart.c
--- hw/hppa/dino.c
--- hw/ssi/xilinx_spi.c
--- hw/usb/tusb6010.c
--- hw/pci-bridge/dec.c
--- hw/pci-host/bonito.c
--- hw/pci-host/ppce500.c
--- hw/input/pl050.c
--- hw/input/milkymist-softusb.c
--- hw/s390x/s390-pci-bus.c
--- hw/mips/mips_malta.c
--- hw/mips/gt64xxx_pci.c
--- hw/arm/musicpal.c
--- hw/nvram/ds1225y.c
--- hw/dma/puv3_dma.c
--- hw/block/onenand.c

I'll probably have a look at some of the arm devices on the
list at some point.

I would recommend that we do this by picking a handful
of related devices (eg same board/target arch) and converting
them, rather than trying to do the whole lot at once. We
can gradually whittle down the number of remaining devices.

I used this coccinelle script to identify the devices:
===begin===
// Find places which still use SysBusDeviceClass::init
// usage; spatch -sp_file find-sysbus-init.spatch -dir hw > diff.out
// then you can grep for the filename with grep '^---' diff.out

@@
SysBusDeviceClass *p;
expression E;
@@
* p->init = E

===endit===

thanks
-- PMM



reply via email to

[Prev in Thread] Current Thread [Next in Thread]