Skip to content

Commit cdfd321

Browse files
jannaujohn-cabaj
authored andcommitted
fixup! rust: drm: ioctl: Add DRM ioctl abstraction
use code::ERANGE to avoid type confusion with u32. Fixes following error in drivers/gpu/drm/asahi/driver.rs:57 | error[E0599]: no method named `to_errno` found for type `u32` in the current scope Signed-off-by: Janne Grunau <j@jannau.net> (cherry picked from commit e2de12b https://github.com/AsahiLinux/linux) Signed-off-by: John Cabaj <john.cabaj@canonical.com>
1 parent fb2a429 commit cdfd321

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

rust/kernel/drm/ioctl.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -136,7 +136,7 @@ macro_rules! declare_drm_ioctls {
136136

137137
match $func(dev, data, &file) {
138138
Err(e) => e.to_errno(),
139-
Ok(i) => i.try_into().unwrap_or(ERANGE.to_errno()),
139+
Ok(i) => i.try_into().unwrap_or(code::ERANGE.to_errno()),
140140
}
141141
}
142142
Some($cmd)

0 commit comments

Comments
 (0)