linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] mm/vmscan.c: use update_lru_size() in update_lru_sizes()
@ 2020-03-31 22:15 Wei Yang
  2020-04-01  1:39 ` Baoquan He
  2020-04-01 15:33 ` Michal Hocko
  0 siblings, 2 replies; 3+ messages in thread
From: Wei Yang @ 2020-03-31 22:15 UTC (permalink / raw)
  To: akpm; +Cc: linux-mm, linux-kernel, Wei Yang

We already defined the helper update_lru_size().

Let's use this to reduce code duplication.

Signed-off-by: Wei Yang <richard.weiyang@gmail.com>
---
 mm/vmscan.c | 5 +----
 1 file changed, 1 insertion(+), 4 deletions(-)

diff --git a/mm/vmscan.c b/mm/vmscan.c
index f92858e5c2e3..a4fdf3dc8887 100644
--- a/mm/vmscan.c
+++ b/mm/vmscan.c
@@ -1603,10 +1603,7 @@ static __always_inline void update_lru_sizes(struct lruvec *lruvec,
 		if (!nr_zone_taken[zid])
 			continue;
 
-		__update_lru_size(lruvec, lru, zid, -nr_zone_taken[zid]);
-#ifdef CONFIG_MEMCG
-		mem_cgroup_update_lru_size(lruvec, lru, zid, -nr_zone_taken[zid]);
-#endif
+		update_lru_size(lruvec, lru, zid, -nr_zone_taken[zid]);
 	}
 
 }
-- 
2.23.0


^ permalink raw reply related	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2020-04-01 15:33 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-03-31 22:15 [PATCH] mm/vmscan.c: use update_lru_size() in update_lru_sizes() Wei Yang
2020-04-01  1:39 ` Baoquan He
2020-04-01 15:33 ` Michal Hocko

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).