Re: [PATCH v1 4/5] hw/arm: Add Axiado SoC AX3005

Kuan-Jui Chiu <[email protected]>
Newsgroups org.nongnu.qemu-devel
Message-ID <[email protected]>
Hi Jack

Thanks for the test, could you share how you built and what the command 
was you used to test?

I did not see this issue on my side, maybe I missed something

B.R.
Howard

Jack Wang 於 2026/8/23 下午 06:33 寫道:
> CAUTION: This email originated from outside of the organization. Do not click links or open attachments unless you recognize the sender and know the content is safe.
>
>
> Hi Kuan-Jui
>
> I tested this series with ax3005-evb machine,the initialization did not complete.
> The process showed it repeatedly executing in 'ax3005_init'
>> +static const TypeInfo ax3005_soc_types[] = {
>> +    {
>> +        .name           = TYPE_AX3005_SOC,
>> +        .parent         = TYPE_SYS_BUS_DEVICE,
>> +        .instance_size  = sizeof(Ax3005SoCState),
>> +        .instance_init  = ax3005_init,
>> +        .class_init     = ax3005_class_init,
>> +    }
>> +};
> You add instance_size here but forget to add class_size. Then qemu defaultly use SysBusDeviceClass’s class_size cause of father-son relationship.
>
>> +typedef struct Ax3005SoCClass {
>> +    SysBusDeviceClass   parent;
>> +
>> +    uint32_t            num_cpus;
>> +} Ax3005SoCClass;
> Here your struct apparently extend SysBusDeviceClass field. I think it is the way why previous repeating behavior.After add class_size locally and rebuild the the machine completed initialization and responded to QMP commands successfully.
>
> Best regards :)
> Jack Wang
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.