diff options
| author | Asahi Lina <[email protected]> | 2025-04-10 23:55:26 +0000 |
|---|---|---|
| committer | Danilo Krummrich <[email protected]> | 2025-04-28 08:08:23 +0000 |
| commit | c284d3e423382be3591d5b1e402e330e6c3f726c (patch) | |
| tree | 965a13ac0a22001bf864e3512ce70467a2a560b1 /rust/helpers/helpers.c | |
| parent | rust: drm: file: Add File abstraction (diff) | |
| download | kernel-c284d3e423382be3591d5b1e402e330e6c3f726c.tar.gz kernel-c284d3e423382be3591d5b1e402e330e6c3f726c.zip | |
rust: drm: gem: Add GEM object abstraction
DRM GEM is the DRM memory management subsystem used by most modern
drivers; add a Rust abstraction for DRM GEM.
This includes the BaseObject trait, which contains operations shared by
all GEM object classes.
Signed-off-by: Asahi Lina <[email protected]>
Reviewed-by: Alyssa Rosenzweig <[email protected]>
Reviewed-by: Lyude Paul <[email protected]>
Link: https://lore.kernel.org/r/[email protected]
[ Rework of GEM object abstractions
* switch to the Opaque<T> type
* fix (mutable) references to struct drm_gem_object (which in this
context is UB)
* drop all custom reference types in favor of AlwaysRefCounted
* bunch of minor changes and simplifications (e.g. IntoGEMObject
trait)
* write and fix safety and invariant comments
* remove necessity for and convert 'as' casts
* original source archive: https://archive.is/dD5SL
- Danilo ]
[ Fix missing CONFIG_DRM guards in rust/helpers/drm.c. - Danilo ]
Signed-off-by: Danilo Krummrich <[email protected]>
Diffstat (limited to 'rust/helpers/helpers.c')
| -rw-r--r-- | rust/helpers/helpers.c | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/rust/helpers/helpers.c b/rust/helpers/helpers.c index 6b279279cb12..6c205454a18e 100644 --- a/rust/helpers/helpers.c +++ b/rust/helpers/helpers.c @@ -15,6 +15,7 @@ #include "cpumask.c" #include "cred.c" #include "device.c" +#include "drm.c" #include "err.c" #include "fs.c" #include "io.c" |
