2 files changed +2
-4
lines changed Original file line number Diff line number Diff line change @@ -239,7 +239,7 @@ of a raw address. The following is an example for the `UART`:
239
239
impl PL011Uart {
240
240
/// Create an instance.
241
241
pub const unsafe fn new (
242
- phys_mmio_descriptor : memory :: mmu :: MMIODescriptor < Physical > ,
242
+ mmio_descriptor : memory :: mmu :: MMIODescriptor ,
243
243
irq_number : bsp :: device_driver :: IRQNumber ,
244
244
) -> Self {
245
245
Self {
Original file line number Diff line number Diff line change @@ -528,9 +528,7 @@ pub unsafe extern "C" fn _start_rust(
528
528
529
529
// Turn on the MMU for EL1.
530
530
let addr = Address :: new (phys_kernel_tables_base_addr as usize );
531
- if unlikely (memory :: mmu :: enable_mmu_and_caching (addr ). is_err ()) {
532
- cpu :: wait_forever ();
533
- }
531
+ memory :: mmu :: enable_mmu_and_caching (addr ). unwrap ();
534
532
535
533
// Use `eret` to "return" to EL1. This results in execution of kernel_init() in EL1.
536
534
asm :: eret ()
0 commit comments