mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Daniel Almeida <daniel.almeida@collabora.com>
To: Danilo Krummrich <dakr@kernel.org>
Cc: aliceryhl@google.com, acourbot@nvidia.com, ojeda@kernel.org,
	boqun@kernel.org, gary@garyguo.net, bjorn3_gh@protonmail.com,
	lossin@kernel.org, a.hindborg@kernel.org, tmgross@umich.edu,
	tamird@kernel.org, work@onurozkan.dev, brauner@kernel.org,
	lyude@redhat.com, j@jananu.net, alvin.sun@linux.dev,
	deborah.brouwer@collabora.com, laura.nao@collabora.com,
	beata.michalska@arm.com, nova-gpu@lists.linux.dev,
	dri-devel@lists.freedesktop.org, rust-for-linux@vger.kernel.org,
	linux-kernel@vger.kernel.org
Subject: Re: [PATCH 4/7] rust: fs: add iminor() helper
Date: Fri, 9 Oct 2026 14:43:01 -0300	[thread overview]
Message-ID: <6395D58C-F3CC-4B2E-8B20-6EEEB92070DC@collabora.com> (raw)
In-Reply-To: <20260814230923.1292966-5-dakr@kernel.org>



> On 14 Aug 2026, at 20:09, Danilo Krummrich <dakr@kernel.org> wrote:
> 
> Add a Rust helper for iminor(), which extracts the minor number from a
> struct inode. This is a static inline function in the C headers, so
> bindgen does not generate a binding for it.
> 
> Signed-off-by: Danilo Krummrich <dakr@kernel.org>
> ---
> rust/helpers/fs.c | 5 +++++
> 1 file changed, 5 insertions(+)
> 
> diff --git a/rust/helpers/fs.c b/rust/helpers/fs.c
> index 789d60fb8908..d6f9782db178 100644
> --- a/rust/helpers/fs.c
> +++ b/rust/helpers/fs.c
> @@ -10,3 +10,8 @@ __rust_helper struct file *rust_helper_get_file(struct file *f)
> {
> return get_file(f);
> }
> +
> +__rust_helper unsigned int rust_helper_iminor(const struct inode *inode)
> +{
> + return iminor(inode);
> +}
> -- 
> 2.55.0
> 
> 


Reviewed-by: Daniel Almeida <daniel.almeida@collabora.com>

  reply	other threads:[~2026-10-09 17:43 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-08-14 23:08 [PATCH 0/7] lifetime-parameterized DRM File private data Danilo Krummrich
2026-08-14 23:08 ` [PATCH 1/7] rust: drm: rename Ioctl device context to Userspace Danilo Krummrich
2026-10-09 16:55   ` Daniel Almeida
2026-08-14 23:09 ` [PATCH 2/7] rust: drm: gem: gate open/close callbacks with RegistrationGuard Danilo Krummrich
2026-08-14 23:09 ` [PATCH 3/7] rust: drm: move file_operations from gem to device Danilo Krummrich
2026-10-09 17:42   ` Daniel Almeida
2026-08-14 23:09 ` [PATCH 4/7] rust: fs: add iminor() helper Danilo Krummrich
2026-10-09 17:43   ` Daniel Almeida [this message]
2026-08-14 23:09 ` [PATCH 5/7] rust: drm: wrap fops open with RegistrationGuard Danilo Krummrich
2026-10-09 18:07   ` Daniel Almeida
2026-08-14 23:09 ` [PATCH 6/7] rust: drm: make Driver::File lifetime-parameterized Danilo Krummrich
2026-08-14 23:09 ` [PATCH 7/7] rust: drm: return impl PinInit from DriverFile::open() 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=6395D58C-F3CC-4B2E-8B20-6EEEB92070DC@collabora.com \
    --to=daniel.almeida@collabora.com \
    --cc=a.hindborg@kernel.org \
    --cc=acourbot@nvidia.com \
    --cc=aliceryhl@google.com \
    --cc=alvin.sun@linux.dev \
    --cc=beata.michalska@arm.com \
    --cc=bjorn3_gh@protonmail.com \
    --cc=boqun@kernel.org \
    --cc=brauner@kernel.org \
    --cc=dakr@kernel.org \
    --cc=deborah.brouwer@collabora.com \
    --cc=dri-devel@lists.freedesktop.org \
    --cc=gary@garyguo.net \
    --cc=j@jananu.net \
    --cc=laura.nao@collabora.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=lossin@kernel.org \
    --cc=lyude@redhat.com \
    --cc=nova-gpu@lists.linux.dev \
    --cc=ojeda@kernel.org \
    --cc=rust-for-linux@vger.kernel.org \
    --cc=tamird@kernel.org \
    --cc=tmgross@umich.edu \
    --cc=work@onurozkan.dev \
    /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

all inboxes | Powered by JetHome®