Message ID | 20250128104519.3981448-1-peter.maydell@linaro.org |
---|---|
Headers | show |
Series | hw/sd: QOMify omap-mmc, remove legacy APIs | expand |
On 28/1/25 11:45, Peter Maydell wrote: > This series QOMifies the omap-mmc device. The main reason for > this is that this device is now the only remaining in-tree > user of the legacy SD APIs defined in sdcard_legacy.h. > The first 8 patches QOMify the device and do some minor > cleanup on it. Patches 9 to 11 then remove the unused > legacy APIs, deleting sdcard_legacy.h entirely. This includes > letting us get rid of the me_no_qdev_me_kill_mammoth_with_rocks > codepaths in sd.c. Thanks for this long due cleanup! Series queued squashing: -- >8 -- diff --git a/hw/sd/omap_mmc.c b/hw/sd/omap_mmc.c index d31456ad236..bbe7b971bbe 100644 --- a/hw/sd/omap_mmc.c +++ b/hw/sd/omap_mmc.c @@ -71,3 +71,2 @@ typedef struct OMAPMMCState { int cdet_enable; - int cdet_state; qemu_irq cdet; @@ -611,9 +610,4 @@ static void omap_mmc_initfn(Object *obj) qdev_init_gpio_out_named(DEVICE(obj), &s->dma_rx_gpio, "dma-rx", 1); -} -static void omap_mmc_realize(DeviceState *dev, Error **errp) -{ - OMAPMMCState *s = OMAP_MMC(dev); - - qbus_init(&s->sdbus, sizeof(s->sdbus), TYPE_SD_BUS, dev, "sd-bus"); + qbus_init(&s->sdbus, sizeof(s->sdbus), TYPE_SD_BUS, DEVICE(obj), "sd-bus"); } @@ -622,3 +616,2 @@ static void omap_mmc_class_init(ObjectClass *oc, void *data) { - DeviceClass *dc = DEVICE_CLASS(oc); ResettableClass *rc = RESETTABLE_CLASS(oc); @@ -626,3 +619,2 @@ static void omap_mmc_class_init(ObjectClass *oc, void *data) rc->phases.hold = omap_mmc_reset_hold; - dc->realize = omap_mmc_realize; } ---