From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:33794) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Ya206-0006VT-4o for qemu-devel@nongnu.org; Mon, 23 Mar 2015 09:02:39 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1Ya1zz-00032Q-Nv for qemu-devel@nongnu.org; Mon, 23 Mar 2015 09:02:38 -0400 Received: from cantor2.suse.de ([195.135.220.15]:33420 helo=mx2.suse.de) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Ya1zz-00032F-HT for qemu-devel@nongnu.org; Mon, 23 Mar 2015 09:02:31 -0400 Message-ID: <55100EE5.9090404@suse.de> Date: Mon, 23 Mar 2015 14:02:29 +0100 From: =?ISO-8859-15?Q?Andreas_F=E4rber?= MIME-Version: 1.0 References: <1427115352-4948-1-git-send-email-leon.alrae@imgtec.com> In-Reply-To: <1427115352-4948-1-git-send-email-leon.alrae@imgtec.com> Content-Type: text/plain; charset=iso-8859-15 Content-Transfer-Encoding: quoted-printable Subject: Re: [Qemu-devel] [PATCH] linux-user: fix broken cpu_copy() List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Leon Alrae , qemu-devel@nongnu.org, riku.voipio@iki.fi Cc: ehabkost@redhat.com, Alexander Graf Am 23.03.2015 um 13:55 schrieb Leon Alrae: > New threads always point at the same env which is incorrect and usually= leads > to a crash. >=20 > Signed-off-by: Leon Alrae > --- > Hi, >=20 > This patch fixes the bug introduced in: >=20 > commit 2994fd96d986578a342f2342501b4ad30f6d0a85 > Author: Eduardo Habkost >=20 > cpu: Make cpu_init() return QOM CPUState object >=20 > Regards, > Leon > --- > linux-user/main.c | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) >=20 > diff --git a/linux-user/main.c b/linux-user/main.c > index 6e446de..04668e8 100644 > --- a/linux-user/main.c > +++ b/linux-user/main.c > @@ -3453,7 +3453,7 @@ CPUArchState *cpu_copy(CPUArchState *env) > { > CPUState *cpu =3D ENV_GET_CPU(env); > CPUState *new_cpu =3D cpu_init(cpu_model); > - CPUArchState *new_env =3D cpu->env_ptr; > + CPUArchState *new_env =3D new_cpu->env_ptr; > CPUBreakpoint *bp; > CPUWatchpoint *wp; > =20 Clearly my fault and might explain some breakage in our OBS, Reviewed-by: Andreas F=E4rber Riku, are you queuing this (-rc1 tomorrow!) or should I take it for a CPU pull? Thanks, Andreas --=20 SUSE Linux GmbH, Maxfeldstr. 5, 90409 N=FCrnberg, Germany GF: Felix Imend=F6rffer, Jane Smithard, Jennifer Guild, Dilip Upmanyu, Graham Norton; HRB 21284 (AG N=FCrnberg)