From: Danilo Krummrich <dakr@kernel.org>
To: Lyude Paul <lyude@redhat.com>
Cc: rust-for-linux@vger.kernel.org,
"Greg Kroah-Hartman" <gregkh@linuxfoundation.org>,
"Maíra Canal" <mairacanal@riseup.net>,
"Miguel Ojeda" <ojeda@kernel.org>,
"Alex Gaynor" <alex.gaynor@gmail.com>,
"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>,
"Wedson Almeida Filho" <wedsonaf@gmail.com>,
"Mika Westerberg" <mika.westerberg@linux.intel.com>,
"Xiangfei Ding" <dingxiangfei2009@gmail.com>,
"open list" <linux-kernel@vger.kernel.org>
Subject: Re: [PATCH] rust/kernel: Add faux device bindings
Date: Fri, 7 Feb 2025 01:35:37 +0100 [thread overview]
Message-ID: <Z6VVWT_vqb9EGGqv@cassiopeiae> (raw)
In-Reply-To: <bab25d10d69e1b6b135cee69ee71be270ed92586.camel@redhat.com>
On Thu, Feb 06, 2025 at 07:21:24PM -0500, Lyude Paul wrote:
> But yeah - I mean, faux::Registration::as_ref::<device::Device>() lets you get
> a device::Device which you can take a reference on using ARef. So you still
> can take a reference count to the device without us adding support for it
> explicitly was what I was getting at.
Yeah, that's true. But it would be nice to have a separate type faux::Device for
that, just like the C struct faux_device only exists to make this obvious given
that it's defined as follows.
struct faux_device {
struct device dev;
};
But I don't think we need that right away. Having a faux::Registration with
as_raw() should be enough for now.
prev parent reply other threads:[~2025-02-07 0:35 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-02-06 21:04 [PATCH] rust/kernel: Add faux device bindings Lyude Paul
2025-02-06 21:44 ` Thomas Weißschuh
2025-02-06 22:30 ` Danilo Krummrich
2025-02-06 22:39 ` Danilo Krummrich
2025-02-06 23:04 ` Lyude Paul
2025-02-07 0:16 ` Danilo Krummrich
2025-02-07 0:21 ` Lyude Paul
2025-02-07 0:35 ` Danilo Krummrich [this message]
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=Z6VVWT_vqb9EGGqv@cassiopeiae \
--to=dakr@kernel.org \
--cc=a.hindborg@kernel.org \
--cc=alex.gaynor@gmail.com \
--cc=aliceryhl@google.com \
--cc=benno.lossin@proton.me \
--cc=bjorn3_gh@protonmail.com \
--cc=boqun.feng@gmail.com \
--cc=dingxiangfei2009@gmail.com \
--cc=gary@garyguo.net \
--cc=gregkh@linuxfoundation.org \
--cc=linux-kernel@vger.kernel.org \
--cc=lyude@redhat.com \
--cc=mairacanal@riseup.net \
--cc=mika.westerberg@linux.intel.com \
--cc=ojeda@kernel.org \
--cc=rust-for-linux@vger.kernel.org \
--cc=tmgross@umich.edu \
--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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.