Function axruntime::rust_main

source ·
#[no_mangle]
pub extern "C" fn rust_main(cpu_id: usize, dtb: usize)
Expand description

The main entry point of the ArceOS runtime.

It is called from the bootstrapping code in axhal. cpu_id is the ID of the current CPU, and dtb is the address of the device tree blob. It finally calls the application’s main function after all initialization work is done.

In multi-core environment, this function is called on the primary CPU, and the secondary CPUs call rust_main_secondary.