mirror of
https://github.com/asterinas/asterinas.git
synced 2025-06-24 18:03:25 +00:00
Avoid generic_const_exprs
feature
This commit is contained in:
committed by
Tate, Hongliang Tian
parent
b08e655a76
commit
0d36375dfa
@ -9,8 +9,8 @@ use core::{
|
||||
};
|
||||
|
||||
use super::{
|
||||
io::PodOnce, nr_subpage_per_huge, page_prop::PageProperty, page_size, Paddr, PagingConstsTrait,
|
||||
PagingLevel, Vaddr,
|
||||
nr_subpage_per_huge, page_prop::PageProperty, page_size, Paddr, PagingConstsTrait, PagingLevel,
|
||||
PodOnce, Vaddr,
|
||||
};
|
||||
use crate::{
|
||||
arch::mm::{PageTableEntry, PagingConsts},
|
||||
@ -84,9 +84,7 @@ pub struct PageTable<
|
||||
M: PageTableMode,
|
||||
E: PageTableEntryTrait = PageTableEntry,
|
||||
C: PagingConstsTrait = PagingConsts,
|
||||
> where
|
||||
[(); C::NR_LEVELS as usize]:,
|
||||
{
|
||||
> {
|
||||
root: RawPageTableNode<E, C>,
|
||||
_phantom: PhantomData<M>,
|
||||
}
|
||||
@ -201,10 +199,7 @@ impl PageTable<KernelMode> {
|
||||
}
|
||||
}
|
||||
|
||||
impl<'a, M: PageTableMode, E: PageTableEntryTrait, C: PagingConstsTrait> PageTable<M, E, C>
|
||||
where
|
||||
[(); C::NR_LEVELS as usize]:,
|
||||
{
|
||||
impl<'a, M: PageTableMode, E: PageTableEntryTrait, C: PagingConstsTrait> PageTable<M, E, C> {
|
||||
/// Create a new empty page table. Useful for the kernel page table and IOMMU page tables only.
|
||||
pub fn empty() -> Self {
|
||||
PageTable {
|
||||
|
Reference in New Issue
Block a user