Skip to content

Commit 063af74

Browse files
uefi: Clean up imports of uefi
Consistently import items in the `uefi` crate with `crate::` instead of `uefi::`.
1 parent b0e8dd2 commit 063af74

File tree

3 files changed

+7
-5
lines changed

3 files changed

+7
-5
lines changed

uefi/src/helpers/mod.rs

+2-2
Original file line numberDiff line numberDiff line change
@@ -92,7 +92,7 @@ pub fn init(st: &mut SystemTable<Boot>) -> Result<()> {
9292

9393
#[cfg(feature = "global_allocator")]
9494
unsafe {
95-
uefi::allocator::init(st);
95+
crate::allocator::init(st);
9696
}
9797

9898
Ok(())
@@ -111,5 +111,5 @@ pub(crate) fn exit() {
111111
logger::disable();
112112

113113
#[cfg(feature = "global_allocator")]
114-
uefi::allocator::exit_boot_services();
114+
crate::allocator::exit_boot_services();
115115
}

uefi/src/helpers/panic_handler.rs

+2-2
Original file line numberDiff line numberDiff line change
@@ -29,9 +29,9 @@ fn panic_handler(info: &core::panic::PanicInfo) -> ! {
2929
} else {
3030
// If the system table is available, use UEFI's standard shutdown mechanism
3131
if let Some(st) = system_table_opt() {
32-
use uefi::table::runtime::ResetType;
32+
use crate::table::runtime::ResetType;
3333
st.runtime_services()
34-
.reset(ResetType::SHUTDOWN, uefi::Status::ABORTED, None);
34+
.reset(ResetType::SHUTDOWN, crate::Status::ABORTED, None);
3535
}
3636

3737
// If we don't have any shutdown mechanism handy, the best we can do is loop

uefi/src/proto/media/file/mod.rs

+3-1
Original file line numberDiff line numberDiff line change
@@ -15,10 +15,12 @@ use core::ffi::c_void;
1515
use core::fmt::Debug;
1616
use core::{mem, ptr};
1717
use uefi_raw::protocol::file_system::FileProtocolV1;
18+
1819
#[cfg(all(feature = "unstable", feature = "alloc"))]
1920
use {alloc::alloc::Global, core::alloc::Allocator};
21+
2022
#[cfg(feature = "alloc")]
21-
use {alloc::boxed::Box, uefi::mem::make_boxed};
23+
use {crate::mem::make_boxed, alloc::boxed::Box};
2224

2325
pub use self::dir::Directory;
2426
pub use self::info::{

0 commit comments

Comments
 (0)