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

Commit c0580dc2 authored by Charan Teja Reddy's avatar Charan Teja Reddy Committed by Chris Goldsworthy
Browse files

mm: set the watermark_boost before updating the low and high wmarks



Updating the zone watermarks by any means, like extra_free_kbytes,
min_free_kbytes, water_mark_scale_factor, when boost_watermark(zone) is
set can result into the higher water_mark_low|min as the macro
min_wmark_pages returns by adding the zone->watermark_boost.
Set this to Zero early.

Change-Id: I5e3edd1798e46974f3df34ef750f9d08b8ff35f4
Signed-off-by: default avatarCharan Teja Reddy <charante@codeaurora.org>
Signed-off-by: default avatarChris Goldsworthy <cgoldswo@codeaurora.org>
parent ed69314e
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -7896,11 +7896,11 @@ static void __setup_per_zone_wmarks(void)
			    mult_frac(zone_managed_pages(zone),
				      watermark_scale_factor, 10000));

		zone->watermark_boost = 0;
		zone->_watermark[WMARK_LOW]  = min_wmark_pages(zone) +
					low + tmp;
		zone->_watermark[WMARK_HIGH] = min_wmark_pages(zone) +
					low + tmp * 2;
		zone->watermark_boost = 0;

		spin_unlock_irqrestore(&zone->lock, flags);
	}