From: Claude Code Review Bot <claude-review@example.com>
To: dri-devel-reviews@example.com
Subject: Claude review: rust: sync: completion: add wait_for_completion_timeout()
Date: Tue, 05 May 2026 09:10:01 +1000 [thread overview]
Message-ID: <review-patch1-20260501205825.73614-2-joelagnelf@nvidia.com> (raw)
In-Reply-To: <20260501205825.73614-2-joelagnelf@nvidia.com>
Patch Review
Clean and straightforward. Wraps the C `wait_for_completion_timeout()` function.
```rust
pub fn wait_for_completion_timeout(&self, timeout: Jiffies) -> bool {
// SAFETY: `self.as_raw()` is a pointer to a valid `struct completion`.
unsafe { bindings::wait_for_completion_timeout(self.as_raw(), timeout) != 0 }
}
```
**Minor:** The `// ` trailing comment on line 171 of the import block looks like a rustfmt artifact:
```rust
types::Opaque, //
```
This appears throughout the series and seems to be an intentional rustfmt workaround to force one-import-per-line. Harmless but unusual.
**Question:** The C function `wait_for_completion_timeout()` returns `unsigned long` - the remaining jiffies if completed, 0 if timed out. Collapsing this to `bool` discards the remaining-jiffies information. For this series that's fine, but the Rust binding might want to return `Option<Jiffies>` (or similar) to expose the full API. This could be a follow-up.
---
Generated by Claude Code Patch Reviewer
next prev parent reply other threads:[~2026-05-04 23:10 UTC|newest]
Thread overview: 16+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-05-01 20:58 [PATCH v1 0/7] gpu: nova-core: add INTR_CTRL interrupt controller and CPU doorbell self-test Joel Fernandes
2026-05-01 20:58 ` [PATCH v1 1/7] rust: sync: completion: add wait_for_completion_timeout() Joel Fernandes
2026-05-04 23:10 ` Claude Code Review Bot [this message]
2026-05-01 20:58 ` [PATCH v1 2/7] gpu: nova-core: allocate PCI MSI vector during probe Joel Fernandes
2026-05-04 23:10 ` Claude review: " Claude Code Review Bot
2026-05-01 20:58 ` [PATCH v1 3/7] gpu: nova-core: add interrupt controller register definitions Joel Fernandes
2026-05-04 23:10 ` Claude review: " Claude Code Review Bot
2026-05-01 20:58 ` [PATCH v1 4/7] gpu: nova-core: add Architecture::is_pre_hopper() helper Joel Fernandes
2026-05-04 23:10 ` Claude review: " Claude Code Review Bot
2026-05-01 20:58 ` [PATCH v1 5/7] gpu: nova-core: add INTR_CTRL interrupt controller API Joel Fernandes
2026-05-04 23:10 ` Claude review: " Claude Code Review Bot
2026-05-01 20:58 ` [PATCH v1 6/7] gpu: nova-core: add CPU doorbell IRQ self-test Joel Fernandes
2026-05-04 23:10 ` Claude review: " Claude Code Review Bot
2026-05-01 20:58 ` [PATCH v1 7/7] gpu: nova-core: document INTR_CTRL interrupt tree Joel Fernandes
2026-05-04 23:10 ` Claude review: " Claude Code Review Bot
2026-05-04 23:10 ` Claude review: gpu: nova-core: add INTR_CTRL interrupt controller and CPU doorbell self-test Claude Code Review Bot
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=review-patch1-20260501205825.73614-2-joelagnelf@nvidia.com \
--to=claude-review@example.com \
--cc=dri-devel-reviews@example.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox