From d52e38c0bc4b8fcbb78538290becf29204373b52 Mon Sep 17 00:00:00 2001 From: Greg Kroah-Hartman Date: Fri, 31 Jan 2014 17:15:35 +0100 Subject: [PATCH] 3.13-stable patches added patches: mm-mempolicy.c-fix-mempolicy-printing-in-numa_maps.patch --- ...-fix-mempolicy-printing-in-numa_maps.patch | 43 +++++++++++++++++++ queue-3.13/series | 1 + 2 files changed, 44 insertions(+) create mode 100644 queue-3.13/mm-mempolicy.c-fix-mempolicy-printing-in-numa_maps.patch diff --git a/queue-3.13/mm-mempolicy.c-fix-mempolicy-printing-in-numa_maps.patch b/queue-3.13/mm-mempolicy.c-fix-mempolicy-printing-in-numa_maps.patch new file mode 100644 index 00000000000..62e70843760 --- /dev/null +++ b/queue-3.13/mm-mempolicy.c-fix-mempolicy-printing-in-numa_maps.patch @@ -0,0 +1,43 @@ +From 8790c71a18e5d2d93532ae250bcf5eddbba729cd Mon Sep 17 00:00:00 2001 +From: David Rientjes +Date: Thu, 30 Jan 2014 15:46:08 -0800 +Subject: mm/mempolicy.c: fix mempolicy printing in numa_maps + +From: David Rientjes + +commit 8790c71a18e5d2d93532ae250bcf5eddbba729cd upstream. + +As a result of commit 5606e3877ad8 ("mm: numa: Migrate on reference +policy"), /proc//numa_maps prints the mempolicy for any as +"prefer:N" for the local node, N, of the process reading the file. + +This should only be printed when the mempolicy of is +MPOL_PREFERRED for node N. + +If the process is actually only using the default mempolicy for local +node allocation, make sure "default" is printed as expected. + +Signed-off-by: David Rientjes +Reported-by: Robert Lippert +Cc: Peter Zijlstra +Acked-by: Mel Gorman +Cc: Ingo Molnar +Signed-off-by: Andrew Morton +Signed-off-by: Linus Torvalds +Signed-off-by: Greg Kroah-Hartman + +--- + mm/mempolicy.c | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +--- a/mm/mempolicy.c ++++ b/mm/mempolicy.c +@@ -2928,7 +2928,7 @@ void mpol_to_str(char *buffer, int maxle + unsigned short mode = MPOL_DEFAULT; + unsigned short flags = 0; + +- if (pol && pol != &default_policy) { ++ if (pol && pol != &default_policy && !(pol->flags & MPOL_F_MORON)) { + mode = pol->mode; + flags = pol->flags; + } diff --git a/queue-3.13/series b/queue-3.13/series index ac3950212b6..f90731aa48e 100644 --- a/queue-3.13/series +++ b/queue-3.13/series @@ -1 +1,2 @@ e752x_edac-fix-pci_dev-usage-count.patch +mm-mempolicy.c-fix-mempolicy-printing-in-numa_maps.patch -- 2.47.2