AArch64: speed up paging and fix exception caused by atomic operation#250
Merged
retrage merged 4 commits intocloud-hypervisor:mainfrom May 28, 2023
Merged
AArch64: speed up paging and fix exception caused by atomic operation#250retrage merged 4 commits intocloud-hypervisor:mainfrom
retrage merged 4 commits intocloud-hypervisor:mainfrom
Conversation
Atomic operation may cause exception when MMU is not enabled. Serial device struct is containered by atomic refcell that should be done after MMU is enabled. Signed-off-by: Jianyong Wu <jianyong.wu@arm.com>
Firmware region is used for edk2 thus will not be used here. Merge it into MMIO region to speed up page table creation. Also enlarge memory map size to 128G then we can use large memory when boot from rust firmware. Signed-off-by: Jianyong Wu <jianyong.wu@arm.com>
To set different page attribute for code segment, it must be align with page size which is 64kB in current implementation. Signed-off-by: Jianyong Wu <jianyong.wu@arm.com>
Member
|
Please fix your formatting. |
Creating page table takes 8K * 2 * MEM_SIZE(GB) times loop while each loop is time-consuming. It may takes a few seconds to complete page table creating. As a certain memory region has the same memory attribute, saying the whole MMIO region and the most normal memory, we can simply use 512M block to map the region instead of use 64kB page. Also, there is some optimization in page table creating algorithm. After this change, page table creating takes only dozens of ms. Signed-off-by: Jianyong Wu <jianyong.wu@arm.com>
7522586 to
d73060a
Compare
retrage
requested changes
May 15, 2023
Contributor
retrage
left a comment
There was a problem hiding this comment.
Please remove the debug-related commit (d73060a) from your PR, as it's too specific to your testing environment. If you want to keep the debug feature, you should provide scripts and documents so that other people can use it.
Contributor
Author
OK, I will remove it currently. |
Contributor
|
@rbradford Yes, as it's listed on the tracking issue #198. I'd like to try vanilla Ubuntu cloud images with this PR changes. |
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.
There are some issues for rust firmware on arm64:
Two of them:
To address above issues: