mirror of
https://github.com/phil-opp/blog_os.git
synced 2025-12-18 23:37:50 +00:00
reexport -> re-export
This commit is contained in:
@@ -598,7 +598,7 @@ pub fn map_to<A>(page: Page, frame: Frame, flags: EntryFlags,
|
||||
p1[page.p1_index()].set(frame, flags | PRESENT);
|
||||
}
|
||||
```
|
||||
We add an reexport for all `entry` types since they are required to call the function. We assert that the page is unmapped and always set the present flag (since it wouldn't make sense to map a page without setting it).
|
||||
We add an re-export for all `entry` types since they are required to call the function. We assert that the page is unmapped and always set the present flag (since it wouldn't make sense to map a page without setting it).
|
||||
|
||||
The `Table::next_table_create` method doesn't exist yet. It should return the next table if it exists, or create a new one. For the implementation we need the `FrameAllocator` from the [previous post] and the `Table::zero` method:
|
||||
|
||||
@@ -781,7 +781,7 @@ pub fn test_paging<A>(allocator: &mut A)
|
||||
// test it
|
||||
}
|
||||
```
|
||||
We borrow the frame allocator since we will need it for the mapping functions. To be able to call that function from main, we need to reexport it in `memory/mod.rs`:
|
||||
We borrow the frame allocator since we will need it for the mapping functions. To be able to call that function from main, we need to re-export it in `memory/mod.rs`:
|
||||
|
||||
```rust
|
||||
// in memory/mod.rs
|
||||
|
||||
Reference in New Issue
Block a user