Tool bug fixes#560
Merged
Merged
Conversation
In main.rs, we build the system in multiple iterations to make setvar region_paddr works. However there was a bug in allocation.rs that did not return an error when the tool picked a bad physical address. The code will continue simulating the capDL allocation algorithm with bad physical addresses and cause the assert: assert_eq!(u64::from(named_obj.object.paddr().unwrap()), cur_paddr); to fail. Since the invariant that all physical addresses are valid at this point have been violated. This commit fixed the error check to always return an error. Signed-off-by: Bill Nguyen <bill.nguyen@unsw.edu.au>
In the system build process, the capDL initialiser object is mutated to pack the spec and estimate the available memory to user space. This process is iterative to work out the exact amout of available memory. But the code recycles the mutated object, which causes the PDs' program images to not be loaded correctly. We need to keep a fresh copy of the initialiser and use that fresh copy every iteration. Signed-off-by: Bill Nguyen <bill.nguyen@unsw.edu.au>
midnightveil
approved these changes
Jul 16, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
See commit messages for motivation.