From: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
To: Josef Zoller <josef@walterzollerpiano.com>
Cc: "Arnd Bergmann" <arnd@arndb.de>,
"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>,
linux-kernel@vger.kernel.org, rust-for-linux@vger.kernel.org
Subject: Re: [PATCH 0/3] Character device abstractions for Rust
Date: Sat, 12 Oct 2024 09:29:32 +0200 [thread overview]
Message-ID: <2024101256-amplifier-joylessly-6ca9@gregkh> (raw)
In-Reply-To: <20241011-rust-char-dev-v1-0-350225ae228b@walterzollerpiano.com>
On Fri, Oct 11, 2024 at 08:55:41PM +0200, Josef Zoller wrote:
> Writing character devices is a common way to start writing kernel code,
> especially because of the book "Linux Device Drivers", which is still
> one of the best resources to learn about Linux kernel programming. To
> allow an easier entry into Rust kernel programming specifically, this
> series adds abstractions for these kinds of devices to the Rust API.
I understand this, but if at all possible, I would prefer that people
stick to using the misc char device interface instead. It's much
simpler and integrates better into the overall system (handles sysfs for
you automatically, etc.)
I've already merged the misc device rust bindings into my tree, so why
not just stick with them?
> I also included a sample that demonstrates how to use these abstractions
> to create the simplest example from LDD3, the "scull" device.
This is great, but why not just provide the scull example using misc
device?
> I'm also aware of the patch series about misc devices that was sent
> recently. I think these are both valuable additions to the Rust API, and
> could even be combined in some way, in which case the file operations
> abstractions in both series should probably be separated and
> generalized. But I'm still sending this series as it is, because it is
> my first ever patch and I could use some feedback on my approach.
That's great, but I'd prefer to stick with the misc code for now until
someone really really really proves that they want a "raw" char
interface.
thanks,
greg k-h
next prev parent reply other threads:[~2024-10-12 7:29 UTC|newest]
Thread overview: 11+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-10-11 18:55 [PATCH 0/3] Character device abstractions for Rust Josef Zoller
2024-10-11 18:55 ` [PATCH 1/3] rust: char_dev: add character device abstraction Josef Zoller
2024-10-12 7:36 ` Greg Kroah-Hartman
2024-10-12 21:48 ` Josef Zoller
2024-10-17 11:38 ` kernel test robot
2024-10-11 18:55 ` [PATCH 2/3] rust: macros: add IoctlCommand derive macro Josef Zoller
2024-10-11 18:55 ` [PATCH 3/3] samples: rust: add character device sample Josef Zoller
2024-10-12 12:37 ` Greg Kroah-Hartman
2024-10-12 23:38 ` Josef Zoller
2024-10-12 7:29 ` Greg Kroah-Hartman [this message]
2024-10-12 21:14 ` [PATCH 0/3] Character device abstractions for Rust Josef Zoller
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=2024101256-amplifier-joylessly-6ca9@gregkh \
--to=gregkh@linuxfoundation.org \
--cc=a.hindborg@kernel.org \
--cc=alex.gaynor@gmail.com \
--cc=aliceryhl@google.com \
--cc=arnd@arndb.de \
--cc=benno.lossin@proton.me \
--cc=bjorn3_gh@protonmail.com \
--cc=boqun.feng@gmail.com \
--cc=gary@garyguo.net \
--cc=josef@walterzollerpiano.com \
--cc=linux-kernel@vger.kernel.org \
--cc=ojeda@kernel.org \
--cc=rust-for-linux@vger.kernel.org \
--cc=tmgross@umich.edu \
/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).