Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
rust/kernel: remove
Error::from_kernel_errno()
dead code warning
It turns out that we don't need an `Error` constructor that checks the `errno` invariant at runtime. This is because we trust return values originating from kernel C. And any return values originating from Rust code can be constucted using `Error::` constants, which also do not need a runtime check: ```rust return Err(Error::EBUSY); ``` However, there is still ongoing discussion about the merits and purpose of this function. To facilitate this discussion, keep the function for the time being, and remove the "dead code" warning. Signed-off-by: Sven Van Asbroeck <[email protected]>
- Loading branch information