linux-mm.kvack.org archive mirror
 help / color / mirror / Atom feed
* [PATCH v2 0/3] Fix calculations in trace_balance_dirty_pages() for cgwb
@ 2025-03-04 11:03 Tang Yizhou
  2025-03-04 11:03 ` [PATCH v2 1/3] writeback: Let trace_balance_dirty_pages() take struct dtc as parameter Tang Yizhou
                   ` (2 more replies)
  0 siblings, 3 replies; 5+ messages in thread
From: Tang Yizhou @ 2025-03-04 11:03 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().

v2:
Adopt Tejun's suggestion and split the renaming code into Patch #2.
Pick up Tejun's Acked-by tag in Patch #3.

Tang Yizhou (3):
  writeback: Let trace_balance_dirty_pages() take struct dtc as
    parameter
  writeback: Rename variables in trace_balance_dirty_pages()
  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 15:39 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2025-03-04 11:03 [PATCH v2 0/3] Fix calculations in trace_balance_dirty_pages() for cgwb Tang Yizhou
2025-03-04 11:03 ` [PATCH v2 1/3] writeback: Let trace_balance_dirty_pages() take struct dtc as parameter Tang Yizhou
2025-03-04 15:39   ` Steven Rostedt
2025-03-04 11:03 ` [PATCH v2 2/3] writeback: Rename variables in trace_balance_dirty_pages() Tang Yizhou
2025-03-04 11:03 ` [PATCH v2 3/3] writeback: Fix calculations in trace_balance_dirty_pages() for cgwb Tang Yizhou

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