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: anx7625: enforce CONFIG_USB_ROLE_SWITCH dependency Date: Thu, 05 Mar 2026 13:44:42 +1000 Message-ID: In-Reply-To: <20260304083604.724519-1-arnd@kernel.org> References: <20260304083604.724519-1-arnd@kernel.org> <20260304083604.724519-1-arnd@kernel.org> X-Mailer: Claude Code Patch Reviewer Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 Patch Review **Kconfig change** (`drivers/gpu/drm/bridge/analogix/Kconfig`): The change from: ``` depends on TYPEC || !TYPEC ``` to: ``` depends on TYPEC depends on USB_ROLE_SWITCH ``` is correct. The old `TYPEC || !TYPEC` idiom meant "allow building regardles= s of TYPEC state but ensure we can't be built-in when TYPEC=3Dm" =E2=80=94 = effectively making it optional. Changing to a hard `depends on` for both TY= PEC and USB_ROLE_SWITCH eliminates all nine problematic tristate combinatio= ns and ensures the driver can only be built when both subsystems are availa= ble at the right level (built-in or module). **C code change** (`drivers/gpu/drm/bridge/analogix/anx7625.c`): Removing the `#if IS_REACHABLE(CONFIG_TYPEC)` / `#else` block with the thre= e empty stub functions (`anx7625_typec_set_status`, `anx7625_typec_register= `, `anx7625_typec_unregister`) is the correct cleanup. Since TYPEC is now a= hard dependency, these stubs can never be reached. The real implementation= s remain intact and are now unconditionally compiled. I verified that after the patch, no `IS_REACHABLE` guards or `#if`/`#else` = blocks related to TYPEC remain in the file. **Minor observation**: The commit message mentions the `Fixes:` tag pointin= g to `f81455b2d332` which introduced the Type-C support =E2=80=94 this is a= ppropriate since that commit introduced the USB_ROLE_SWITCH usage without t= he corresponding Kconfig dependency. **No issues found.** --- Generated by Claude Code Patch Reviewer