summaryrefslogtreecommitdiff
path: root/arch/unicore32
diff options
context:
space:
mode:
authorDavid Rientjes <rientjes@google.com>2013-04-30 02:06:11 +0400
committerBen Hutchings <ben@decadent.org.uk>2013-10-27 00:06:13 +0400
commit7c617fda8c72a55a65cc5320cadb916f5981cfeb (patch)
tree91b0628764f936eecf3ae4c27f01f7fbac639ee7 /arch/unicore32
parentdffcc9dc54d22e3c5eadd5d42835fa47ee25b071 (diff)
downloadlinux-7c617fda8c72a55a65cc5320cadb916f5981cfeb.tar.xz
mm, show_mem: suppress page counts in non-blockable contexts
commit 4b59e6c4730978679b414a8da61514a2518da512 upstream. On large systems with a lot of memory, walking all RAM to determine page types may take a half second or even more. In non-blockable contexts, the page allocator will emit a page allocation failure warning unless __GFP_NOWARN is specified. In such contexts, irqs are typically disabled and such a lengthy delay may even result in NMI watchdog timeouts. To fix this, suppress the page walk in such contexts when printing the page allocation failure warning. Signed-off-by: David Rientjes <rientjes@google.com> Cc: Mel Gorman <mgorman@suse.de> Acked-by: Michal Hocko <mhocko@suse.cz> Cc: Dave Hansen <dave@linux.vnet.ibm.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> Signed-off-by: Ben Hutchings <ben@decadent.org.uk>
Diffstat (limited to 'arch/unicore32')
-rw-r--r--arch/unicore32/mm/init.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/arch/unicore32/mm/init.c b/arch/unicore32/mm/init.c
index 3b379cddbc64..d1af4ed5694d 100644
--- a/arch/unicore32/mm/init.c
+++ b/arch/unicore32/mm/init.c
@@ -65,6 +65,9 @@ void show_mem(unsigned int filter)
printk(KERN_DEFAULT "Mem-info:\n");
show_free_areas(filter);
+ if (filter & SHOW_MEM_FILTER_PAGE_COUNT)
+ return;
+
for_each_bank(i, mi) {
struct membank *bank = &mi->bank[i];
unsigned int pfn1, pfn2;