WARNING - OLD ARCHIVES

This is an archived copy of the Xen.org mailing list, which we have preserved to ensure that existing links to archives are not broken. The live archive, which contains the latest emails, can be found at http://lists.xen.org/
   
 
 
Xen 
 
Home Products Support Community News
 
   
 

xen-devel

RE: [Xen-devel] Re: A race condition in xenlinux exit_mmap

To: <ben@xxxxxxxxxxxxxxx>
Subject: RE: [Xen-devel] Re: A race condition in xenlinux exit_mmap
From: "Li, Xin B" <xin.b.li@xxxxxxxxx>
Date: Tue, 1 Aug 2006 21:53:36 +0800
Cc: hanzhu@xxxxxxxxxxx, xen-devel@xxxxxxxxxxxxxxxxxxx
Delivery-date: Tue, 01 Aug 2006 06:54:32 -0700
Envelope-to: www-data@xxxxxxxxxxxxxxxxxx
List-help: <mailto:xen-devel-request@lists.xensource.com?subject=help>
List-id: Xen developer discussion <xen-devel.lists.xensource.com>
List-post: <mailto:xen-devel@lists.xensource.com>
List-subscribe: <http://lists.xensource.com/cgi-bin/mailman/listinfo/xen-devel>, <mailto:xen-devel-request@lists.xensource.com?subject=subscribe>
List-unsubscribe: <http://lists.xensource.com/cgi-bin/mailman/listinfo/xen-devel>, <mailto:xen-devel-request@lists.xensource.com?subject=unsubscribe>
Sender: xen-devel-bounces@xxxxxxxxxxxxxxxxxxx
Thread-index: Aca1atMOZmZQvDyzR5iN3tuEkhFjtQABrIJw
Thread-topic: [Xen-devel] Re: A race condition in xenlinux exit_mmap
yes, elegant fix is not easy.
-Xin


From: bjthomas3@xxxxxxxxx [mailto:bjthomas3@xxxxxxxxx] On Behalf Of Ben Thomas
Sent: 2006年8月1日 21:03
To: Li, Xin B
Cc: hanzhu@xxxxxxxxxxx; xen-devel@xxxxxxxxxxxxxxxxxxx
Subject: Re: [Xen-devel] Re: A race condition in xenlinux exit_mmap

Xin,

I'm attaching a patch that we've been using since late May/early June to address an "Eeek" issues. Since we applied the patch, we haven't seen the issue.  As this was some time ago, I cannot recall if this is the same problem that you're seeing now. The patch wasn't submitted, as it isn't particularly clean. It's one of the many "some day soon" patches that we need to get resubmitted after a bit more work. I attach it here, not because I believe that it is "the answer", but as a data point for you.

-b


On 8/1/06, Keir Fraser <Keir.Fraser@xxxxxxxxxxxx > wrote:

On 1 Aug 2006, at 11:39, Li, Xin B wrote:

>> Do you mind creating a patch to do this? I can send you more
>> details if you like.
>
> Sure, pls send more info on this.

  1. Add an 'int has_foreign_mappings' to mmu_context structure
  2. Ensure the field is initialised in init_new_context() (e.g.,
memset-zero the whole structure; already done on x86/64)
  3. Set the field in direct_remap_pfn_range()
  4. Check the field in _arch_exit_mmap() to avoid calling mm_unpin().

That's it. Just needs testing.

  -- Keir


_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-devel

_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-devel