From mboxrd@z Thu Jan 1 00:00:00 1970 From: Joerg Roedel Subject: Re: [PATCH] Use WARN_ON_ONCE for missing X86_FEATURE_NRIPS Date: Tue, 6 Oct 2015 12:23:29 +0200 Message-ID: <20151006102329.GC20886@8bytes.org> References: <560D1C6E.2060803@suse.com> <560D278F.10801@redhat.com> <20151005095022.GX3036@8bytes.org> <20151005171537.GD12506@8bytes.org> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Cc: Paolo Bonzini , kvm@vger.kernel.org, Dirk =?iso-8859-1?Q?M=FCller?= To: Bandan Das Return-path: Received: from 8bytes.org ([81.169.241.247]:35502 "EHLO theia.8bytes.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751597AbbJFKXb (ORCPT ); Tue, 6 Oct 2015 06:23:31 -0400 Content-Disposition: inline In-Reply-To: Sender: kvm-owner@vger.kernel.org List-ID: On Mon, Oct 05, 2015 at 01:42:43PM -0400, Bandan Das wrote: > Joerg Roedel writes: > > > On Mon, Oct 05, 2015 at 12:54:43PM -0400, Bandan Das wrote: > >> Joerg Roedel writes: > >> The problems is that the next_rip field could be stale. If the processor supports > >> next_rip, then it will clear it out on the next entry. If it doesn't, > >> an old value just sits there (no matter who wrote it) and the problem > >> happens when skip_emulated_instruction advances the rip with an incorrect > >> value. > > > > So the right fix would be to just set the guests next_rip to 0 when we > > emulate vmrun, just like real hardware does, no? > > Agreed, resetting to 0 if nrips isn't supported seems right. It would still > help having a printk_once in this case IMO :) I meant to reset it always to 0 on vmrun, like real hardware does. Joerg