From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([208.118.235.92]:37040) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1SbiVj-0003tX-Rk for qemu-devel@nongnu.org; Mon, 04 Jun 2012 21:24:42 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1SbiVi-0008WU-32 for qemu-devel@nongnu.org; Mon, 04 Jun 2012 21:24:39 -0400 Received: from cantor2.suse.de ([195.135.220.15]:52794 helo=mx2.suse.de) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1SbiVh-0008WD-Pz for qemu-devel@nongnu.org; Mon, 04 Jun 2012 21:24:38 -0400 Received: from relay1.suse.de (unknown [195.135.220.254]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (No client certificate requested) by mx2.suse.de (Postfix) with ESMTP id B28C48738D for ; Tue, 5 Jun 2012 03:24:36 +0200 (CEST) From: =?UTF-8?q?Andreas=20F=C3=A4rber?= Date: Tue, 5 Jun 2012 03:22:42 +0200 Message-Id: <1338859366-20689-71-git-send-email-afaerber@suse.de> In-Reply-To: <1338859366-20689-1-git-send-email-afaerber@suse.de> References: <1338859366-20689-1-git-send-email-afaerber@suse.de> MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable Subject: [Qemu-devel] [PATCH 70/74] leon3: Use cpu_sparc_init() to obtain SPARCCPU List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: qemu-devel@nongnu.org Cc: =?UTF-8?q?Andreas=20F=C3=A4rber?= Needed for main_cpu_reset(). Signed-off-by: Andreas F=C3=A4rber Acked-by: Blue Swirl --- hw/leon3.c | 6 ++++-- 1 files changed, 4 insertions(+), 2 deletions(-) diff --git a/hw/leon3.c b/hw/leon3.c index 0a5ff16..8ffef83 100644 --- a/hw/leon3.c +++ b/hw/leon3.c @@ -101,6 +101,7 @@ static void leon3_generic_hw_init(ram_addr_t ram_siz= e, const char *initrd_filename, const char *cpu_model) { + SPARCCPU *cpu; CPUSPARCState *env; MemoryRegion *address_space_mem =3D get_system_memory(); MemoryRegion *ram =3D g_new(MemoryRegion, 1); @@ -117,11 +118,12 @@ static void leon3_generic_hw_init(ram_addr_t ram_s= ize, cpu_model =3D "LEON3"; } =20 - env =3D cpu_init(cpu_model); - if (!env) { + cpu =3D cpu_sparc_init(cpu_model); + if (cpu =3D=3D NULL) { fprintf(stderr, "qemu: Unable to find Sparc CPU definition\n"); exit(1); } + env =3D &cpu->env; =20 cpu_sparc_set_id(env, 0); =20 --=20 1.7.7