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/amd/display: add GPIO HW translation helpers Date: Sat, 16 May 2026 13:03:13 +1000 Message-ID: In-Reply-To: <20260512190019.228440-2-guilherme.bozi@usp.br> References: <20260512190019.228440-1-guilherme.bozi@usp.br> <20260512190019.228440-2-guilherme.bozi@usp.br> X-Mailer: Claude Code Patch Reviewer Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: 7bit MIME-Version: 1.0 Patch Review Good foundational patch. The three helpers and table entry types are clean and generic. One thing worth noting: `dal_hw_translate_gpio_ddc_offset_to_id()` sets `*en` but does **not** set `*id`. This matches the original switch-statement behavior where DDC cases never set `*id` (with the comment "we don't care about the GPIO_ID for DDC"), but it means callers must not read `*id` after a DDC match. This is pre-existing behavior, not a regression. The hardcoded offset arithmetic in `dal_hw_translate_id_to_offset()` is correct: ```c info->offset_y = info->offset + 2; info->offset_en = info->offset + 1; info->offset_mask = info->offset - 1; ``` This was duplicated identically in every ASIC's `id_to_offset` function, so centralizing it here is the right call. No issues. --- Generated by Claude Code Patch Reviewer