mm, compaction: create compact_gap wrapper
authorVlastimil Babka <[email protected]>
Fri, 7 Oct 2016 23:57:53 +0000 (16:57 -0700)
committerLinus Torvalds <[email protected]>
Sat, 8 Oct 2016 01:46:27 +0000 (18:46 -0700)
commit9861a62c335cd34a2b6b25aaaf5898e8370299ec
tree4eb21fe16acfb2e229422de1927bfcb152781829
parentf2b8228c5f99a92bc07efd36f8dc840e0705a266
mm, compaction: create compact_gap wrapper

Compaction uses a watermark gap of (2UL << order) pages at various
places and it's not immediately obvious why.  Abstract it through a
compact_gap() wrapper to create a single place with a thorough
explanation.

[[email protected]: clarify the comment of compact_gap()]
Link: http://lkml.kernel.org/r/[email protected]
Link: http://lkml.kernel.org/r/[email protected]
Signed-off-by: Vlastimil Babka <[email protected]>
Tested-by: Lorenzo Stoakes <[email protected]>
Acked-by: Michal Hocko <[email protected]>
Cc: Mel Gorman <[email protected]>
Cc: Joonsoo Kim <[email protected]>
Cc: David Rientjes <[email protected]>
Cc: Rik van Riel <[email protected]>
Signed-off-by: Vlastimil Babka <[email protected]>
Signed-off-by: Andrew Morton <[email protected]>
Signed-off-by: Linus Torvalds <[email protected]>
include/linux/compaction.h
mm/compaction.c
mm/vmscan.c