From mboxrd@z Thu Jan 1 00:00:00 1970 From: Marcelo Tosatti Subject: Re: [patch 3/3] KVM: move postcommit flush to x86, as mmio sptes are x86 specific Date: Tue, 28 Aug 2012 17:41:56 -0300 Message-ID: <20120828204156.GA19425@amt.cnet> References: <20120824185456.658814016@amt.cnet> <20120824185634.625676530@amt.cnet> <20120827234108.6f4417e2922e42ef461135c6@gmail.com> <20120827190601.GB27575@amt.cnet> <20120828093024.837e0147.yoshikawa.takuya@oss.ntt.co.jp> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Cc: Takuya Yoshikawa , Paul Mackerras , Avi Kivity , Xiao Guangrong , kvm@vger.kernel.org To: Takuya Yoshikawa Return-path: Received: from mx1.redhat.com ([209.132.183.28]:5409 "EHLO mx1.redhat.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752363Ab2H1UoA (ORCPT ); Tue, 28 Aug 2012 16:44:00 -0400 Content-Disposition: inline In-Reply-To: <20120828093024.837e0147.yoshikawa.takuya@oss.ntt.co.jp> Sender: kvm-owner@vger.kernel.org List-ID: On Tue, Aug 28, 2012 at 09:30:24AM +0900, Takuya Yoshikawa wrote: > On Mon, 27 Aug 2012 16:06:01 -0300 > Marcelo Tosatti wrote: > > > > Any explanation why (old.base_gfn != new.base_gfn) case can be > > > omitted? > > > > (old.base_gfn != new.base_gfn) check covers the cases > > > > 1. old.base_gfn = 0, new.base_gfn = !0 (slot creation) > > > > and > > > > x != 0, y != 0, x != y. > > 2. old.base_gfn = x, new.base_gfn = y (gpa base change) > > > > Patch 2 covers case 2, so its only necessary to cover case > > 1 here. > > > > Makes sense? > > Yes. > > But didn't you change the flush in the if block modified by patch 2 > to kvm_arch_flush_shadow_memslot()? > > Although current implementation flushes everything, this may trigger > problem when we change it. > > Takuya Yay, thanks.