Skip to content

uefi: Deprecate RuntimeServices #1365

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

Merged
Merged
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
3 changes: 3 additions & 0 deletions uefi-test-runner/src/main.rs
Original file line number Diff line number Diff line change
@@ -1,5 +1,8 @@
#![no_std]
#![no_main]
// TODO: temporarily allow deprecated code so that we can continue to test
// SystemTable/BootServices/RuntimeServices.
#![allow(deprecated)]

#[macro_use]
extern crate log;
Expand Down
1 change: 1 addition & 0 deletions uefi/src/prelude.rs
Original file line number Diff line number Diff line change
Expand Up @@ -6,5 +6,6 @@ pub use crate::{cstr16, cstr8, entry, Handle, ResultExt, Status, StatusExt};

// Import the basic table types.
pub use crate::table::boot::BootServices;
#[allow(deprecated)]
pub use crate::table::runtime::RuntimeServices;
pub use crate::table::{Boot, SystemTable};
3 changes: 3 additions & 0 deletions uefi/src/table/runtime.rs
Original file line number Diff line number Diff line change
@@ -1,5 +1,7 @@
//! UEFI services available at runtime, even after the OS boots.

#![allow(deprecated)]

pub use crate::runtime::{
CapsuleInfo, Time, TimeByteConversionError, TimeError, TimeParams, VariableStorageInfo,
};
Expand Down Expand Up @@ -35,6 +37,7 @@ use {
/// A reference to `RuntimeServices` can only be accessed by calling [`SystemTable::runtime_services`].
///
/// [`SystemTable::runtime_services`]: crate::table::SystemTable::runtime_services
#[deprecated = "Use the uefi::runtime module instead. See https://github.com/rust-osdev/uefi-rs/blob/HEAD/docs/funcs_migration.md"]
#[derive(Debug)]
#[repr(C)]
pub struct RuntimeServices(uefi_raw::table::runtime::RuntimeServices);
Expand Down
2 changes: 2 additions & 0 deletions uefi/src/table/system.rs
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
#![allow(deprecated)]

use super::boot::BootServices;
use super::runtime::{ResetType, RuntimeServices};
use super::{cfg, Revision};
Expand Down
Loading