// Restore the Link register\r
mov lr, r7\r
\r
- beq ArmPlatformStackSetPrimary\r
+ beq ArmPlatformStackSetPrimary\r
bne ArmPlatformStackSetSecondary\r
ENDFUNC\r
\r
// IN UINTN SecondaryStackSize\r
// );\r
ArmPlatformStackSetPrimary FUNCTION\r
- mov r4, lr\r
+ mov r4, lr\r
\r
// Add stack of primary stack to StackBase\r
- add r0, r0, r2\r
+ add r0, r0, r2\r
\r
// Compute SecondaryCoresCount * SecondaryCoreStackSize\r
LoadConstantToReg (_gPcd_FixedAtBuild_PcdCoreCount, r1)\r
- ldr r1, [r1]\r
- sub r1, #1\r
- mul r3, r3, r1\r
+ ldr r1, [r1]\r
+ sub r1, #1\r
+ mul r3, r3, r1\r
\r
// Set Primary Stack ((StackBase + PrimaryStackSize) + (SecondaryCoresCount * SecondaryCoreStackSize))\r
- add sp, r0, r3\r
+ add sp, r0, r3\r
\r
bx r4\r
ENDFUNC\r
// IN UINTN SecondaryStackSize\r
// );\r
ArmPlatformStackSetSecondary FUNCTION\r
- mov r4, lr\r
+ mov r4, lr\r
mov sp, r0\r
\r
// Get Core Position\r
- mov r0, r1\r
+ mov r0, r1\r
bl ArmPlatformGetCorePosition\r
- mov r5, r0\r
+ mov r5, r0\r
\r
// Get Primary Core Position\r
bl ArmPlatformGetPrimaryCoreMpId\r
bl ArmPlatformGetCorePosition\r
\r
// Get Secondary Core Position. We should get consecutive secondary stack number from 1...(CoreCount-1)\r
- cmp r5, r0\r
+ cmp r5, r0\r
subhi r5, r5, #1\r
- add r5, r5, #1\r
+ add r5, r5, #1\r
\r
// Compute top of the secondary stack\r
- mul r3, r3, r5\r
+ mul r3, r3, r5\r
\r
// Set stack\r
- add sp, sp, r3\r
+ add sp, sp, r3\r
\r
bx r4\r
ENDFUNC\r