From: Jisheng Zhang <jszhang@marvell.com>
To: <catalin.marinas@arm.com>, <will.deacon@arm.com>
Cc: <linux-arm-kernel@lists.infradead.org>,
<linux-kernel@vger.kernel.org>,
Jisheng Zhang <jszhang@marvell.com>
Subject: [PATCH] arm64: mm: update SECTION_SIZE_BITS to 27 for 4k pagesize
Date: Mon, 13 Jun 2016 20:31:59 +0800 [thread overview]
Message-ID: <1465821119-3384-1-git-send-email-jszhang@marvell.com> (raw)
On one of my platforms, linux is given 1152MB memory. With current
SECTION_SIZE_BITS 30, the reserved memmap is larger, it's a waste for
us. Inspired by disscusion[1], reducing the SECTION_SIZE_BITS to 27
which means 128M section size saves us about 14MB, a huge gain for
embeded memory constrained system.
[1]http://lkml.iu.edu/hypermail/linux/kernel/1604.1/03036.html
Signed-off-by: Jisheng Zhang <jszhang@marvell.com>
---
arch/arm64/include/asm/sparsemem.h | 4 ++++
1 file changed, 4 insertions(+)
diff --git a/arch/arm64/include/asm/sparsemem.h b/arch/arm64/include/asm/sparsemem.h
index 74a9d30..41c10f7 100644
--- a/arch/arm64/include/asm/sparsemem.h
+++ b/arch/arm64/include/asm/sparsemem.h
@@ -18,7 +18,11 @@
#ifdef CONFIG_SPARSEMEM
#define MAX_PHYSMEM_BITS 48
+#ifdef CONFIG_ARM64_64K_PAGES
#define SECTION_SIZE_BITS 30
+#else
+#define SECTION_SIZE_BITS 27
+#endif
#endif
#endif
--
2.8.1
reply other threads:[~2016-06-13 12:36 UTC|newest]
Thread overview: [no followups] expand[flat|nested] mbox.gz Atom feed
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=1465821119-3384-1-git-send-email-jszhang@marvell.com \
--to=jszhang@marvell.com \
--cc=catalin.marinas@arm.com \
--cc=linux-arm-kernel@lists.infradead.org \
--cc=linux-kernel@vger.kernel.org \
--cc=will.deacon@arm.com \
/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
all inboxes | Powered by JetHome®