From 6fc150de80ffa9d3a7eba3e4f26793eb44347eda Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Andreas=20F=C3=A4rber?= Date: Thu, 3 May 2012 04:16:07 +0200 Subject: [PATCH] s390-virtio: Use cpu_s390x_init() to obtain S390CPU MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Needed to store S390CPU in ipi_states[]. Signed-off-by: Andreas Färber --- hw/s390-virtio.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/hw/s390-virtio.c b/hw/s390-virtio.c index c0e19fd66d..49b3495248 100644 --- a/hw/s390-virtio.c +++ b/hw/s390-virtio.c @@ -209,9 +209,11 @@ static void s390_init(ram_addr_t my_ram_size, ipi_states = g_malloc(sizeof(CPUS390XState *) * smp_cpus); for (i = 0; i < smp_cpus; i++) { + S390CPU *cpu; CPUS390XState *tmp_env; - tmp_env = cpu_init(cpu_model); + cpu = cpu_s390x_init(cpu_model); + tmp_env = &cpu->env; if (!env) { env = tmp_env; }