summaryrefslogtreecommitdiffstats
path: root/include/asm-sh/pgtable.h
diff options
context:
space:
mode:
authorPaul Mundt <lethal@linux-sh.org>2005-11-07 00:58:23 -0800
committerLinus Torvalds <torvalds@g5.osdl.org>2005-11-07 07:53:28 -0800
commitd229401f130941583eb46a2e8886df61241c14eb (patch)
tree1f51fe9ee16695b89efea56ea46f7966ceba2738 /include/asm-sh/pgtable.h
parentd5cb9783536a41df9f9cba5b0a1d78047ed787f7 (diff)
downloadtalos-obmc-linux-d229401f130941583eb46a2e8886df61241c14eb.tar.gz
talos-obmc-linux-d229401f130941583eb46a2e8886df61241c14eb.zip
[PATCH] sh: pte_mkhuge() compile fix for !CONFIG_HUGETLB_PAGE
Presently it is bogus to call pte_mkhuge() outside of the CONFIG_HUGETLB_PAGE context, as the only processors that support _PAGE_SZHUGE do so in the hugetlbpage context only (and this is the only time that _PAGE_SZHUGE is even defined). SH-2 and SH-3 do not support huge pages at all, and so it is not possible to enable this. Signed-off-by: Paul Mundt <lethal@linux-sh.org> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
Diffstat (limited to 'include/asm-sh/pgtable.h')
-rw-r--r--include/asm-sh/pgtable.h2
1 files changed, 2 insertions, 0 deletions
diff --git a/include/asm-sh/pgtable.h b/include/asm-sh/pgtable.h
index aef8ae43de13..dee36bcbcf98 100644
--- a/include/asm-sh/pgtable.h
+++ b/include/asm-sh/pgtable.h
@@ -196,7 +196,9 @@ static inline pte_t pte_mkexec(pte_t pte) { set_pte(&pte, __pte(pte_val(pte) | _
static inline pte_t pte_mkdirty(pte_t pte) { set_pte(&pte, __pte(pte_val(pte) | _PAGE_DIRTY)); return pte; }
static inline pte_t pte_mkyoung(pte_t pte) { set_pte(&pte, __pte(pte_val(pte) | _PAGE_ACCESSED)); return pte; }
static inline pte_t pte_mkwrite(pte_t pte) { set_pte(&pte, __pte(pte_val(pte) | _PAGE_RW)); return pte; }
+#ifdef CONFIG_HUGETLB_PAGE
static inline pte_t pte_mkhuge(pte_t pte) { set_pte(&pte, __pte(pte_val(pte) | _PAGE_SZHUGE)); return pte; }
+#endif
/*
* Macro and implementation to make a page protection as uncachable.
OpenPOWER on IntegriCloud