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: drm/bridge: chipone-icn6211: remove bridge when chipone_dsi_host_attach fails
Date: Sun, 12 Apr 2026 09:26:11 +1000	[thread overview]
Message-ID: <review-patch1-20260410195537.295119-1-osama.abdelkader@gmail.com> (raw)
In-Reply-To: <20260410195537.295119-1-osama.abdelkader@gmail.com>

Patch Review

**Correctness: Good.** The fix is correct. Looking at the existing code, `chipone_dsi_probe()` (line 713) already handles the equivalent error path for the DSI probe:

```c
ret = chipone_dsi_attach(icn);
if (ret)
    drm_bridge_remove(&icn->bridge);

return ret;
```

The `chipone_i2c_probe()` function was missing the same cleanup pattern. The patch correctly adds `drm_bridge_remove()` on the `chipone_dsi_host_attach()` failure path, making the two probe functions consistent.

**Style nit:** The commit message subject line is fine, but the body could be improved. It currently reads:

> when chipone_dsi_host_attach fails in chipone_i2c_probe remove drm
> bridge before return

This lacks proper capitalization and punctuation. A better version would be:

> When chipone_dsi_host_attach() fails in chipone_i2c_probe(), the
> bridge added by drm_bridge_add() is not removed, leaving a stale
> bridge registered. Add the missing drm_bridge_remove() call to the
> error path.

Also, adding a `Fixes:` tag referencing the commit that introduced `chipone_i2c_probe()` would be appropriate for a bugfix like this, as it helps with stable backporting.

**Code style nit:** There should be a blank line before `return ret;` to separate the error-handling block from the return, matching the style in `chipone_dsi_probe()` (line 739):

```c
	ret = chipone_dsi_host_attach(icn);
	if (ret)
		drm_bridge_remove(&icn->bridge);
+
	return ret;
```

**Overall: The fix is correct and should be accepted, ideally with the commit message improvements and `Fixes:` tag added.**

---
Generated by Claude Code Patch Reviewer

      parent reply	other threads:[~2026-04-11 23:26 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-04-10 19:55 [PATCH] drm/bridge: chipone-icn6211: remove bridge when chipone_dsi_host_attach fails Osama Abdelkader
2026-04-11 23:26 ` Claude review: " Claude Code Review Bot
2026-04-11 23:26 ` Claude Code Review Bot [this message]

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-patch1-20260410195537.295119-1-osama.abdelkader@gmail.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