]> pilppa.org Git - linux-2.6-omap-h63xx.git/commitdiff
[PATCH] sh: pte_mkhuge() compile fix for !CONFIG_HUGETLB_PAGE
authorPaul Mundt <lethal@linux-sh.org>
Mon, 7 Nov 2005 08:58:23 +0000 (00:58 -0800)
committerLinus Torvalds <torvalds@g5.osdl.org>
Mon, 7 Nov 2005 15:53:28 +0000 (07:53 -0800)
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>
include/asm-sh/pgtable.h

index aef8ae43de1367de335ee4b698ae76f5a040f33a..dee36bcbcf98e228c2082c0291a174d4b0168ec2 100644 (file)
@@ -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.