public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: Andy Whitcroft <apw@shadowen.org>
To: Paul Mackerras <paulus@samba.org>, Anton Blanchard <anton@samba.org>
Cc: linuxppc64-dev@ozlabs.org, linux-kernel@vger.kernel.org,
	Andy Whitcroft <apw@shadowen.org>
Subject: [PATCH] ppc64 need HPAGE_SHIFT when huge pages disabled
Date: Thu, 17 Nov 2005 17:00:31 +0000	[thread overview]
Message-ID: <20051117170031.GA30223@shadowen.org> (raw)

With the new powerpc architecture we don't seem to be able to disable
huge pages anymore.

    mm/built-in.o(.toc1+0xae0): undefined reference to `HPAGE_SHIFT'
    make: *** [.tmp_vmlinux1] Error 1

We seem to need to define HPAGE_SHIFT to something when HUGETLB_PAGE isn't
defined.  This patch defines it to 0 when we have no support.

How does this look?  Against 2.6.15-rc1-mm1.

Signed-off-by: Andy Whitcroft <apw@shadowen.org>
---
diff -upN reference/include/asm-powerpc/page_64.h current/include/asm-powerpc/page_64.h
--- reference/include/asm-powerpc/page_64.h
+++ current/include/asm-powerpc/page_64.h
@@ -86,7 +86,11 @@ static inline void copy_page(void *to, v
 extern u64 ppc64_pft_size;
 
 /* Large pages size */
+#ifdef CONFIG_HUGETLB_PAGE
 extern unsigned int HPAGE_SHIFT;
+#else
+#define HPAGE_SHIFT 0
+#endif
 #define HPAGE_SIZE		((1UL) << HPAGE_SHIFT)
 #define HPAGE_MASK		(~(HPAGE_SIZE - 1))
 #define HUGETLB_PAGE_ORDER	(HPAGE_SHIFT - PAGE_SHIFT)

             reply	other threads:[~2005-11-17 17:00 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2005-11-17 17:00 Andy Whitcroft [this message]
2005-11-17 21:11 ` [PATCH] ppc64 need HPAGE_SHIFT when huge pages disabled Andrew Morton

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=20051117170031.GA30223@shadowen.org \
    --to=apw@shadowen.org \
    --cc=anton@samba.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linuxppc64-dev@ozlabs.org \
    --cc=paulus@samba.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