File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -64,13 +64,15 @@ pub(crate) const IOVA_USER_TOP: u64 = 1 << (UAT_IAS as u64);
6464pub ( crate ) const IOVA_USER_RANGE : Range < u64 > = IOVA_USER_BASE ..IOVA_USER_TOP ;
6565
6666/// Upper/kernel base VA
67- // const IOVA_TTBR1_BASE: usize = 0xffffff8000000000;
67+ const IOVA_TTBR1_BASE : u64 = 0xffffff8000000000 ;
6868/// Driver-managed kernel base VA
6969const IOVA_KERN_BASE : u64 = 0xffffffa000000000 ;
7070/// Driver-managed kernel top VA
7171const IOVA_KERN_TOP : u64 = 0xffffffb000000000 ;
72- /// Lower/user VA range
72+ /// Driver-managed kernel VA range
7373const IOVA_KERN_RANGE : Range < u64 > = IOVA_KERN_BASE ..IOVA_KERN_TOP ;
74+ /// Full kernel VA range
75+ const IOVA_KERN_FULL_RANGE : Range < u64 > = IOVA_TTBR1_BASE ..( !UAT_PGMSK as u64 ) ;
7476
7577const TTBR_VALID : u64 = 0x1 ; // BIT(0)
7678const TTBR_ASID_SHIFT : usize = 48 ;
@@ -1380,6 +1382,11 @@ impl Uat {
13801382 & self . kernel_lower_vm
13811383 }
13821384
1385+ pub ( crate ) fn dump_kernel_pages ( & self ) -> Result < KVVec < pgtable:: DumpedPage > > {
1386+ let mut inner = self . kernel_vm . inner . exec_lock ( None , false ) ?;
1387+ inner. page_table . dump_pages ( IOVA_KERN_FULL_RANGE )
1388+ }
1389+
13831390 /// Returns the base physical address of the TTBAT region.
13841391 pub ( crate ) fn ttb_base ( & self ) -> u64 {
13851392 let inner = self . inner . lock ( ) ;
You can’t perform that action at this time.
0 commit comments