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: Act on the DRM color format property Date: Sun, 12 Apr 2026 11:01:41 +1000 Message-ID: In-Reply-To: <20260409-color-format-v12-4-ce84e1817a27@collabora.com> References: <20260409-color-format-v12-0-ce84e1817a27@collabora.com> <20260409-color-format-v12-4-ce84e1817a27@collabora.com> X-Mailer: Claude Code Patch Reviewer Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: 7bit MIME-Version: 1.0 Patch Review Adds `bus_format_is_color_fmt()` which maps MEDIA_BUS_FMT values to connector color formats, and modifies `drm_atomic_bridge_chain_select_bus_fmts()` to filter output bus formats. **Notes**: 1. `bus_format_is_color_fmt()` correctly returns `true` for `MEDIA_BUS_FMT_FIXED` regardless of requested format -- FIXED means the bridge doesn't care about format negotiation. 2. For HDMI bridges, the code converts `conn_state->hdmi.output_format` to a `drm_connector_color_format` via a switch statement: ```c if (last_bridge->type == DRM_MODE_CONNECTOR_HDMIA) { switch (conn_state->hdmi.output_format) { case DRM_OUTPUT_COLOR_FORMAT_RGB444: fmt = DRM_CONNECTOR_COLOR_FORMAT_RGB444; break; ... ``` This is a second instance of the output-to-connector format translation (also appears in patch 6). Consider factoring this out into a small helper, though at v12 this may not be worth the churn. 3. The `ret = -ENOTSUPP` inside the format filtering loop means if all formats are skipped, the final `ret` will be `-ENOTSUPP`, which matches the existing convention. Good. 4. The `out_free_bus_fmts` label is added for the HDMI default case error path. Correct. 5. Non-HDMI bridges use `conn_state->color_format` directly, with AUTO allowing all formats through since `bus_format_is_color_fmt()` returns true for AUTO. Correct design. **Verdict**: Good. --- --- Generated by Claude Code Patch Reviewer