- mm-fix-incorrect-mempolicy-for-idle-threads.patch removed from -mm tree

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



The patch titled

     mm: Fix incorrect mempolicy for idle threads

has been removed from the -mm tree.  Its filename is

     mm-fix-incorrect-mempolicy-for-idle-threads.patch

This patch was dropped because it was nacked by the maintainer

------------------------------------------------------
Subject: mm: Fix incorrect mempolicy for idle threads
From: Ravikiran G Thirumalai <kiran@xxxxxxxxxxxx>

The kernel boots up on the BP with an initial memory policy of
MPOL_INTERLEAVE (start_kernel() -> numa_policy_init()).  This is done to
avoid all boot data structure allocations to be off the boot node.

Current mainline resets the memory policy to MPOL_DEFAULT at init(), just
before calling userspace init.  But, this is too late and leaves the kernel
idle thread with MPOL_INTERLEAVE, causing later allocations off
interrupt/BH context to use MPOL_INTERLEAVE, rather than MPOL_DEFAULT (if
the interrupt occurs on an idle cpu).

This can be fixed by changing the mempolicy to MPOL_DEFAULT just before the
'init' kernel thread is spawned, OR just before smp_init() (smp_init would
spawn idle threads).  The following patch uses the latter approach and
moves numa_default_policy() to just before smp_init().

Signed-off-by: Alok N Kataria <alok.kataria@xxxxxxxxxxxxxx>
Signed-off-by: Ravikiran Thirumalai <kiran@xxxxxxxxxxxx>
Signed-off-by: Shai Fultheim <shai@xxxxxxxxxxxx>
Cc: Andi Kleen <ak@xxxxxxx>
Cc: Christoph Lameter <clameter@xxxxxxxxxxxx>
Cc: Paul Jackson <pj@xxxxxxx>
Signed-off-by: Andrew Morton <akpm@xxxxxxxx>
---

 init/main.c |    3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff -puN init/main.c~mm-fix-incorrect-mempolicy-for-idle-threads init/main.c
--- a/init/main.c~mm-fix-incorrect-mempolicy-for-idle-threads
+++ a/init/main.c
@@ -727,6 +727,8 @@ static int init(void * unused)
 
 	do_pre_smp_initcalls();
 
+	numa_default_policy();
+
 	smp_init();
 	sched_init_smp();
 
@@ -762,7 +764,6 @@ static int init(void * unused)
 	unlock_kernel();
 	mark_rodata_ro();
 	system_state = SYSTEM_RUNNING;
-	numa_default_policy();
 
 	if (sys_open((const char __user *) "/dev/console", O_RDWR, 0) < 0)
 		printk(KERN_WARNING "Warning: unable to open an initial console.\n");
_

Patches currently in -mm which might be from kiran@xxxxxxxxxxxx are

origin.patch
mm-fix-incorrect-mempolicy-for-idle-threads.patch
slab-leaks3-default-y.patch

-
To unsubscribe from this list: send the line "unsubscribe mm-commits" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html

[Index of Archives]     [Kernel Newbies FAQ]     [Kernel Archive]     [IETF Annouce]     [DCCP]     [Netdev]     [Networking]     [Security]     [Bugtraq]     [Photo]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]

  Powered by Linux