]> git.baikalelectronics.ru Git - kernel.git/commit
mm/compaction.c: add an is_via_compact_memory() helper
authorYaowei Bai <bywxiaobai@163.com>
Fri, 6 Nov 2015 02:47:20 +0000 (18:47 -0800)
committerLinus Torvalds <torvalds@linux-foundation.org>
Fri, 6 Nov 2015 03:34:48 +0000 (19:34 -0800)
commitb66e02f927e44fc9f0d60858a5c814e468648478
treea87e5607b438dce4fce6c1cc49a6759d37e38712
parent3e88a5eb8de2ab5bd1d451cca7bf120d4ed4c534
mm/compaction.c: add an is_via_compact_memory() helper

Introduce is_via_compact_memory() helper indicating compacting via
/proc/sys/vm/compact_memory to improve readability.

To catch this situation in __compaction_suitable, use order as parameter
directly instead of using struct compact_control.

This patch has no functional changes.

Signed-off-by: Yaowei Bai <bywxiaobai@163.com>
Cc: Mel Gorman <mgorman@techsingularity.net>
Acked-by: David Rientjes <rientjes@google.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
mm/compaction.c