Skip to content

Commit 6192d40

Browse files
authored
Merge pull request #2060 from hermit-os/rm-recursive_page_table
fix(x86_64): remove unused remains of recursive page tables
2 parents 4406c2f + 6bcf1d3 commit 6192d40

File tree

1 file changed

+1
-6
lines changed

1 file changed

+1
-6
lines changed

src/arch/x86_64/mm/paging.rs

Lines changed: 1 addition & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -12,8 +12,7 @@ use x86_64::structures::paging::frame::PhysFrameRange;
1212
use x86_64::structures::paging::mapper::{MapToError, MappedFrame, TranslateResult, UnmapError};
1313
use x86_64::structures::paging::page::PageRange;
1414
use x86_64::structures::paging::{
15-
FrameAllocator, Mapper, OffsetPageTable, Page, PageTable, PhysFrame, RecursivePageTable,
16-
Size4KiB, Translate,
15+
FrameAllocator, Mapper, OffsetPageTable, Page, PageTable, PhysFrame, Size4KiB, Translate,
1716
};
1817

1918
use crate::arch::x86_64::kernel::processor;
@@ -148,7 +147,6 @@ pub fn map<S>(
148147
flags: PageTableEntryFlags,
149148
) where
150149
S: PageSize + Debug,
151-
for<'a> RecursivePageTable<'a>: Mapper<S>,
152150
for<'a> OffsetPageTable<'a>: Mapper<S>,
153151
{
154152
let pages = {
@@ -208,7 +206,6 @@ pub fn map<S>(
208206
pub fn map_heap<S>(virt_addr: VirtAddr, count: usize) -> Result<(), usize>
209207
where
210208
S: PageSize + Debug,
211-
for<'a> RecursivePageTable<'a>: Mapper<S>,
212209
for<'a> OffsetPageTable<'a>: Mapper<S>,
213210
{
214211
let flags = {
@@ -232,7 +229,6 @@ where
232229
pub fn identity_map<S>(phys_addr: PhysAddr)
233230
where
234231
S: PageSize + Debug,
235-
for<'a> RecursivePageTable<'a>: Mapper<S>,
236232
for<'a> OffsetPageTable<'a>: Mapper<S>,
237233
{
238234
let frame = PhysFrame::<S>::from_start_address(phys_addr.into()).unwrap();
@@ -258,7 +254,6 @@ where
258254
pub fn unmap<S>(virtual_address: VirtAddr, count: usize)
259255
where
260256
S: PageSize + Debug,
261-
for<'a> RecursivePageTable<'a>: Mapper<S>,
262257
for<'a> OffsetPageTable<'a>: Mapper<S>,
263258
{
264259
trace!("Unmapping virtual address {virtual_address:p} ({count} pages)");

0 commit comments

Comments
 (0)