From: Miguel Ojeda <miguel.ojeda.sandonis@gmail.com>
To: Igor Korotin <igor.korotin.linux@gmail.com>
Cc: "Danilo Krummrich" <dakr@kernel.org>,
"Benno Lossin" <lossin@kernel.org>,
"Miguel Ojeda" <ojeda@kernel.org>,
"Alex Gaynor" <alex.gaynor@gmail.com>,
"Rafael J . Wysocki" <rafael@kernel.org>,
"Greg Kroah-Hartman" <gregkh@linuxfoundation.org>,
linux-kernel@vger.kernel.org, rust-for-linux@vger.kernel.org,
linux-acpi@vger.kernel.org, "Boqun Feng" <boqun.feng@gmail.com>,
"Gary Guo" <gary@garyguo.net>,
"Björn Roy Baron" <bjorn3_gh@protonmail.com>,
"Benno Lossin" <benno.lossin@proton.me>,
"Andreas Hindborg" <a.hindborg@kernel.org>,
"Alice Ryhl" <aliceryhl@google.com>,
"Trevor Gross" <tmgross@umich.edu>, "Len Brown" <lenb@kernel.org>,
"Wedson Almeida Filho" <wedsonaf@gmail.com>,
"Viresh Kumar" <viresh.kumar@linaro.org>,
"Alex Hung" <alex.hung@amd.com>,
"Xiang Fei Ding" <dingxiangfei2009@gmail.com>
Subject: Re: [PATCH v3 2/4] rust: driver: Add ACPI id table support to Adapter trait
Date: Mon, 9 Jun 2025 16:50:21 +0200 [thread overview]
Message-ID: <CANiq72=ph_XG0TtkdsNJCUZMiAMYBo11eJaCTLCTpTAFXtcNMA@mail.gmail.com> (raw)
In-Reply-To: <CAJxaTdMFp0WAB3BBDPUztVvTtDGUt9=KyHTDpDOgAZ4ZEk2XUw@mail.gmail.com>
On Mon, Jun 9, 2025 at 4:07 PM Igor Korotin
<igor.korotin.linux@gmail.com> wrote:
>
> 1. rename it to `_dev`. This is nasty to my opinion, because it is misleading.
Yes, please do not change the name that would be use in the "normal/full case".
> 2. add #[alloc(unused_variables)] on top of it. Also not good since it
> will suppress
> all other possible unused_variables as well.
This can be done conditionally with `cfg_attr`, but it is not great.
> 3. The third option is `let _ = dev;` in `#[cfg(not(CONFIG_OF))]`
> section. I came to
> it while I was writing this reply. This looks like the best option of
> three in my opinion.
Yeah.
Cheers,
Miguel
next prev parent reply other threads:[~2025-06-09 14:50 UTC|newest]
Thread overview: 21+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-06-06 17:03 [PATCH v3 0/4] rust: Add ACPI match table support for Rust drivers Igor Korotin
2025-06-06 17:06 ` [PATCH v3 1/4] rust: acpi: add `acpi::DeviceId` abstraction Igor Korotin
2025-06-08 7:48 ` Benno Lossin
2025-06-08 10:42 ` Danilo Krummrich
2025-06-06 17:08 ` [PATCH v3 2/4] rust: driver: Add ACPI id table support to Adapter trait Igor Korotin
2025-06-08 7:54 ` Benno Lossin
2025-06-08 10:48 ` Danilo Krummrich
2025-06-08 11:46 ` Benno Lossin
2025-06-08 11:49 ` Danilo Krummrich
2025-06-09 13:09 ` Igor Korotin
2025-06-09 13:42 ` Miguel Ojeda
[not found] ` <CAG7QV91u4rVgAqDjKAofupASSk9q0uRKNtsrHg7Q6KExRMkFog@mail.gmail.com>
2025-06-09 14:06 ` Igor Korotin
2025-06-09 14:50 ` Miguel Ojeda [this message]
2025-06-09 14:44 ` Benno Lossin
2025-06-06 17:09 ` [PATCH v3 3/4] rust: platform: Add ACPI match table support to `Driver` trait Igor Korotin
2025-06-07 6:28 ` kernel test robot
2025-06-08 10:58 ` Danilo Krummrich
2025-06-06 17:10 ` [PATCH v3 4/4] samples: rust: add ACPI match table example to platform driver Igor Korotin
2025-06-08 7:58 ` Benno Lossin
2025-06-08 10:50 ` Danilo Krummrich
2025-06-08 11:08 ` Danilo Krummrich
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='CANiq72=ph_XG0TtkdsNJCUZMiAMYBo11eJaCTLCTpTAFXtcNMA@mail.gmail.com' \
--to=miguel.ojeda.sandonis@gmail.com \
--cc=a.hindborg@kernel.org \
--cc=alex.gaynor@gmail.com \
--cc=alex.hung@amd.com \
--cc=aliceryhl@google.com \
--cc=benno.lossin@proton.me \
--cc=bjorn3_gh@protonmail.com \
--cc=boqun.feng@gmail.com \
--cc=dakr@kernel.org \
--cc=dingxiangfei2009@gmail.com \
--cc=gary@garyguo.net \
--cc=gregkh@linuxfoundation.org \
--cc=igor.korotin.linux@gmail.com \
--cc=lenb@kernel.org \
--cc=linux-acpi@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=lossin@kernel.org \
--cc=ojeda@kernel.org \
--cc=rafael@kernel.org \
--cc=rust-for-linux@vger.kernel.org \
--cc=tmgross@umich.edu \
--cc=viresh.kumar@linaro.org \
--cc=wedsonaf@gmail.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;
as well as URLs for NNTP newsgroup(s).