summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorzilong <[email protected]>2023-03-11 12:34:14 +0800
committerGitHub <[email protected]>2023-03-11 12:34:14 +0800
commit50e1f6327d2e03b887dfbff0af2dd87fd41d4d48 (patch)
treeb26d905f2920cc514a83a5888988b7fe4805d502
parent23786ee481698063b64d8dff37c7ac6e4351e406 (diff)
[libcpu/riscv/virt64] fix (#5979) (#7040)
-rw-r--r--libcpu/risc-v/virt64/startup_gcc.S6
1 files changed, 4 insertions, 2 deletions
diff --git a/libcpu/risc-v/virt64/startup_gcc.S b/libcpu/risc-v/virt64/startup_gcc.S
index 230c258db8..d1d4ce11e5 100644
--- a/libcpu/risc-v/virt64/startup_gcc.S
+++ b/libcpu/risc-v/virt64/startup_gcc.S
@@ -13,8 +13,10 @@
#include <encoding.h>
#include <cpuport.h>
-boot_hartid: .int
- .global boot_hartid
+ .data
+ .global boot_hartid /* global varible rt_boot_hartid in .data section */
+boot_hartid:
+ .word 0xdeadbeef
.global _start
.section ".start", "ax"