Skip to content

Commit

Permalink
Modfied aarch64 cpu id to hex
Browse files Browse the repository at this point in the history
  • Loading branch information
elliott10 committed Aug 22, 2023
1 parent 8e70ca4 commit 56db436
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
4 changes: 2 additions & 2 deletions modules/axhal/src/platform/aarch64_common/psci.rs
Original file line number Diff line number Diff line change
Expand Up @@ -110,10 +110,10 @@ pub fn system_off() -> ! {
/// `entry_point` is the physical address of the secondary CPU's entry point.
/// `arg` will be passed to the `X0` register of the secondary CPU.
pub fn cpu_on(target_cpu: usize, entry_point: usize, arg: usize) {
info!("Starting CPU {} ON ...", target_cpu);
info!("Starting CPU {:x} ON ...", target_cpu);
let res = psci_call(PSCI_0_2_FN64_CPU_ON, target_cpu, entry_point, arg);
if let Err(e) = res {
error!("failed to boot CPU {} ({:?})", target_cpu, e);
error!("failed to boot CPU {:x} ({:?})", target_cpu, e);
}
}

Expand Down
4 changes: 2 additions & 2 deletions modules/axruntime/src/mp.rs
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ pub fn start_secondary_cpus(primary_cpu_id: usize) {
#[no_mangle]
pub extern "C" fn rust_main_secondary(cpu_id: usize) -> ! {
ENTERED_CPUS.fetch_add(1, Ordering::Relaxed);
info!("Secondary CPU {} started.", cpu_id);
info!("Secondary CPU {:x} started.", cpu_id);

#[cfg(feature = "paging")]
super::remap_kernel_memory().unwrap();
Expand All @@ -42,7 +42,7 @@ pub extern "C" fn rust_main_secondary(cpu_id: usize) -> ! {
#[cfg(feature = "multitask")]
axtask::init_scheduler_secondary();

info!("Secondary CPU {} init OK.", cpu_id);
info!("Secondary CPU {:x} init OK.", cpu_id);
super::INITED_CPUS.fetch_add(1, Ordering::Relaxed);

while !super::is_init_ok() {
Expand Down

0 comments on commit 56db436

Please sign in to comment.