Skip to content

Commit 3005469

Browse files
hoshinolinajannau
authored andcommitted
drm/asahi: driver: Silence unused field warning
Signed-off-by: Asahi Lina <lina@asahilina.net>
1 parent 450dfde commit 3005469

1 file changed

Lines changed: 4 additions & 2 deletions

File tree

drivers/gpu/drm/asahi/driver.rs

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,9 @@ pub(crate) struct AsahiData {
2929
pub(crate) resources: regs::Resources,
3030
}
3131

32-
pub(crate) struct AsahiDriver(ARef<AsahiDevice>);
32+
pub(crate) struct AsahiDriver {
33+
_dev: ARef<AsahiDevice>,
34+
}
3335

3436
/// Convenience type alias for the DRM device type for this driver.
3537
pub(crate) type AsahiDevice = kernel::drm::device::Device<AsahiDriver>;
@@ -198,6 +200,6 @@ impl platform::Driver for AsahiDriver {
198200

199201
drm::drv::Registration::new_foreign_owned(drm.clone(), 0)?;
200202

201-
Ok(KBox::new(Self(drm), GFP_KERNEL)?.into())
203+
Ok(KBox::new(Self { _dev: drm }, GFP_KERNEL)?.into())
202204
}
203205
}

0 commit comments

Comments
 (0)