From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:59360) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Z7oyi-0007ME-P0 for qemu-devel@nongnu.org; Wed, 24 Jun 2015 14:00:53 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1Z7oyf-0006Fx-5T for qemu-devel@nongnu.org; Wed, 24 Jun 2015 14:00:52 -0400 Received: from cantor2.suse.de ([195.135.220.15]:48715 helo=mx2.suse.de) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Z7oye-0006Fp-OQ for qemu-devel@nongnu.org; Wed, 24 Jun 2015 14:00:48 -0400 Message-ID: <558AF04F.30908@suse.de> Date: Wed, 24 Jun 2015 20:00:47 +0200 From: =?UTF-8?B?QW5kcmVhcyBGw6RyYmVy?= MIME-Version: 1.0 References: <2d37cbbe85f142eb56e07538e0ef4e341b7fa637.1435115710.git.crosthwaite.peter@gmail.com> In-Reply-To: <2d37cbbe85f142eb56e07538e0ef4e341b7fa637.1435115710.git.crosthwaite.peter@gmail.com> Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Subject: Re: [Qemu-devel] [PATCH qom v3 4/4] microblaze: boot: Use cpu_set_pc() List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Peter Crosthwaite , qemu-devel@nongnu.org Cc: peter.maydell@linaro.org, edgar.iglesias@gmail.com, Peter Crosthwaite Am 24.06.2015 um 05:19 schrieb Peter Crosthwaite: > Use cpu_set_pc() for setting program counters when bootloading. This > removes an instance of system level code having to reach into the CPU > env. >=20 > Reviewed-by: Andreas F=C3=A4rber > Signed-off-by: Peter Crosthwaite > --- > changed since v2: > Add () to function names in commit messages > --- > dtc | 2 +- > hw/microblaze/boot.c | 2 +- > 2 files changed, 2 insertions(+), 2 deletions(-) >=20 > diff --git a/dtc b/dtc > index 65cc4d2..bc895d6 160000 > --- a/dtc > +++ b/dtc > @@ -1 +1 @@ > -Subproject commit 65cc4d2748a2c2e6f27f1cf39e07a5dbabd80ebf > +Subproject commit bc895d6d09695d05ceb8b52486ffe861d6cfbdde Submodule strikes again. Preparing to queue. Andreas > diff --git a/hw/microblaze/boot.c b/hw/microblaze/boot.c > index 4c44317..9f4698a 100644 > --- a/hw/microblaze/boot.c > +++ b/hw/microblaze/boot.c > @@ -54,7 +54,7 @@ static void main_cpu_reset(void *opaque) > env->regs[5] =3D boot_info.cmdline; > env->regs[6] =3D boot_info.initrd_start; > env->regs[7] =3D boot_info.fdt; > - env->sregs[SR_PC] =3D boot_info.bootstrap_pc; > + cpu_set_pc(CPU(cpu), boot_info.bootstrap_pc); > if (boot_info.machine_cpu_reset) { > boot_info.machine_cpu_reset(cpu); > } >=20 --=20 SUSE Linux GmbH, Maxfeldstr. 5, 90409 N=C3=BCrnberg, Germany GF: Felix Imend=C3=B6rffer, Jane Smithard, Dilip Upmanyu, Graham Norton; = HRB 21284 (AG N=C3=BCrnberg)