Skip to content

Commit 0ac9805

Browse files
committed
uefi-raw: Add HII_CONFIG_ROUTING protocol bindings
1 parent 565b1aa commit 0ac9805

File tree

2 files changed

+49
-0
lines changed

2 files changed

+49
-0
lines changed

uefi-raw/CHANGELOG.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,7 @@
77
- Added `HiiConfigAccessProtocol`.
88
- Added `::octets()` for `Ipv4Address`, `Ipv6Address`, and
99
`MacAddress` to streamline the API with `core::net`.
10+
- Added `HiiConfigRoutingProtocol`.
1011

1112
## Changed
1213
- **Breaking:** The MSRV is now 1.85.1 and the crate uses the Rust 2024 edition.

uefi-raw/src/protocol/hii/config.rs

Lines changed: 48 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,7 @@
44
55
use core::fmt::Debug;
66

7+
use crate::protocol::device_path::DevicePathProtocol;
78
use crate::{Char16, Guid, Status, guid};
89

910
/// EFI_CONFIG_KEYWORD_HANDLER_PROTOCOL
@@ -172,3 +173,50 @@ pub struct HiiConfigAccessProtocol {
172173
impl HiiConfigAccessProtocol {
173174
pub const GUID: Guid = guid!("330d4706-f2a0-4e4f-a369-b66fa8d54385");
174175
}
176+
177+
/// EFI_HII_CONFIG_ROUTING_PROTOCOL
178+
#[derive(Debug)]
179+
#[repr(C)]
180+
pub struct HiiConfigRoutingProtocol {
181+
pub extract_config: unsafe extern "efiapi" fn(
182+
this: *const Self,
183+
config_request: *const Char16,
184+
progress: *mut *const Char16,
185+
results: *mut *const Char16,
186+
) -> Status,
187+
pub export_config:
188+
unsafe extern "efiapi" fn(this: *const Self, results: *mut *const Char16) -> Status,
189+
pub route_config: unsafe extern "efiapi" fn(
190+
this: *const Self,
191+
configuration: *const Char16,
192+
progress: *mut *const Char16,
193+
) -> Status,
194+
pub block_to_config: unsafe extern "efiapi" fn(
195+
this: *const Self,
196+
config_request: *const Char16,
197+
block: *const u8,
198+
block_size: usize,
199+
config: *mut *const Char16,
200+
progress: *mut *const Char16,
201+
) -> Status,
202+
pub config_to_block: unsafe extern "efiapi" fn(
203+
this: *const Self,
204+
config_resp: *const Char16,
205+
block: *mut *const u8,
206+
block_size: *mut usize,
207+
progress: *mut *const Char16,
208+
) -> Status,
209+
pub get_alt_cfg: unsafe extern "efiapi" fn(
210+
this: *const Self,
211+
config_resp: *const Char16,
212+
guid: *const Guid,
213+
name: *const Char16,
214+
device_path: *const DevicePathProtocol,
215+
alt_cfg_id: *const Char16,
216+
alt_cfg_resp: *mut *const Char16,
217+
) -> Status,
218+
}
219+
220+
impl HiiConfigRoutingProtocol {
221+
pub const GUID: Guid = guid!("587e72d7-cc50-4f79-8209-ca291fc1a10f");
222+
}

0 commit comments

Comments
 (0)