public inbox for drm-ai-reviews@public-inbox.freedesktop.org
 help / color / mirror / Atom feed
From: Claude Code Review Bot <claude-review@example.com>
To: dri-devel-reviews@example.com
Subject: Claude review: cgroup/dmem: introduce a peak file
Date: Thu, 07 May 2026 13:37:55 +1000	[thread overview]
Message-ID: <review-overall-20260506-dmem_peak-v1-0-8d803eb3449c@igalia.com> (raw)
In-Reply-To: <20260506-dmem_peak-v1-0-8d803eb3449c@igalia.com>

Overall Series Review

Subject: cgroup/dmem: introduce a peak file
Author: Thadeu Lima de Souza Cascardo <cascardo@igalia.com>
Patches: 6
Reviewed: 2026-05-07T13:37:55.340313

---

This 2-patch series adds a `dmem.peak` cgroup file, mirroring the existing `memory.peak` functionality for the DRM device-memory cgroup controller. Patch 1 extracts the peak-reset logic from memcontrol into a shared helper; Patch 2 uses it to implement per-region peak tracking in dmem.

**The overall approach is sound and the core logic is correct.** The reference counting is carefully handled, concurrent read/write races are safe due to appropriate use of `READ_ONCE`/`WRITE_ONCE` and fallback to global watermark, and the per-fd peak semantics correctly mirror the existing memory.peak behavior.

There are a few design concerns worth discussing, mainly around the addition of a dmem-specific `pool` pointer into the generic `cgroup_of_peak` struct, and the unused `seq_file *` parameter added to four getter functions. Neither is a correctness issue, but both are layering concerns that reviewers from the cgroup/mm side may push back on.

No bugs found. The series is in good shape for a v1.

---

---
Generated by Claude Code Patch Reviewer

  parent reply	other threads:[~2026-05-07  3:37 UTC|newest]

Thread overview: 13+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-05-06 11:58 [PATCH 0/2] cgroup/dmem: introduce a peak file Thadeu Lima de Souza Cascardo
2026-05-06 11:58 ` [PATCH 1/2] mm/page_counter: decouple peak_reset from peak_write Thadeu Lima de Souza Cascardo
2026-05-07  3:37   ` Claude review: " Claude Code Review Bot
2026-05-06 11:58 ` [PATCH 2/2] cgroup/dmem: introduce a peak file Thadeu Lima de Souza Cascardo
2026-05-07  3:37   ` Claude review: " Claude Code Review Bot
2026-05-06 13:53 ` [PATCH 0/2] " Michal Koutný
2026-05-06 14:18   ` Thadeu Lima de Souza Cascardo
2026-05-06 15:09     ` Michal Koutný
2026-05-07  3:37 ` Claude Code Review Bot [this message]
  -- strict thread matches above, loose matches on Subject: below --
2026-05-13 18:58 [PATCH v2] " Thadeu Lima de Souza Cascardo
2026-05-16  1:20 ` Claude review: " Claude Code Review Bot
2026-05-16  1:20 ` Claude Code Review Bot
2026-05-14 17:36 [PATCH v3] " Thadeu Lima de Souza Cascardo
2026-05-16  0:32 ` Claude review: " Claude Code Review Bot
2026-05-16  0:32 ` Claude Code Review Bot

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=review-overall-20260506-dmem_peak-v1-0-8d803eb3449c@igalia.com \
    --to=claude-review@example.com \
    --cc=dri-devel-reviews@example.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox