Skip to contentSkip to conversation

PG_uncached, CONFIG_EXTENDED_PAGEFLAGS and !NUMA

PATCH H. Peter Anvin 1 participant 2 messages Aug 28, 2009 – Aug 31, 2009

Subsystems (3)
lore
Share & tools
lore
#0 lore raw

Hi all,

I am looking at a patchset by Venkatesh Pallipadi which cleans up a lot of the corner cases in x86 PAT.

http://marc.info/[email protected]

This patchset pages PG_uncached available to other architectures than IA64 on an opt-in basis. Unfortunately, it means we run out of page flags on X86_32+PAE+SPARSEMEM.

Rather than increasing SECTION_SIZE_BITS further, it seems more reasonable to disable CONFIG_EXTENDED_PAGEFLAGS in this case:

mm/Kconfig +1 -1
index c948d4c..fe221c7 100644
@@ -153,7 +153,7 @@ config MEMORY_HOTREMOVE
 #
 config PAGEFLAGS_EXTENDED
        def_bool y
-       depends on 64BIT || SPARSEMEM_VMEMMAP || !NUMA || !SPARSEMEM
+       depends on 64BIT || SPARSEMEM_VMEMMAP || !SPARSEMEM
 
 # Heavily threaded applications may benefit from splitting the mm-wide
 

Dropping the !NUMA requirement here seems reasonable, since we already have generic code that handles removing the node number from the page flags when there are too many.

We could make this an x86-specific change, but the above generic change would be cleaner in terms of Kconfig complexity. Would people object to this as a general change?

-hpa

--
To unsubscribe, send a message with 'unsubscribe linux-mm' in the body to [email protected]. For more info on Linux MM,
see: http://www.linux-mm.org/ .
Don't email: <a href=mailto:"[email protected]"> [email protected] </a>

#1 lore raw

[tip:x86/pat] mm: remove !NUMA condition from PAGEFLAGS_EXTENDED condition set

Commit-ID:  a269cca9926faf8e44b340b017be0d884203141b
Gitweb:     http://git.kernel.org/tip/a269cca9926faf8e44b340b017be0d884203141b
Author:     H. Peter Anvin <[email protected]>
AuthorDate: Mon, 31 Aug 2009 11:17:44 -0700
Committer:  H. Peter Anvin <[email protected]>
CommitDate: Mon, 31 Aug 2009 11:17:44 -0700

mm: remove !NUMA condition from PAGEFLAGS_EXTENDED condition set

CONFIG_PAGEFLAGS_EXTENDED disables a trick to conserve pageflags. This trick is indended to be enabled when the pressure on page flags is very high.

The previous condition was:

- depends on 64BIT || SPARSEMEM_VMEMMAP || !NUMA || !SPARSEMEM

... however, the sparsemem code already has a way to crowd out the node number from the pageflags, which means that !NUMA actually doesn't contribute to hard pageflags exhaustion.

This is required for the new PG_uncached flag to not cause pageflags exhaustion on x86_32 + PAE + SPARSEMEM + !NUMA.

LKML-Reference: <[email protected]>
Cc: Venkatesh Pallipadi <[email protected]>
Cc: Suresh Siddha <[email protected]>

---
 mm/Kconfig |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)
mm/Kconfig +1 -1
index c948d4c..fe221c7 100644
@@ -153,7 +153,7 @@ config MEMORY_HOTREMOVE
 #
 config PAGEFLAGS_EXTENDED
 	def_bool y
-	depends on 64BIT || SPARSEMEM_VMEMMAP || !NUMA || !SPARSEMEM
+	depends on 64BIT || SPARSEMEM_VMEMMAP || !SPARSEMEM
 
 # Heavily threaded applications may benefit from splitting the mm-wide
 # page_table_lock, so that faults on different parts of the user address