Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix lints with Rust 1.86 #1601

Closed
wants to merge 1 commit into from
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion uefi/src/proto/driver/component_name.rs
Original file line number Diff line number Diff line change
Expand Up @@ -184,7 +184,7 @@ impl ComponentName {
///
/// [ISO 639-2]: https://en.wikipedia.org/wiki/List_of_ISO_639-2_codes
/// [RFC 4646]: https://www.rfc-editor.org/rfc/rfc4646
pub fn supported_languages(&self) -> core::result::Result<LanguageIter, LanguageError> {
pub const fn supported_languages(&self) -> core::result::Result<LanguageIter, LanguageError> {
match self {
Self::V1(cn1) => cn1.supported_languages(),
Self::V2(cn2) => cn2.supported_languages(),
Expand Down
14 changes: 7 additions & 7 deletions uefi/src/proto/media/block.rs
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ impl BlockIO {
///
/// # Arguments
/// * `extended_verification` Indicates that the driver may perform a more exhaustive verification operation of
/// the device during reset.
/// the device during reset.
///
/// # Errors
/// * `uefi::Status::DEVICE_ERROR` The block device is not functioning correctly and could not be reset.
Expand All @@ -41,13 +41,13 @@ impl BlockIO {
///
/// # Errors
/// * `uefi::Status::DEVICE_ERROR` The device reported an error while attempting to perform the read
/// operation.
/// operation.
/// * `uefi::Status::NO_MEDIA` There is no media in the device.
/// * `uefi::Status::MEDIA_CHANGED` The `media_id` is not for the current media.
/// * `uefi::Status::BAD_BUFFER_SIZE` The buffer size parameter is not a multiple of the intrinsic block size of
/// the device.
/// the device.
/// * `uefi::Status::INVALID_PARAMETER` The read request contains LBAs that are not valid, or the buffer is not on
/// proper alignment.
/// proper alignment.
pub fn read_blocks(&self, media_id: u32, lba: Lba, buffer: &mut [u8]) -> Result {
let buffer_size = buffer.len();
unsafe {
Expand All @@ -74,11 +74,11 @@ impl BlockIO {
/// * `uefi::Status::NO_MEDIA` There is no media in the device.
/// * `uefi::Status::MEDIA_CHANGED` The `media_id` is not for the current media.
/// * `uefi::Status::DEVICE_ERROR` The device reported an error while attempting to perform the write
/// operation.
/// operation.
/// * `uefi::Status::BAD_BUFFER_SIZE` The buffer size parameter is not a multiple of the intrinsic block size
/// of the device.
/// of the device.
/// * `uefi::Status::INVALID_PARAMETER` The write request contains LBAs that are not valid, or the buffer is not
/// on proper alignment.
/// on proper alignment.
pub fn write_blocks(&mut self, media_id: u32, lba: Lba, buffer: &[u8]) -> Result {
let buffer_size = buffer.len();
unsafe {
Expand Down
Loading