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: synopsys: dw-dp: fix bool function returning negative error code Date: Sat, 16 May 2026 10:13:40 +1000 Message-ID: In-Reply-To: <20260515020156.601-1-yanlonglong@kylinos.cn> References: <20260515020156.601-1-yanlonglong@kylinos.cn> <20260515020156.601-1-yanlonglong@kylinos.cn> X-Mailer: Claude Code Patch Reviewer Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 Patch Review **Analysis:** The function `dw_dp_video_need_vsc_sdp()` at line 1139 return= s `bool`. Before the patch, the error path at line 1145 was: ```c if (!state) return -EINVAL; ``` Since `-EINVAL` is `-22`, and C implicitly converts any non-zero integer to= `true` for a `bool` return, this error path was silently returning `true` = =E2=80=94 indicating a VSC SDP *is* needed, when the function actually coul= dn't determine the answer. The sole caller at line 1163: ```c if (dw_dp_video_need_vsc_sdp(dp)) misc |=3D DP_MSA_MISC_COLOR_VSC_SDP; ``` would incorrectly set the VSC SDP color bit in the MSA miscellaneous field = on failure. **The fix** =E2=80=94 changing to `return false` =E2=80=94 is correct. Retu= rning `false` on failure is the safe default: it avoids setting the VSC SDP= flag when state is unavailable, which matches the behavior of the other ea= rly-return (`!link->vsc_sdp_supported`) in the same function. **Minor nits on the commit message:** - The Fixes tag formatting has a minor style issue: there should be a space= before the parenthesis: `Fixes: 86eecc3a9c2e ("drm/bridge:...")` (kernel c= onvention uses `("...)` not `("...)`). This is cosmetic but maintainers so= metimes ask for it to be fixed. - The commit message body is missing a period at the end of the sentence ("= the opposite of the intended behavior" =E2=86=92 "the opposite of the inten= ded behavior."). **Verdict:** The code change itself is correct and complete. No functional = concerns. --- Generated by Claude Code Patch Reviewer