[PATCH openEuler-1.0-LTS] mm: fix missing reclaim of low-reliable page cache

From: Chen Wandun <chenwandun@huawei.com> hulk inclusion category: feature bugzilla: https://gitee.com/openeuler/kernel/issues/I4SK3S CVE: NA -------------------------------- Low-reliable memory is located in ZONE_MOVABLE, so gfp should contain GFP_HIGHMEM and GFP_MOVABLE when reclaim memory. Signed-off-by: Chen Wandun <chenwandun@huawei.com> Reviewed-by: Kefeng Wang <wangkefeng.wang@huawei.com> Signed-off-by: Yang Yingliang <yangyingliang@huawei.com> --- mm/vmscan.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/mm/vmscan.c b/mm/vmscan.c index 994c116306aa2..b6afafdef5075 100644 --- a/mm/vmscan.c +++ b/mm/vmscan.c @@ -4042,8 +4042,8 @@ unsigned long shrink_page_cache(gfp_t mask) { unsigned long nr_pages; - /* We reclaim the highmem zone too, it is useful for 32bit arch */ - nr_pages = __shrink_page_cache(mask | __GFP_HIGHMEM); + /* reclaim from movable zone */ + nr_pages = __shrink_page_cache(mask | __GFP_HIGHMEM | __GFP_MOVABLE); return nr_pages; } -- 2.25.1
participants (1)
-
Yang Yingliang