Integrator/CP regression after QOM'ification of integratorcp.c
| Affects | Status | Importance | Assigned to | Milestone | |
|---|---|---|---|---|---|
| HelenOS branches |
New
|
Undecided
|
|||
| QEMU |
Fix Released
|
Undecided
|
Unassigned | ||
Bug Description
The following command line no longer works (i.e. the guest does not boot) with QEMU 2.7.0:
qemu-system-arm -M integratorcp -m 128M -kernel HelenOS-
The HelenOS image can be downloaded here:
http://
I did git bisect and came to this revision:
a1f42e0c9abc102
commit a1f42e0c9abc102
Author: xiaoqiang.zhao <zxq_yx_
Date: Mon Mar 7 15:05:44 2016 +0800
hw/arm: QOM'ify integratorcp.c
* Drop the use of old SysBus init function and use instance_init
* Remove the empty 'icp_pic_
Signed-off-by: xiaoqiang zhao <zxq_yx_
Reviewed-by: Peter Maydell <email address hidden>
Signed-off-by: Peter Maydell <email address hidden>
:040000 040000 b73418ea3fb69ed
Upon closer inspection, I discovered that for some reason s->memsz in integratorcm_init() is zero. In the last good revision, this value was 128. As a temporary workaround, hardcoding it to this expected value fixes the problem.

Turns out integratorcm_init() depends on the memsz property being already set, but that unfortunately is not the case as setting of memsz depends on integratorcm_init() having completed:
dev = qdev_create(NULL, TYPE_INTEGRATOR _CM); <= calls integratorcm_ init(), needs memsz prop_set_ uint32( dev, "memsz", ram_size >> 20); <= memsz set here, needs dev
qdev_