[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Qemu-devel] [PATCH qom-next 17/22] vexpress: Use cpu_arm_init() to obta
From: |
Andreas Färber |
Subject: |
[Qemu-devel] [PATCH qom-next 17/22] vexpress: Use cpu_arm_init() to obtain ARMCPU |
Date: |
Mon, 14 May 2012 19:32:04 +0200 |
Needed for arm_pic_init_cpu().
Signed-off-by: Andreas Färber <address@hidden>
---
hw/vexpress.c | 16 ++++++++--------
1 files changed, 8 insertions(+), 8 deletions(-)
diff --git a/hw/vexpress.c b/hw/vexpress.c
index 8b0ca42..4797c6a 100644
--- a/hw/vexpress.c
+++ b/hw/vexpress.c
@@ -159,7 +159,6 @@ static void a9_daughterboard_init(const VEDBoardInfo
*daughterboard,
const char *cpu_model,
qemu_irq *pic, uint32_t *proc_id)
{
- CPUARMState *env = NULL;
MemoryRegion *sysmem = get_system_memory();
MemoryRegion *ram = g_new(MemoryRegion, 1);
MemoryRegion *lowram = g_new(MemoryRegion, 1);
@@ -177,12 +176,12 @@ static void a9_daughterboard_init(const VEDBoardInfo
*daughterboard,
*proc_id = 0x0c000191;
for (n = 0; n < smp_cpus; n++) {
- env = cpu_init(cpu_model);
- if (!env) {
+ ARMCPU *cpu = cpu_arm_init(cpu_model);
+ if (!cpu) {
fprintf(stderr, "Unable to find CPU definition\n");
exit(1);
}
- irqp = arm_pic_init_cpu(env);
+ irqp = arm_pic_init_cpu(&cpu->env);
cpu_irq[n] = irqp[ARM_PIC_CPU_IRQ];
}
@@ -259,7 +258,6 @@ static void a15_daughterboard_init(const VEDBoardInfo
*daughterboard,
qemu_irq *pic, uint32_t *proc_id)
{
int n;
- CPUARMState *env = NULL;
MemoryRegion *sysmem = get_system_memory();
MemoryRegion *ram = g_new(MemoryRegion, 1);
MemoryRegion *sram = g_new(MemoryRegion, 1);
@@ -274,13 +272,15 @@ static void a15_daughterboard_init(const VEDBoardInfo
*daughterboard,
*proc_id = 0x14000217;
for (n = 0; n < smp_cpus; n++) {
+ ARMCPU *cpu;
qemu_irq *irqp;
- env = cpu_init(cpu_model);
- if (!env) {
+
+ cpu = cpu_arm_init(cpu_model);
+ if (!cpu) {
fprintf(stderr, "Unable to find CPU definition\n");
exit(1);
}
- irqp = arm_pic_init_cpu(env);
+ irqp = arm_pic_init_cpu(&cpu->env);
cpu_irq[n] = irqp[ARM_PIC_CPU_IRQ];
}
--
1.7.7
- [Qemu-devel] [PATCH qom-next 00/22] ARM: QOM cpu_reset() followups, Andreas Färber, 2012/05/14
- [Qemu-devel] [PATCH for-1.1 01/22] arm_boot: Fix typos in comment, Andreas Färber, 2012/05/14
- [Qemu-devel] [PATCH qom-next 04/22] mainstone: Rename PXA2xxState variable, Andreas Färber, 2012/05/14
- [Qemu-devel] [PATCH qom-next 16/22] realview: Use cpu_arm_init() to obtain ARMCPU, Andreas Färber, 2012/05/14
- [Qemu-devel] [PATCH qom-next 03/22] palm: Rename omap_mpu_state_s variable, Andreas Färber, 2012/05/14
- [Qemu-devel] [PATCH qom-next 17/22] vexpress: Use cpu_arm_init() to obtain ARMCPU,
Andreas Färber <=
- [Qemu-devel] [PATCH qom-next 21/22] pxa2xx_pic: Store ARMCPU in PXA2xxPICState, Andreas Färber, 2012/05/14
- [Qemu-devel] [PATCH qom-next 12/22] xilinx_zynq: Use cpu_arm_init() to obtain ARMCPU, Andreas Färber, 2012/05/14
- [Qemu-devel] [PATCH qom-next 06/22] tosa: Rename PXA2xxState variable, Andreas Färber, 2012/05/14
- [Qemu-devel] [PATCH qom-next 19/22] arm_pic: Pass ARMCPU to arm_pic_init_cpu(), Andreas Färber, 2012/05/14
- [Qemu-devel] [PATCH qom-next 20/22] pxa2xx: Pass ARMCPU to pxa2xx_pic_init(), Andreas Färber, 2012/05/14
- [Qemu-devel] [PATCH qom-next 14/22] arm_boot: Pass ARMCPU to arm_boot_info::secondary_cpu_reset_hook(), Andreas Färber, 2012/05/14
- [Qemu-devel] [PATCH qom-next 02/22] omap_sx1: Rename omap_mpu_state_s variable, Andreas Färber, 2012/05/14
- [Qemu-devel] [PATCH qom-next 09/22] integratorcp: Use cpu_arm_init() to obtain ARMCPU, Andreas Färber, 2012/05/14