From: Marc-Christian Petersen <m.c.p@wolk-project.de>
To: linux-kernel@vger.kernel.org
Cc: Pavel Machek <pavel@ucw.cz>
Subject: Re: Highmem emulation for 2.6?
Date: Sun, 7 Mar 2004 14:19:36 +0100 [thread overview]
Message-ID: <200403071415.51065@WOLK> (raw)
In-Reply-To: <20040307125939.GA965@elf.ucw.cz>
[-- Attachment #1: Type: text/plain, Size: 175 bytes --]
On Sunday 07 March 2004 13:59, Pavel Machek wrote:
Hi Pavel,
> Does anyone have `subj`?
something like attached patch? Only for x86 now. Ontop of 2.6.4-rc1-mm2.
ciao, Marc
[-- Attachment #2: emulate-highmem-2.6.patch --]
[-- Type: text/x-diff, Size: 1361 bytes --]
--- old/include/asm-i386/setup.h 2004-02-26 01:29:43.000000000 +0100
+++ 2.6.4-rc1-mm2/include/asm-i386/setup.h 2004-03-07 14:08:33.000000000 +0100
@@ -13,7 +13,21 @@
/*
* Reserved space for vmalloc and iomap - defined in asm/page.h
*/
+#ifdef CONFIG_HIGHMEM_EMULATION
+#define ORDER_DOWN(x) ((x >> (MAX_ORDER-1)) << (MAX_ORDER-1))
+#define MAXMEM_PFN \
+({ \
+ int __max_pfn; \
+ if (max_pfn > PFN_DOWN(MAXMEM)) \
+ __max_pfn = PFN_DOWN(MAXMEM); \
+ else \
+ __max_pfn = ORDER_DOWN(max_pfn / 5); \
+ __max_pfn; \
+)}
+#else
#define MAXMEM_PFN PFN_DOWN(MAXMEM)
+#endif
+
#define MAX_NONPAE_PFN (1 << 20)
/*
--- old/arch/i386/Kconfig 2004-03-05 17:16:45.000000000 +0100
+++ 2.6.4-rc1-mm2/arch/i386/Kconfig 2004-03-07 14:11:57.000000000 +0100
@@ -773,6 +773,19 @@ config X86_PAE
depends on HIGHMEM64G
default y
+config HIGHMEM_EMULATION
+ bool ' Emulate HIGHMEM on lowmem machines'
+ depends on HIGHMEM
+ default n
+ ---help---
+ Really obvious. With this option turned on and also selecting
+ High Memory Support (4GB||64GB) you can emulate HIGHMEM on lowmem
+ mashines. This does nothing usefull, nothing speed improvement
+ or anything else but helps you to debug HIGHMEM code on lowmem
+ mashines.
+
+ If unsure, say N.
+
# Common NUMA Features
config NUMA
bool "Numa Memory Allocation Support"
prev parent reply other threads:[~2004-03-07 13:31 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2004-03-07 12:59 Highmem emulation for 2.6? Pavel Machek
2004-03-07 13:17 ` Michael Frank
2004-03-07 13:41 ` Michael Frank
2004-03-07 13:19 ` Marc-Christian Petersen [this message]
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=200403071415.51065@WOLK \
--to=m.c.p@wolk-project.de \
--cc=linux-kernel@vger.kernel.org \
--cc=pavel@ucw.cz \
/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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.