Skip to content

Update set_virtual_address_map() to allow remapping of SystemTable #301

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 6 commits into from
Oct 18, 2021

Conversation

foxcob
Copy link
Contributor

@foxcob foxcob commented Oct 16, 2021

… struct.

* Updated set_virtual_address_map() to also take a new virtual address for the `SystemTableImpl` used internally.
* Provided new `SystemTable` function `get_current_system_table_addr()` to allow the caller to calculate a new virtual address.
@foxcob foxcob changed the title Update set_virtual_address_map() to allow remapping of SystemTable Update set_virtual_address_map() to allow remapping of SystemTable, fixes #278 Oct 16, 2021
@foxcob foxcob changed the title Update set_virtual_address_map() to allow remapping of SystemTable, fixes #278 Update set_virtual_address_map() to allow remapping of SystemTable Oct 16, 2021
…o method SystemTable::set_virtual_address_map().

* Cleanup implementation of SystemTable::set_virtual_address_map().
@foxcob
Copy link
Contributor Author

foxcob commented Oct 18, 2021

Will address the doc error

/// Changes the runtime addressing mode of EFI firmware from physical to virtual.
/// It is up to the caller to translate the old SystemTable address to a new virtual
/// address and provide it for this function.
/// See ['get_current_system_table_addr']
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Here and below in the link, change the single-quotes to backticks (` instead of ') so that code formatting is used.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Found it, thanks!

@nicholasbishop
Copy link
Member

Looks good, thanks for the PR!

@nicholasbishop nicholasbishop merged commit d0b78d0 into rust-osdev:master Oct 18, 2021
@foxcob foxcob deleted the fix_set_virtual_address_map branch October 18, 2021 16:19
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Remapping UEFI runtime services via set_virtual_address_map() breaks the SystemTable struct
2 participants