aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMel Gorman <mgorman@suse.de>2012-12-17 09:05:53 -0500
committerLinus Torvalds <torvalds@linux-foundation.org>2012-12-17 11:25:50 -0500
commit221392c3ad0432e39fd74a349364f66cb0ed78f6 (patch)
treecc47a75ade22ee1e32da36c67f3dea2bb9a42393
parenta4f1de176614f634c367e5994a7bcc428c940df0 (diff)
sched: numa: Fix build error if CONFIG_NUMA_BALANCING && !CONFIG_TRANSPARENT_HUGEPAGE
Michal Hocko reported that the following build error occurs if CONFIG_NUMA_BALANCING is set without THP support kernel/sched/fair.c: In function ‘task_numa_work’: kernel/sched/fair.c:932:55: error: call to ‘__build_bug_failed’ declared with attribute error: BUILD_BUG failed The problem is that HPAGE_PMD_SHIFT triggers a BUILD_BUG() on !CONFIG_TRANSPARENT_HUGEPAGE. This patch addresses the problem. Reported-by: Michal Hocko <mhocko@suse.cz> Signed-off-by: Mel Gorman <mgorman@suse.de> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
-rw-r--r--kernel/sched/fair.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/kernel/sched/fair.c b/kernel/sched/fair.c
index 9af5af979a13..4603d6cb9e25 100644
--- a/kernel/sched/fair.c
+++ b/kernel/sched/fair.c
@@ -929,7 +929,7 @@ void task_numa_work(struct callback_head *work)
929 continue; 929 continue;
930 930
931 /* Skip small VMAs. They are not likely to be of relevance */ 931 /* Skip small VMAs. They are not likely to be of relevance */
932 if (((vma->vm_end - vma->vm_start) >> PAGE_SHIFT) < HPAGE_PMD_NR) 932 if (vma->vm_end - vma->vm_start < HPAGE_SIZE)
933 continue; 933 continue;
934 934
935 do { 935 do {