-
Notifications
You must be signed in to change notification settings - Fork 157
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
RFC: Re-design SystemTable/BootServices/RuntimeServices #893
Comments
This would also make the uefi-services crate (in its current form) deprecated as we'd already have a static global of boot services in the uefi crate. I'd be in favor of deprecating uefi-services as well (#563 (comment)) eventually. |
I'm cautiously in favor of this proposal. We did something along these lines in #478, where we added a global image handle that gets set automatically by the The only downsides I can think of so far are:
|
Expanding on downside 1 from my list above with a related problem: Structs that currently have a lifetime tied to BootServices (like |
I've been playing around with this a bit, to get an idea of what it would look like in practice. I put up what I have for discussion: #905 A few notes:
|
A few more thoughts in favor of adding global pointers:
|
General notes on API direction:
Something I'm still unsure about is exactly what the intermediate upgrade path will be. I think ideally we'll just mark the current stuff as deprecated for at least one release, but it may be tricky in some areas to have both APIs present at once. I am working on updating the WIP PR. |
Summarizing recent changes:
Next steps:
|
Status of the implementation (I'll keep this updated as changes are merged): System
Runtime
Boot
|
Nice, looks good! All the checkboxes are now checked. |
Adding a few more tasks:
|
It might be already too late to clean this up, but perhaps, it might be a good idea to make a dedicated release with
How does that sound to you? This will make adoption and migration easier. |
I think that's a very good idea. I'll put up a revert for #1327, if we're not deprecating stuff yet then that change can wait. |
I went ahead and put up the release PR: #1330, anything else you can think of that we need to do before releasing 0.31? |
The checklist above is done, so I think we're ready for the deprecation release. I'll put up a PR. |
Next stage:
|
This also switches to the new API of the uefi crate that was introduced in version 0.31. The old api was deprecated in 0.32 and will be removed in 0.33. See https://github.com/rust-osdev/uefi-rs/blob/ac19526656953c32e8e0ef7bc703f7700b151ae4/docs/funcs_migration.md and rust-osdev/uefi-rs#893
This also switches to the new API of the uefi crate that was introduced in version 0.31. The old api was deprecated in 0.32 and will be removed in 0.33. See https://github.com/rust-osdev/uefi-rs/blob/ac19526656953c32e8e0ef7bc703f7700b151ae4/docs/funcs_migration.md and rust-osdev/uefi-rs#893
This also switches to the new API of the uefi crate that was introduced in version 0.31. The old api was deprecated in 0.32 and will be removed in 0.33. See https://github.com/rust-osdev/uefi-rs/blob/ac19526656953c32e8e0ef7bc703f7700b151ae4/docs/funcs_migration.md and rust-osdev/uefi-rs#893
Let's discuss #841 again which was unfortunately closed without further discussions.
Personally, I am in strong favor of the proposed API design. I copy the key points here again:
I'm especially in strong favor of renaming
#[entry]
to#[efi_main]
, simplify the function signature and not having to manually passbs
to so many functions. Instead, it should be provided by a global static.The text was updated successfully, but these errors were encountered: