Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit bc96157d authored by Kyle Yan's avatar Kyle Yan Committed by Gerrit - the friendly Code Review server
Browse files

Merge "mm: vmscan: support equal reclaim for anon and file pages" into msm-4.9

parents 3cd2bcfb 7231212f
Loading
Loading
Loading
Loading
+9 −0
Original line number Diff line number Diff line
@@ -656,6 +656,15 @@ config MAX_STACK_SIZE_MB

	  A sane initial value is 80 MB.

config BALANCE_ANON_FILE_RECLAIM
	bool "During reclaim treat anon and file backed pages equally"
	depends on SWAP
	help
	  When performing memory reclaim treat anonymous and file backed pages
	  equally.
	  Swapping anonymous pages out to memory can be efficient enough to justify
	  treating anonymous and file backed pages equally.

# For architectures that support deferred memory initialisation
config ARCH_SUPPORTS_DEFERRED_STRUCT_PAGE_INIT
	bool
+2 −1
Original line number Diff line number Diff line
@@ -2204,7 +2204,8 @@ static void get_scan_count(struct lruvec *lruvec, struct mem_cgroup *memcg,
	 * lruvec even if it has plenty of old anonymous pages unless the
	 * system is under heavy pressure.
	 */
	if (!inactive_list_is_low(lruvec, true, sc) &&
	if (!IS_ENABLED(CONFIG_BALANCE_ANON_FILE_RECLAIM) &&
	    !inactive_list_is_low(lruvec, true, sc) &&
	    lruvec_lru_size(lruvec, LRU_INACTIVE_FILE, sc->reclaim_idx) >> sc->priority) {
		scan_balance = SCAN_FILE;
		goto out;