瀏覽代碼

small fix

Yifan Wu 4 年之前
父節點
當前提交
865e6a3273
共有 1 個文件被更改,包括 2 次插入3 次删除
  1. 2 3
      platform/k210/src/main.rs

+ 2 - 3
platform/k210/src/main.rs

@@ -76,7 +76,7 @@ fn main() -> ! {
         csrr    a2, mhartid
         lui     t0, %hi(_max_hart_id)
         add     t0, t0, %lo(_max_hart_id)
-        bgt     a2, t0, _start_abort
+        bgtu    a2, t0, _start_abort
         la      sp, _stack_start
         lui     t0, %hi(_hart_stack_size)
         add     t0, t0, %lo(_hart_stack_size)
@@ -104,8 +104,7 @@ fn main() -> ! {
     "
         )
     };
-    let hart_boot = mp_hook();
-    if hart_boot {
+    if mp_hook() {
         extern "C" {
             static mut _ebss: u32;
             static mut _sbss: u32;