From mboxrd@z Thu Jan 1 00:00:00 1970 From: Claude Code Review Bot 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 Message-ID: In-Reply-To: <20260410195537.295119-1-osama.abdelkader@gmail.com> References: <20260410195537.295119-1-osama.abdelkader@gmail.com> <20260410195537.295119-1-osama.abdelkader@gmail.com> X-Mailer: Claude Code Patch Reviewer Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: 7bit MIME-Version: 1.0 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