linuxppc-dev.lists.ozlabs.org archive mirror
 help / color / mirror / Atom feed
From: Yuri Tikhonov <yur@emcraft.com>
To: Paul Mackerras <paulus@samba.org>
Cc: linuxppc-dev@ozlabs.org
Subject: Re: [PATCH] ppc: Add support for bigger page sizes than 4KB on PPC44x
Date: Wed, 25 Apr 2007 21:37:06 +0400	[thread overview]
Message-ID: <200704252137.06340.yur@emcraft.com> (raw)
In-Reply-To: <17921.3150.242081.66071@cargo.ozlabs.ibm.com>


 The patch replaces the CONFIG_PPC_PAGE_SHIFT integer option with choice of
three boolean options

 Signed-off-by: Yuri Tikhonov <yur@emcraft.com>
--

diff --git a/arch/ppc/Kconfig b/arch/ppc/Kconfig
index 72af523..5eb58dc 100644
--- a/arch/ppc/Kconfig
+++ b/arch/ppc/Kconfig
@@ -1201,15 +1201,24 @@ config SECCOMP

          If unsure, say Y. Only embedded should say N here.

-config PPC_PAGE_SHIFT
-       int "Page size (12=>4KB; 14=>16KB; 16=>64KB)" if 44x
-       default "12"
-       range 12 16
-       help
+choice
+       prompt "Page size"
+       default PPC_PAGE_4K
+       ---help---
          The PAGE_SIZE definition. Increasing the page size may
          improve the system performance in some dedicated cases.

-         If unsure, set it to 12 (4KB).
+         If unsure, set it to 4 KB.
+
+config PPC_PAGE_4K
+       bool "4 KB"
+
+config PPC_PAGE_16K
+       bool "16 KB" if 44x
+
+config PPC_PAGE_64K
+       bool "64 KB" if 44x
+endchoice

 endmenu

diff --git a/include/asm-ppc/page.h b/include/asm-ppc/page.h
index 0b8f354..f46712e 100644
--- a/include/asm-ppc/page.h
+++ b/include/asm-ppc/page.h
@@ -4,7 +4,13 @@
 #include <asm/asm-compat.h>

 /* PAGE_SHIFT determines the page size */
-#define PAGE_SHIFT     CONFIG_PPC_PAGE_SHIFT
+#if defined(CONFIG_PPC_PAGE_4K)
+#define PAGE_SHIFT     12
+#elif defined(CONFIG_PPC_PAGE_16K)
+#define PAGE_SHIFT     14
+#elif defined(CONFIG_PPC_PAGE_64K)
+#define PAGE_SHIFT     16
+#endif
 #define PAGE_SIZE      (ASM_CONST(1) << PAGE_SHIFT)

 /*

  parent reply	other threads:[~2007-04-25 18:33 UTC|newest]

Thread overview: 19+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2007-03-16 13:34 [PATCH] ppc: Add support for bigger page sizes than 4KB on PPC44x Yuri Tikhonov
2007-03-16 22:34 ` Paul Mackerras
2007-03-17 11:41   ` Yuri Tikhonov
2007-03-21 10:43     ` Paul Mackerras
2007-03-21 11:23       ` Yuri Tikhonov
2007-04-25 17:37       ` Yuri Tikhonov [this message]
  -- strict thread matches above, loose matches on Subject: below --
2007-03-16 13:35 Yuri Tikhonov
2007-03-12 21:54 Stefan Roese
2007-03-13  4:56 ` Paul Mackerras
2007-03-13  5:10   ` David Gibson
2007-03-13  7:12 ` Benjamin Herrenschmidt
2007-03-13  7:37   ` Stefan Roese
2007-03-13  9:37   ` Wolfgang Denk
2007-03-13 13:54     ` Benjamin Herrenschmidt
2007-03-13  9:42 ` Christoph Hellwig
2007-03-13  9:54   ` David Gibson
2007-03-13 14:00   ` Grant Likely
2007-03-13 14:09     ` Josh Boyer
2007-03-16  5:14 ` Paul Mackerras

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=200704252137.06340.yur@emcraft.com \
    --to=yur@emcraft.com \
    --cc=linuxppc-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;
as well as URLs for NNTP newsgroup(s).