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/
Home Products Support Community News


Re: [Xen-devel] Fwd: Re: struct page field arrangement

To: Jan Beulich <jbeulich@xxxxxxxxxx>, Keir Fraser <keir@xxxxxxxxxxxxx>
Subject: Re: [Xen-devel] Fwd: Re: struct page field arrangement
From: Keir Fraser <keir@xxxxxxxxxxxxx>
Date: Fri, 16 Mar 2007 15:30:05 +0000
Cc: xen-devel@xxxxxxxxxxxxxxxxxxx
Delivery-date: Fri, 16 Mar 2007 08:29:22 -0700
Envelope-to: www-data@xxxxxxxxxxxxxxxxxx
In-reply-to: <45FAC2A7.76E4.0078.0@xxxxxxxxxx>
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: Acdn3/igN3OHlNPTEduhtwAX8io7RQ==
Thread-topic: [Xen-devel] Fwd: Re: struct page field arrangement
User-agent: Microsoft-Entourage/
On 16/3/07 15:15, "Jan Beulich" <jbeulich@xxxxxxxxxx> wrote:

> But without being attached to an mm, the user portion of the pgd should
> be blank? I really can't follow why i386 requires so much more special
> handling here than x86-64.

PAE allocates the pmd's early (in pgd_alloc() in fact). So any pgd_alloc()ed
pgd must be captured by mm_pin_all().

> And what about the pgd_test_and_unpin() case?

It's only called from pgd_alloc, pgd_free, pgd_dtor. I'm not sure it's
needed in all those places, but it's needed in some of them to deal with the
case that _arch_exit_mmap() didn't unpin the pgd, because a PAE pgd does not
lose its pmd's until pgd_free(). In none of those cases is there a
concurrency problem: there's no mm associated with the pgd and hence no
concurrency issue.

I just checked in a patch to clarify some of this, particularly around
mm_pin_all, as c/s 14408. Feel free to submit more clarification patches --
I suspect a few more comments around these functions would help avoid

 -- Keir

Xen-devel mailing list