Skip to content

Commit 10f2b26

Browse files
committed
uefi: Add ConfigKeywordHandler and HiiConfigAccess protocol stubs
1 parent 1fcf4d8 commit 10f2b26

File tree

4 files changed

+38
-0
lines changed

4 files changed

+38
-0
lines changed

uefi/CHANGELOG.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,8 @@
44
- Added `ConfigTableEntry::MEMORY_ATTRIBUTES_GUID` and `ConfigTableEntry::IMAGE_SECURITY_DATABASE_GUID`.
55
- Added `proto::usb::io::UsbIo`.
66
- Added `proto::pci::PciRootBridgeIo`.
7+
- Added `proto::hii::config::ConfigKeywordHandler`.
8+
- Added `proto::hii::config::HiiConfigAccess`.
79

810
## Changed
911
- **Breaking:** `boot::stall` now take `core::time::Duration` instead of `usize`.

uefi/src/proto/hii/config.rs

Lines changed: 30 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,30 @@
1+
// SPDX-License-Identifier: MIT OR Apache-2.0
2+
3+
//! HII Configuration protocols.
4+
5+
use uefi_macros::unsafe_protocol;
6+
use uefi_raw::protocol::hii::config::{ConfigKeywordHandlerProtocol, HiiConfigAccessProtocol};
7+
8+
/// The HII Keyword Handler Protocol.
9+
///
10+
/// # UEFI Spec Description
11+
///
12+
/// This protocol provides the mechanism to set and get the values associated
13+
/// with a keyword exposed through a x-UEFI- prefixed configuration language namespace.
14+
#[derive(Debug)]
15+
#[repr(transparent)]
16+
#[unsafe_protocol(ConfigKeywordHandlerProtocol::GUID)]
17+
pub struct ConfigKeywordHandler(ConfigKeywordHandlerProtocol);
18+
19+
/// The HII Configuration Access Protocol.
20+
///
21+
/// # UEFI Spec Description
22+
///
23+
/// This protocol is responsible for facilitating access to configuration data from HII.
24+
/// It is typically invoked by the HII Configuration Routing Protocol for handling
25+
/// configuration requests. Forms browsers also interact with this protocol through
26+
/// the `Callback()` function.
27+
#[derive(Debug)]
28+
#[repr(transparent)]
29+
#[unsafe_protocol(HiiConfigAccessProtocol::GUID)]
30+
pub struct HiiConfigAccess(HiiConfigAccessProtocol);

uefi/src/proto/hii/mod.rs

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
// SPDX-License-Identifier: MIT OR Apache-2.0
2+
3+
//! HII Protocols
4+
5+
pub mod config;

uefi/src/proto/mod.rs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -37,6 +37,7 @@ pub mod console;
3737
pub mod debug;
3838
pub mod device_path;
3939
pub mod driver;
40+
pub mod hii;
4041
pub mod loaded_image;
4142
pub mod media;
4243
pub mod misc;

0 commit comments

Comments
 (0)