xfs-masters
[Top] [All Lists]

[xfs-masters] Re: Interaction between Xen and XFS: stray RW mappings

To: Andi Kleen <andi@xxxxxxxxxxxxxx>
Subject: [xfs-masters] Re: Interaction between Xen and XFS: stray RW mappings
From: Jeremy Fitzhardinge <jeremy@xxxxxxxx>
Date: Mon, 22 Oct 2007 11:40:52 -0700
Cc: dean gaudet <dean@xxxxxxxxxx>, Nick Piggin <nickpiggin@xxxxxxxxxxxx>, Xen-devel <xen-devel@xxxxxxxxxxxxxxxxxxx>, Morten@xxxxxxx, David Chinner <dgc@xxxxxxx>, Linux Kernel Mailing List <linux-kernel@xxxxxxxxxxxxxxx>, Bøgeskov <xen-users@xxxxxxxxxxxxxxxxxx>, xfs@xxxxxxxxxxx, xfs-masters@xxxxxxxxxxx, Mark Williamson <mark.williamson@xxxxxxxxxxxx>
In-reply-to: <p73sl439s7k.fsf@xxxxxxxxxxxxxx>
References: <470FA7C3.90404@xxxxxxxx> <20071014225618.GN23367404@xxxxxxx> <4712A254.4090604@xxxxxxxx> <200710151415.07248.nickpiggin@xxxxxxxxxxxx> <alpine.DEB.0.9999.0710212015430.2320@xxxxxxxxxxxxxxxxxxx> <471C1A61.1010001@xxxxxxxx> <p73sl439s7k.fsf@xxxxxxxxxxxxxx>
Reply-to: xfs-masters@xxxxxxxxxxx
Sender: xfs-masters-bounce@xxxxxxxxxxx
User-agent: Thunderbird 2.0.0.5 (X11/20070727)
Andi Kleen wrote:
> Jeremy Fitzhardinge <jeremy@xxxxxxxx> writes:
>   
>> Yes, that's precisely the problem.  xfs does delay the unmap, leaving
>> stray mappings, which upsets Xen.
>>     
>
> Again it not just upsets Xen, keeping mappings to freed pages is wrong 
> generally 
> and violates the x86 (and likely others like PPC) architecture because it can 
> cause illegal caching attribute aliases.
>
> The patch that went into the tree was really not correct -- this
> bogus optimization should have been unconditionally removed
> or if you really wanted an ifdef made dependent on !CONFIG_XEN &&
> !CONFIG_AGP (and likely && !CONFIG_DRM && !CONFIG_anything else that
> uses uncached mappings in memory). 
>
> You just worked around the obvious failure and leave the non obvious
> rare corruptions in, which isn't a good strategy.

Well, at least it becomes a known issue and/or placeholder for when Nick
does his grand unified vmap manager.  I guess a clean workaround would
be to add a CONFIG_XFS_LAZY_UNMAP, and do it at the Kconfig level... 
I'll cook up a patch.

    J


<Prev in Thread] Current Thread [Next in Thread>