-
Notifications
You must be signed in to change notification settings - Fork 36
feat: add ARMv7-A support with page table structures and tests #31
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
base: main
Are you sure you want to change the base?
Conversation
equation314
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Currently, PagingHandler::alloc_frame is designed to support pages of only 4KB in size, but the L1 page table in ARMv7-A is 16KB.
It may require updating the page frame allocation interface, such as #16.
This comment was marked as resolved.
This comment was marked as resolved.
…x extraction functions
Unifies the public API by re-exporting architecture-specific definitions, making them accessible to downstream users without direct module imports. Improves usability and reduces friction for multi-arch consumers.
…e table structures
… improve common flag logic
…nd GenericPTE implementations
…include documentation support
| // Deallocate all L2 page tables (each is 4KB) | ||
| let table = self.get_table(self.root_paddr); | ||
| for entry in table { | ||
| if !entry.is_unused() && !entry.is_huge() { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It may cause double-free if another page table is created by copy_from. See the solution in PageTable64.
| // TODO: tune threshold; employ a more advanced data structure | ||
| const SMALL_FLUSH_THRESHOLD: usize = 32; | ||
|
|
||
| enum TlbFlusher<M: PagingMetaData> { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Move this common enum to lib.rs
This module implements page table entries for ARMv7-A architecture using
the Short-descriptor format, which supports 2-level page tables: