]> git.karo-electronics.de Git - karo-tx-linux.git/commitdiff
memory-hotplug-update-mce_bad_pages-when-removing-the-memory-fix
authorAndrew Morton <akpm@linux-foundation.org>
Tue, 23 Oct 2012 02:50:13 +0000 (13:50 +1100)
committerStephen Rothwell <sfr@canb.auug.org.au>
Tue, 23 Oct 2012 03:11:48 +0000 (14:11 +1100)
cleanup ifdefs

Cc: Benjamin Herrenschmidt <benh@kernel.crashing.org>
Cc: Christoph Lameter <cl@linux.com>
Cc: Dave Hansen <dave@linux.vnet.ibm.com>
Cc: David Rientjes <rientjes@google.com>
Cc: Jiang Liu <liuj97@gmail.com>
Cc: KOSAKI Motohiro <kosaki.motohiro@jp.fujitsu.com>
Cc: Len Brown <len.brown@intel.com>
Cc: Minchan Kim <minchan.kim@gmail.com>
Cc: Paul Mackerras <paulus@samba.org>
Cc: Wen Congyang <wency@cn.fujitsu.com>
Cc: Yasuaki Ishimatsu <isimatu.yasuaki@jp.fujitsu.com>
Cc: Mel Gorman <mel@csn.ul.ie>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
mm/sparse.c

index 24072e435bf82014686c43335d1f3b6ef53b41de..8152952e50141509aa96648a7fdfa10743086150 100644 (file)
@@ -788,6 +788,10 @@ static void clear_hwpoisoned_pages(struct page *memmap, int nr_pages)
                }
        }
 }
+#else
+static inline void clear_hwpoisoned_pages(struct page *memmap, int nr_pages)
+{
+}
 #endif
 
 void sparse_remove_one_section(struct zone *zone, struct mem_section *ms)
@@ -803,10 +807,7 @@ void sparse_remove_one_section(struct zone *zone, struct mem_section *ms)
                ms->pageblock_flags = NULL;
        }
 
-#ifdef CONFIG_MEMORY_FAILURE
        clear_hwpoisoned_pages(memmap, PAGES_PER_SECTION);
-#endif
-
        free_section_usemap(memmap, usemap);
 }
 #endif