MdePkg/BaseLib: Fix an instruction write width error in LoongArch64

Cpucfg fetch is a 32-bit register, and AsmCpucfg's function
 declaration is a 32-bit address storage operation in BaseLib.h,
So, fix it by replacing stptr.d with stptr.w instrcution.

BZ: https://bugzilla.tianocore.org/show_bug.cgi?id=4797

Cc: Chao Li <lichao@loongson.cn>
Signed-off-by: Dongyan Qian <qiandongyan@loongson.cn>
Co-authored-by: Chao Li <lichao@loongson.cn>
This commit is contained in:
Dongyan Qian 2024-06-25 11:09:01 +08:00 committed by mergify[bot]
parent 5db0091418
commit 2fbaaa96d1

View File

@ -20,7 +20,7 @@ ASM_GLOBAL ASM_PFX(AsmCpucfg)
ASM_PFX(AsmCpucfg):
cpucfg $t0, $a0
stptr.d $t0, $a1, 0
stptr.w $t0, $a1, 0
jirl $zero, $ra, 0
.end