patina-v12.1.0
What's Changed
-
patina\_samples: Follow Patina component layout conventions @makubacki (#935)
Change Details
## Description
Updates the crate to follow Patina component conventions as described in RFC
0009-standardize-component-crate.This also positions the crate to more cleanly support new samples being added in the future.
- Impacts functionality?
- Impacts security?
- Breaking change?
- Includes tests?
- Includes documentation?
How This Was Tested
cargo make allcargo make doc-opento reviewpatina_samplesdocumentation
Integration Instructions
Access the currently provided samples with the following paths:
component::hello_world::HelloStructcomponent::hello_world::GreetingsEnum
-
patina: Remove pi/address\_helpers [Rebase \& FF] @makubacki (#934)
Change Details
## Description
The
align_up()andalign_down()function inaddress_helpersare redundant with the existing and more accessible functions inpatina::base. They are removed here in favor of having a single set of alignment functions inpatina::base.Note: The
patina::basefunctions are notconstas a tradeoff for a trait bound clause, that's acknowledged as acceptable for now in this change.- Impacts functionality?
- Impacts security?
- Breaking change?
- Includes tests?
- Includes documentation?
How This Was Tested
cargo make all- QEMU Q35 boot
Integration Instructions
- The
address_helpersmodule is no longer available. Use the alignment functions inpatina::base.
-
Add safety comments for patina\_internal\_device\_path @apop5 (#895)
Change Details
## Description
Add safety comments for patina_internal_device_path
- Impacts functionality?
- Impacts security?
- Breaking change?
- Includes tests?
- Includes documentation?
How This Was Tested
Comments only.
Passedcargo make clippy
with Makefile.toml modified to include"-W", "clippy::undocumented_unsafe_blocks"Integration Instructions
No integration necessary.
-
patina\_mm: Add missing safety comments @makubacki (#892)
Change Details
## Description
Adds missing safety comments to the
patina_mmcrate.- Impacts functionality?
- Impacts security?
- Breaking change?
- Includes tests?
- Includes documentation?
How This Was Tested
cargo make allpatina_mmresults fromcargo clippy --all-targets -- -W clippy::undocumented_unsafe_blocks
Integration Instructions
- N/A
-
patina: test: Update how tests are executed @Javagedes (#925)
Change Details
## Description
Recent changes to how tests were executed and filtered with the
enable_patina_testfeature resulted in almost no testing actually being performed for the functionality. This pull-request updates how we test thepatina-testlogic, so that it does not rely on theenable_patina_testfeature being enabled.It does this in two parts:
- Creates a second static collection of patina-tests that only collects fake patina-tests from the local file.
- Splits the main logic of
TestRunnerinto two parts. The first collects the patina-tests, and the second runs the patina-tests. This allowed us properly test the patina-test execution process by passing in our second static collection of controlled patina-tests.
- Impacts functionality?
- Impacts security?
- Breaking change?
- Includes tests?
- Includes documentation?
How This Was Tested
CI
Integration Instructions
N/A
-
chore: Release v12.0.0 @makubacki (#926)
Change Details
## Description
Updates the version for the 12.0.0 release.
As of this release,
patina_piis no longer published. The content is now accessible inpatina::pi.- Impacts functionality?
- Impacts security?
- Breaking change?
- Includes tests?
- Includes documentation?
How This Was Tested
- N/A
Integration Instructions
- N/A
🚀 Features & ✨ Enhancements
-
patina: Add the BinaryGuid type @makubacki (#929)
Change Details
## Description
Closes #901
Adds a new
BinaryGuidtype that can be directly used in C compatible binary structures in place ofr_efi::efi::Guid.The guid module documentation is updated to describe when to use this type versus the pre-existing Guid types.
- Impacts functionality?
- Impacts security?
- Breaking change?
- Includes tests?
- Includes documentation?
How This Was Tested
cargo make all(which includes unit tests)
Integration Instructions
- No special integration is needed. Review the included documentation to understand how to use
BinaryGuid.
🐛 Bug Fixes
-
patina\_dxe\_core: Prevent spurious test failures @makubacki (#936)
Change Details
## Description
Three dispatcher tests in dxe_services.rs added in 1d9a702 were failing intermittently when run in parallel. The tests call
dispatch()which depends on theDISPATCHER_CONTEXTglobal static, but the dxe_services.rs test helper did not reset this context between test runs, causing tests to inherit leftover state from previous tests which could cause tests to fail depending on test dispatch order.This change adds a function called
reset_dispatcher_context_for_teststo dispatcher.rs to use in the dxe_services.rs test setup to clean state for all dispatch-related tests. It also cleans up repeated functions called throughout unit tests indxe_services.- Impacts functionality?
- Impacts security?
- Breaking change?
- Includes tests?
- Includes documentation?
How This Was Tested
Tested by running:
cargo test --lib --package patina_dxe_core test_dispatchIn sets of 10 runs 10 times in a row. Before this change failure rate was an average of 60%, after 0%.
Integration Instructions
- N/A
-
Change the image handle for the EFI System Table Pointer structure to EfiRuntimeServicesData. @joschock (#931)
Change Details
## Description
This PR changes the image handle for the allocation for the EFI System Table Pointer structure to be EfiBootServicesData; the prior use of the DXE_CORE_HANDLE caused the region to appear as free in the memory map.
- Impacts functionality?
- Impacts security?
- Breaking change?
- Includes tests?
- Includes documentation?
How This Was Tested
Confirmed windows boot with the change, verified memory map by inspection.
Integration Instructions
N/A
-
patina\_debugger: Fix OS lock check for aarch64 @cfernald (#930)
Change Details
## Description
When the OS lock register is set, certain debug features like single stepping will not be allowed. This has been observed on aarch64 systems where the OS lock is set initially. This fixes a typo on the initial implementation that checked the wrong bit in the system register that shows the status of the OS lock.
- Impacts functionality?
- Impacts security?
- Breaking change?
- Includes tests?
- Includes documentation?
How This Was Tested
- Tested on physical aarch64 system
Integration Instructions
N/A
📖 Documentation Updates
-
patina: Add the BinaryGuid type @makubacki (#929)
Change Details
## Description
Closes #901
Adds a new
BinaryGuidtype that can be directly used in C compatible binary structures in place ofr_efi::efi::Guid.The guid module documentation is updated to describe when to use this type versus the pre-existing Guid types.
- Impacts functionality?
- Impacts security?
- Breaking change?
- Includes tests?
- Includes documentation?
How This Was Tested
cargo make all(which includes unit tests)
Integration Instructions
- No special integration is needed. Review the included documentation to understand how to use
BinaryGuid.
Full Changelog: patina-v12.0.0...v12.1.0