From: Lee Schermerhorn <Lee.Schermerhorn@hp.com>
To: linux-ia64@vger.kernel.org
Subject: [PATCH 2.6.17-rc1-mm2] pg_uncached-is-ia64-only-fix
Date: Wed, 12 Apr 2006 16:38:03 +0000 [thread overview]
Message-ID: <1144859883.5229.6.camel@localhost.localdomain> (raw)
In 2.6.17-rc1-mm2, the patch 'pg_uncached-is-ia64-only.patch'
moves the ia64-only PG_uncached flag to the high order 32-bits
of the page flags, and reduces FLAGS_RESERVED to 24. This
latter change interacts with SPARSEMEM to push the nodes out
of the flags word. ia64 actually needs all 32 high order
reserved bits to hold up to 1024 nodes in the flags along with
zone info and SPARSEMEM section index.
For some reason that I have not investigated [this may be a bug
or a feature], pushing the node field out of the flags word
increases the size of the mm/page_alloc.o data region by ~32MB.
before patch:size mm/page_alloc.o
text data bss dec hex filename
39506 10264 65548 115318 1c276 mm/page_alloc.o
after patch: size mm/page_alloc.o
text data bss dec hex filename
39650 33556504 65548 33661702 201a306 mm/page_alloc.o
So, 32MB is chump change on ia64 systems, but an unnecessary
waste. The stated reason for the change was to "make room for
another flag on 32-bit machines." 32-bit machines themselves
reserve some bits of the page flags for zone and node info--
currently 9 bits. So, we can use the upper ~8 bits of the low
order flags word for 64-bit only page flags.
This patch restores the 64-bit system FLAGS_RESERVED to 32 and
moves the PG_uncached bit back down into the high order byte of
the low order flags word.
Signed-off-by: Lee Schermerhorn <lee.schermerhorn@hp.com>
Index: linux-2.6.17-rc1-mm2/include/linux/mmzone.h
=================================--- linux-2.6.17-rc1-mm2.orig/include/linux/mmzone.h 2006-04-12 12:07:22.000000000 -0400
+++ linux-2.6.17-rc1-mm2/include/linux/mmzone.h 2006-04-12 12:09:26.000000000 -0400
@@ -457,7 +457,7 @@ extern struct zone *next_zone(struct zon
/*
* with 64 bit flags field, there's plenty of room.
*/
-#define FLAGS_RESERVED 24
+#define FLAGS_RESERVED 32
#else
Index: linux-2.6.17-rc1-mm2/include/linux/page-flags.h
=================================--- linux-2.6.17-rc1-mm2.orig/include/linux/page-flags.h 2006-04-12 12:07:22.000000000 -0400
+++ linux-2.6.17-rc1-mm2/include/linux/page-flags.h 2006-04-12 12:10:57.000000000 -0400
@@ -90,7 +90,7 @@
#define PG_nosave_free 18 /* Free, should not be written */
#if (BITS_PER_LONG > 32)
-#define PG_uncached 32 /* Page has been mapped as uncached */
+#define PG_uncached 24 /* Page has been mapped as uncached */
#endif
/*
next reply other threads:[~2006-04-12 16:38 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2006-04-12 16:38 Lee Schermerhorn [this message]
2006-04-12 20:20 ` [PATCH 2.6.17-rc1-mm2] pg_uncached-is-ia64-only-fix 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=1144859883.5229.6.camel@localhost.localdomain \
--to=lee.schermerhorn@hp.com \
--cc=linux-ia64@vger.kernel.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