linux-mm.kvack.org archive mirror
 help / color / mirror / Atom feed
* [PATCH RESEND 0/2] Fix calculations in trace_balance_dirty_pages() for cgwb
@ 2025-03-03 10:06 Tang Yizhou
  2025-03-03 10:06 ` [PATCH RESEND 1/2] writeback: Let trace_balance_dirty_pages() take struct dtc as parameter Tang Yizhou
  2025-03-03 10:06 ` [PATCH RESEND 2/2] writeback: Fix calculations in trace_balance_dirty_pages() for cgwb Tang Yizhou
  0 siblings, 2 replies; 5+ messages in thread
From: Tang Yizhou @ 2025-03-03 10:06 UTC (permalink / raw)
  To: tj, jack, brauner, willy, akpm
  Cc: rostedt, mhiramat, ast, linux-mm, linux-fsdevel, linux-kernel,
	Tang Yizhou

From: Tang Yizhou <yizhou.tang@shopee.com>

In my experiment, I found that the output of trace_balance_dirty_pages()
in the cgroup writeback scenario was strange because
trace_balance_dirty_pages() always uses global_wb_domain.dirty_limit for
related calculations instead of the dirty_limit of the corresponding
memcg's wb_domain.

The basic idea of the fix is to store the hard dirty limit value computed
in wb_position_ratio() into struct dirty_throttle_control and use it for
calculations in trace_balance_dirty_pages().

Tang Yizhou (2):
  writeback: Let trace_balance_dirty_pages() take struct dtc as
    parameter
  writeback: Fix calculations in trace_balance_dirty_pages() for cgwb

 include/linux/writeback.h        | 24 +++++++++++++++++++++
 include/trace/events/writeback.h | 33 ++++++++++++----------------
 mm/page-writeback.c              | 37 +++-----------------------------
 3 files changed, 41 insertions(+), 53 deletions(-)

-- 
2.25.1



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

end of thread, other threads:[~2025-03-04 14:36 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2025-03-03 10:06 [PATCH RESEND 0/2] Fix calculations in trace_balance_dirty_pages() for cgwb Tang Yizhou
2025-03-03 10:06 ` [PATCH RESEND 1/2] writeback: Let trace_balance_dirty_pages() take struct dtc as parameter Tang Yizhou
2025-03-04 14:25   ` Jan Kara
2025-03-03 10:06 ` [PATCH RESEND 2/2] writeback: Fix calculations in trace_balance_dirty_pages() for cgwb Tang Yizhou
2025-03-04 14:35   ` Jan Kara

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox