aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--rust/kernel/error.rs2
1 files changed, 1 insertions, 1 deletions
diff --git a/rust/kernel/error.rs b/rust/kernel/error.rs
index 5f4114b30b94c..01dd4d2f63d27 100644
--- a/rust/kernel/error.rs
+++ b/rust/kernel/error.rs
@@ -177,7 +177,7 @@ impl From<core::convert::Infallible> for Error {
/// Note that even if a function does not return anything when it succeeds,
/// it should still be modeled as returning a `Result` rather than
/// just an [`Error`].
-pub type Result<T = ()> = core::result::Result<T, Error>;
+pub type Result<T = (), E = Error> = core::result::Result<T, E>;
/// Converts an integer as returned by a C kernel function to an error if it's negative, and
/// `Ok(())` otherwise.