File tree Expand file tree Collapse file tree 2 files changed +9
-5
lines changed Expand file tree Collapse file tree 2 files changed +9
-5
lines changed Original file line number Diff line number Diff line change 4
4
5
5
use core:: ops:: RangeInclusive ;
6
6
7
- use aarch64_cpu:: { asm:: barrier, registers:: * } ;
8
- use tock_registers:: interfaces:: { ReadWriteable , Readable , Writeable } ;
7
+ use aarch64_cpu:: {
8
+ asm:: barrier,
9
+ registers:: { Readable , Writeable , * } ,
10
+ } ;
9
11
10
12
use self :: interface:: Mmu ;
11
13
@@ -287,7 +289,10 @@ impl interface::Mmu for MemoryManagementUnit {
287
289
barrier:: isb ( barrier:: SY ) ;
288
290
289
291
// Enable the MMU and turn on data and instruction caching.
290
- SCTLR_EL1 . modify ( SCTLR_EL1 :: M :: Enable + SCTLR_EL1 :: C :: Cacheable + SCTLR_EL1 :: I :: Cacheable ) ;
292
+ SCTLR_EL1 . modify_no_read (
293
+ SCTLR_EL1 . extract ( ) ,
294
+ SCTLR_EL1 :: M :: Enable + SCTLR_EL1 :: C :: Cacheable + SCTLR_EL1 :: I :: Cacheable ,
295
+ ) ;
291
296
292
297
// Force MMU init to complete before next instruction.
293
298
barrier:: isb ( barrier:: SY ) ;
Original file line number Diff line number Diff line change 2
2
// Copyright (C) 2023 Akira Moroo
3
3
4
4
use aarch64_cpu:: registers:: * ;
5
- use tock_registers:: interfaces:: ReadWriteable ;
6
5
7
6
pub fn setup_simd ( ) {
8
- CPACR_EL1 . modify ( CPACR_EL1 :: FPEN :: TrapNothing ) ;
7
+ CPACR_EL1 . modify_no_read ( CPACR_EL1 . extract ( ) , CPACR_EL1 :: FPEN :: TrapNothing ) ;
9
8
}
You can’t perform that action at this time.
0 commit comments