From mboxrd@z Thu Jan 1 00:00:00 1970 From: =?ISO-8859-1?Q?Andreas_F=E4rber?= Subject: Re: [Qemu-devel] [PATCH] kvm: sync cpu state on internal error before dump Date: Sat, 24 Aug 2013 19:28:44 +0200 Message-ID: <5218ED4C.8060201@suse.de> References: <1377260760-32056-1-git-send-email-james.hogan@imgtec.com> <20130823125846.GE15513@redhat.com> <52176679.6020006@imgtec.com> <20130824103729.GF15513@redhat.com> Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: QUOTED-PRINTABLE Cc: Paolo Bonzini , qemu-devel@nongnu.org, kvm@vger.kernel.org To: Gleb Natapov , James Hogan Return-path: Received: from cantor2.suse.de ([195.135.220.15]:53964 "EHLO mx2.suse.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1750876Ab3HXR2x (ORCPT ); Sat, 24 Aug 2013 13:28:53 -0400 In-Reply-To: <20130824103729.GF15513@redhat.com> Sender: kvm-owner@vger.kernel.org List-ID: Am 24.08.2013 12:37, schrieb Gleb Natapov: > On Fri, Aug 23, 2013 at 02:41:13PM +0100, James Hogan wrote: >> On 23/08/13 13:58, Gleb Natapov wrote: >>> On Fri, Aug 23, 2013 at 01:26:00PM +0100, James Hogan wrote: >>>> When a KVM internal error occurs QEMU dumps the CPU state, however= it >>>> doesn't synchronise the state from KVM first so the dumped state i= s out >>>> of date. Add the synchronisation calls before the dump in both loc= ations >>>> (which is used depends on whether the arch says to stop or not). >>>> >>> x86_cpu_dump_state() calls cpu_synchronize_state() already. >> >> Ah yes, thanks. I hadn't noticed that. >> >> Out of the arches that support KVM only x86 and ppc call it. arm, mi= ps >> (qemu support not upstream yet), and s390 don't. s390 never seems to >> emit that exit code, and arm only does so for unsupported exceptions >> (which should never happen). >> >> I'll fix in mips_cpu_dump_state() instead. >> > Moving cpu_synchronize_state() up to cpu_dump_state() would be better= =2E Yes, please. I did not review the hooks themselves much, just avoided global functions. Andreas --=20 SUSE LINUX Products GmbH, Maxfeldstr. 5, 90409 N=FCrnberg, Germany GF: Jeff Hawn, Jennifer Guild, Felix Imend=F6rffer; HRB 16746 AG N=FCrn= berg