From: Pasi =?iso-8859-1?Q?K=E4rkk=E4inen?= Subject: Re: xen.git branch reorg / success with 2.6.30-rc3 pv_ops dom0 Date: Tue, 9 Jun 2009 21:07:23 +0300 Message-ID: <20090609180723.GP24960@edu.joroinen.fi> References: <20090605181925.GC24960@edu.joroinen.fi> <1244475935.27370.309.camel@zakaz.uk.xensource.com> <1244476858.27370.325.camel@zakaz.uk.xensource.com> <20090608161329.GG24960@edu.joroinen.fi> <1244477865.27370.329.camel@zakaz.uk.xensource.com> <20090608162146.GH24960@edu.joroinen.fi> <20090608170543.GJ24960@edu.joroinen.fi> <20090608191141.GL24960@edu.joroinen.fi> <20090609145311.GO24960@edu.joroinen.fi> <1244561872.27370.403.camel@zakaz.uk.xensource.com> Mime-Version: 1.0 Content-Type: text/plain; charset=iso-8859-1 Content-Transfer-Encoding: quoted-printable Return-path: Content-Disposition: inline In-Reply-To: <1244561872.27370.403.camel@zakaz.uk.xensource.com> List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Sender: xen-devel-bounces@lists.xensource.com Errors-To: xen-devel-bounces@lists.xensource.com To: Ian Campbell Cc: Jeremy Fitzhardinge , Xen-devel List-Id: xen-devel@lists.xenproject.org On Tue, Jun 09, 2009 at 04:37:52PM +0100, Ian Campbell wrote: > On Tue, 2009-06-09 at 10:53 -0400, Pasi K=E4rkk=E4inen wrote: > >=20 > >=20 > > And here's one with only the second patch applied: > > http://pasik.reaktio.net/xen/pv_ops-dom0-debug/pv_ops-dom0-log-07-wit= h-highpte-no-swap-with-debug5.txt > >=20 > > Now Xen is complaining again.. does that sound correct? >=20 > Well, it suggests my theory around pte locking and split pte locks may > be invalid... I guess even without split pte locks the call to > kmap_atomic_pte from page_check_address() is still outside > mm->page_table_lock and hence subject to the race. >=20 > Without redoing the core locking rules I'm not sure what we could do > about that. Perhaps as a workaround always doing kmap_atomic_pte as a > read only mapping would be sufficient (it seems to be in this particula= r > call chain which never writes the pte but I didn't check them all and I > guess some of them must want to write). >=20 > Does this patch (without any of the others) make any difference to you? >=20 Yeah, now the kernel crashes very early during system startup :) http://pasik.reaktio.net/xen/pv_ops-dom0-debug/pv_ops-dom0-log-08-with-hi= ghpte-no-swap-with-debug6.txt -- Pasi > --- a/arch/x86/xen/mmu.c > +++ b/arch/x86/xen/mmu.c > @@ -1522,7 +1522,7 @@ static void *xen_kmap_atomic_pte(struct page *pag= e, enum km_type type) > { > pgprot_t prot =3D PAGE_KERNEL; > =20 > - if (PagePinned(page)) > + if (1 || PagePinned(page)) > prot =3D PAGE_KERNEL_RO; > =20 > if (0 && PageHighMem(page)) >=20 >=20 > Ian. >=20 >=20