summaryrefslogtreecommitdiff
path: root/ArmPkg/Drivers/ArmCpuLib
diff options
context:
space:
mode:
authoroliviermartin <oliviermartin@6f19259b-4bc3-4df7-8a09-765794883524>2011-11-01 23:32:04 +0000
committeroliviermartin <oliviermartin@6f19259b-4bc3-4df7-8a09-765794883524>2011-11-01 23:32:04 +0000
commit81be6e070f4d9b3cb3bb756302c3090d406744ba (patch)
treef72e724d934b722b6955b31c1f04776a7450b1fb /ArmPkg/Drivers/ArmCpuLib
parent793275a85867b5558c897b4ae8ebab6381335ca4 (diff)
ArmPkg/ArmCpuLib: Fix GCC/XCode builds
git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@12626 6f19259b-4bc3-4df7-8a09-765794883524
Diffstat (limited to 'ArmPkg/Drivers/ArmCpuLib')
-rw-r--r--ArmPkg/Drivers/ArmCpuLib/ArmCortexA15Lib/ArmCortexA15Helper.S6
-rw-r--r--ArmPkg/Drivers/ArmCpuLib/ArmCortexA15Lib/ArmCortexA15Helper.asm8
-rw-r--r--ArmPkg/Drivers/ArmCpuLib/ArmCortexA9Lib/ArmCortexA9Helper.S8
-rw-r--r--ArmPkg/Drivers/ArmCpuLib/ArmCortexA9Lib/ArmCortexA9Helper.asm10
4 files changed, 28 insertions, 4 deletions
diff --git a/ArmPkg/Drivers/ArmCpuLib/ArmCortexA15Lib/ArmCortexA15Helper.S b/ArmPkg/Drivers/ArmCpuLib/ArmCortexA15Lib/ArmCortexA15Helper.S
index b3e0597dd..feeefcdd4 100644
--- a/ArmPkg/Drivers/ArmCpuLib/ArmCortexA15Lib/ArmCortexA15Helper.S
+++ b/ArmPkg/Drivers/ArmCpuLib/ArmCortexA15Lib/ArmCortexA15Helper.S
@@ -34,7 +34,11 @@ ASM_PFX(ArmCpuSynchronizeWait):
cmp r0, #ARM_CPU_EVENT_BOOT_MEM_INIT
// The SCU enabled is the event to tell us the Init Boot Memory is initialized
beq ArmWaitGicDistributorEnabled
- bx ASM_PFX(CArmCpuSynchronizeWait)
+ push {r1,lr}
+ LoadConstantToReg (ASM_PFX(CArmCpuSynchronizeWait), r1)
+ blx r1
+ pop {r1,lr}
+ bx lr
// IN None
ArmWaitGicDistributorEnabled:
diff --git a/ArmPkg/Drivers/ArmCpuLib/ArmCortexA15Lib/ArmCortexA15Helper.asm b/ArmPkg/Drivers/ArmCpuLib/ArmCortexA15Lib/ArmCortexA15Helper.asm
index 7dbff1b04..886c00b61 100644
--- a/ArmPkg/Drivers/ArmCpuLib/ArmCortexA15Lib/ArmCortexA15Helper.asm
+++ b/ArmPkg/Drivers/ArmCpuLib/ArmCortexA15Lib/ArmCortexA15Helper.asm
@@ -35,7 +35,13 @@ ArmCpuSynchronizeWait
cmp r0, #ARM_CPU_EVENT_BOOT_MEM_INIT
// The SCU enabled is the event to tell us the Init Boot Memory is initialized
beq ArmWaitGicDistributorEnabled
- b CArmCpuSynchronizeWait
+ // Case when the stack has been set up
+ push {r1,lr}
+ LoadConstantToReg (CArmCpuSynchronizeWait, r1)
+ blx r1
+ pop {r1,lr}
+ bx lr
+
// IN None
ArmWaitGicDistributorEnabled
diff --git a/ArmPkg/Drivers/ArmCpuLib/ArmCortexA9Lib/ArmCortexA9Helper.S b/ArmPkg/Drivers/ArmCpuLib/ArmCortexA9Lib/ArmCortexA9Helper.S
index a66e8e785..c69c8d44c 100644
--- a/ArmPkg/Drivers/ArmCpuLib/ArmCortexA9Lib/ArmCortexA9Helper.S
+++ b/ArmPkg/Drivers/ArmCpuLib/ArmCortexA9Lib/ArmCortexA9Helper.S
@@ -11,6 +11,7 @@
//
//
+#include <AsmMacroIoLib.h>
#include <Library/ArmCpuLib.h>
#include <Chipset/ArmCortexA9.h>
@@ -29,7 +30,12 @@ ASM_PFX(ArmCpuSynchronizeWait):
cmp r0, #ARM_CPU_EVENT_BOOT_MEM_INIT
// The SCU enabled is the event to tell us the Init Boot Memory is initialized
beq ASM_PFX(ArmWaitScuEnabled)
- b ASM_PFX(CArmCpuSynchronizeWait)
+ // Case when the stack has been set up
+ push {r1,lr}
+ LoadConstantToReg (ASM_PFX(CArmCpuSynchronizeWait), r1)
+ blx r1
+ pop {r1,lr}
+ bx lr
// IN None
// OUT r0 = SCU Base Address
diff --git a/ArmPkg/Drivers/ArmCpuLib/ArmCortexA9Lib/ArmCortexA9Helper.asm b/ArmPkg/Drivers/ArmCpuLib/ArmCortexA9Lib/ArmCortexA9Helper.asm
index d0fc2b5a8..ef5015c18 100644
--- a/ArmPkg/Drivers/ArmCpuLib/ArmCortexA9Lib/ArmCortexA9Helper.asm
+++ b/ArmPkg/Drivers/ArmCpuLib/ArmCortexA9Lib/ArmCortexA9Helper.asm
@@ -11,9 +11,12 @@
//
//
+#include <AsmMacroIoLib.h>
#include <Library/ArmCpuLib.h>
#include <Chipset/ArmCortexA9.h>
+ INCLUDE AsmMacroIoLib.inc
+
EXPORT ArmCpuSynchronizeWait
EXPORT ArmGetScuBaseAddress
IMPORT CArmCpuSynchronizeWait
@@ -29,7 +32,12 @@ ArmCpuSynchronizeWait
cmp r0, #ARM_CPU_EVENT_BOOT_MEM_INIT
// The SCU enabled is the event to tell us the Init Boot Memory is initialized
beq ArmWaitScuEnabled
- b CArmCpuSynchronizeWait
+ // Case when the stack has been set up
+ push {r1,lr}
+ LoadConstantToReg (CArmCpuSynchronizeWait, r1)
+ blx r1
+ pop {r1,lr}
+ bx lr
// IN None
// OUT r0 = SCU Base Address