//! K2120 crashing service: sends one immediate health reply and one that PID1 //! receives late (after this generation is gone), then crashes with a real //! EL0 data abort on a store to the unmapped address zero. #![no_std] #![no_main] use turkos_os_feature_user::call; const HEALTH: u64 = 16; #[unsafe(no_mangle)] #[unsafe(link_section = ".text._start")] pub extern "C" fn _start(_: u64, _: u64) -> ! { call(HEALTH, 0, 0, 0); call(HEALTH, 1, 0, 0); // A store to address zero: unmapped in the user root, so EL0 faults. unsafe { core::arch::asm!("mov x9, #0", "mov x10, #0x2120", "str x10, [x9]", out("x9") _, out("x10") _, options(nostack)) }; loop {} }