qemu-arm
[Top][All Lists]
Advanced

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

Re: [PATCH 11/14] aspeed: Switch to create_unimplemented_device_in


From: Peter Delevoryas
Subject: Re: [PATCH 11/14] aspeed: Switch to create_unimplemented_device_in
Date: Thu, 23 Jun 2022 18:32:42 +0000


> On Jun 23, 2022, at 5:56 AM, Peter Maydell <peter.maydell@linaro.org> wrote:
> 
> On Thu, 23 Jun 2022 at 13:04, Peter Delevoryas <pdel@fb.com> wrote:
>> 
>> Signed-off-by: Peter Delevoryas <pdel@fb.com>
>> ---
>> hw/arm/aspeed_ast10x0.c | 10 ++++------
>> hw/arm/aspeed_ast2600.c | 19 ++++++++++---------
>> hw/arm/aspeed_soc.c     |  9 +++++----
>> 3 files changed, 19 insertions(+), 19 deletions(-)
>> 
>> diff --git a/hw/arm/aspeed_ast10x0.c b/hw/arm/aspeed_ast10x0.c
>> index d259d30fc0..4e6688cc68 100644
>> --- a/hw/arm/aspeed_ast10x0.c
>> +++ b/hw/arm/aspeed_ast10x0.c
>> @@ -158,12 +158,10 @@ static void aspeed_soc_ast1030_realize(DeviceState 
>> *dev_soc, Error **errp)
>>     }
>> 
>>     /* General I/O memory space to catch all unimplemented device */
>> -    create_unimplemented_device("aspeed.sbc",
>> -                                sc->memmap[ASPEED_DEV_SBC],
>> -                                0x40000);
>> -    create_unimplemented_device("aspeed.io",
>> -                                sc->memmap[ASPEED_DEV_IOMEM],
>> -                                ASPEED_SOC_IOMEM_SIZE);
>> +    create_unimplemented_device_in("aspeed.sbc", sc->memmap[ASPEED_DEV_SBC],
>> +                                   0x40000, s->system_memory);
>> +    create_unimplemented_device_in("aspeed.io", 
>> sc->memmap[ASPEED_DEV_IOMEM],
>> +                                   ASPEED_SOC_IOMEM_SIZE, s->system_memory);
> 
> This is SoC code, so it should probably be handling its unimplemented
> devices by creating and mapping TYPE_UNIMPLEMENTED_DEVICE child
> objects directly, the same way it handles all its other child devices.

Ah, right. I’ll include a patch to create the device as a regular
child object, and after that it will probably make more sense to
remove “create_unimplemented_device_in” too and just do that
memory mapping directly. Especially since I’m going to remove
the “sysbus_mmio_map_overlap_in” function too.

> 
> thanks
> -- PMM


reply via email to

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