From mboxrd@z Thu Jan 1 00:00:00 1970 From: Claude Code Review Bot To: dri-devel-reviews@example.com Subject: Claude review: rust: faux: Allow retrieving a bound Device Date: Thu, 04 Jun 2026 16:06:44 +1000 Message-ID: In-Reply-To: <20260529183702.677677-5-lyude@redhat.com> References: <20260529183702.677677-1-lyude@redhat.com> <20260529183702.677677-5-lyude@redhat.com> X-Mailer: Claude Code Patch Reviewer Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 Patch Review **Status: Looks good** The change from `AsRef` to `AsRef>` is correct. The invariant reasoning is sound =E2=80=94 a `Registrati= on` exists only after successful creation and registration of the device, s= o it is proof that the device is bound: ```rust +/// - This object is proof that the object described by this `Registration= ` is bound to a device. ``` ```rust -impl AsRef for Registration { - fn as_ref(&self) -> &device::Device { +impl AsRef> for Registration { + fn as_ref(&self) -> &device::Device { ``` This is a prerequisite for the sg_table() API which requires `&device::Devi= ce`. **Note**: This changes the public API of `faux::Registration`. Any existing= callers using `AsRef` without the `Bound` parameter would = break. Given this is upstream kernel Rust, the caller base should be limite= d, but it's worth noting for the merge window. --- Generated by Claude Code Patch Reviewer