From: Ingo Molnar <mingo@elte.hu>
To: Jeremy Fitzhardinge <jeremy@goop.org>
Cc: Harvey Harrison <harvey.harrison@gmail.com>,
Linux Kernel Mailing List <linux-kernel@vger.kernel.org>,
Andi Kleen <ak@suse.de>
Subject: Re: [PATCH UPDATE] x86: ignore spurious faults
Date: Fri, 25 Jan 2008 16:30:32 +0100 [thread overview]
Message-ID: <20080125153032.GE11846@elte.hu> (raw)
In-Reply-To: <4797DBA0.5020909@goop.org>
* Jeremy Fitzhardinge <jeremy@goop.org> wrote:
> When changing a kernel page from RO->RW, it's OK to leave stale TLB
> entries around, since doing a global flush is expensive and they pose
> no security problem. They can, however, generate a spurious fault,
> which we should catch and simply return from (which will have the
> side-effect of reloading the TLB to the current PTE).
>
> This can occur when running under Xen, because it frequently changes
> kernel pages from RW->RO->RW to implement Xen's pagetable semantics.
> It could also occur when using CONFIG_DEBUG_PAGEALLOC, since it avoids
> doing a global TLB flush after changing page permissions.
thanks, applied.
it would be nice to expose this ability of the architecture to the core
Linux kernel mprotect code as well, and let it skip on a TLB flush when
doing a RO->RW transition. It could speed up valgrind and the other
mprotect() users i guess? [and UML too perhaps]
Ingo
next prev parent reply other threads:[~2008-01-25 15:30 UTC|newest]
Thread overview: 24+ messages / expand[flat|nested] mbox.gz Atom feed top
2008-01-24 0:05 [PATCH] x86: ignore spurious faults Jeremy Fitzhardinge
2008-01-24 0:18 ` Harvey Harrison
2008-01-24 0:26 ` Jeremy Fitzhardinge
2008-01-24 0:28 ` [PATCH UPDATE] " Jeremy Fitzhardinge
2008-01-24 19:14 ` Matt Mackall
2008-01-24 19:21 ` Jeremy Fitzhardinge
2008-01-24 23:41 ` Nick Piggin
2008-01-25 0:26 ` Jeremy Fitzhardinge
2008-01-25 7:36 ` Keir Fraser
2008-01-25 8:15 ` Jan Beulich
2008-01-25 8:38 ` Nick Piggin
2008-01-25 9:11 ` Andi Kleen
2008-01-25 9:18 ` Keir Fraser
2008-01-25 9:51 ` Andi Kleen
2008-01-25 10:19 ` Andi Kleen
2008-01-25 13:17 ` Keir Fraser
2008-01-25 9:18 ` Jan Beulich
2008-01-25 15:30 ` Ingo Molnar [this message]
2008-01-25 15:54 ` Jeremy Fitzhardinge
2008-01-25 18:08 ` Ingo Molnar
2008-01-25 18:39 ` Jeremy Fitzhardinge
2008-01-24 6:49 ` [PATCH] " Andi Kleen
2008-01-24 7:02 ` Jeremy Fitzhardinge
2008-01-24 7:11 ` Andi Kleen
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20080125153032.GE11846@elte.hu \
--to=mingo@elte.hu \
--cc=ak@suse.de \
--cc=harvey.harrison@gmail.com \
--cc=jeremy@goop.org \
--cc=linux-kernel@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox