Skip to content

Commit ff5384d

Browse files
uefi-macros: Call set_image_handle from the entry macro
1 parent f14a72a commit ff5384d

File tree

2 files changed

+4
-0
lines changed

2 files changed

+4
-0
lines changed

uefi-macros/CHANGELOG.md

+3
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,8 @@
11
# uefi-macros - [Unreleased]
22

3+
## Changed
4+
- The `entry` macro now sets the global system table pointer with `uefi::set_system_table`.
5+
36
## Removed
47
- Removed the `cstr8` and `cstr16` macros. Use the declarative macros of the
58
same names exported by the `uefi` crate as a replacement.

uefi-macros/src/lib.rs

+1
Original file line numberDiff line numberDiff line change
@@ -204,6 +204,7 @@ pub fn entry(args: TokenStream, input: TokenStream) -> TokenStream {
204204
parse_quote! {
205205
unsafe {
206206
#system_table_ident.boot_services().set_image_handle(#image_handle_ident);
207+
::uefi::table::set_system_table(#system_table_ident.as_ptr().cast());
207208
}
208209
},
209210
);

0 commit comments

Comments
 (0)