Update to use DEBUG/RELEASE properly in DSC now tools have been fixed. Add VectorBase PCD to SEC. Don't assume it is at start of DRAM.

git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@10200 6f19259b-4bc3-4df7-8a09-765794883524
This commit is contained in:
andrewfish 2010-03-05 03:17:47 +00:00
parent 4951b2482f
commit 0f02314814
3 changed files with 9 additions and 7 deletions

View File

@ -34,7 +34,7 @@
[LibraryClasses.common] [LibraryClasses.common]
!if DEBUG_TARGET == RELEASE !if $(BUILD_TARGETS) == RELEASE
DebugLib|MdePkg/Library/BaseDebugLibNull/BaseDebugLibNull.inf DebugLib|MdePkg/Library/BaseDebugLibNull/BaseDebugLibNull.inf
!else !else
DebugLib|MdePkg/Library/BaseDebugLibSerialPort/BaseDebugLibSerialPort.inf DebugLib|MdePkg/Library/BaseDebugLibSerialPort/BaseDebugLibSerialPort.inf

View File

@ -40,7 +40,7 @@ _ModuleEntryPoint
mcr p15, 0, r0, c1, c0, 0 mcr p15, 0, r0, c1, c0, 0
// Set CPU vectors to start of DRAM // Set CPU vectors to start of DRAM
LoadConstantToReg (FixedPcdGet32(PcdMemoryBase) ,r0) /* memory size arg0 */ LoadConstantToReg (FixedPcdGet32(PcdCpuVectorBaseAddress) ,r0) // Get vector base
mcr p15, 0, r0, c12, c0, 0 mcr p15, 0, r0, c12, c0, 0
isb // Sync changes to control registers isb // Sync changes to control registers
@ -60,8 +60,8 @@ stack_pointer_setup
// Set stack based on PCD values. Need to do it this way to make C code work // Set stack based on PCD values. Need to do it this way to make C code work
// when it runs from FLASH. // when it runs from FLASH.
// //
LoadConstantToReg (FixedPcdGet32(PcdPrePiStackBase) ,r2) /* stack base arg2 */ LoadConstantToReg (FixedPcdGet32(PcdPrePiStackBase) ,r2) // stack base arg2
LoadConstantToReg (FixedPcdGet32(PcdPrePiStackSize) ,r3) /* stack size arg3 */ LoadConstantToReg (FixedPcdGet32(PcdPrePiStackSize) ,r3) // stack size arg3
add r4, r2, r3 add r4, r2, r3
//Enter SVC mode and set up SVC stack pointer //Enter SVC mode and set up SVC stack pointer
@ -70,9 +70,9 @@ stack_pointer_setup
mov r13,r4 mov r13,r4
// Call C entry point // Call C entry point
LoadConstantToReg (FixedPcdGet32(PcdMemorySize) ,r1) /* memory size arg1 */ LoadConstantToReg (FixedPcdGet32(PcdMemorySize) ,r1) // memory size arg1
// LoadConstantToReg (FixedPcdGet32(PcdMemoryBase) ,r0) Done above LoadConstantToReg (FixedPcdGet32(PcdMemoryBase) ,r0) // memory start arg0
blx CEntryPoint /* Assume C code is thumb */ blx CEntryPoint // Assume C code is thumb
ShouldNeverGetHere ShouldNeverGetHere
/* _CEntryPoint should never return */ /* _CEntryPoint should never return */

View File

@ -66,3 +66,5 @@
gOmap35xxTokenSpaceGuid.PcdBeagleConsoleUart gOmap35xxTokenSpaceGuid.PcdBeagleConsoleUart
gOmap35xxTokenSpaceGuid.PcdBeagleFreeTimer gOmap35xxTokenSpaceGuid.PcdBeagleFreeTimer
gArmTokenSpaceGuid.PcdCpuVectorBaseAddress