mirror of
https://github.com/Motorhead1991/qemu.git
synced 2025-08-07 01:33:56 -06:00
hw/*: Use type casting for SysBusDevice in NPCM7XX
A device shouldn't access its parent object which is QOM internal. Instead it should use type cast for this purporse. This patch fixes this issue for all NPCM7XX Devices. Signed-off-by: Hao Wu <wuhaotsh@google.com> Reviewed-by: Peter Maydell <peter.maydell@linaro.org> Message-id: 20210108190945.949196-7-wuhaotsh@google.com Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
This commit is contained in:
parent
73314f1384
commit
828d651c58
7 changed files with 7 additions and 7 deletions
|
@ -220,7 +220,7 @@ static void npcm7xx_gcr_init(Object *obj)
|
|||
|
||||
memory_region_init_io(&s->iomem, obj, &npcm7xx_gcr_ops, s,
|
||||
TYPE_NPCM7XX_GCR, 4 * KiB);
|
||||
sysbus_init_mmio(&s->parent, &s->iomem);
|
||||
sysbus_init_mmio(SYS_BUS_DEVICE(s), &s->iomem);
|
||||
}
|
||||
|
||||
static const VMStateDescription vmstate_npcm7xx_gcr = {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue