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] [PATCH] i386 linux: make 32-bit PAE kernel work when bui

To: "Keir Fraser" <Keir.Fraser@xxxxxxxxxxxx>
Subject: Re: [Xen-devel] [PATCH] i386 linux: make 32-bit PAE kernel work when built with newer gcc
From: "Jan Beulich" <JBeulich@xxxxxxxxxx>
Date: Fri, 17 Mar 2006 12:35:42 +0100
Cc: xen-devel@xxxxxxxxxxxxxxxxxxx
Delivery-date: Fri, 17 Mar 2006 11:35:38 +0000
Envelope-to: www-data@xxxxxxxxxxxxxxxxxxx
In-reply-to: <e4b4e1639418830cc923ffe12a3dcc57@xxxxxxxxxxxx>
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>
References: <4415AE7C.76F0.0078.0@xxxxxxxxxx> <e4b4e1639418830cc923ffe12a3dcc57@xxxxxxxxxxxx>
Sender: xen-devel-bounces@xxxxxxxxxxxxxxxxxxx
>>> Keir Fraser <Keir.Fraser@xxxxxxxxxxxx> 17.03.06 11:19:21 >>>
>
>On 13 Mar 2006, at 16:40, Jan Beulich wrote:
>
>> The compiler isn't required to order the two stores 
>> ptep_get_and_clear_full() in any particular way, and we saw cases
>> where the upper 32 bits get stored before the lower ones, which causes 
>> the access to fail (page-fault propagated out of
>> Xen).
>
>Isn't this patch needed for native also? Even though this fastpath is 
>(I think) only called from exit_mmap(), processors may still be running 
>on those pagetables at that point (e.g., due to lazy switching).

I thought about that, too, but wasn't sure.

>So what if:
>
>1. Compiler causes high to be cleared before low.
>2. This causes an invalid PTE (e.g., pointing into an uncacheable I/O 
>region)
>3. A processor speculatively loads the PTE into its TLB
>4. A processor speculatively fetches a cacheline from the bogus area
>5. You get a bug like the old AMD GART hang, where the CPU writes back 
>the cache line at an inopportune moment, when it should never have been 
>cached in the first place.

It, at least as per the spec, cannot write this cache line back, as everything
up to here was speculative, and hence no change to the cache line may have
occurred. But the caching inconsistencies would still be a problem and could,
if I recall right, lead to processor hangs.
If such a speculative access is considered theoretically possible, then yes, I'd
think the same change is needed for native.

Jan


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