]> git.karo-electronics.de Git - karo-tx-linux.git/commit
x86/mm: Introduce pte_accessible()
authorRik van Riel <riel@redhat.com>
Tue, 9 Oct 2012 13:31:12 +0000 (15:31 +0200)
committerIngo Molnar <mingo@kernel.org>
Sun, 28 Oct 2012 16:30:55 +0000 (17:30 +0100)
commite9df40bfeb2572ac61f894daabd029fdebbb3b4a
tree50257ac3e49a9621ded6b877cc6d430a4d19a4cd
parent3f2b613771ecb927519ce95e902136c4e7bc0948
x86/mm: Introduce pte_accessible()

We need pte_present to return true for _PAGE_PROTNONE pages, to indicate that
the pte is associated with a page.

However, for TLB flushing purposes, we would like to know whether the pte
points to an actually accessible page.  This allows us to skip remote TLB
flushes for pages that are not actually accessible.

Fill in this method for x86 and provide a safe (but slower) method
on other architectures.

Signed-off-by: Rik van Riel <riel@redhat.com>
Signed-off-by: Peter Zijlstra <a.p.zijlstra@chello.nl>
Fixed-by: Linus Torvalds <torvalds@linux-foundation.org>
Cc: Andrew Morton <akpm@linux-foundation.org>
Cc: Peter Zijlstra <a.p.zijlstra@chello.nl>
Link: http://lkml.kernel.org/n/tip-66p11te4uj23gevgh4j987ip@git.kernel.org
[ Added Linus's review fixes. ]
Signed-off-by: Ingo Molnar <mingo@kernel.org>
arch/x86/include/asm/pgtable.h
include/asm-generic/pgtable.h