From mboxrd@z Thu Jan 1 00:00:00 1970 From: Claude Code Review Bot To: dri-devel-reviews@example.com Subject: Claude review: serdev: add rust private data to serdev_device Date: Thu, 04 Jun 2026 15:18:43 +1000 Message-ID: In-Reply-To: <20260530-rust_serdev-v10-2-65d1d5db876c@posteo.de> References: <20260530-rust_serdev-v10-0-65d1d5db876c@posteo.de> <20260530-rust_serdev-v10-2-65d1d5db876c@posteo.de> X-Mailer: Claude Code Patch Reviewer Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: 7bit MIME-Version: 1.0 Patch Review ```c + void *rust_private_data; ``` This adds a `void *rust_private_data` field to `struct serdev_device` in the C header. The field is documented as "Private data for the rust abstraction. This should not be used by the C drivers." **Question:** Adding a field to a C struct that is only used by Rust is somewhat unusual. Normally bus subsystems provide a mechanism like `dev_set_drvdata()` for private data. The commit message says this is "required by the rust abstraction" but it would benefit from a brief explanation of *why* the existing `drvdata` mechanism isn't sufficient (presumably because `drvdata` is used for `T::Data` and the abstraction needs a second private data slot for the `PrivateData` mutex). The serdev maintainer (Rob Herring, being replaced in patch 5) should weigh in. **Minor:** The doc comment reformatting (re-aligning the `@` entries with tabs) is a cosmetic change bundled with the functional change. It's harmless but slightly noisy. --- Generated by Claude Code Patch Reviewer