From: Nick Piggin Subject: Re: Interaction between Xen and XFS: stray RW mappings Date: Mon, 15 Oct 2007 21:28:10 +1000 Message-ID: <200710152128.10900.nickpiggin@yahoo.com.au> References: <470FA7C3.90404@goop.org> <200710160056.47458.nickpiggin@yahoo.com.au> <20071015110735.GA11748@one.firstfloor.org> Mime-Version: 1.0 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: 7bit Return-path: In-Reply-To: <20071015110735.GA11748@one.firstfloor.org> Content-Disposition: inline Sender: linux-kernel-owner@vger.kernel.org To: Andi Kleen Cc: David Chinner , Jeremy Fitzhardinge , xfs@oss.sgi.com, Xen-devel , Linux Kernel Mailing List , Mark Williamson , Morten =?iso-8859-1?q?B=C3=B8geskov?= , xfs-masters@oss.sgi.com List-Id: xen-devel@lists.xenproject.org On Monday 15 October 2007 21:07, Andi Kleen wrote: > On Tue, Oct 16, 2007 at 12:56:46AM +1000, Nick Piggin wrote: > > Is this true even if you don't write through those old mappings? > > I think it happened for reads too. It is a little counter intuitive > because in theory the CPU doesn't need to write back non dirty lines, > but in the one case which took so long to debug exactly this happened > somehow. > > At it is undefined for reads and writes in the architecture so > better be safe than sorry. Yes, typo. I meant reads or writes. > And x86 CPUs are out of order and do speculative executation > and that can lead to arbitary memory accesses even if the code > never touches an particular address. > > Newer Intel CPUs have something called self-snoop which was supposed > to handle this; but in some situations it doesn't seem to catch it > either. Fair enough, so we have to have this lazy tlb flush hook for Xen/PAT/etc. I don't think it should be much problem to implement. > > Is DRM or AGP then not also broken with lazy highmem flushing, or > > how do they solve that? > > AGP doesn't allocate highmem pages. Not sure about the DRM code. Hmm, OK. It looks like DRM vmallocs memory (which gives highmem).