From: Lyude Paul <lyude@redhat.com>
To: dri-devel@lists.freedesktop.org, rust-for-linux@vger.kernel.org,
linux-kernel@vger.kernel.org
Cc: "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>,
"Danilo Krummrich" <dakr@kernel.org>,
"Sumit Semwal" <sumit.semwal@linaro.org>,
"Christian König" <christian.koenig@amd.com>,
linux-media@vger.kernel.org (open list:DMA BUFFER SHARING
FRAMEWORK:Keyword:bdma_(?:buf|fence|resv)b),
linaro-mm-sig@lists.linaro.org (moderated list:DMA BUFFER
SHARING FRAMEWORK:Keyword:bdma_(?:buf|fence|resv)b)
Subject: [PATCH v2 00/12] Rust abstractions for shmem-backed GEM objects
Date: Wed, 21 May 2025 16:29:07 -0400 [thread overview]
Message-ID: <20250521204654.1610607-1-lyude@redhat.com> (raw)
This is the next version of the shmem backed GEM objects series
originally from Asahi, previously posted by Daniel Almeida. Along with
bindings for shmem backed GEM objects, it also adds a few features that
various users like Tyr and Asahi are interested in:
* The ability to pass custom arguments to new GEM objects (needed by
Tyr)
* OpaqueObject (to enable the use of custom private GEM objects, which I
believe asahi wanted)
And replaces some of the hand-rolled API bindings (sg_table mainly) with
some of the WIP patch series for adding kernel-wide bindings. It also
addresses the comments from the code review of the last version of this
patch series.
Currently doesn't apply on an upstream branch, but should very soon as
all of the dependencies in this series are on a mailing list already.
The current branch this can be applied on top of is here:
https://gitlab.freedesktop.org/lyudess/linux/-/commits/rust%2Fgem-shmem-base
Which is based on top of nova/nova-next with the following patch series
applied:
* My (hopefully final) gem bindings cleanup:
https://lkml.org/lkml/2025/5/20/1541
* Benno's derive Zeroable series:
https://lkml.org/lkml/2025/5/20/1446
* Abdiel's sg_table series:
https://lwn.net/Articles/1020986/
Also, there is one FIXES patch on top of Abdiel's work to fix some
iterator bugs. These fixes have already been mentioned on the
mailing list and should not be needed for their V2 version
Asahi Lina (3):
rust: helpers: Add bindings/wrappers for dma_resv_lock
rust: drm: gem: shmem: Add DRM shmem helper abstraction
rust: drm: gem: shmem: Add share_dma_resv to ObjectConfig
Lyude Paul (9):
rust: drm: gem: Add raw_dma_resv() function
drm/gem/shmem: Extract drm_gem_shmem_init() from
drm_gem_shmem_create()
drm/gem/shmem: Extract drm_gem_shmem_release() from
drm_gem_shmem_free()
rust: gem: Introduce BaseDriverObject::Args
rust: drm: gem: Add OpaqueObject
rust: drm: gem: Introduce OwnedSGTable
rust: Add dma_buf stub bindings
rust: drm: gem: Add export() callback
rust: drm: gem: Add BaseObject::prime_export()
drivers/gpu/drm/drm_gem_shmem_helper.c | 98 +++++--
drivers/gpu/drm/nova/gem.rs | 6 +-
include/drm/drm_gem_shmem_helper.h | 2 +
rust/bindings/bindings_helper.h | 4 +
rust/helpers/dma-resv.c | 13 +
rust/helpers/drm.c | 48 +++-
rust/helpers/helpers.c | 1 +
rust/kernel/dma_buf.rs | 39 +++
rust/kernel/drm/gem/mod.rs | 187 ++++++++++++-
rust/kernel/drm/gem/shmem.rs | 370 +++++++++++++++++++++++++
rust/kernel/lib.rs | 1 +
11 files changed, 727 insertions(+), 42 deletions(-)
create mode 100644 rust/helpers/dma-resv.c
create mode 100644 rust/kernel/dma_buf.rs
create mode 100644 rust/kernel/drm/gem/shmem.rs
--
2.49.0
next reply other threads:[~2025-05-21 20:47 UTC|newest]
Thread overview: 15+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-05-21 20:29 Lyude Paul [this message]
2025-05-21 20:29 ` [PATCH v2 01/12] rust: helpers: Add bindings/wrappers for dma_resv_lock Lyude Paul
2025-05-22 8:44 ` Christian König
2025-05-22 15:03 ` Daniel Almeida
2025-05-21 20:29 ` [PATCH v2 02/12] rust: drm: gem: Add raw_dma_resv() function Lyude Paul
2025-05-21 20:29 ` [PATCH v2 03/12] drm/gem/shmem: Extract drm_gem_shmem_init() from drm_gem_shmem_create() Lyude Paul
2025-05-21 20:29 ` [PATCH v2 04/12] drm/gem/shmem: Extract drm_gem_shmem_release() from drm_gem_shmem_free() Lyude Paul
2025-05-21 20:29 ` [PATCH v2 05/12] rust: gem: Introduce BaseDriverObject::Args Lyude Paul
2025-05-21 20:29 ` [PATCH v2 06/12] rust: drm: gem: Add OpaqueObject Lyude Paul
2025-05-21 20:29 ` [PATCH v2 07/12] rust: drm: gem: shmem: Add DRM shmem helper abstraction Lyude Paul
2025-05-21 20:29 ` [PATCH v2 08/12] rust: drm: gem: shmem: Add share_dma_resv to ObjectConfig Lyude Paul
2025-05-21 20:29 ` [PATCH v2 09/12] rust: drm: gem: Introduce OwnedSGTable Lyude Paul
2025-05-21 20:29 ` [PATCH v2 10/12] rust: Add dma_buf stub bindings Lyude Paul
2025-05-21 20:29 ` [PATCH v2 11/12] rust: drm: gem: Add export() callback Lyude Paul
2025-05-21 20:29 ` [PATCH v2 12/12] rust: drm: gem: Add BaseObject::prime_export() Lyude Paul
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=20250521204654.1610607-1-lyude@redhat.com \
--to=lyude@redhat.com \
--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=christian.koenig@amd.com \
--cc=dakr@kernel.org \
--cc=dri-devel@lists.freedesktop.org \
--cc=gary@garyguo.net \
--cc=linaro-mm-sig@lists.linaro.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-media@vger.kernel.org \
--cc=ojeda@kernel.org \
--cc=rust-for-linux@vger.kernel.org \
--cc=sumit.semwal@linaro.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