* [PATCH] mm/vmstat.c: erase latency in vmstat_shepherd
@ 2021-01-11 3:55 Jiang Biao
0 siblings, 0 replies; only message in thread
From: Jiang Biao @ 2021-01-11 3:55 UTC (permalink / raw)
To: akpm; +Cc: linux-mm, linux-kernel, Jiang Biao, Bin Lai
From: Jiang Biao <benbjiang@tencent.com>
Many 100us+ latencies have been deteceted in vmstat_shepherd()
on CPX platform which has 208 logic cpus. And vmstat_shepherd is
queued every second, which could make the case worse.
Add schedule point in vmstat_shepherd() to erase the latency.
Signed-off-by: Jiang Biao <benbjiang@tencent.com>
Reported-by: Bin Lai <robinlai@tencent.com>
---
mm/vmstat.c | 2 ++
1 file changed, 2 insertions(+)
diff --git a/mm/vmstat.c b/mm/vmstat.c
index f8942160fc95..b538199883b5 100644
--- a/mm/vmstat.c
+++ b/mm/vmstat.c
@@ -1953,6 +1953,8 @@ static void vmstat_shepherd(struct work_struct *w)
if (!delayed_work_pending(dw) && need_update(cpu))
queue_delayed_work_on(cpu, mm_percpu_wq, dw, 0);
+
+ cond_resched();
}
put_online_cpus();
--
2.21.0
^ permalink raw reply [flat|nested] only message in thread
only message in thread, other threads:[~2021-01-11 3:56 UTC | newest]
Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-01-11 3:55 [PATCH] mm/vmstat.c: erase latency in vmstat_shepherd Jiang Biao
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox