diff options
author | Ronald Cron <ronald.cron@arm.com> | 2014-08-19 13:29:52 +0000 |
---|---|---|
committer | oliviermartin <oliviermartin@6f19259b-4bc3-4df7-8a09-765794883524> | 2014-08-19 13:29:52 +0000 |
commit | 3402aac7d985bf8a9f9d3c639f3fe93609380513 (patch) | |
tree | 67b11334dc45181581aaaac236243fe72c7f614c | |
parent | 62d441fb17d59958bf00c4a1f3b52bf6a0b40b24 (diff) | |
download | edk2-platforms-3402aac7d985bf8a9f9d3c639f3fe93609380513.tar.xz |
ARM Packages: Removed trailing spaces
Trailing spaces create issue/warning when generating/applying patches.
Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Ronald Cron <ronald.cron@arm.com>
Reviewed-By: Olivier Martin <olivier.martin@arm.com>
git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@15833 6f19259b-4bc3-4df7-8a09-765794883524
554 files changed, 6330 insertions, 6342 deletions
diff --git a/ArmPkg/Application/LinuxLoader/LinuxAtagLoader.inf b/ArmPkg/Application/LinuxLoader/LinuxAtagLoader.inf index db1a3dc827..dcc2597c24 100644 --- a/ArmPkg/Application/LinuxLoader/LinuxAtagLoader.inf +++ b/ArmPkg/Application/LinuxLoader/LinuxAtagLoader.inf @@ -1,13 +1,13 @@ #/* @file
# Copyright (c) 2011-2013, ARM Limited. All rights reserved.
-#
-# This program and the accompanying materials
-# are licensed and made available under the terms and conditions of the BSD License
-# which accompanies this distribution. The full text of the license may be found at
-# http://opensource.org/licenses/bsd-license.php
#
-# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
-# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
+# This program and the accompanying materials
+# are licensed and made available under the terms and conditions of the BSD License
+# which accompanies this distribution. The full text of the license may be found at
+# http://opensource.org/licenses/bsd-license.php
+#
+# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
+# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
#
#*/
diff --git a/ArmPkg/Application/LinuxLoader/LinuxFdtLoader.inf b/ArmPkg/Application/LinuxLoader/LinuxFdtLoader.inf index fbd13308ad..55a6969bb8 100644 --- a/ArmPkg/Application/LinuxLoader/LinuxFdtLoader.inf +++ b/ArmPkg/Application/LinuxLoader/LinuxFdtLoader.inf @@ -1,13 +1,13 @@ #/* @file
# Copyright (c) 2011-2013, ARM Limited. All rights reserved.
-#
-# This program and the accompanying materials
-# are licensed and made available under the terms and conditions of the BSD License
-# which accompanies this distribution. The full text of the license may be found at
-# http://opensource.org/licenses/bsd-license.php
#
-# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
-# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
+# This program and the accompanying materials
+# are licensed and made available under the terms and conditions of the BSD License
+# which accompanies this distribution. The full text of the license may be found at
+# http://opensource.org/licenses/bsd-license.php
+#
+# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
+# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
#
#*/
diff --git a/ArmPkg/ArmPkg.dsc b/ArmPkg/ArmPkg.dsc index 2dbcb86e2c..15ea2ef939 100644 --- a/ArmPkg/ArmPkg.dsc +++ b/ArmPkg/ArmPkg.dsc @@ -31,13 +31,13 @@ [BuildOptions]
XCODE:*_*_ARM_PLATFORM_FLAGS == -arch armv7
- XCODE:RELEASE_*_*_CC_FLAGS = -DMDEPKG_NDEBUG
-
+ XCODE:RELEASE_*_*_CC_FLAGS = -DMDEPKG_NDEBUG
+
GCC:*_*_ARM_PLATFORM_FLAGS == -march=armv7-a -mfpu=neon
- GCC:RELEASE_*_*_CC_FLAGS = -DMDEPKG_NDEBUG
+ GCC:RELEASE_*_*_CC_FLAGS = -DMDEPKG_NDEBUG
RVCT:*_*_ARM_PLATFORM_FLAGS == --cpu Cortex-A8
- RVCT:RELEASE_*_*_CC_FLAGS = -DMDEPKG_NDEBUG
+ RVCT:RELEASE_*_*_CC_FLAGS = -DMDEPKG_NDEBUG
[LibraryClasses.common]
BaseLib|MdePkg/Library/BaseLib/BaseLib.inf
@@ -74,7 +74,7 @@ BdsLib|ArmPkg/Library/BdsLib/BdsLib.inf
FdtLib|EmbeddedPkg/Library/FdtLib/FdtLib.inf
-
+
IoLib|MdePkg/Library/BaseIoLibIntrinsic/BaseIoLibIntrinsic.inf
[LibraryClasses.ARM]
diff --git a/ArmPkg/Drivers/ArmCpuLib/Arm11MpCoreLib/Arm11MpCoreLib.inf b/ArmPkg/Drivers/ArmCpuLib/Arm11MpCoreLib/Arm11MpCoreLib.inf index f7ecfb0900..3a796c19d0 100644 --- a/ArmPkg/Drivers/ArmCpuLib/Arm11MpCoreLib/Arm11MpCoreLib.inf +++ b/ArmPkg/Drivers/ArmCpuLib/Arm11MpCoreLib/Arm11MpCoreLib.inf @@ -1,13 +1,13 @@ #/* @file
# Copyright (c) 2011-2012, ARM Limited. All rights reserved.
-#
-# This program and the accompanying materials
-# are licensed and made available under the terms and conditions of the BSD License
-# which accompanies this distribution. The full text of the license may be found at
-# http://opensource.org/licenses/bsd-license.php
#
-# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
-# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
+# This program and the accompanying materials
+# are licensed and made available under the terms and conditions of the BSD License
+# which accompanies this distribution. The full text of the license may be found at
+# http://opensource.org/licenses/bsd-license.php
+#
+# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
+# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
#
#*/
diff --git a/ArmPkg/Drivers/ArmCpuLib/ArmCortexA15Lib/ArmCortexA15Lib.inf b/ArmPkg/Drivers/ArmCpuLib/ArmCortexA15Lib/ArmCortexA15Lib.inf index 3ddd4c5704..ed4bdc377d 100644 --- a/ArmPkg/Drivers/ArmCpuLib/ArmCortexA15Lib/ArmCortexA15Lib.inf +++ b/ArmPkg/Drivers/ArmCpuLib/ArmCortexA15Lib/ArmCortexA15Lib.inf @@ -1,13 +1,13 @@ #/* @file
# Copyright (c) 2011-2012, ARM Limited. All rights reserved.
-#
-# This program and the accompanying materials
-# are licensed and made available under the terms and conditions of the BSD License
-# which accompanies this distribution. The full text of the license may be found at
-# http://opensource.org/licenses/bsd-license.php
#
-# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
-# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
+# This program and the accompanying materials
+# are licensed and made available under the terms and conditions of the BSD License
+# which accompanies this distribution. The full text of the license may be found at
+# http://opensource.org/licenses/bsd-license.php
+#
+# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
+# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
#
#*/
diff --git a/ArmPkg/Drivers/ArmCpuLib/ArmCortexA8Lib/ArmCortexA8Lib.inf b/ArmPkg/Drivers/ArmCpuLib/ArmCortexA8Lib/ArmCortexA8Lib.inf index c6895879c2..890958a7e3 100644 --- a/ArmPkg/Drivers/ArmCpuLib/ArmCortexA8Lib/ArmCortexA8Lib.inf +++ b/ArmPkg/Drivers/ArmCpuLib/ArmCortexA8Lib/ArmCortexA8Lib.inf @@ -1,13 +1,13 @@ #/* @file
# Copyright (c) 2011, ARM Limited. All rights reserved.
-#
-# This program and the accompanying materials
-# are licensed and made available under the terms and conditions of the BSD License
-# which accompanies this distribution. The full text of the license may be found at
-# http://opensource.org/licenses/bsd-license.php
#
-# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
-# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
+# This program and the accompanying materials
+# are licensed and made available under the terms and conditions of the BSD License
+# which accompanies this distribution. The full text of the license may be found at
+# http://opensource.org/licenses/bsd-license.php
+#
+# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
+# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
#
#*/
diff --git a/ArmPkg/Drivers/ArmCpuLib/ArmCortexA9Lib/ArmCortexA9Lib.inf b/ArmPkg/Drivers/ArmCpuLib/ArmCortexA9Lib/ArmCortexA9Lib.inf index a84501dea4..236b0bcb6c 100644 --- a/ArmPkg/Drivers/ArmCpuLib/ArmCortexA9Lib/ArmCortexA9Lib.inf +++ b/ArmPkg/Drivers/ArmCpuLib/ArmCortexA9Lib/ArmCortexA9Lib.inf @@ -1,13 +1,13 @@ #/* @file
# Copyright (c) 2011-2013, ARM Limited. All rights reserved.
-#
-# This program and the accompanying materials
-# are licensed and made available under the terms and conditions of the BSD License
-# which accompanies this distribution. The full text of the license may be found at
-# http://opensource.org/licenses/bsd-license.php
#
-# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
-# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
+# This program and the accompanying materials
+# are licensed and made available under the terms and conditions of the BSD License
+# which accompanies this distribution. The full text of the license may be found at
+# http://opensource.org/licenses/bsd-license.php
+#
+# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
+# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
#
#*/
diff --git a/ArmPkg/Drivers/ArmGic/ArmGicDxe.inf b/ArmPkg/Drivers/ArmGic/ArmGicDxe.inf index 9be6160255..7dc14b34ec 100644 --- a/ArmPkg/Drivers/ArmGic/ArmGicDxe.inf +++ b/ArmPkg/Drivers/ArmGic/ArmGicDxe.inf @@ -16,7 +16,7 @@ [Defines]
INF_VERSION = 0x00010005
BASE_NAME = ArmGicDxe
- FILE_GUID = DE371F7C-DEC4-4D21-ADF1-593ABCC15882
+ FILE_GUID = DE371F7C-DEC4-4D21-ADF1-593ABCC15882
MODULE_TYPE = DXE_DRIVER
VERSION_STRING = 1.0
diff --git a/ArmPkg/Drivers/CpuDxe/ArmV4/ExceptionSupport.S b/ArmPkg/Drivers/CpuDxe/ArmV4/ExceptionSupport.S index 2b439f3331..c82618aa1b 100644 --- a/ArmPkg/Drivers/CpuDxe/ArmV4/ExceptionSupport.S +++ b/ArmPkg/Drivers/CpuDxe/ArmV4/ExceptionSupport.S @@ -1,4 +1,4 @@ -#------------------------------------------------------------------------------
+#------------------------------------------------------------------------------
#
# Copyright (c) 2008 - 2010, Apple Inc. All rights reserved.<BR>
#
@@ -52,7 +52,7 @@ ASM_PFX(ResetEntry): stmfd SP!,{LR} @ Store the link register for the current mode
sub SP,SP,#0x20 @ Save space for SP, LR, PC, IFAR - CPSR
stmfd SP!,{R0-R12} @ Store the register state
-
+
mov R0,#0
ldr R1,ASM_PFX(CommonExceptionEntry)
bx R1
@@ -147,18 +147,18 @@ ASM_PFX(ExceptionHandlersEnd): ASM_PFX(AsmCommonExceptionEntry):
mrc p15, 0, R1, c6, c0, 2 @ Read IFAR
- str R1, [SP, #0x50] @ Store it in EFI_SYSTEM_CONTEXT_ARM.IFAR
-
+ str R1, [SP, #0x50] @ Store it in EFI_SYSTEM_CONTEXT_ARM.IFAR
+
mrc p15, 0, R1, c5, c0, 1 @ Read IFSR
str R1, [SP, #0x4c] @ Store it in EFI_SYSTEM_CONTEXT_ARM.IFSR
-
+
mrc p15, 0, R1, c6, c0, 0 @ Read DFAR
str R1, [SP, #0x48] @ Store it in EFI_SYSTEM_CONTEXT_ARM.DFAR
-
+
mrc p15, 0, R1, c5, c0, 0 @ Read DFSR
str R1, [SP, #0x44] @ Store it in EFI_SYSTEM_CONTEXT_ARM.DFSR
-
- ldr R1, [SP, #0x5c] @ srsdb saved pre-exception CPSR on the stack
+
+ ldr R1, [SP, #0x5c] @ srsdb saved pre-exception CPSR on the stack
str R1, [SP, #0x40] @ Store it in EFI_SYSTEM_CONTEXT_ARM.CPSR
and r1, r1, #0x1f @ Check to see if User or System Mode
cmp r1, #0x1f
@@ -167,25 +167,25 @@ ASM_PFX(AsmCommonExceptionEntry): ldmneed r2, {lr}^ @ User or System mode, use unbanked register
ldmneed r2, {lr} @ All other modes used banked register
- ldr R1, [SP, #0x58] @ PC is the LR pushed by srsdb
+ ldr R1, [SP, #0x58] @ PC is the LR pushed by srsdb
str R1, [SP, #0x3c] @ Store it in EFI_SYSTEM_CONTEXT_ARM.PC
-
- sub R1, SP, #0x60 @ We pused 0x60 bytes on the stack
+
+ sub R1, SP, #0x60 @ We pused 0x60 bytes on the stack
str R1, [SP, #0x34] @ Store it in EFI_SYSTEM_CONTEXT_ARM.SP
-
- @ R0 is exception type
+
+ @ R0 is exception type
mov R1,SP @ Prepare System Context pointer as an argument for the exception handler
blx ASM_PFX(CommonCExceptionHandler) @ Call exception handler
-
+
ldr R2,[SP,#0x40] @ EFI_SYSTEM_CONTEXT_ARM.CPSR
- str R2,[SP,#0x5c] @ Store it back to srsdb stack slot so it can be restored
+ str R2,[SP,#0x5c] @ Store it back to srsdb stack slot so it can be restored
ldr R2,[SP,#0x3c] @ EFI_SYSTEM_CONTEXT_ARM.PC
- str R2,[SP,#0x58] @ Store it back to srsdb stack slot so it can be restored
+ str R2,[SP,#0x58] @ Store it back to srsdb stack slot so it can be restored
ldmfd SP!,{R0-R12} @ Restore general purpose registers
@ Exception handler can not change SP or LR as we would blow chunks
-
+
add SP,SP,#0x20 @ Clear out the remaining stack space
ldmfd SP!,{LR} @ restore the link register for this context
rfefd SP! @ return from exception via srsdb stack slot
diff --git a/ArmPkg/Drivers/CpuDxe/ArmV4/ExceptionSupport.asm b/ArmPkg/Drivers/CpuDxe/ArmV4/ExceptionSupport.asm index 2ea8d65f15..9f09a0bc76 100644 --- a/ArmPkg/Drivers/CpuDxe/ArmV4/ExceptionSupport.asm +++ b/ArmPkg/Drivers/CpuDxe/ArmV4/ExceptionSupport.asm @@ -1,4 +1,4 @@ -//------------------------------------------------------------------------------
+//------------------------------------------------------------------------------
//
// Copyright (c) 2008 - 2009, Apple Inc. All rights reserved.<BR>
//
@@ -20,7 +20,7 @@ PRESERVE8
AREA DxeExceptionHandlers, CODE, READONLY
-
+
ExceptionHandlersStart
Reset
@@ -107,35 +107,35 @@ ExceptionHandlersEnd AsmCommonExceptionEntry
mrc p15, 0, r1, c6, c0, 2 ; Read IFAR
stmfd SP!,{R1} ; Store the IFAR
-
+
mrc p15, 0, r1, c5, c0, 1 ; Read IFSR
stmfd SP!,{R1} ; Store the IFSR
-
+
mrc p15, 0, r1, c6, c0, 0 ; Read DFAR
stmfd SP!,{R1} ; Store the DFAR
-
+
mrc p15, 0, r1, c5, c0, 0 ; Read DFSR
stmfd SP!,{R1} ; Store the DFSR
-
+
mrs R1,SPSR ; Read SPSR (which is the pre-exception CPSR)
stmfd SP!,{R1} ; Store the SPSR
-
+
stmfd SP!,{LR} ; Store the link register (which is the pre-exception PC)
stmfd SP,{SP,LR}^ ; Store user/system mode stack pointer and link register
nop ; Required by ARM architecture
SUB SP,SP,#0x08 ; Adjust stack pointer
stmfd SP!,{R2-R12} ; Store general purpose registers
-
+
ldr R3,[SP,#0x50] ; Read saved R1 from the stack (it was saved by the exception entry routine)
ldr R2,[SP,#0x4C] ; Read saved R0 from the stack (it was saved by the exception entry routine)
stmfd SP!,{R2-R3} ; Store general purpose registers R0 and R1
-
+
mov R1,SP ; Prepare System Context pointer as an argument for the exception handler
-
+
sub SP,SP,#4 ; Adjust SP to preserve 8-byte alignment
blx CommonCExceptionHandler ; Call exception handler
add SP,SP,#4 ; Adjust SP back to where we were
-
+
ldr R2,[SP,#0x40] ; Load CPSR from context, in case it has changed
MSR SPSR_cxsf,R2 ; Store it back to the SPSR to be restored when exiting this handler
@@ -146,7 +146,7 @@ AsmCommonExceptionEntry ldmfd SP!,{LR} ; Restore the link register (which is the pre-exception PC)
add SP,SP,#0x1C ; Clear out the remaining stack space
movs PC,LR ; Return from exception
-
+
END
diff --git a/ArmPkg/Drivers/CpuDxe/ArmV6/Exception.c b/ArmPkg/Drivers/CpuDxe/ArmV6/Exception.c index 22c56a347b..4b05199db3 100644 --- a/ArmPkg/Drivers/CpuDxe/ArmV6/Exception.c +++ b/ArmPkg/Drivers/CpuDxe/ArmV6/Exception.c @@ -2,7 +2,7 @@ Copyright (c) 2008 - 2009, Apple Inc. All rights reserved.<BR>
Copyright (c) 2014, ARM Limited. All rights reserved.<BR>
-
+
This program and the accompanying materials
are licensed and made available under the terms and conditions of the BSD License
which accompanies this distribution. The full text of the license may be found at
@@ -13,7 +13,7 @@ **/
-#include "CpuDxe.h"
+#include "CpuDxe.h"
//FIXME: Will not compile on non-ARMv7 builds
#include <Chipset/ArmV7.h>
@@ -45,9 +45,9 @@ EFI_EXCEPTION_CALLBACK gDebuggerExceptionHandlers[MAX_ARM_EXCEPTION + 1]; /**
- This function registers and enables the handler specified by InterruptHandler for a processor
- interrupt or exception type specified by InterruptType. If InterruptHandler is NULL, then the
- handler for the processor interrupt or exception type specified by InterruptType is uninstalled.
+ This function registers and enables the handler specified by InterruptHandler for a processor
+ interrupt or exception type specified by InterruptType. If InterruptHandler is NULL, then the
+ handler for the processor interrupt or exception type specified by InterruptType is uninstalled.
The installed handler is called once for each processor interrupt or exception.
@param InterruptType A pointer to the processor's current interrupt state. Set to TRUE if interrupts
@@ -102,7 +102,7 @@ CommonCExceptionHandler ( DEBUG ((EFI_D_ERROR, "Unknown exception type %d from %08x\n", ExceptionType, SystemContext.SystemContextArm->PC));
ASSERT (FALSE);
}
-
+
if (ExceptionType == EXCEPT_ARM_SOFTWARE_INTERRUPT) {
//
// ARM JTAG debuggers some times use this vector, so it is not an error to get one
@@ -139,8 +139,8 @@ InitializeExceptions ( Cpu->DisableInterrupt (Cpu);
//
- // EFI does not use the FIQ, but a debugger might so we must disable
- // as we take over the exception vectors.
+ // EFI does not use the FIQ, but a debugger might so we must disable
+ // as we take over the exception vectors.
//
FiqEnabled = ArmGetFiqState ();
ArmDisableFiq ();
@@ -224,7 +224,7 @@ InitializeExceptions ( }
if (IrqEnabled) {
- //
+ //
// Restore interrupt state
//
Status = Cpu->EnableInterrupt (Cpu);
diff --git a/ArmPkg/Drivers/CpuDxe/ArmV6/ExceptionSupport.S b/ArmPkg/Drivers/CpuDxe/ArmV6/ExceptionSupport.S index 6a1a15570f..3433b99cd4 100644 --- a/ArmPkg/Drivers/CpuDxe/ArmV6/ExceptionSupport.S +++ b/ArmPkg/Drivers/CpuDxe/ArmV6/ExceptionSupport.S @@ -1,4 +1,4 @@ -#------------------------------------------------------------------------------
+#------------------------------------------------------------------------------
#
# Use ARMv6 instruction to operate on a single stack
#
@@ -22,7 +22,7 @@ This is the stack constructed by the exception handler (low address to high address)
# R0 - IFAR is EFI_SYSTEM_CONTEXT for ARM
Reg Offset
- === ======
+ === ======
R0 0x00 # stmfd SP!,{R0-R12}
R1 0x04
R2 0x08
@@ -44,14 +44,14 @@ This is the stack constructed by the exception handler (low address to high addr DFAR 0x48
IFSR 0x4c
IFAR 0x50
-
+
LR 0x54 # SVC Link register (we need to restore it)
-
- LR 0x58 # pushed by srsfd
- CPSR 0x5c
+
+ LR 0x58 # pushed by srsfd
+ CPSR 0x5c
*/
-
+
GCC_ASM_EXPORT(ExceptionHandlersStart)
GCC_ASM_EXPORT(ExceptionHandlersEnd)
@@ -103,7 +103,7 @@ ASM_PFX(ResetEntry): stmfd SP!,{LR} @ Store the link register for the current mode
sub SP,SP,#0x20 @ Save space for SP, LR, PC, IFAR - CPSR
stmfd SP!,{R0-R12} @ Store the register state
-
+
mov R0,#0 @ ExceptionType
ldr R1,ASM_PFX(CommonExceptionEntry)
bx R1
@@ -200,53 +200,53 @@ ASM_PFX(CommonExceptionEntry): ASM_PFX(ExceptionHandlersEnd):
//
-// This code runs from CpuDxe driver loaded address. It is patched into
+// This code runs from CpuDxe driver loaded address. It is patched into
// CommonExceptionEntry.
//
ASM_PFX(AsmCommonExceptionEntry):
mrc p15, 0, R1, c6, c0, 2 @ Read IFAR
- str R1, [SP, #0x50] @ Store it in EFI_SYSTEM_CONTEXT_ARM.IFAR
-
+ str R1, [SP, #0x50] @ Store it in EFI_SYSTEM_CONTEXT_ARM.IFAR
+
mrc p15, 0, R1, c5, c0, 1 @ Read IFSR
str R1, [SP, #0x4c] @ Store it in EFI_SYSTEM_CONTEXT_ARM.IFSR
-
+
mrc p15, 0, R1, c6, c0, 0 @ Read DFAR
str R1, [SP, #0x48] @ Store it in EFI_SYSTEM_CONTEXT_ARM.DFAR
-
+
mrc p15, 0, R1, c5, c0, 0 @ Read DFSR
str R1, [SP, #0x44] @ Store it in EFI_SYSTEM_CONTEXT_ARM.DFSR
-
- ldr R1, [SP, #0x5c] @ srsdb saved pre-exception CPSR on the stack
+
+ ldr R1, [SP, #0x5c] @ srsdb saved pre-exception CPSR on the stack
str R1, [SP, #0x40] @ Store it in EFI_SYSTEM_CONTEXT_ARM.CPSR
add R2, SP, #0x38 @ Make R2 point to EFI_SYSTEM_CONTEXT_ARM.LR
and R3, R1, #0x1f @ Check CPSR to see if User or System Mode
cmp R3, #0x1f @ if ((CPSR == 0x10) || (CPSR == 0x1f))
- cmpne R3, #0x10 @
+ cmpne R3, #0x10 @
stmeqed R2, {lr}^ @ save unbanked lr
- @ else
+ @ else
stmneed R2, {lr} @ save SVC lr
- ldr R5, [SP, #0x58] @ PC is the LR pushed by srsfd
+ ldr R5, [SP, #0x58] @ PC is the LR pushed by srsfd
@ Check to see if we have to adjust for Thumb entry
sub r4, r0, #1 @ if (ExceptionType == 1 || ExceptionType == 2)) {
- cmp r4, #1 @ // UND & SVC have differnt LR adjust for Thumb
+ cmp r4, #1 @ // UND & SVC have differnt LR adjust for Thumb
bhi NoAdjustNeeded
-
- tst r1, #0x20 @ if ((CPSR & T)) == T) { // Thumb Mode on entry
+
+ tst r1, #0x20 @ if ((CPSR & T)) == T) { // Thumb Mode on entry
addne R5, R5, #2 @ PC += 2;
strne R5,[SP,#0x58] @ Update LR value pushed by srsfd
-
+
NoAdjustNeeded:
str R5, [SP, #0x3c] @ Store it in EFI_SYSTEM_CONTEXT_ARM.PC
-
+
add R1, SP, #0x60 @ We pushed 0x60 bytes on the stack
str R1, [SP, #0x34] @ Store it in EFI_SYSTEM_CONTEXT_ARM.SP
-
- @ R0 is ExceptionType
- mov R1,SP @ R1 is SystemContext
+
+ @ R0 is ExceptionType
+ mov R1,SP @ R1 is SystemContext
#if (FixedPcdGet32(PcdVFPEnabled))
vpush {d0-d15} @ save vstm registers in case they are used in optimizations
@@ -256,7 +256,7 @@ NoAdjustNeeded: tst R4, #4
subne SP, SP, #4 @ Adjust SP if not 8-byte aligned
-/*
+/*
VOID
EFIAPI
CommonCExceptionHandler (
@@ -264,13 +264,13 @@ CommonCExceptionHandler ( IN OUT EFI_SYSTEM_CONTEXT SystemContext R1
)
-*/
+*/
blx ASM_PFX(CommonCExceptionHandler) @ Call exception handler
mov SP, R4 @ Restore SP
#if (FixedPcdGet32(PcdVFPEnabled))
- vpop {d0-d15}
+ vpop {d0-d15}
#endif
ldr R1, [SP, #0x4c] @ Restore EFI_SYSTEM_CONTEXT_ARM.IFSR
@@ -278,26 +278,26 @@ CommonCExceptionHandler ( ldr R1, [SP, #0x44] @ Restore EFI_SYSTEM_CONTEXT_ARM.DFSR
mcr p15, 0, R1, c5, c0, 0 @ Write DFSR
-
+
ldr R1,[SP,#0x3c] @ EFI_SYSTEM_CONTEXT_ARM.PC
- str R1,[SP,#0x58] @ Store it back to srsfd stack slot so it can be restored
+ str R1,[SP,#0x58] @ Store it back to srsfd stack slot so it can be restored
ldr R1,[SP,#0x40] @ EFI_SYSTEM_CONTEXT_ARM.CPSR
- str R1,[SP,#0x5c] @ Store it back to srsfd stack slot so it can be restored
-
+ str R1,[SP,#0x5c] @ Store it back to srsfd stack slot so it can be restored
+
add R3, SP, #0x54 @ Make R3 point to SVC LR saved on entry
add R2, SP, #0x38 @ Make R2 point to EFI_SYSTEM_CONTEXT_ARM.LR
and R1, R1, #0x1f @ Check to see if User or System Mode
cmp R1, #0x1f @ if ((CPSR == 0x10) || (CPSR == 0x1f))
- cmpne R1, #0x10 @
+ cmpne R1, #0x10 @
ldmeqed R2, {lr}^ @ restore unbanked lr
@ else
ldmneed R3, {lr} @ restore SVC lr, via ldmfd SP!, {LR}
-
+
ldmfd SP!,{R0-R12} @ Restore general purpose registers
@ Exception handler can not change SP
-
+
add SP,SP,#0x20 @ Clear out the remaining stack space
ldmfd SP!,{LR} @ restore the link register for this context
rfefd SP! @ return from exception via srsfd stack slot
-
+
diff --git a/ArmPkg/Drivers/CpuDxe/ArmV6/ExceptionSupport.asm b/ArmPkg/Drivers/CpuDxe/ArmV6/ExceptionSupport.asm index fbb86993dc..b28ff9f7ee 100644 --- a/ArmPkg/Drivers/CpuDxe/ArmV6/ExceptionSupport.asm +++ b/ArmPkg/Drivers/CpuDxe/ArmV6/ExceptionSupport.asm @@ -1,4 +1,4 @@ -//------------------------------------------------------------------------------
+//------------------------------------------------------------------------------
//
// Use ARMv6 instruction to operate on a single stack
//
@@ -22,7 +22,7 @@ This is the stack constructed by the exception handler (low address to high address)
# R0 - IFAR is EFI_SYSTEM_CONTEXT for ARM
Reg Offset
- === ======
+ === ======
R0 0x00 # stmfd SP!,{R0-R12}
R1 0x04
R2 0x08
@@ -44,15 +44,15 @@ This is the stack constructed by the exception handler (low address to high addr DFAR 0x48
IFSR 0x4c
IFAR 0x50
-
+
LR 0x54 # SVC Link register (we need to restore it)
-
- LR 0x58 # pushed by srsfd
- CPSR 0x5c
+
+ LR 0x58 # pushed by srsfd
+ CPSR 0x5c
*/
-
-
+
+
EXPORT ExceptionHandlersStart
EXPORT ExceptionHandlersEnd
EXPORT CommonExceptionEntry
@@ -61,7 +61,7 @@ This is the stack constructed by the exception handler (low address to high addr PRESERVE8
AREA DxeExceptionHandlers, CODE, READONLY, CODEALIGN, ALIGN=5
-
+
//
// This code gets copied to the ARM vector table
// ExceptionHandlersStart - ExceptionHandlersEnd gets copied
@@ -98,7 +98,7 @@ ResetEntry stmfd SP!,{LR} ; Store the link register for the current mode
sub SP,SP,#0x20 ; Save space for SP, LR, PC, IFAR - CPSR
stmfd SP!,{R0-R12} ; Store the register state
-
+
mov R0,#0 ; ExceptionType
ldr R1,CommonExceptionEntry
bx R1
@@ -112,7 +112,7 @@ UndefinedInstructionEntry stmfd SP!,{R0-R12} ; Store the register state
mov R0,#1 ; ExceptionType
- ldr R1,CommonExceptionEntry;
+ ldr R1,CommonExceptionEntry;
bx R1
SoftwareInterruptEntry
@@ -195,53 +195,53 @@ CommonExceptionEntry ExceptionHandlersEnd
//
-// This code runs from CpuDxe driver loaded address. It is patched into
+// This code runs from CpuDxe driver loaded address. It is patched into
// CommonExceptionEntry.
//
AsmCommonExceptionEntry
mrc p15, 0, R1, c6, c0, 2 ; Read IFAR
- str R1, [SP, #0x50] ; Store it in EFI_SYSTEM_CONTEXT_ARM.IFAR
-
+ str R1, [SP, #0x50] ; Store it in EFI_SYSTEM_CONTEXT_ARM.IFAR
+
mrc p15, 0, R1, c5, c0, 1 ; Read IFSR
str R1, [SP, #0x4c] ; Store it in EFI_SYSTEM_CONTEXT_ARM.IFSR
-
+
mrc p15, 0, R1, c6, c0, 0 ; Read DFAR
str R1, [SP, #0x48] ; Store it in EFI_SYSTEM_CONTEXT_ARM.DFAR
-
+
mrc p15, 0, R1, c5, c0, 0 ; Read DFSR
str R1, [SP, #0x44] ; Store it in EFI_SYSTEM_CONTEXT_ARM.DFSR
-
- ldr R1, [SP, #0x5c] ; srsfd saved pre-exception CPSR on the stack
+
+ ldr R1, [SP, #0x5c] ; srsfd saved pre-exception CPSR on the stack
str R1, [SP, #0x40] ; Store it in EFI_SYSTEM_CONTEXT_ARM.CPSR
add R2, SP, #0x38 ; Make R2 point to EFI_SYSTEM_CONTEXT_ARM.LR
and R3, R1, #0x1f ; Check CPSR to see if User or System Mode
cmp R3, #0x1f ; if ((CPSR == 0x10) || (CPSR == 0x1f))
- cmpne R3, #0x10 ;
+ cmpne R3, #0x10 ;
stmeqed R2, {lr}^ ; save unbanked lr
- ; else
+ ; else
stmneed R2, {lr} ; save SVC lr
- ldr R5, [SP, #0x58] ; PC is the LR pushed by srsfd
+ ldr R5, [SP, #0x58] ; PC is the LR pushed by srsfd
; Check to see if we have to adjust for Thumb entry
sub r4, r0, #1 ; if (ExceptionType == 1 || ExceptionType == 2)) {
- cmp r4, #1 ; // UND & SVC have differnt LR adjust for Thumb
+ cmp r4, #1 ; // UND & SVC have differnt LR adjust for Thumb
bhi NoAdjustNeeded
-
- tst r1, #0x20 ; if ((CPSR & T)) == T) { // Thumb Mode on entry
+
+ tst r1, #0x20 ; if ((CPSR & T)) == T) { // Thumb Mode on entry
addne R5, R5, #2 ; PC += 2;
strne R5,[SP,#0x58] ; Update LR value pushed by srsfd
-
+
NoAdjustNeeded
str R5, [SP, #0x3c] ; Store it in EFI_SYSTEM_CONTEXT_ARM.PC
-
+
add R1, SP, #0x60 ; We pushed 0x60 bytes on the stack
str R1, [SP, #0x34] ; Store it in EFI_SYSTEM_CONTEXT_ARM.SP
-
- ; R0 is ExceptionType
- mov R1,SP ; R1 is SystemContext
+
+ ; R0 is ExceptionType
+ mov R1,SP ; R1 is SystemContext
#if (FixedPcdGet32(PcdVFPEnabled))
vpush {d0-d15} ; save vstm registers in case they are used in optimizations
@@ -251,7 +251,7 @@ NoAdjustNeeded tst R4, #4
subne SP, SP, #4 ; Adjust SP if not 8-byte aligned
-/*
+/*
VOID
EFIAPI
CommonCExceptionHandler (
@@ -267,35 +267,35 @@ CommonCExceptionHandler ( #if (FixedPcdGet32(PcdVFPEnabled))
vpop {d0-d15}
#endif
-
+
ldr R1, [SP, #0x4c] ; Restore EFI_SYSTEM_CONTEXT_ARM.IFSR
mcr p15, 0, R1, c5, c0, 1 ; Write IFSR
ldr R1, [SP, #0x44] ; Restore EFI_SYSTEM_CONTEXT_ARM.DFSR
mcr p15, 0, R1, c5, c0, 0 ; Write DFSR
-
+
ldr R1,[SP,#0x3c] ; EFI_SYSTEM_CONTEXT_ARM.PC
- str R1,[SP,#0x58] ; Store it back to srsfd stack slot so it can be restored
+ str R1,[SP,#0x58] ; Store it back to srsfd stack slot so it can be restored
ldr R1,[SP,#0x40] ; EFI_SYSTEM_CONTEXT_ARM.CPSR
- str R1,[SP,#0x5c] ; Store it back to srsfd stack slot so it can be restored
-
+ str R1,[SP,#0x5c] ; Store it back to srsfd stack slot so it can be restored
+
add R3, SP, #0x54 ; Make R3 point to SVC LR saved on entry
add R2, SP, #0x38 ; Make R2 point to EFI_SYSTEM_CONTEXT_ARM.LR
and R1, R1, #0x1f ; Check to see if User or System Mode
cmp R1, #0x1f ; if ((CPSR == 0x10) || (CPSR == 0x1f))
- cmpne R1, #0x10 ;
+ cmpne R1, #0x10 ;
ldmeqed R2, {lr}^ ; restore unbanked lr
; else
ldmneed R3, {lr} ; restore SVC lr, via ldmfd SP!, {LR}
-
+
ldmfd SP!,{R0-R12} ; Restore general purpose registers
; Exception handler can not change SP
-
+
add SP,SP,#0x20 ; Clear out the remaining stack space
ldmfd SP!,{LR} ; restore the link register for this context
rfefd SP! ; return from exception via srsfd stack slot
-
+
END
diff --git a/ArmPkg/Drivers/CpuDxe/ArmV6/Mmu.c b/ArmPkg/Drivers/CpuDxe/ArmV6/Mmu.c index 18778f3ac6..63da8ba8cb 100644 --- a/ArmPkg/Drivers/CpuDxe/ArmV6/Mmu.c +++ b/ArmPkg/Drivers/CpuDxe/ArmV6/Mmu.c @@ -24,7 +24,7 @@ typedef UINT32 ARM_FIRST_LEVEL_DESCRIPTOR; // Second Level Descriptors
typedef UINT32 ARM_PAGE_TABLE_ENTRY;
-EFI_STATUS
+EFI_STATUS
SectionToGcdAttributes (
IN UINT32 SectionAttributes,
OUT UINT64 *GcdAttributes
@@ -418,12 +418,12 @@ UpdatePageEntries ( // Calculate number of 4KB page table entries to change
NumPageEntries = Length / TT_DESCRIPTOR_PAGE_SIZE;
-
+
// Iterate for the number of 4KB pages to change
Offset = 0;
for(p = 0; p < NumPageEntries; p++) {
// Calculate index into first level translation table for page table value
-
+
FirstLevelIdx = TT_DESCRIPTOR_SECTION_BASE_ADDRESS(BaseAddress + Offset) >> TT_DESCRIPTOR_SECTION_BASE_SHIFT;
ASSERT (FirstLevelIdx < TRANSLATION_TABLE_SECTION_COUNT);
@@ -435,9 +435,9 @@ UpdatePageEntries ( Status = ConvertSectionToPages (FirstLevelIdx << TT_DESCRIPTOR_SECTION_BASE_SHIFT);
if (EFI_ERROR(Status)) {
// Exit for loop
- break;
- }
-
+ break;
+ }
+
// Re-read descriptor
Descriptor = FirstLevelTable[FirstLevelIdx];
}
@@ -462,7 +462,7 @@ UpdatePageEntries ( // Make this virtual address point at a physical page
PageTableEntry &= ~VirtualMask;
}
-
+
if (CurrentPageTableEntry != PageTableEntry) {
Mva = (VOID *)(UINTN)((((UINTN)FirstLevelIdx) << TT_DESCRIPTOR_SECTION_BASE_SHIFT) + (PageTableIndex << TT_DESCRIPTOR_PAGE_BASE_SHIFT));
if ((CurrentPageTableEntry & TT_DESCRIPTOR_PAGE_CACHEABLE_MASK) == TT_DESCRIPTOR_PAGE_CACHEABLE_MASK) {
@@ -471,14 +471,14 @@ UpdatePageEntries ( WriteBackInvalidateDataCacheRange (Mva, TT_DESCRIPTOR_PAGE_SIZE);
}
- // Only need to update if we are changing the entry
- PageTable[PageTableIndex] = PageTableEntry;
+ // Only need to update if we are changing the entry
+ PageTable[PageTableIndex] = PageTableEntry;
ArmUpdateTranslationTableEntry ((VOID *)&PageTable[PageTableIndex], Mva);
}
Status = EFI_SUCCESS;
Offset += TT_DESCRIPTOR_PAGE_SIZE;
-
+
} // End first level translation table loop
return Status;
@@ -508,7 +508,7 @@ UpdateSectionEntries ( // EntryMask: bitmask of values to change (1 = change this value, 0 = leave alone)
// EntryValue: values at bit positions specified by EntryMask
- // Make sure we handle a section range that is unmapped
+ // Make sure we handle a section range that is unmapped
EntryMask = TT_DESCRIPTOR_SECTION_TYPE_MASK;
EntryValue = TT_DESCRIPTOR_SECTION_TYPE_SECTION;
@@ -567,7 +567,7 @@ UpdateSectionEntries ( // calculate number of 1MB first level entries this applies to
NumSections = Length / TT_DESCRIPTOR_SECTION_SIZE;
-
+
// iterate through each descriptor
for(i=0; i<NumSections; i++) {
CurrentDescriptor = FirstLevelTable[FirstLevelIdx + i];
@@ -578,7 +578,7 @@ UpdateSectionEntries ( Status = UpdatePageEntries ((FirstLevelIdx + i) << TT_DESCRIPTOR_SECTION_BASE_SHIFT, TT_DESCRIPTOR_SECTION_SIZE, Attributes, VirtualMask);
} else {
// still a section entry
-
+
// mask off appropriate fields
Descriptor = CurrentDescriptor & ~EntryMask;
@@ -596,7 +596,7 @@ UpdateSectionEntries ( WriteBackInvalidateDataCacheRange (Mva, SIZE_1MB);
}
- // Only need to update if we are changing the descriptor
+ // Only need to update if we are changing the descriptor
FirstLevelTable[FirstLevelIdx + i] = Descriptor;
ArmUpdateTranslationTableEntry ((VOID *)&FirstLevelTable[FirstLevelIdx + i], Mva);
}
@@ -608,7 +608,7 @@ UpdateSectionEntries ( return Status;
}
-EFI_STATUS
+EFI_STATUS
ConvertSectionToPages (
IN EFI_PHYSICAL_ADDRESS BaseAddress
)
@@ -673,7 +673,7 @@ SetMemoryAttributes ( )
{
EFI_STATUS Status;
-
+
if(((BaseAddress & 0xFFFFF) == 0) && ((Length & 0xFFFFF) == 0)) {
// Is the base and length a multiple of 1 MB?
DEBUG ((EFI_D_PAGE, "SetMemoryAttributes(): MMU section 0x%x length 0x%x to %lx\n", (UINTN)BaseAddress, (UINTN)Length, Attributes));
diff --git a/ArmPkg/Drivers/CpuDxe/CpuDxe.c b/ArmPkg/Drivers/CpuDxe/CpuDxe.c index 337ab7cfb5..0c49acb510 100644 --- a/ArmPkg/Drivers/CpuDxe/CpuDxe.c +++ b/ArmPkg/Drivers/CpuDxe/CpuDxe.c @@ -2,7 +2,7 @@ Copyright (c) 2008 - 2009, Apple Inc. All rights reserved.<BR>
Copyright (c) 2011, ARM Limited. All rights reserved.
-
+
This program and the accompanying materials
are licensed and made available under the terms and conditions of the BSD License
which accompanies this distribution. The full text of the license may be found at
@@ -21,14 +21,14 @@ BOOLEAN mInterruptState = FALSE; /**
- This function flushes the range of addresses from Start to Start+Length
- from the processor's data cache. If Start is not aligned to a cache line
- boundary, then the bytes before Start to the preceding cache line boundary
- are also flushed. If Start+Length is not aligned to a cache line boundary,
- then the bytes past Start+Length to the end of the next cache line boundary
- are also flushed. The FlushType of EfiCpuFlushTypeWriteBackInvalidate must be
- supported. If the data cache is fully coherent with all DMA operations, then
- this function can just return EFI_SUCCESS. If the processor does not support
+ This function flushes the range of addresses from Start to Start+Length
+ from the processor's data cache. If Start is not aligned to a cache line
+ boundary, then the bytes before Start to the preceding cache line boundary
+ are also flushed. If Start+Length is not aligned to a cache line boundary,
+ then the bytes past Start+Length to the end of the next cache line boundary
+ are also flushed. The FlushType of EfiCpuFlushTypeWriteBackInvalidate must be
+ supported. If the data cache is fully coherent with all DMA operations, then
+ this function can just return EFI_SUCCESS. If the processor does not support
flushing a range of the data cache, then the entire data cache can be flushed.
@param This The EFI_CPU_ARCH_PROTOCOL instance.
@@ -70,13 +70,13 @@ CpuFlushCpuDataCache ( default:
return EFI_INVALID_PARAMETER;
}
-
+
return EFI_SUCCESS;
}
/**
- This function enables interrupt processing by the processor.
+ This function enables interrupt processing by the processor.
@param This The EFI_CPU_ARCH_PROTOCOL instance.
@@ -120,8 +120,8 @@ CpuDisableInterrupt ( /**
- This function retrieves the processor's current interrupt state a returns it in
- State. If interrupts are currently enabled, then TRUE is returned. If interrupts
+ This function retrieves the processor's current interrupt state a returns it in
+ State. If interrupts are currently enabled, then TRUE is returned. If interrupts
are currently disabled, then FALSE is returned.
@param This The EFI_CPU_ARCH_PROTOCOL instance.
@@ -150,9 +150,9 @@ CpuGetInterruptState ( /**
This function generates an INIT on the processor. If this function succeeds, then the
- processor will be reset, and control will not be returned to the caller. If InitType is
- not supported by this processor, or the processor cannot programmatically generate an
- INIT without help from external hardware, then EFI_UNSUPPORTED is returned. If an error
+ processor will be reset, and control will not be returned to the caller. If InitType is
+ not supported by this processor, or the processor cannot programmatically generate an
+ INIT without help from external hardware, then EFI_UNSUPPORTED is returned. If an error
occurs attempting to generate an INIT, then EFI_DEVICE_ERROR is returned.
@param This The EFI_CPU_ARCH_PROTOCOL instance.
@@ -199,7 +199,7 @@ CpuGetTimerValue ( /**
Callback function for idle events.
-
+
@param Event Event whose notification function is being invoked.
@param Context The pointer to the notification function's context,
which is implementation-dependent.
@@ -241,22 +241,22 @@ CpuDxeInitialize ( EFI_STATUS Status;
EFI_EVENT IdleLoopEvent;
- InitializeExceptions (&mCpu);
-
+ InitializeExceptions (&mCpu);
+
Status = gBS->InstallMultipleProtocolInterfaces (
- &mCpuHandle,
- &gEfiCpuArchProtocolGuid, &mCpu,
+ &mCpuHandle,
+ &gEfiCpuArchProtocolGuid, &mCpu,
&gVirtualUncachedPagesProtocolGuid, &gVirtualUncachedPages,
NULL
);
-
+
//
// Make sure GCD and MMU settings match. This API calls gDS->SetMemorySpaceAttributes ()
// and that calls EFI_CPU_ARCH_PROTOCOL.SetMemoryAttributes, so this code needs to go
// after the protocol is installed
//
SyncCacheConfig (&mCpu);
-
+
// If the platform is a MPCore system then install the Configuration Table describing the
// secondary core states
if (ArmIsMpCore()) {
diff --git a/ArmPkg/Drivers/CpuDxe/CpuDxe.h b/ArmPkg/Drivers/CpuDxe/CpuDxe.h index d5b50641e3..d16abe400e 100644 --- a/ArmPkg/Drivers/CpuDxe/CpuDxe.h +++ b/ArmPkg/Drivers/CpuDxe/CpuDxe.h @@ -48,9 +48,9 @@ /**
- This function registers and enables the handler specified by InterruptHandler for a processor
- interrupt or exception type specified by InterruptType. If InterruptHandler is NULL, then the
- handler for the processor interrupt or exception type specified by InterruptType is uninstalled.
+ This function registers and enables the handler specified by InterruptHandler for a processor
+ interrupt or exception type specified by InterruptType. If InterruptHandler is NULL, then the
+ handler for the processor interrupt or exception type specified by InterruptType is uninstalled.
The installed handler is called once for each processor interrupt or exception.
@param InterruptType A pointer to the processor's current interrupt state. Set to TRUE if interrupts
@@ -75,9 +75,9 @@ RegisterInterruptHandler ( /**
- This function registers and enables the handler specified by InterruptHandler for a processor
- interrupt or exception type specified by InterruptType. If InterruptHandler is NULL, then the
- handler for the processor interrupt or exception type specified by InterruptType is uninstalled.
+ This function registers and enables the handler specified by InterruptHandler for a processor
+ interrupt or exception type specified by InterruptType. If InterruptHandler is NULL, then the
+ handler for the processor interrupt or exception type specified by InterruptType is uninstalled.
The installed handler is called once for each processor interrupt or exception.
@param InterruptType A pointer to the processor's current interrupt state. Set to TRUE if interrupts
@@ -120,7 +120,7 @@ SyncCacheConfig ( IN EFI_CPU_ARCH_PROTOCOL *CpuProtocol
);
-EFI_STATUS
+EFI_STATUS
ConvertSectionToPages (
IN EFI_PHYSICAL_ADDRESS BaseAddress
);
diff --git a/ArmPkg/Drivers/CpuDxe/CpuDxe.inf b/ArmPkg/Drivers/CpuDxe/CpuDxe.inf index e0d5190e55..01f65a3655 100644 --- a/ArmPkg/Drivers/CpuDxe/CpuDxe.inf +++ b/ArmPkg/Drivers/CpuDxe/CpuDxe.inf @@ -1,7 +1,7 @@ #/** @file
-#
+#
# DXE CPU driver
-#
+#
# Copyright (c) 2009, Apple Inc. All rights reserved.<BR>
# Copyright (c) 2011-2013, ARM Limited. All rights reserved.
#
@@ -9,10 +9,10 @@ # are licensed and made available under the terms and conditions of the BSD License
# which accompanies this distribution. The full text of the license may be found at
# http://opensource.org/licenses/bsd-license.php
-#
+#
# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
-#
+#
#**/
[Defines]
@@ -83,7 +83,7 @@ [Pcd.common]
gArmTokenSpaceGuid.PcdVFPEnabled
gArmTokenSpaceGuid.PcdCpuVectorBaseAddress
-
+
[FeaturePcd.common]
gArmTokenSpaceGuid.PcdCpuDxeProduceDebugSupport
gArmTokenSpaceGuid.PcdRelocateVectorTable
diff --git a/ArmPkg/Drivers/CpuPei/CpuPei.c b/ArmPkg/Drivers/CpuPei/CpuPei.c index e070c998c2..d54f42acfc 100755 --- a/ArmPkg/Drivers/CpuPei/CpuPei.c +++ b/ArmPkg/Drivers/CpuPei/CpuPei.c @@ -4,18 +4,18 @@ Copyright (c) 2006, Intel Corporation. All rights reserved.<BR> Copyright (c) 2011 Hewlett Packard Corporation. All rights reserved.<BR>
Copyright (c) 2011-2013, ARM Limited. All rights reserved.<BR>
-This program and the accompanying materials
-are licensed and made available under the terms and conditions of the BSD License
-which accompanies this distribution. The full text of the license may be found at
-http://opensource.org/licenses/bsd-license.php
-
-THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
-WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
+This program and the accompanying materials
+are licensed and made available under the terms and conditions of the BSD License
+which accompanies this distribution. The full text of the license may be found at
+http://opensource.org/licenses/bsd-license.php
+
+THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
+WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
Module Name:
MemoryInit.c
-
+
Abstract:
PEIM to provide fake memory init
@@ -51,7 +51,7 @@ Arguments: FileHandle - Handle of the file being invoked.
PeiServices - Describes the list of possible PEI Services.
-
+
Returns:
Status - EFI_SUCCESS if the boot mode could be set
diff --git a/ArmPkg/Drivers/CpuPei/CpuPei.inf b/ArmPkg/Drivers/CpuPei/CpuPei.inf index ebd1fe412b..eafccd6009 100755 --- a/ArmPkg/Drivers/CpuPei/CpuPei.inf +++ b/ArmPkg/Drivers/CpuPei/CpuPei.inf @@ -45,7 +45,7 @@ [Ppis]
gArmMpCoreInfoPpiGuid
-
+
[Guids]
gArmMpCoreInfoGuid
@@ -55,4 +55,4 @@ [Depex]
gEfiPeiMemoryDiscoveredPpiGuid
-
+
diff --git a/ArmPkg/Drivers/TimerDxe/TimerDxe.c b/ArmPkg/Drivers/TimerDxe/TimerDxe.c index a43a10f48c..633876bea6 100644 --- a/ArmPkg/Drivers/TimerDxe/TimerDxe.c +++ b/ArmPkg/Drivers/TimerDxe/TimerDxe.c @@ -40,16 +40,16 @@ UINT64 mTimerPeriod = 0; EFI_HARDWARE_INTERRUPT_PROTOCOL *gInterrupt = NULL;
/**
- This function registers the handler NotifyFunction so it is called every time
- the timer interrupt fires. It also passes the amount of time since the last
- handler call to the NotifyFunction. If NotifyFunction is NULL, then the
- handler is unregistered. If the handler is registered, then EFI_SUCCESS is
- returned. If the CPU does not support registering a timer interrupt handler,
- then EFI_UNSUPPORTED is returned. If an attempt is made to register a handler
- when a handler is already registered, then EFI_ALREADY_STARTED is returned.
- If an attempt is made to unregister a handler when a handler is not registered,
- then EFI_INVALID_PARAMETER is returned. If an error occurs attempting to
- register the NotifyFunction with the timer interrupt, then EFI_DEVICE_ERROR
+ This function registers the handler NotifyFunction so it is called every time
+ the timer interrupt fires. It also passes the amount of time since the last
+ handler call to the NotifyFunction. If NotifyFunction is NULL, then the
+ handler is unregistered. If the handler is registered, then EFI_SUCCESS is
+ returned. If the CPU does not support registering a timer interrupt handler,
+ then EFI_UNSUPPORTED is returned. If an attempt is made to register a handler
+ when a handler is already registered, then EFI_ALREADY_STARTED is returned.
+ If an attempt is made to unregister a handler when a handler is not registered,
+ then EFI_INVALID_PARAMETER is returned. If an error occurs attempting to
+ register the NotifyFunction with the timer interrupt, then EFI_DEVICE_ERROR
is returned.
@param This The EFI_TIMER_ARCH_PROTOCOL instance.
@@ -102,17 +102,17 @@ ExitBootServicesEvent ( /**
- This function adjusts the period of timer interrupts to the value specified
- by TimerPeriod. If the timer period is updated, then the selected timer
- period is stored in EFI_TIMER.TimerPeriod, and EFI_SUCCESS is returned. If
- the timer hardware is not programmable, then EFI_UNSUPPORTED is returned.
- If an error occurs while attempting to update the timer period, then the
- timer hardware will be put back in its state prior to this call, and
- EFI_DEVICE_ERROR is returned. If TimerPeriod is 0, then the timer interrupt
- is disabled. This is not the same as disabling the CPU's interrupts.
- Instead, it must either turn off the timer hardware, or it must adjust the
- interrupt controller so that a CPU interrupt is not generated when the timer
- interrupt fires.
+ This function adjusts the period of timer interrupts to the value specified
+ by TimerPeriod. If the timer period is updated, then the selected timer
+ period is stored in EFI_TIMER.TimerPeriod, and EFI_SUCCESS is returned. If
+ the timer hardware is not programmable, then EFI_UNSUPPORTED is returned.
+ If an error occurs while attempting to update the timer period, then the
+ timer hardware will be put back in its state prior to this call, and
+ EFI_DEVICE_ERROR is returned. If TimerPeriod is 0, then the timer interrupt
+ is disabled. This is not the same as disabling the CPU's interrupts.
+ Instead, it must either turn off the timer hardware, or it must adjust the
+ interrupt controller so that a CPU interrupt is not generated when the timer
+ interrupt fires.
@param This The EFI_TIMER_ARCH_PROTOCOL instance.
@param TimerPeriod The rate to program the timer interrupt in 100 nS units. If
@@ -136,7 +136,7 @@ TimerDriverSetTimerPeriod ( )
{
UINT64 TimerTicks;
-
+
// Always disable the timer
ArmArchTimerDisableTimer ();
@@ -158,9 +158,9 @@ TimerDriverSetTimerPeriod ( }
/**
- This function retrieves the period of timer interrupts in 100 ns units,
- returns that value in TimerPeriod, and returns EFI_SUCCESS. If TimerPeriod
- is NULL, then EFI_INVALID_PARAMETER is returned. If a TimerPeriod of 0 is
+ This function retrieves the period of timer interrupts in 100 ns units,
+ returns that value in TimerPeriod, and returns EFI_SUCCESS. If TimerPeriod
+ is NULL, then EFI_INVALID_PARAMETER is returned. If a TimerPeriod of 0 is
returned, then the timer is currently disabled.
@param This The EFI_TIMER_ARCH_PROTOCOL instance.
@@ -188,12 +188,12 @@ TimerDriverGetTimerPeriod ( }
/**
- This function generates a soft timer interrupt. If the platform does not support soft
- timer interrupts, then EFI_UNSUPPORTED is returned. Otherwise, EFI_SUCCESS is returned.
- If a handler has been registered through the EFI_TIMER_ARCH_PROTOCOL.RegisterHandler()
- service, then a soft timer interrupt will be generated. If the timer interrupt is
- enabled when this service is called, then the registered handler will be invoked. The
- registered handler should not be able to distinguish a hardware-generated timer
+ This function generates a soft timer interrupt. If the platform does not support soft
+ timer interrupts, then EFI_UNSUPPORTED is returned. Otherwise, EFI_SUCCESS is returned.
+ If a handler has been registered through the EFI_TIMER_ARCH_PROTOCOL.RegisterHandler()
+ service, then a soft timer interrupt will be generated. If the timer interrupt is
+ enabled when this service is called, then the registered handler will be invoked. The
+ registered handler should not be able to distinguish a hardware-generated timer
interrupt from a software-generated timer interrupt.
@param This The EFI_TIMER_ARCH_PROTOCOL instance.
diff --git a/ArmPkg/Drivers/TimerDxe/TimerDxe.inf b/ArmPkg/Drivers/TimerDxe/TimerDxe.inf index 061fcbc688..50477ba42a 100644 --- a/ArmPkg/Drivers/TimerDxe/TimerDxe.inf +++ b/ArmPkg/Drivers/TimerDxe/TimerDxe.inf @@ -1,22 +1,22 @@ #/** @file
-#
+#
# Component description file for Timer DXE module
-#
+#
# Copyright (c) 2009 - 2010, Apple Inc. All rights reserved.<BR>
# This program and the accompanying materials
# are licensed and made available under the terms and conditions of the BSD License
# which accompanies this distribution. The full text of the license may be found at
# http://opensource.org/licenses/bsd-license.php
-#
+#
# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
-#
+#
#**/
[Defines]
INF_VERSION = 0x00010005
BASE_NAME = ArmTimerDxe
- FILE_GUID = 49ea041e-6752-42ca-b0b1-7344fe2546b7
+ FILE_GUID = 49ea041e-6752-42ca-b0b1-7344fe2546b7
MODULE_TYPE = DXE_DRIVER
VERSION_STRING = 1.0
@@ -40,20 +40,19 @@ BaseMemoryLib
DebugLib
UefiDriverEntryPoint
- IoLib
+ IoLib
[Guids]
[Protocols]
- gEfiTimerArchProtocolGuid
+ gEfiTimerArchProtocolGuid
gHardwareInterruptProtocolGuid
[Pcd.common]
gEmbeddedTokenSpaceGuid.PcdTimerPeriod
- gArmTokenSpaceGuid.PcdArmArchTimerSecIntrNum
+ gArmTokenSpaceGuid.PcdArmArchTimerSecIntrNum
gArmTokenSpaceGuid.PcdArmArchTimerIntrNum
- gArmTokenSpaceGuid.PcdArmArchTimerFreqInHz
+ gArmTokenSpaceGuid.PcdArmArchTimerFreqInHz
[Depex]
gHardwareInterruptProtocolGuid
-
\ No newline at end of file diff --git a/ArmPkg/Filesystem/SemihostFs/Arm/SemihostFs.c b/ArmPkg/Filesystem/SemihostFs/Arm/SemihostFs.c index ede23ef2ed..3d6e72aa5a 100644 --- a/ArmPkg/Filesystem/SemihostFs/Arm/SemihostFs.c +++ b/ArmPkg/Filesystem/SemihostFs/Arm/SemihostFs.c @@ -21,7 +21,7 @@ #include <Guid/FileSystemVolumeLabelInfo.h>
#include <Library/BaseLib.h>
-#include <Library/BaseMemoryLib.h>
+#include <Library/BaseMemoryLib.h>
#include <Library/DebugLib.h>
#include <Library/MemoryAllocationLib.h>
#include <Library/SemihostLib.h>
@@ -129,7 +129,7 @@ VolumeOpen ( )
{
SEMIHOST_FCB *RootFcb = NULL;
-
+
if (Root == NULL) {
return EFI_INVALID_PARAMETER;
}
@@ -138,7 +138,7 @@ VolumeOpen ( if (RootFcb == NULL) {
return EFI_OUT_OF_RESOURCES;
}
-
+
RootFcb->IsRoot = TRUE;
RootFcb->Info.Attribute = EFI_FILE_READ_ONLY | EFI_FILE_DIRECTORY;
@@ -212,7 +212,7 @@ FileOpen ( if (EFI_ERROR(Status)) {
return Status;
}
-
+
IsRoot = FALSE;
}
@@ -267,7 +267,7 @@ FileClose ( FreeFCB (Fcb);
}
}
-
+
return Status;
}
@@ -357,7 +357,7 @@ FileWrite ( *BufferSize -= WriteSize;
Fcb->Position += *BufferSize;
}
-
+
return Status;
}
@@ -368,7 +368,7 @@ FileGetPosition ( )
{
SEMIHOST_FCB *Fcb = NULL;
-
+
if (Position == NULL) {
return EFI_INVALID_PARAMETER;
}
@@ -447,11 +447,11 @@ GetFileInfo ( Info->FileName[0] = L'\0';
} else {
for (Index = 0; Index < NameSize; Index++) {
- Info->FileName[Index] = Fcb->FileName[Index];
+ Info->FileName[Index] = Fcb->FileName[Index];
}
}
- *BufferSize = ResultSize;
+ *BufferSize = ResultSize;
return EFI_SUCCESS;
}
@@ -467,11 +467,11 @@ GetFilesystemInfo ( EFI_FILE_SYSTEM_INFO *Info = NULL;
EFI_STATUS Status;
UINTN ResultSize = SIZE_OF_EFI_FILE_SYSTEM_INFO + StrSize (mSemihostFsLabel);
-
+
if (*BufferSize >= ResultSize) {
ZeroMem (Buffer, ResultSize);
Status = EFI_SUCCESS;
-
+
Info = Buffer;
Info->Size = ResultSize;
@@ -485,7 +485,7 @@ GetFilesystemInfo ( Status = EFI_BUFFER_TOO_SMALL;
}
- *BufferSize = ResultSize;
+ *BufferSize = ResultSize;
return Status;
}
@@ -500,9 +500,9 @@ FileGetInfo ( SEMIHOST_FCB *Fcb;
EFI_STATUS Status;
UINTN ResultSize;
-
+
Fcb = SEMIHOST_FCB_FROM_THIS(File);
-
+
if (CompareGuid (InformationType, &gEfiFileSystemInfoGuid) != 0) {
Status = GetFilesystemInfo (Fcb, BufferSize, Buffer);
} else if (CompareGuid (InformationType, &gEfiFileInfoGuid) != 0) {
@@ -596,8 +596,8 @@ SemihostFsEntryPoint ( }
Status = gBS->InstallMultipleProtocolInterfaces (
- &gInstallHandle,
- &gEfiSimpleFileSystemProtocolGuid, &gSemihostFs,
+ &gInstallHandle,
+ &gEfiSimpleFileSystemProtocolGuid, &gSemihostFs,
&gEfiDevicePathProtocolGuid, &gDevicePath,
NULL
);
@@ -606,6 +606,6 @@ SemihostFsEntryPoint ( FreePool (mSemihostFsLabel);
}
}
-
+
return Status;
}
diff --git a/ArmPkg/Filesystem/SemihostFs/SemihostFs.inf b/ArmPkg/Filesystem/SemihostFs/SemihostFs.inf index fdf669be56..164df2d85e 100644 --- a/ArmPkg/Filesystem/SemihostFs/SemihostFs.inf +++ b/ArmPkg/Filesystem/SemihostFs/SemihostFs.inf @@ -4,13 +4,13 @@ # Copyright (c) 2009, Apple Inc. All rights reserved.<BR>
# Portions copyright (c) 2011 - 2013, ARM Ltd. All rights reserved.
#
-# This program and the accompanying materials
-# are licensed and made available under the terms and conditions of the BSD License
-# which accompanies this distribution. The full text of the license may be found at
-# http://opensource.org/licenses/bsd-license.php
+# This program and the accompanying materials
+# are licensed and made available under the terms and conditions of the BSD License
+# which accompanies this distribution. The full text of the license may be found at
+# http://opensource.org/licenses/bsd-license.php
#
-# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
-# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
+# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
+# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
#
#**/
@@ -25,7 +25,7 @@ [Sources.ARM, Sources.AARCH64]
Arm/SemihostFs.c
-
+
[Packages]
MdePkg/MdePkg.dec
ArmPkg/ArmPkg.dec
@@ -45,4 +45,4 @@ [Protocols]
gEfiSimpleFileSystemProtocolGuid
gEfiDevicePathProtocolGuid
-
+
diff --git a/ArmPkg/Include/AsmMacroIoLib.h b/ArmPkg/Include/AsmMacroIoLib.h index dac2e150cc..408b2ca280 100644 --- a/ArmPkg/Include/AsmMacroIoLib.h +++ b/ArmPkg/Include/AsmMacroIoLib.h @@ -159,7 +159,7 @@ _InitializePrimaryStackEnd: ldr r1, =Address ; \
ldr r0, =Data ; \
str r0, [r1]
-
+
#define MmioOr32(Address, OrData) \
ldr r1, =Address ; \
ldr r2, =OrData ; \
@@ -181,7 +181,7 @@ _InitializePrimaryStackEnd: and r0, r0, r2 ; \
ldr r2, =OrData ; \
orr r0, r0, r2 ; \
- str r0, [r1]
+ str r0, [r1]
#define MmioWriteFromReg32(Address, Reg) \
ldr r1, =Address ; \
@@ -235,7 +235,7 @@ _InitializePrimaryStackEnd: #else
//
-// Use ARM assembly macros, form armasam
+// Use ARM assembly macros, form armasam
//
// Less magic in the macros if ldr reg, =expr works
//
@@ -251,7 +251,7 @@ _InitializePrimaryStackEnd: // returns Data in R0 and Address in R1, and OrData in r2
#define MmioOr32(Address, OrData) MmioOr32Macro Address, OrData
-
+
// returns _Data in R0 and _Address in R1, and _OrData in r2
diff --git a/ArmPkg/Include/AsmMacroIoLib.inc b/ArmPkg/Include/AsmMacroIoLib.inc index 54c32d4c34..87e497b31a 100644 --- a/ArmPkg/Include/AsmMacroIoLib.inc +++ b/ArmPkg/Include/AsmMacroIoLib.inc @@ -5,81 +5,81 @@ ; Copyright (c) 2009, Apple Inc. All rights reserved.<BR>
; Copyright (c) 2011-2012, ARM Ltd. All rights reserved.<BR>
;
-; This program and the accompanying materials
-; are licensed and made available under the terms and conditions of the BSD License
-; which accompanies this distribution. The full text of the license may be found at
-; http://opensource.org/licenses/bsd-license.php
-;
-; THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
-; WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
+; This program and the accompanying materials
+; are licensed and made available under the terms and conditions of the BSD License
+; which accompanies this distribution. The full text of the license may be found at
+; http://opensource.org/licenses/bsd-license.php
+;
+; THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
+; WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
;
;**/
- MACRO
- MmioWrite32Macro $Address, $Data
- ldr r1, = ($Address)
- ldr r0, = ($Data)
- str r0, [r1]
+ MACRO
+ MmioWrite32Macro $Address, $Data
+ ldr r1, = ($Address)
+ ldr r0, = ($Data)
+ str r0, [r1]
MEND
-
- MACRO
- MmioOr32Macro $Address, $OrData
- ldr r1, =($Address)
- ldr r2, =($OrData)
- ldr r0, [r1]
- orr r0, r0, r2
- str r0, [r1]
+
+ MACRO
+ MmioOr32Macro $Address, $OrData
+ ldr r1, =($Address)
+ ldr r2, =($OrData)
+ ldr r0, [r1]
+ orr r0, r0, r2
+ str r0, [r1]
MEND
- MACRO
- MmioAnd32Macro $Address, $AndData
- ldr r1, =($Address)
- ldr r2, =($AndData)
- ldr r0, [r1]
- and r0, r0, r2
- str r0, [r1]
+ MACRO
+ MmioAnd32Macro $Address, $AndData
+ ldr r1, =($Address)
+ ldr r2, =($AndData)
+ ldr r0, [r1]
+ and r0, r0, r2
+ str r0, [r1]
MEND
- MACRO
- MmioAndThenOr32Macro $Address, $AndData, $OrData
- ldr r1, =($Address)
- ldr r0, [r1]
- ldr r2, =($AndData)
- and r0, r0, r2
- ldr r2, =($OrData)
- orr r0, r0, r2
- str r0, [r1]
+ MACRO
+ MmioAndThenOr32Macro $Address, $AndData, $OrData
+ ldr r1, =($Address)
+ ldr r0, [r1]
+ ldr r2, =($AndData)
+ and r0, r0, r2
+ ldr r2, =($OrData)
+ orr r0, r0, r2
+ str r0, [r1]
MEND
- MACRO
- MmioWriteFromReg32Macro $Address, $Reg
- ldr r1, =($Address)
- str $Reg, [r1]
+ MACRO
+ MmioWriteFromReg32Macro $Address, $Reg
+ ldr r1, =($Address)
+ str $Reg, [r1]
MEND
- MACRO
- MmioRead32Macro $Address
- ldr r1, =($Address)
- ldr r0, [r1]
+ MACRO
+ MmioRead32Macro $Address
+ ldr r1, =($Address)
+ ldr r0, [r1]
+ MEND
+
+ MACRO
+ MmioReadToReg32Macro $Address, $Reg
+ ldr r1, =($Address)
+ ldr $Reg, [r1]
MEND
- MACRO
- MmioReadToReg32Macro $Address, $Reg
- ldr r1, =($Address)
- ldr $Reg, [r1]
+ MACRO
+ LoadConstantMacro $Data
+ ldr r0, =($Data)
MEND
- MACRO
- LoadConstantMacro $Data
- ldr r0, =($Data)
+ MACRO
+ LoadConstantToRegMacro $Data, $Reg
+ ldr $Reg, =($Data)
MEND
- MACRO
- LoadConstantToRegMacro $Data, $Reg
- ldr $Reg, =($Data)
- MEND
-
; The reserved place must be 8-bytes aligned for pushing 64-bit variable on the stack
; Note: Global Size will be modified
MACRO
diff --git a/ArmPkg/Include/Chipset/ARM926EJ-S.h b/ArmPkg/Include/Chipset/ARM926EJ-S.h index 8e1b6e1462..4ef110358f 100644 --- a/ArmPkg/Include/Chipset/ARM926EJ-S.h +++ b/ArmPkg/Include/Chipset/ARM926EJ-S.h @@ -58,7 +58,7 @@ #define TT_DESCRIPTOR_SECTION_WRITE_BACK (TT_DESCRIPTOR_SECTION_ACCESS_PERMISSION_READ_WRITE | \
TT_DESCRIPTOR_SECTION_DOMAIN(0) | \
TT_DESCRIPTOR_SECTION_CACHE_POLICY_WRITE_BACK | \
- TT_DESCRIPTOR_TYPE_SECTION)
+ TT_DESCRIPTOR_TYPE_SECTION)
#define TT_DESCRIPTOR_SECTION_WRITE_THROUGH (TT_DESCRIPTOR_SECTION_ACCESS_PERMISSION_READ_WRITE | \
TT_DESCRIPTOR_SECTION_DOMAIN(0) | \
TT_DESCRIPTOR_SECTION_CACHE_POLICY_WRITE_THROUGH | \
diff --git a/ArmPkg/Include/Chipset/ArmArchTimer.h b/ArmPkg/Include/Chipset/ArmArchTimer.h index fcc03ca921..1caad3d336 100644 --- a/ArmPkg/Include/Chipset/ArmArchTimer.h +++ b/ArmPkg/Include/Chipset/ArmArchTimer.h @@ -1,14 +1,14 @@ /** @file
*
* Copyright (c) 2011-2013, ARM Limited. All rights reserved.
-*
-* This program and the accompanying materials
-* are licensed and made available under the terms and conditions of the BSD License
-* which accompanies this distribution. The full text of the license may be found at
-* http://opensource.org/licenses/bsd-license.php
*
-* THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
-* WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
+* This program and the accompanying materials
+* are licensed and made available under the terms and conditions of the BSD License
+* which accompanies this distribution. The full text of the license may be found at
+* http://opensource.org/licenses/bsd-license.php
+*
+* THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
+* WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
*
**/
diff --git a/ArmPkg/Include/Chipset/ArmV7.h b/ArmPkg/Include/Chipset/ArmV7.h index 839a192516..ceb32170ed 100644 --- a/ArmPkg/Include/Chipset/ArmV7.h +++ b/ArmPkg/Include/Chipset/ArmV7.h @@ -94,7 +94,7 @@ ArmEnableSWPInstruction ( VOID
);
-UINTN
+UINTN
EFIAPI
ArmReadCbar (
VOID
diff --git a/ArmPkg/Include/Chipset/ArmV7Mmu.h b/ArmPkg/Include/Chipset/ArmV7Mmu.h index a3b3e35f10..24ab1755fa 100644 --- a/ArmPkg/Include/Chipset/ArmV7Mmu.h +++ b/ArmPkg/Include/Chipset/ArmV7Mmu.h @@ -1,14 +1,14 @@ /** @file
*
* Copyright (c) 2011-2013, ARM Limited. All rights reserved.
-*
-* This program and the accompanying materials
-* are licensed and made available under the terms and conditions of the BSD License
-* which accompanies this distribution. The full text of the license may be found at
-* http://opensource.org/licenses/bsd-license.php
*
-* THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
-* WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
+* This program and the accompanying materials
+* are licensed and made available under the terms and conditions of the BSD License
+* which accompanies this distribution. The full text of the license may be found at
+* http://opensource.org/licenses/bsd-license.php
+*
+* THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
+* WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
*
**/
diff --git a/ArmPkg/Include/Guid/ArmMpCoreInfo.h b/ArmPkg/Include/Guid/ArmMpCoreInfo.h index dba2becca9..fe690e274b 100644 --- a/ArmPkg/Include/Guid/ArmMpCoreInfo.h +++ b/ArmPkg/Include/Guid/ArmMpCoreInfo.h @@ -1,14 +1,14 @@ /** @file
*
* Copyright (c) 2011, ARM Limited. All rights reserved.
-*
-* This program and the accompanying materials
-* are licensed and made available under the terms and conditions of the BSD License
-* which accompanies this distribution. The full text of the license may be found at
-* http://opensource.org/licenses/bsd-license.php
*
-* THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
-* WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
+* This program and the accompanying materials
+* are licensed and made available under the terms and conditions of the BSD License
+* which accompanies this distribution. The full text of the license may be found at
+* http://opensource.org/licenses/bsd-license.php
+*
+* THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
+* WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
*
**/
diff --git a/ArmPkg/Include/Library/ArmDisassemblerLib.h b/ArmPkg/Include/Library/ArmDisassemblerLib.h index 757c95ec79..d6a493f2cb 100644 --- a/ArmPkg/Include/Library/ArmDisassemblerLib.h +++ b/ArmPkg/Include/Library/ArmDisassemblerLib.h @@ -16,19 +16,19 @@ #define __ARM_DISASSEBLER_LIB_H__
/**
- Place a dissasembly of of **OpCodePtr into buffer, and update OpCodePtr to
- point to next instructin.
-
- We cheat and only decode instructions that access
+ Place a dissasembly of of **OpCodePtr into buffer, and update OpCodePtr to
+ point to next instructin.
+
+ We cheat and only decode instructions that access
memory. If the instruction is not found we dump the instruction in hex.
-
- @param OpCodePtrPtr Pointer to pointer of ARM Thumb instruction to disassemble.
+
+ @param OpCodePtrPtr Pointer to pointer of ARM Thumb instruction to disassemble.
@param Thumb TRUE for Thumb(2), FALSE for ARM instruction stream
@param Extended TRUE dump hex for instruction too.
@param ItBlock Size of IT Block
@param Buf Buffer to sprintf disassembly into.
- @param Size Size of Buf in bytes.
-
+ @param Size Size of Buf in bytes.
+
**/
VOID
DisassembleInstruction (
@@ -39,5 +39,5 @@ DisassembleInstruction ( OUT CHAR8 *Buf,
OUT UINTN Size
);
-
-#endif
+
+#endif
diff --git a/ArmPkg/Include/Library/ArmLib.h b/ArmPkg/Include/Library/ArmLib.h index bc3b89663c..0bb0d4a063 100644 --- a/ArmPkg/Include/Library/ArmLib.h +++ b/ArmPkg/Include/Library/ArmLib.h @@ -148,43 +148,43 @@ EFIAPI ArmDataCachePresent (
VOID
);
-
+
UINTN
EFIAPI
ArmDataCacheSize (
VOID
);
-
+
UINTN
EFIAPI
ArmDataCacheAssociativity (
VOID
);
-
+
UINTN
EFIAPI
ArmDataCacheLineLength (
VOID
);
-
+
BOOLEAN
EFIAPI
ArmInstructionCachePresent (
VOID
);
-
+
UINTN
EFIAPI
ArmInstructionCacheSize (
VOID
);
-
+
UINTN
EFIAPI
ArmInstructionCacheAssociativity (
VOID
);
-
+
UINTN
EFIAPI
ArmInstructionCacheLineLength (
@@ -311,7 +311,7 @@ EFIAPI ArmDisableInstructionCache (
VOID
);
-
+
VOID
EFIAPI
ArmEnableMmu (
@@ -395,7 +395,7 @@ EFIAPI ArmDisableFiq (
VOID
);
-
+
BOOLEAN
EFIAPI
ArmGetFiqState (
@@ -407,14 +407,14 @@ EFIAPI ArmInvalidateTlb (
VOID
);
-
+
VOID
EFIAPI
ArmUpdateTranslationTableEntry (
IN VOID *TranslationTableEntry,
IN VOID *Mva
);
-
+
VOID
EFIAPI
ArmSetDomainAccessControl (
@@ -440,13 +440,13 @@ ArmConfigureMmu ( OUT VOID **TranslationTableBase OPTIONAL,
OUT UINTN *TranslationTableSize OPTIONAL
);
-
+
BOOLEAN
EFIAPI
ArmMmuEnabled (
VOID
);
-
+
VOID
EFIAPI
ArmEnableBranchPrediction (
@@ -482,13 +482,13 @@ EFIAPI ArmDataMemoryBarrier (
VOID
);
-
+
VOID
EFIAPI
ArmDataSyncronizationBarrier (
VOID
);
-
+
VOID
EFIAPI
ArmInstructionSynchronizationBarrier (
diff --git a/ArmPkg/Include/Library/DefaultExceptionHandlerLib.h b/ArmPkg/Include/Library/DefaultExceptionHandlerLib.h index 7166dbb36e..5c7d7e2600 100644 --- a/ArmPkg/Include/Library/DefaultExceptionHandlerLib.h +++ b/ArmPkg/Include/Library/DefaultExceptionHandlerLib.h @@ -27,5 +27,5 @@ DefaultExceptionHandler ( IN EFI_EXCEPTION_TYPE ExceptionType,
IN OUT EFI_SYSTEM_CONTEXT SystemContext
);
-
-#endif
+
+#endif
diff --git a/ArmPkg/Include/Library/SemihostLib.h b/ArmPkg/Include/Library/SemihostLib.h index 6256551771..4026f51736 100644 --- a/ArmPkg/Include/Library/SemihostLib.h +++ b/ArmPkg/Include/Library/SemihostLib.h @@ -22,7 +22,7 @@ * about the semihosting interface.
*
*/
-
+
#define SEMIHOST_FILE_MODE_READ (0 << 2)
#define SEMIHOST_FILE_MODE_WRITE (1 << 2)
#define SEMIHOST_FILE_MODE_APPEND (2 << 2)
@@ -92,10 +92,10 @@ VOID SemihostWriteString (
IN CHAR8 *String
);
-
+
UINT32
SemihostSystem (
IN CHAR8 *CommandLine
);
-
+
#endif // __SEMIHOSTING_H__
diff --git a/ArmPkg/Include/Library/UncachedMemoryAllocationLib.h b/ArmPkg/Include/Library/UncachedMemoryAllocationLib.h index 4161fc7c62..a49d8d3ac9 100644 --- a/ArmPkg/Include/Library/UncachedMemoryAllocationLib.h +++ b/ArmPkg/Include/Library/UncachedMemoryAllocationLib.h @@ -121,7 +121,7 @@ UncachedAllocateReservedPages ( If Buffer was not allocated with a page allocation function in the Memory Allocation Library,
then ASSERT().
If Pages is zero, then ASSERT().
-
+
@param Buffer Pointer to the buffer of pages to free.
@param Pages The number of 4 KB pages to free.
@@ -212,7 +212,7 @@ UncachedAllocateAlignedReservedPages ( If Buffer was not allocated with an aligned page allocation function in the Memory Allocation
Library, then ASSERT().
If Pages is zero, then ASSERT().
-
+
@param Buffer Pointer to the buffer of pages to free.
@param Pages The number of 4 KB pages to free.
@@ -343,7 +343,7 @@ UncachedAllocateReservedZeroPool ( allocated buffer. If AllocationSize is 0, then a valid buffer of 0 size is returned. If there
is not enough memory remaining to satisfy the request, then NULL is returned.
If Buffer is NULL, then ASSERT().
- If AllocationSize is greater than (MAX_ADDRESS ? Buffer + 1), then ASSERT().
+ If AllocationSize is greater than (MAX_ADDRESS ? Buffer + 1), then ASSERT().
@param AllocationSize The number of bytes to allocate and zero.
@param Buffer The buffer to copy to the allocated buffer.
@@ -366,7 +366,7 @@ UncachedAllocateCopyPool ( allocated buffer. If AllocationSize is 0, then a valid buffer of 0 size is returned. If there
is not enough memory remaining to satisfy the request, then NULL is returned.
If Buffer is NULL, then ASSERT().
- If AllocationSize is greater than (MAX_ADDRESS ? Buffer + 1), then ASSERT().
+ If AllocationSize is greater than (MAX_ADDRESS ? Buffer + 1), then ASSERT().
@param AllocationSize The number of bytes to allocate and zero.
@param Buffer The buffer to copy to the allocated buffer.
@@ -389,7 +389,7 @@ UncachedAllocateRuntimeCopyPool ( allocated buffer. If AllocationSize is 0, then a valid buffer of 0 size is returned. If there
is not enough memory remaining to satisfy the request, then NULL is returned.
If Buffer is NULL, then ASSERT().
- If AllocationSize is greater than (MAX_ADDRESS ? Buffer + 1), then ASSERT().
+ If AllocationSize is greater than (MAX_ADDRESS ? Buffer + 1), then ASSERT().
@param AllocationSize The number of bytes to allocate and zero.
@param Buffer The buffer to copy to the allocated buffer.
@@ -639,7 +639,7 @@ UncachedAllocateAlignedReservedCopyPool ( );
/**
- Frees a buffer that was previously allocated with one of the aligned pool allocation functions
+ Frees a buffer that was previously allocated with one of the aligned pool allocation functions
in the Memory Allocation Library.
Frees the buffer specified by Buffer. Buffer must have been allocated on a previous call to the
diff --git a/ArmPkg/Include/Protocol/VirtualUncachedPages.h b/ArmPkg/Include/Protocol/VirtualUncachedPages.h index cf987b0438..0822184b89 100644 --- a/ArmPkg/Include/Protocol/VirtualUncachedPages.h +++ b/ArmPkg/Include/Protocol/VirtualUncachedPages.h @@ -37,7 +37,7 @@ EFI_STATUS IN EFI_PHYSICAL_ADDRESS VirtualMask,
OUT UINT64 *Attributes OPTIONAL
);
-
+
typedef
EFI_STATUS
(EFIAPI *FREE_CONVERTED_PAGES) (
@@ -57,4 +57,4 @@ struct _VIRTUAL_UNCACHED_PAGES_PROTOCOL { extern EFI_GUID gVirtualUncachedPagesProtocolGuid;
-#endif
+#endif
diff --git a/ArmPkg/Library/ArmArchTimerLib/ArmArchTimerLib.inf b/ArmPkg/Library/ArmArchTimerLib/ArmArchTimerLib.inf index 9c13e81307..fa5ca0cc7a 100644 --- a/ArmPkg/Library/ArmArchTimerLib/ArmArchTimerLib.inf +++ b/ArmPkg/Library/ArmArchTimerLib/ArmArchTimerLib.inf @@ -1,14 +1,14 @@ #/** @file
-#
+#
# Copyright (c) 2011-2012, ARM Limited. All rights reserved.<BR>
# This program and the accompanying materials
# are licensed and made available under the terms and conditions of the BSD License
# which accompanies this distribution. The full text of the license may be found at
# http://opensource.org/licenses/bsd-license.php
-#
+#
# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
-#
+#
#**/
[Defines]
@@ -17,7 +17,7 @@ FILE_GUID = 82da1b44-d2d6-4a7d-bbf0-a0cb67964034
MODULE_TYPE = BASE
VERSION_STRING = 1.0
- LIBRARY_CLASS = TimerLib
+ LIBRARY_CLASS = TimerLib
CONSTRUCTOR = TimerConstructor
[Sources.common]
@@ -27,18 +27,18 @@ MdePkg/MdePkg.dec
EmbeddedPkg/EmbeddedPkg.dec
ArmPkg/ArmPkg.dec
-
+
[LibraryClasses]
DebugLib
IoLib
ArmLib
- BaseLib
-
+ BaseLib
+
[Protocols]
-
+
[Guids]
-
+
[Pcd]
gArmTokenSpaceGuid.PcdArmArchTimerFreqInHz
diff --git a/ArmPkg/Library/ArmCacheMaintenanceLib/ArmCacheMaintenanceLib.c b/ArmPkg/Library/ArmCacheMaintenanceLib/ArmCacheMaintenanceLib.c index f4c12e7173..8501e5c613 100644 --- a/ArmPkg/Library/ArmCacheMaintenanceLib/ArmCacheMaintenanceLib.c +++ b/ArmPkg/Library/ArmCacheMaintenanceLib/ArmCacheMaintenanceLib.c @@ -2,7 +2,7 @@ Copyright (c) 2008 - 2009, Apple Inc. All rights reserved.<BR>
Copyright (c) 2011 - 2014, ARM Limited. All rights reserved.
-
+
This program and the accompanying materials
are licensed and made available under the terms and conditions of the BSD License
which accompanies this distribution. The full text of the license may be found at
@@ -27,7 +27,7 @@ CacheRangeOperation ( UINTN ArmCacheLineLength = ArmDataCacheLineLength();
UINTN ArmCacheLineAlignmentMask = ArmCacheLineLength - 1;
UINTN ArmCacheOperationThreshold = PcdGet32(PcdArmCacheOperationThreshold);
-
+
if ((CacheOperation != NULL) && (Length >= ArmCacheOperationThreshold)) {
ArmDrainWriteBuffer ();
CacheOperation ();
diff --git a/ArmPkg/Library/ArmDisassemblerLib/ArmDisassembler.c b/ArmPkg/Library/ArmDisassemblerLib/ArmDisassembler.c index 78f0d137ea..29a8d44386 100644 --- a/ArmPkg/Library/ArmDisassemblerLib/ArmDisassembler.c +++ b/ArmPkg/Library/ArmDisassemblerLib/ArmDisassembler.c @@ -2,7 +2,7 @@ Default exception handler
Copyright (c) 2008 - 2010, Apple Inc. All rights reserved.<BR>
-
+
This program and the accompanying materials
are licensed and made available under the terms and conditions of the BSD License
which accompanies this distribution. The full text of the license may be found at
@@ -90,7 +90,7 @@ MRegList ( UINTN Index, Start, End;
CHAR8 *Str;
BOOLEAN First;
-
+
Str = mMregListStr;
*Str = '\0';
AsciiStrCat (Str, "{");
@@ -100,13 +100,13 @@ MRegList ( for (Index++; ((OpCode & (1 << Index)) != 0) && Index <= 15; Index++) {
End = Index;
}
-
+
if (!First) {
AsciiStrCat (Str, ",");
} else {
First = FALSE;
}
-
+
if (Start == End) {
AsciiStrCat (Str, gReg[Start]);
AsciiStrCat (Str, ", ");
@@ -121,7 +121,7 @@ MRegList ( AsciiStrCat (Str, "ERROR");
}
AsciiStrCat (Str, "}");
-
+
// BugBug: Make caller pass in buffer it is cleaner
return mMregListStr;
}
@@ -145,17 +145,17 @@ RotateRight ( /**
- Place a dissasembly of of **OpCodePtr into buffer, and update OpCodePtr to
- point to next instructin.
-
- We cheat and only decode instructions that access
+ Place a dissasembly of of **OpCodePtr into buffer, and update OpCodePtr to
+ point to next instructin.
+
+ We cheat and only decode instructions that access
memory. If the instruction is not found we dump the instruction in hex.
-
- @param OpCodePtr Pointer to pointer of ARM instruction to disassemble.
+
+ @param OpCodePtr Pointer to pointer of ARM instruction to disassemble.
@param Buf Buffer to sprintf disassembly into.
- @param Size Size of Buf in bytes.
+ @param Size Size of Buf in bytes.
@param Extended TRUE dump hex for instruction too.
-
+
**/
VOID
DisassembleArmInstruction (
@@ -177,7 +177,7 @@ DisassembleArmInstruction ( P = (OpCode & BIT24) == BIT24;
U = (OpCode & BIT23) == BIT23;
B = (OpCode & BIT22) == BIT22; // Also called S
- W = (OpCode & BIT21) == BIT21;
+ W = (OpCode & BIT21) == BIT21;
L = (OpCode & BIT20) == BIT20;
S = (OpCode & BIT6) == BIT6;
H = (OpCode & BIT5) == BIT5;
@@ -195,27 +195,27 @@ DisassembleArmInstruction ( // LDREX, STREX
if ((OpCode & 0x0fe000f0) == 0x01800090) {
if (L) {
- // A4.1.27 LDREX{<cond>} <Rd>, [<Rn>]
- AsciiSPrint (Buf, Size, "LDREX%a %a, [%a]", COND (OpCode), gReg[Rd], gReg[Rn]);
+ // A4.1.27 LDREX{<cond>} <Rd>, [<Rn>]
+ AsciiSPrint (Buf, Size, "LDREX%a %a, [%a]", COND (OpCode), gReg[Rd], gReg[Rn]);
} else {
// A4.1.103 STREX{<cond>} <Rd>, <Rm>, [<Rn>]
- AsciiSPrint (Buf, Size, "STREX%a %a, %a, [%a]", COND (OpCode), gReg[Rd], gReg[Rn], gReg[Rn]);
- }
+ AsciiSPrint (Buf, Size, "STREX%a %a, %a, [%a]", COND (OpCode), gReg[Rd], gReg[Rn], gReg[Rn]);
+ }
return;
}
-
+
// LDM/STM
if ((OpCode & 0x0e000000) == 0x08000000) {
if (L) {
// A4.1.20 LDM{<cond>}<addressing_mode> <Rn>{!}, <registers>
// A4.1.21 LDM{<cond>}<addressing_mode> <Rn>, <registers_without_pc>^
// A4.1.22 LDM{<cond>}<addressing_mode> <Rn>{!}, <registers_and_pc>^
- AsciiSPrint (Buf, Size, "LDM%a%a, %a%a, %a", COND (OpCode), LDM_EXT (Rn ,(OpCode >> 23) & 3), gReg[Rn], WRITE (W), MRegList (OpCode), USER (B));
+ AsciiSPrint (Buf, Size, "LDM%a%a, %a%a, %a", COND (OpCode), LDM_EXT (Rn ,(OpCode >> 23) & 3), gReg[Rn], WRITE (W), MRegList (OpCode), USER (B));
} else {
// A4.1.97 STM{<cond>}<addressing_mode> <Rn>{!}, <registers>
// A4.1.98 STM{<cond>}<addressing_mode> <Rn>, <registers>^
- AsciiSPrint (Buf, Size, "STM%a%a, %a%a, %a", COND (OpCode), LDM_EXT (Rn ,(OpCode >> 23) & 3), gReg[Rn], WRITE (W), MRegList (OpCode), USER (B));
- }
+ AsciiSPrint (Buf, Size, "STM%a%a, %a%a, %a", COND (OpCode), LDM_EXT (Rn ,(OpCode >> 23) & 3), gReg[Rn], WRITE (W), MRegList (OpCode), USER (B));
+ }
return;
}
@@ -225,7 +225,7 @@ DisassembleArmInstruction ( if ((OpCode & 0xfd70f000 ) == 0xf550f000) {
Index = AsciiSPrint (Buf, Size, "PLD");
} else {
- Index = AsciiSPrint (Buf, Size, "%a%a%a%a %a, ", L ? "LDR" : "STR", COND (OpCode), BYTE (B), (!(P) && W) ? "T":"", gReg[Rd]);
+ Index = AsciiSPrint (Buf, Size, "%a%a%a%a %a, ", L ? "LDR" : "STR", COND (OpCode), BYTE (B), (!(P) && W) ? "T":"", gReg[Rd]);
}
if (P) {
if (!I) {
@@ -256,7 +256,7 @@ DisassembleArmInstruction ( } else {
Type = "ROR";
}
-
+
AsciiSPrint (&Buf[Index], Size - Index, "[%a, #%a%a, %a, #%d]%a", gReg[Rn], SIGN (U), gReg[Rm], Type, shift_imm, WRITE (W));
}
} else { // !P
@@ -287,13 +287,13 @@ DisassembleArmInstruction ( } else {
Type = "ROR";
}
-
+
AsciiSPrint (&Buf[Index], Size - Index, "[%a], #%a%a, %a, #%d", gReg[Rn], SIGN (U), gReg[Rm], Type, shift_imm);
}
}
- return;
+ return;
}
-
+
if ((OpCode & 0x0e000000) == 0x00000000) {
// LDR/STR address mode 3
// LDR|STR{<cond>}H|SH|SB|D <Rd>, <addressing_mode>
@@ -314,8 +314,8 @@ DisassembleArmInstruction ( Root = "STR%aD %a ";
}
}
-
- Index = AsciiSPrint (Buf, Size, Root, COND (OpCode), gReg[Rd]);
+
+ Index = AsciiSPrint (Buf, Size, Root, COND (OpCode), gReg[Rd]);
S = (OpCode & BIT6) == BIT6;
H = (OpCode & BIT5) == BIT5;
@@ -350,7 +350,7 @@ DisassembleArmInstruction ( AsciiSPrint (Buf, Size, "SWP%a%a %a, %a, [%a]", COND (OpCode), BYTE (B), gReg[Rd], gReg[Rm], gReg[Rn]);
return;
}
-
+
if ((OpCode & 0xfe5f0f00) == 0xf84d0500) {
// A4.1.90 SRS SRS<addressing_mode> #<mode>{!}
AsciiSPrint (Buf, Size, "SRS%a #0x%x%a", gLdmStack[(OpCode >> 23) & 3], OpCode & 0x1f, WRITE (W));
@@ -362,13 +362,13 @@ DisassembleArmInstruction ( AsciiSPrint (Buf, Size, "RFE%a %a", gLdmStack[(OpCode >> 23) & 3], gReg[Rn], WRITE (W));
return;
}
-
+
if ((OpCode & 0xfff000f0) == 0xe1200070) {
// A4.1.7 BKPT <immed_16>
AsciiSPrint (Buf, Size, "BKPT %x", ((OpCode >> 8) | (OpCode & 0xf)) & 0xffff);
return;
- }
-
+ }
+
if ((OpCode & 0xfff10020) == 0xf1000000) {
// A4.1.16 CPS<effect> <iflags> {, #<mode>}
if (((OpCode >> 6) & 0x7) == 0) {
@@ -381,19 +381,19 @@ DisassembleArmInstruction ( }
}
return;
- }
-
+ }
+
if ((OpCode & 0x0f000000) == 0x0f000000) {
// A4.1.107 SWI{<cond>} <immed_24>
AsciiSPrint (Buf, Size, "SWI%a %x", COND (OpCode), OpCode & 0x00ffffff);
return;
- }
+ }
if ((OpCode & 0x0fb00000) == 0x01000000) {
// A4.1.38 MRS{<cond>} <Rd>, CPSR MRS{<cond>} <Rd>, SPSR
AsciiSPrint (Buf, Size, "MRS%a %a, %a", COND (OpCode), gReg[Rd], B ? "SPSR" : "CPSR");
return;
- }
+ }
if ((OpCode & 0x0db00000) == 0x03200000) {
@@ -406,14 +406,14 @@ DisassembleArmInstruction ( AsciiSPrint (Buf, Size, "MRS%a %a_%a, %a", COND (OpCode), B ? "SPSR" : "CPSR", gReg[Rd]);
}
return;
- }
+ }
if ((OpCode & 0xff000010) == 0xfe000000) {
// A4.1.13 CDP{<cond>} <coproc>, <opcode_1>, <CRd>, <CRn>, <CRm>, <opcode_2>
AsciiSPrint (Buf, Size, "CDP%a 0x%x, 0x%x, CR%d, CR%d, CR%d, 0x%x", COND (OpCode), (OpCode >> 8) & 0xf, (OpCode >> 20) & 0xf, Rn, Rd, Rm, (OpCode >> 5) &0x7);
return;
}
-
+
if ((OpCode & 0x0e000000) == 0x0c000000) {
// A4.1.19 LDC and A4.1.96 SDC
if ((OpCode & 0xf0000000) == 0xf0000000) {
@@ -421,36 +421,36 @@ DisassembleArmInstruction ( } else {
Index = AsciiSPrint (Buf, Size, "%a%a 0x%x, CR%d, ", L ? "LDC":"SDC", COND (OpCode), (OpCode >> 8) & 0xf, Rd);
}
-
+
if (!P) {
- if (!W) {
+ if (!W) {
// A5.5.5.5 [<Rn>], <option>
- AsciiSPrint (&Buf[Index], Size - Index, "[%a], {0x%x}", gReg[Rn], OpCode & 0xff);
+ AsciiSPrint (&Buf[Index], Size - Index, "[%a], {0x%x}", gReg[Rn], OpCode & 0xff);
} else {
// A.5.5.4 [<Rn>], #+/-<offset_8>*4
- AsciiSPrint (&Buf[Index], Size - Index, "[%a], #%a0x%x*4", gReg[Rn], SIGN (U), OpCode & 0xff);
+ AsciiSPrint (&Buf[Index], Size - Index, "[%a], #%a0x%x*4", gReg[Rn], SIGN (U), OpCode & 0xff);
}
} else {
// A5.5.5.2 [<Rn>, #+/-<offset_8>*4 ]!
- AsciiSPrint (&Buf[Index], Size - Index, "[%a, #%a0x%x*4]%a", gReg[Rn], SIGN (U), OpCode & 0xff, WRITE (W));
+ AsciiSPrint (&Buf[Index], Size - Index, "[%a, #%a0x%x*4]%a", gReg[Rn], SIGN (U), OpCode & 0xff, WRITE (W));
}
-
+
}
-
+
if ((OpCode & 0x0f000010) == 0x0e000010) {
- // A4.1.32 MRC2, MCR2
+ // A4.1.32 MRC2, MCR2
AsciiSPrint (Buf, Size, "%a%a 0x%x, 0x%x, %a, CR%d, CR%d, 0x%x", L ? "MRC":"MCR", COND (OpCode), (OpCode >> 8) & 0xf, (OpCode >> 20) & 0xf, gReg[Rd], Rn, Rm, (OpCode >> 5) &0x7);
- return;
+ return;
}
if ((OpCode & 0x0ff00000) == 0x0c400000) {
- // A4.1.33 MRRC2, MCRR2
+ // A4.1.33 MRRC2, MCRR2
AsciiSPrint (Buf, Size, "%a%a 0x%x, 0x%x, %a, %a, CR%d", L ? "MRRC":"MCRR", COND (OpCode), (OpCode >> 4) & 0xf, (OpCode >> 20) & 0xf, gReg[Rd], gReg[Rn], Rm);
- return;
+ return;
}
AsciiSPrint (Buf, Size, "Faulting OpCode 0x%08x", OpCode);
-
+
*OpCodePtr += 1;
return;
}
diff --git a/ArmPkg/Library/ArmDisassemblerLib/ThumbDisassembler.c b/ArmPkg/Library/ArmDisassemblerLib/ThumbDisassembler.c index fbe8949d7d..108cda9442 100644 --- a/ArmPkg/Library/ArmDisassemblerLib/ThumbDisassembler.c +++ b/ArmPkg/Library/ArmDisassemblerLib/ThumbDisassembler.c @@ -1,15 +1,15 @@ /** @file
Thumb Dissassembler. Still a work in progress.
- Wrong output is a bug, so please fix it.
+ Wrong output is a bug, so please fix it.
Hex output means there is not yet an entry or a decode bug.
- gOpThumb[] are Thumb 16-bit, and gOpThumb2[] work on the 32-bit
- 16-bit stream of Thumb2 instruction. Then there are big case
+ gOpThumb[] are Thumb 16-bit, and gOpThumb2[] work on the 32-bit
+ 16-bit stream of Thumb2 instruction. Then there are big case
statements to print everything out. If you are adding instructions
try to reuse existing case entries if possible.
Copyright (c) 2008 - 2010, Apple Inc. All rights reserved.<BR>
-
+
This program and the accompanying materials
are licensed and made available under the terms and conditions of the BSD License
which accompanies this distribution. The full text of the license may be found at
@@ -32,13 +32,13 @@ extern CHAR8 *gReg[]; // Thumb address modes
#define LOAD_STORE_FORMAT1 1
#define LOAD_STORE_FORMAT1_H 101
-#define LOAD_STORE_FORMAT1_B 111
+#define LOAD_STORE_FORMAT1_B 111
#define LOAD_STORE_FORMAT2 2
#define LOAD_STORE_FORMAT3 3
#define LOAD_STORE_FORMAT4 4
-#define LOAD_STORE_MULTIPLE_FORMAT1 5
-#define PUSH_FORMAT 6
-#define POP_FORMAT 106
+#define LOAD_STORE_MULTIPLE_FORMAT1 5
+#define PUSH_FORMAT 6
+#define POP_FORMAT 106
#define IMMED_8 7
#define CONDITIONAL_BRANCH 8
#define UNCONDITIONAL_BRANCH 9
@@ -93,8 +93,8 @@ extern CHAR8 *gReg[]; #define THUMB2_4REGS 230
#define ADD_IMM12_1REG 231
#define THUMB2_IMM16 232
-#define MRC_THUMB2 233
-#define MRRC_THUMB2 234
+#define MRC_THUMB2 233
+#define MRRC_THUMB2 234
#define THUMB2_MRS 235
#define THUMB2_MSR 236
@@ -118,7 +118,7 @@ THUMB_INSTRUCTIONS gOpThumb[] = { { "ADD" , 0x1800, 0xfe00, DATA_FORMAT1 },
{ "ADD" , 0x4400, 0xff00, DATA_FORMAT8 }, // A8.6.9
{ "ADD" , 0xa000, 0xf100, DATA_FORMAT6_PC },
- { "ADD" , 0xa800, 0xf800, DATA_FORMAT6_SP },
+ { "ADD" , 0xa800, 0xf800, DATA_FORMAT6_SP },
{ "ADD" , 0xb000, 0xff80, DATA_FORMAT7 },
{ "AND" , 0x4000, 0xffc0, DATA_FORMAT5 },
@@ -156,7 +156,7 @@ THUMB_INSTRUCTIONS gOpThumb[] = { { "LDRH" , 0x7a00, 0xfe00, LOAD_STORE_FORMAT2 },
{ "LDRSB" , 0x5600, 0xfe00, LOAD_STORE_FORMAT2 }, // STR <Rt>, [<Rn>, <Rm>]
{ "LDRSH" , 0x5e00, 0xfe00, LOAD_STORE_FORMAT2 },
-
+
{ "MOVS", 0x0000, 0xffc0, DATA_FORMAT5 }, // LSL with imm5 == 0 is a MOVS, so this must go before LSL
{ "LSL" , 0x0000, 0xf800, DATA_FORMAT4 },
{ "LSL" , 0x4080, 0xffc0, DATA_FORMAT5 },
@@ -212,8 +212,8 @@ THUMB_INSTRUCTIONS gOpThumb[] = { THUMB_INSTRUCTIONS gOpThumb2[] = {
//Instruct OpCode OpCode Mask Addressig Mode
-
- { "ADR", 0xf2af0000, 0xfbff8000, ADR_THUMB2 }, // ADDR <Rd>, <label> ;Needs to go before ADDW
+
+ { "ADR", 0xf2af0000, 0xfbff8000, ADR_THUMB2 }, // ADDR <Rd>, <label> ;Needs to go before ADDW
{ "CMN", 0xf1100f00, 0xfff08f00, CMN_THUMB2 }, // CMN <Rn>, #<const> ;Needs to go before ADD
{ "CMN", 0xeb100f00, 0xfff08f00, ADD_IMM5_2REG }, // CMN <Rn>, <Rm> {,<shift> #<const>}
{ "CMP", 0xf1a00f00, 0xfff08f00, CMN_THUMB2 }, // CMP <Rn>, #<const>
@@ -225,7 +225,7 @@ THUMB_INSTRUCTIONS gOpThumb2[] = { { "MOV", 0xf04f0000, 0xfbef8000, ADD_IMM12_1REG }, // MOV <Rd>, #<const>
{ "MOVW", 0xf2400000, 0xfbe08000, THUMB2_IMM16 }, // MOVW <Rd>, #<const>
{ "MOVT", 0xf2c00000, 0xfbe08000, THUMB2_IMM16 }, // MOVT <Rd>, #<const>
-
+
{ "ADC", 0xf1400000, 0xfbe08000, ADD_IMM12 }, // ADC{S} <Rd>, <Rn>, #<const>
{ "ADC", 0xeb400000, 0xffe08000, ADD_IMM5 }, // ADC{S} <Rd>, <Rn>, <Rm> {,<shift> #<const>}
{ "ADD", 0xf1000000, 0xfbe08000, ADD_IMM12 }, // ADD{S} <Rd>, <Rn>, #<const>
@@ -249,11 +249,11 @@ THUMB_INSTRUCTIONS gOpThumb2[] = { { "SUB", 0xeba00000, 0xffe08000, ADD_IMM5 }, // SUB{S} <Rd>, <Rn>, <Rm> {,<shift> #<const>}
{ "ASR", 0xea4f0020, 0xffef8030, ASR_IMM5 }, // ARS <Rd>, <Rm> #<const>} imm3:imm2
- { "ASR", 0xfa40f000, 0xffe0f0f0, ASR_3REG }, // ARS <Rd>, <Rn>, <Rm>
+ { "ASR", 0xfa40f000, 0xffe0f0f0, ASR_3REG }, // ARS <Rd>, <Rn>, <Rm>
{ "LSR", 0xea4f0010, 0xffef8030, ASR_IMM5 }, // LSR <Rd>, <Rm> #<const>} imm3:imm2
- { "LSR", 0xfa20f000, 0xffe0f0f0, ASR_3REG }, // LSR <Rd>, <Rn>, <Rm>
+ { "LSR", 0xfa20f000, 0xffe0f0f0, ASR_3REG }, // LSR <Rd>, <Rn>, <Rm>
{ "ROR", 0xea4f0030, 0xffef8030, ASR_IMM5 }, // ROR <Rd>, <Rm> #<const>} imm3:imm2
- { "ROR", 0xfa60f000, 0xffe0f0f0, ASR_3REG }, // ROR <Rd>, <Rn>, <Rm>
+ { "ROR", 0xfa60f000, 0xffe0f0f0, ASR_3REG }, // ROR <Rd>, <Rn>, <Rm>
{ "BFC", 0xf36f0000, 0xffff8010, BFC_THUMB2 }, // BFC <Rd>, #<lsb>, #<width>
{ "BIC", 0xf3600000, 0xfff08010, BFC_THUMB2 }, // BIC <Rn>, <Rd>, #<lsb>, #<width>
@@ -317,19 +317,19 @@ THUMB_INSTRUCTIONS gOpThumb2[] = { { "STMDB", 0xe9800000, 0xffd0a000, STM_FORMAT }, // STMDB <Rn>{!},<registers>
{ "LDM" , 0xe8900000, 0xffd02000, STM_FORMAT }, // LDM <Rn>{!},<registers>
{ "LDMDB", 0xe9100000, 0xffd02000, STM_FORMAT }, // LDMDB <Rn>{!},<registers>
-
+
{ "LDR", 0xf8d00000, 0xfff00000, LDM_REG_IMM12 }, // LDR <rt>, [<rn>, {, #<imm12>]}
{ "LDRB", 0xf8900000, 0xfff00000, LDM_REG_IMM12 }, // LDRB <rt>, [<rn>, {, #<imm12>]}
{ "LDRH", 0xf8b00000, 0xfff00000, LDM_REG_IMM12 }, // LDRH <rt>, [<rn>, {, #<imm12>]}
{ "LDRSB", 0xf9900000, 0xfff00000, LDM_REG_IMM12 }, // LDRSB <rt>, [<rn>, {, #<imm12>]}
{ "LDRSH", 0xf9b00000, 0xfff00000, LDM_REG_IMM12 }, // LDRSH <rt>, [<rn>, {, #<imm12>]}
- { "LDR", 0xf85f0000, 0xff7f0000, LDM_REG_IMM12_SIGNED }, // LDR <Rt>, <label>
- { "LDRB", 0xf81f0000, 0xff7f0000, LDM_REG_IMM12_SIGNED }, // LDRB <Rt>, <label>
- { "LDRH", 0xf83f0000, 0xff7f0000, LDM_REG_IMM12_SIGNED }, // LDRH <Rt>, <label>
- { "LDRSB", 0xf91f0000, 0xff7f0000, LDM_REG_IMM12_SIGNED }, // LDRSB <Rt>, <label>
- { "LDRSH", 0xf93f0000, 0xff7f0000, LDM_REG_IMM12_SIGNED }, // LDRSB <Rt>, <label>
-
+ { "LDR", 0xf85f0000, 0xff7f0000, LDM_REG_IMM12_SIGNED }, // LDR <Rt>, <label>
+ { "LDRB", 0xf81f0000, 0xff7f0000, LDM_REG_IMM12_SIGNED }, // LDRB <Rt>, <label>
+ { "LDRH", 0xf83f0000, 0xff7f0000, LDM_REG_IMM12_SIGNED }, // LDRH <Rt>, <label>
+ { "LDRSB", 0xf91f0000, 0xff7f0000, LDM_REG_IMM12_SIGNED }, // LDRSB <Rt>, <label>
+ { "LDRSH", 0xf93f0000, 0xff7f0000, LDM_REG_IMM12_SIGNED }, // LDRSB <Rt>, <label>
+
{ "LDR", 0xf8500000, 0xfff00fc0, LDM_REG_INDIRECT_LSL }, // LDR <rt>, [<rn>, <rm> {, LSL #<imm2>]}
{ "LDRB", 0xf8100000, 0xfff00fc0, LDM_REG_INDIRECT_LSL }, // LDRB <rt>, [<rn>, <rm> {, LSL #<imm2>]}
{ "LDRH", 0xf8300000, 0xfff00fc0, LDM_REG_INDIRECT_LSL }, // LDRH <rt>, [<rn>, <rm> {, LSL #<imm2>]}
@@ -339,25 +339,25 @@ THUMB_INSTRUCTIONS gOpThumb2[] = { { "LDR", 0xf8500800, 0xfff00800, LDM_REG_IMM8 }, // LDR <rt>, [<rn>, {, #<imm8>]}
{ "LDRBT", 0xf8100e00, 0xfff00f00, LDM_REG_IMM8 }, // LDRBT <rt>, [<rn>, {, #<imm8>]}
{ "LDRHT", 0xf8300e00, 0xfff00f00, LDM_REG_IMM8 }, // LDRHT <rt>, [<rn>, {, #<imm8>]}
- { "LDRSB", 0xf9100800, 0xfff00800, LDM_REG_IMM8 }, // LDRHT <rt>, [<rn>, {, #<imm8>]} {!} form?
- { "LDRSBT",0xf9100e00, 0xfff00f00, LDM_REG_IMM8 }, // LDRHBT <rt>, [<rn>, {, #<imm8>]} {!} form?
- { "LDRSH" ,0xf9300800, 0xfff00800, LDM_REG_IMM8 }, // LDRSH <rt>, [<rn>, {, #<imm8>]}
- { "LDRSHT",0xf9300e00, 0xfff00f00, LDM_REG_IMM8 }, // LDRSHT <rt>, [<rn>, {, #<imm8>]}
- { "LDRT", 0xf8500e00, 0xfff00f00, LDM_REG_IMM8 }, // LDRT <rt>, [<rn>, {, #<imm8>]}
+ { "LDRSB", 0xf9100800, 0xfff00800, LDM_REG_IMM8 }, // LDRHT <rt>, [<rn>, {, #<imm8>]} {!} form?
+ { "LDRSBT",0xf9100e00, 0xfff00f00, LDM_REG_IMM8 }, // LDRHBT <rt>, [<rn>, {, #<imm8>]} {!} form?
+ { "LDRSH" ,0xf9300800, 0xfff00800, LDM_REG_IMM8 }, // LDRSH <rt>, [<rn>, {, #<imm8>]}
+ { "LDRSHT",0xf9300e00, 0xfff00f00, LDM_REG_IMM8 }, // LDRSHT <rt>, [<rn>, {, #<imm8>]}
+ { "LDRT", 0xf8500e00, 0xfff00f00, LDM_REG_IMM8 }, // LDRT <rt>, [<rn>, {, #<imm8>]}
{ "LDRD", 0xe8500000, 0xfe500000, LDRD_REG_IMM8_SIGNED }, // LDRD <rt>, <rt2>, [<rn>, {, #<imm8>]}{!}
{ "LDRD", 0xe8500000, 0xfe500000, LDRD_REG_IMM8 }, // LDRD <rt>, <rt2>, <label>
-
- { "LDREX", 0xe8500f00, 0xfff00f00, LDM_REG_IMM8 }, // LDREX <Rt>, [Rn, {#imm8}]]
- { "LDREXB", 0xe8d00f4f, 0xfff00fff, LDREXB }, // LDREXB <Rt>, [<Rn>]
- { "LDREXH", 0xe8d00f5f, 0xfff00fff, LDREXB }, // LDREXH <Rt>, [<Rn>]
-
- { "LDREXD", 0xe8d00f4f, 0xfff00fff, LDREXD }, // LDREXD <Rt>, <Rt2>, [<Rn>]
-
- { "STR", 0xf8c00000, 0xfff00000, LDM_REG_IMM12 }, // STR <rt>, [<rn>, {, #<imm12>]}
+
+ { "LDREX", 0xe8500f00, 0xfff00f00, LDM_REG_IMM8 }, // LDREX <Rt>, [Rn, {#imm8}]]
+ { "LDREXB", 0xe8d00f4f, 0xfff00fff, LDREXB }, // LDREXB <Rt>, [<Rn>]
+ { "LDREXH", 0xe8d00f5f, 0xfff00fff, LDREXB }, // LDREXH <Rt>, [<Rn>]
+
+ { "LDREXD", 0xe8d00f4f, 0xfff00fff, LDREXD }, // LDREXD <Rt>, <Rt2>, [<Rn>]
+
+ { "STR", 0xf8c00000, 0xfff00000, LDM_REG_IMM12 }, // STR <rt>, [<rn>, {, #<imm12>]}
{ "STRB", 0xf8800000, 0xfff00000, LDM_REG_IMM12 }, // STRB <rt>, [<rn>, {, #<imm12>]}
{ "STRH", 0xf8a00000, 0xfff00000, LDM_REG_IMM12 }, // STRH <rt>, [<rn>, {, #<imm12>]}
-
+
{ "STR", 0xf8400000, 0xfff00fc0, LDM_REG_INDIRECT_LSL }, // STR <rt>, [<rn>, <rm> {, LSL #<imm2>]}
{ "STRB", 0xf8000000, 0xfff00fc0, LDM_REG_INDIRECT_LSL }, // STRB <rt>, [<rn>, <rm> {, LSL #<imm2>]}
{ "STRH", 0xf8200000, 0xfff00fc0, LDM_REG_INDIRECT_LSL }, // STRH <rt>, [<rn>, <rm> {, LSL #<imm2>]}
@@ -366,15 +366,15 @@ THUMB_INSTRUCTIONS gOpThumb2[] = { { "STRH", 0xf8200800, 0xfff00800, LDM_REG_IMM8 }, // STRH <rt>, [<rn>, {, #<imm8>]}
{ "STRBT", 0xf8000e00, 0xfff00f00, LDM_REG_IMM8 }, // STRBT <rt>, [<rn>, {, #<imm8>]}
{ "STRHT", 0xf8200e00, 0xfff00f00, LDM_REG_IMM8 }, // STRHT <rt>, [<rn>, {, #<imm8>]}
- { "STRT", 0xf8400e00, 0xfff00f00, LDM_REG_IMM8 }, // STRT <rt>, [<rn>, {, #<imm8>]}
+ { "STRT", 0xf8400e00, 0xfff00f00, LDM_REG_IMM8 }, // STRT <rt>, [<rn>, {, #<imm8>]}
{ "STRD", 0xe8400000, 0xfe500000, LDRD_REG_IMM8_SIGNED }, // STRD <rt>, <rt2>, [<rn>, {, #<imm8>]}{!}
- { "STREX", 0xe8400f00, 0xfff00f00, LDM_REG_IMM8 }, // STREX <Rt>, [Rn, {#imm8}]]
- { "STREXB", 0xe8c00f4f, 0xfff00fff, LDREXB }, // STREXB <Rd>, <Rt>, [<Rn>]
- { "STREXH", 0xe8c00f5f, 0xfff00fff, LDREXB }, // STREXH <Rd>, <Rt>, [<Rn>]
-
- { "STREXD", 0xe8d00f4f, 0xfff00fff, LDREXD }, // STREXD <Rd>, <Rt>, <Rt2>, [<Rn>]
+ { "STREX", 0xe8400f00, 0xfff00f00, LDM_REG_IMM8 }, // STREX <Rt>, [Rn, {#imm8}]]
+ { "STREXB", 0xe8c00f4f, 0xfff00fff, LDREXB }, // STREXB <Rd>, <Rt>, [<Rn>]
+ { "STREXH", 0xe8c00f5f, 0xfff00fff, LDREXB }, // STREXH <Rd>, <Rt>, [<Rn>]
+
+ { "STREXD", 0xe8d00f4f, 0xfff00fff, LDREXD }, // STREXD <Rd>, <Rt>, <Rt2>, [<Rn>]
{ "SRSDB", 0xe80dc000, 0xffdffff0, SRS_FORMAT }, // SRSDB<c> SP{!},#<mode>
{ "SRS" , 0xe98dc000, 0xffdffff0, SRS_FORMAT }, // SRS{IA}<c> SP{!},#<mode>
@@ -399,24 +399,24 @@ ThumbMRegList ( UINTN Index, Start, End;
CHAR8 *Str;
BOOLEAN First;
-
+
Str = mThumbMregListStr;
*Str = '\0';
AsciiStrCat (Str, "{");
-
+
for (Index = 0, First = TRUE; Index <= 15; Index++) {
if ((RegBitMask & (1 << Index)) != 0) {
Start = End = Index;
for (Index++; ((RegBitMask & (1 << Index)) != 0) && (Index <= 9); Index++) {
End = Index;
}
-
+
if (!First) {
AsciiStrCat (Str, ",");
} else {
First = FALSE;
}
-
+
if (Start == End) {
AsciiStrCat (Str, gReg[Start]);
} else {
@@ -430,7 +430,7 @@ ThumbMRegList ( AsciiStrCat (Str, "ERROR");
}
AsciiStrCat (Str, "}");
-
+
// BugBug: Make caller pass in buffer it is cleaner
return mThumbMregListStr;
}
@@ -444,17 +444,17 @@ SignExtend32 ( if (((Data & TopBit) == 0) || (TopBit == BIT31)) {
return Data;
}
-
+
do {
TopBit <<= 1;
- Data |= TopBit;
+ Data |= TopBit;
} while ((TopBit & BIT31) != BIT31);
return Data;
}
//
-// Some instructions specify the PC is always considered aligned
+// Some instructions specify the PC is always considered aligned
// The PC is after the instruction that is excuting. So you pass
// in the instruction address and you get back the aligned answer
//
@@ -467,17 +467,17 @@ PCAlign4 ( }
/**
- Place a dissasembly of of **OpCodePtr into buffer, and update OpCodePtr to
- point to next instructin.
-
- We cheat and only decode instructions that access
+ Place a dissasembly of of **OpCodePtr into buffer, and update OpCodePtr to
+ point to next instructin.
+
+ We cheat and only decode instructions that access
memory. If the instruction is not found we dump the instruction in hex.
-
- @param OpCodePtrPtr Pointer to pointer of ARM Thumb instruction to disassemble.
+
+ @param OpCodePtrPtr Pointer to pointer of ARM Thumb instruction to disassemble.
@param Buf Buffer to sprintf disassembly into.
- @param Size Size of Buf in bytes.
+ @param Size Size of Buf in bytes.
@param Extended TRUE dump hex for instruction too.
-
+
**/
VOID
DisassembleThumbInstruction (
@@ -499,12 +499,12 @@ DisassembleThumbInstruction ( UINT32 PC, Target, msbit, lsbit;
CHAR8 *Cond;
BOOLEAN S, J1, J2, P, U, W;
- UINT32 coproc, opc1, opc2, CRd, CRn, CRm;
+ UINT32 coproc, opc1, opc2, CRd, CRn, CRm;
UINT32 Mask;
OpCodePtr = *OpCodePtrPtr;
OpCode = **OpCodePtrPtr;
-
+
// Thumb2 is a stream of 16-bit instructions not a 32-bit instruction.
OpCode32 = (((UINT32)OpCode) << 16) | *(OpCodePtr + 1);
@@ -519,7 +519,7 @@ DisassembleThumbInstruction ( // Increment by the minimum instruction size, Thumb2 could be bigger
*OpCodePtrPtr += 1;
-
+
// Manage IT Block ItFlag TRUE means we are in an IT block
/*if (*ItBlock != 0) {
ItFlag = TRUE;
@@ -531,58 +531,58 @@ DisassembleThumbInstruction ( for (Index = 0; Index < sizeof (gOpThumb)/sizeof (THUMB_INSTRUCTIONS); Index++) {
if ((OpCode & gOpThumb[Index].Mask) == gOpThumb[Index].OpCode) {
if (Extended) {
- Offset = AsciiSPrint (Buf, Size, "0x%04x %-6a", OpCode, gOpThumb[Index].Start);
+ Offset = AsciiSPrint (Buf, Size, "0x%04x %-6a", OpCode, gOpThumb[Index].Start);
} else {
- Offset = AsciiSPrint (Buf, Size, "%-6a", gOpThumb[Index].Start);
+ Offset = AsciiSPrint (Buf, Size, "%-6a", gOpThumb[Index].Start);
}
switch (gOpThumb[Index].AddressMode) {
case LOAD_STORE_FORMAT1:
// A6.5.1 <Rd>, [<Rn>, #<5_bit_offset>]
- AsciiSPrint (&Buf[Offset], Size - Offset, " r%d, [r%d #0x%x]", Rd, Rn, (OpCode >> 4) & 0x7c);
+ AsciiSPrint (&Buf[Offset], Size - Offset, " r%d, [r%d #0x%x]", Rd, Rn, (OpCode >> 4) & 0x7c);
return;
case LOAD_STORE_FORMAT1_H:
// A6.5.1 <Rd>, [<Rn>, #<5_bit_offset>]
- AsciiSPrint (&Buf[Offset], Size - Offset, " r%d, [r%d #0x%x]", Rd, Rn, (OpCode >> 5) & 0x3e);
+ AsciiSPrint (&Buf[Offset], Size - Offset, " r%d, [r%d #0x%x]", Rd, Rn, (OpCode >> 5) & 0x3e);
return;
case LOAD_STORE_FORMAT1_B:
// A6.5.1 <Rd>, [<Rn>, #<5_bit_offset>]
- AsciiSPrint (&Buf[Offset], Size - Offset, " r%d, [r%d #0x%x]", Rd, Rn, (OpCode >> 6) & 0x1f);
+ AsciiSPrint (&Buf[Offset], Size - Offset, " r%d, [r%d #0x%x]", Rd, Rn, (OpCode >> 6) & 0x1f);
return;
case LOAD_STORE_FORMAT2:
// A6.5.1 <Rd>, [<Rn>, <Rm>]
- AsciiSPrint (&Buf[Offset], Size - Offset, " r%d, [r%d, r%d]", Rd, Rn, Rm);
+ AsciiSPrint (&Buf[Offset], Size - Offset, " r%d, [r%d, r%d]", Rd, Rn, Rm);
return;
case LOAD_STORE_FORMAT3:
// A6.5.1 <Rd>, [PC, #<8_bit_offset>]
Target = (OpCode & 0xff) << 2;
- AsciiSPrint (&Buf[Offset], Size - Offset, " r%d, [pc, #0x%x] ;0x%08x", (OpCode >> 8) & 7, Target, PCAlign4 (PC) + Target);
+ AsciiSPrint (&Buf[Offset], Size - Offset, " r%d, [pc, #0x%x] ;0x%08x", (OpCode >> 8) & 7, Target, PCAlign4 (PC) + Target);
return;
case LOAD_STORE_FORMAT4:
// Rt, [SP, #imm8]
Target = (OpCode & 0xff) << 2;
- AsciiSPrint (&Buf[Offset], Size - Offset, " r%d, [sp, #0x%x]", (OpCode >> 8) & 7, Target);
+ AsciiSPrint (&Buf[Offset], Size - Offset, " r%d, [sp, #0x%x]", (OpCode >> 8) & 7, Target);
return;
-
+
case LOAD_STORE_MULTIPLE_FORMAT1:
// <Rn>!, {r0-r7}
- AsciiSPrint (&Buf[Offset], Size - Offset, " r%d!, %a", (OpCode >> 8) & 7, ThumbMRegList (OpCode & 0xff));
+ AsciiSPrint (&Buf[Offset], Size - Offset, " r%d!, %a", (OpCode >> 8) & 7, ThumbMRegList (OpCode & 0xff));
return;
-
+
case POP_FORMAT:
// POP {r0-r7,pc}
- AsciiSPrint (&Buf[Offset], Size - Offset, " %a", ThumbMRegList ((OpCode & 0xff) | ((OpCode & BIT8) == BIT8 ? BIT15 : 0)));
+ AsciiSPrint (&Buf[Offset], Size - Offset, " %a", ThumbMRegList ((OpCode & 0xff) | ((OpCode & BIT8) == BIT8 ? BIT15 : 0)));
return;
case PUSH_FORMAT:
// PUSH {r0-r7,lr}
- AsciiSPrint (&Buf[Offset], Size - Offset, " %a", ThumbMRegList ((OpCode & 0xff) | ((OpCode & BIT8) == BIT8 ? BIT14 : 0)));
+ AsciiSPrint (&Buf[Offset], Size - Offset, " %a", ThumbMRegList ((OpCode & 0xff) | ((OpCode & BIT8) == BIT8 ? BIT14 : 0)));
return;
-
+
case IMMED_8:
// A6.7 <immed_8>
- AsciiSPrint (&Buf[Offset], Size - Offset, " 0x%x", OpCode & 0xff);
+ AsciiSPrint (&Buf[Offset], Size - Offset, " 0x%x", OpCode & 0xff);
return;
case CONDITIONAL_BRANCH:
@@ -591,83 +591,83 @@ DisassembleThumbInstruction ( Cond = gCondition[(OpCode >> 8) & 0xf];
Buf[Offset-5] = *Cond++;
Buf[Offset-4] = *Cond;
- AsciiSPrint (&Buf[Offset], Size - Offset, " 0x%04x", PC + 4 + SignExtend32 ((OpCode & 0xff) << 1, BIT8));
+ AsciiSPrint (&Buf[Offset], Size - Offset, " 0x%04x", PC + 4 + SignExtend32 ((OpCode & 0xff) << 1, BIT8));
return;
case UNCONDITIONAL_BRANCH_SHORT:
// A6.3.2 B <target_address>
- AsciiSPrint (&Buf[Offset], Size - Offset, " 0x%04x", PC + 4 + SignExtend32 ((OpCode & 0x3ff) << 1, BIT11));
+ AsciiSPrint (&Buf[Offset], Size - Offset, " 0x%04x", PC + 4 + SignExtend32 ((OpCode & 0x3ff) << 1, BIT11));
return;
-
+
case BRANCH_EXCHANGE:
// A6.3.3 BX|BLX <Rm>
- AsciiSPrint (&Buf[Offset], Size - Offset, " %a", gReg[Rn | (H2 ? 8:0)]);
+ AsciiSPrint (&Buf[Offset], Size - Offset, " %a", gReg[Rn | (H2 ? 8:0)]);
return;
case DATA_FORMAT1:
// A6.4.3 <Rd>, <Rn>, <Rm>
- AsciiSPrint (&Buf[Offset], Size - Offset, " r%d, r%d, r%d", Rd, Rn, Rm);
+ AsciiSPrint (&Buf[Offset], Size - Offset, " r%d, r%d, r%d", Rd, Rn, Rm);
return;
case DATA_FORMAT2:
// A6.4.3 <Rd>, <Rn>, #3_bit_immed
- AsciiSPrint (&Buf[Offset], Size - Offset, " r%d, r%d, 0x%x", Rd, Rn, Rm);
+ AsciiSPrint (&Buf[Offset], Size - Offset, " r%d, r%d, 0x%x", Rd, Rn, Rm);
return;
case DATA_FORMAT3:
// A6.4.3 <Rd>|<Rn>, #imm8
- AsciiSPrint (&Buf[Offset], Size - Offset, " r%d, #0x%x", (OpCode >> 8) & 7, OpCode & 0xff);
+ AsciiSPrint (&Buf[Offset], Size - Offset, " r%d, #0x%x", (OpCode >> 8) & 7, OpCode & 0xff);
return;
case DATA_FORMAT4:
// A6.4.3 <Rd>|<Rm>, #immed_5
- AsciiSPrint (&Buf[Offset], Size - Offset, " r%d, r%d, 0x%x", Rn, Rd, (OpCode >> 6) & 0x1f);
+ AsciiSPrint (&Buf[Offset], Size - Offset, " r%d, r%d, 0x%x", Rn, Rd, (OpCode >> 6) & 0x1f);
return;
case DATA_FORMAT5:
// A6.4.3 <Rd>|<Rm>, <Rm>|<Rs>
- AsciiSPrint (&Buf[Offset], Size - Offset, " r%d, r%d", Rd, Rn);
+ AsciiSPrint (&Buf[Offset], Size - Offset, " r%d, r%d", Rd, Rn);
return;
case DATA_FORMAT6_SP:
// A6.4.3 <Rd>, <reg>, #<8_Bit_immed>
- AsciiSPrint (&Buf[Offset], Size - Offset, " r%d, sp, 0x%x", (OpCode >> 8) & 7, (OpCode & 0xff) << 2);
+ AsciiSPrint (&Buf[Offset], Size - Offset, " r%d, sp, 0x%x", (OpCode >> 8) & 7, (OpCode & 0xff) << 2);
return;
case DATA_FORMAT6_PC:
// A6.4.3 <Rd>, <reg>, #<8_Bit_immed>
- AsciiSPrint (&Buf[Offset], Size - Offset, " r%d, pc, 0x%x", (OpCode >> 8) & 7, (OpCode & 0xff) << 2);
+ AsciiSPrint (&Buf[Offset], Size - Offset, " r%d, pc, 0x%x", (OpCode >> 8) & 7, (OpCode & 0xff) << 2);
return;
case DATA_FORMAT7:
// A6.4.3 SP, SP, #<7_Bit_immed>
- AsciiSPrint (&Buf[Offset], Size - Offset, " sp, sp, 0x%x", (OpCode & 0x7f)*4);
+ AsciiSPrint (&Buf[Offset], Size - Offset, " sp, sp, 0x%x", (OpCode & 0x7f)*4);
return;
case DATA_FORMAT8:
// A6.4.3 <Rd>|<Rn>, <Rm>
- AsciiSPrint (&Buf[Offset], Size - Offset, " %a, %a", gReg[Rd | (H1 ? 8:0)], gReg[Rn | (H2 ? 8:0)]);
+ AsciiSPrint (&Buf[Offset], Size - Offset, " %a, %a", gReg[Rd | (H1 ? 8:0)], gReg[Rn | (H2 ? 8:0)]);
return;
-
+
case CPS_FORMAT:
// A7.1.24
- AsciiSPrint (&Buf[Offset], Size - Offset, "%a %a%a%a", imod ? "ID":"IE", ((OpCode & BIT2) == 0) ? "":"a", ((OpCode & BIT1) == 0) ? "":"i", ((OpCode & BIT0) == 0) ? "":"f");
+ AsciiSPrint (&Buf[Offset], Size - Offset, "%a %a%a%a", imod ? "ID":"IE", ((OpCode & BIT2) == 0) ? "":"a", ((OpCode & BIT1) == 0) ? "":"i", ((OpCode & BIT0) == 0) ? "":"f");
return;
case ENDIAN_FORMAT:
// A7.1.24
- AsciiSPrint (&Buf[Offset], Size - Offset, " %a", (OpCode & BIT3) == 0 ? "LE":"BE");
+ AsciiSPrint (&Buf[Offset], Size - Offset, " %a", (OpCode & BIT3) == 0 ? "LE":"BE");
return;
case DATA_CBZ:
// CB{N}Z <Rn>, <Lable>
Target = ((OpCode >> 2) & 0x3e) | (((OpCode & BIT9) == BIT9) ? BIT6 : 0);
- AsciiSPrint (&Buf[Offset], Size - Offset, " %a, %08x", gReg[Rd], PC + 4 + Target);
+ AsciiSPrint (&Buf[Offset], Size - Offset, " %a, %08x", gReg[Rd], PC + 4 + Target);
return;
case ADR_FORMAT:
// ADR <Rd>, <Label>
Target = (OpCode & 0xff) << 2;
- AsciiSPrint (&Buf[Offset], Size - Offset, " %a, %08x", gReg[(OpCode >> 8) & 7], PCAlign4 (PC) + Target);
+ AsciiSPrint (&Buf[Offset], Size - Offset, " %a, %08x", gReg[(OpCode >> 8) & 7], PCAlign4 (PC) + Target);
return;
case IT_BLOCK:
// ITSTATE = cond:mask OpCode[7:4]:OpCode[3:0]
// ITSTATE[7:5] == cond[3:1]
- // ITSTATE[4] == 1st Instruction cond[0]
- // ITSTATE[3] == 2st Instruction cond[0]
- // ITSTATE[2] == 3st Instruction cond[0]
+ // ITSTATE[4] == 1st Instruction cond[0]
+ // ITSTATE[3] == 2st Instruction cond[0]
+ // ITSTATE[2] == 3st Instruction cond[0]
// ITSTATE[1] == 4st Instruction cond[0]
// ITSTATE[0] == 1 4 instruction IT block. 0 means 0,1,2 or 3 instructions
// 1st one in ITSTATE low bits defines the number of instructions
@@ -684,13 +684,13 @@ DisassembleThumbInstruction ( } else if ((OpCode & 0xf) == 0x8) {
*ItBlock = 1;
}
- AsciiSPrint (&Buf[Offset], Size - Offset, " %a", gCondition[(OpCode >> 4) & 0xf]);
+ AsciiSPrint (&Buf[Offset], Size - Offset, " %a", gCondition[(OpCode >> 4) & 0xf]);
return;
}
}
}
-
+
// Thumb2 are 32-bit instructions
*OpCodePtrPtr += 1;
Rt = (OpCode32 >> 12) & 0xf;
@@ -701,9 +701,9 @@ DisassembleThumbInstruction ( for (Index = 0; Index < sizeof (gOpThumb2)/sizeof (THUMB_INSTRUCTIONS); Index++) {
if ((OpCode32 & gOpThumb2[Index].Mask) == gOpThumb2[Index].OpCode) {
if (Extended) {
- Offset = AsciiSPrint (Buf, Size, "0x%04x %-6a", OpCode32, gOpThumb2[Index].Start);
+ Offset = AsciiSPrint (Buf, Size, "0x%04x %-6a", OpCode32, gOpThumb2[Index].Start);
} else {
- Offset = AsciiSPrint (Buf, Size, " %-6a", gOpThumb2[Index].Start);
+ Offset = AsciiSPrint (Buf, Size, " %-6a", gOpThumb2[Index].Start);
}
switch (gOpThumb2[Index].AddressMode) {
case B_T3:
@@ -716,7 +716,7 @@ DisassembleThumbInstruction ( Target |= ((OpCode32 & BIT13) == BIT13)? BIT18 : 0; // J1
Target |= ((OpCode32 & BIT26) == BIT26)? BIT20 : 0; // S
Target = SignExtend32 (Target, BIT20);
- AsciiSPrint (&Buf[Offset], Size - Offset, " 0x%08x", PC + 4 + Target);
+ AsciiSPrint (&Buf[Offset], Size - Offset, " 0x%08x", PC + 4 + Target);
return;
case B_T4:
// S:I1:I2:imm10:imm11:0
@@ -728,7 +728,7 @@ DisassembleThumbInstruction ( Target |= (!(J1 ^ S) ? BIT23 : 0); // I1
Target |= (S ? BIT24 : 0); // S
Target = SignExtend32 (Target, BIT24);
- AsciiSPrint (&Buf[Offset], Size - Offset, " 0x%08x", PC + 4 + Target);
+ AsciiSPrint (&Buf[Offset], Size - Offset, " 0x%08x", PC + 4 + Target);
return;
case BL_T2:
@@ -741,7 +741,7 @@ DisassembleThumbInstruction ( Target |= (!(J1 ^ S) ? BIT24 : 0); // I1
Target |= (S ? BIT25 : 0); // S
Target = SignExtend32 (Target, BIT25);
- AsciiSPrint (&Buf[Offset], Size - Offset, " 0x%08x", PCAlign4 (PC) + Target);
+ AsciiSPrint (&Buf[Offset], Size - Offset, " 0x%08x", PCAlign4 (PC) + Target);
return;
case POP_T2:
@@ -750,7 +750,7 @@ DisassembleThumbInstruction ( return;
case POP_T3:
- // <register>
+ // <register>
AsciiSPrint (&Buf[Offset], Size - Offset, " %a", gReg[(OpCode32 >> 12) & 0xf]);
return;
@@ -762,7 +762,7 @@ DisassembleThumbInstruction ( case LDM_REG_IMM12_SIGNED:
// <rt>, <label>
- Target = OpCode32 & 0xfff;
+ Target = OpCode32 & 0xfff;
if ((OpCode32 & BIT23) == 0) {
// U == 0 means subtrack, U == 1 means add
Target = -Target;
@@ -779,7 +779,7 @@ DisassembleThumbInstruction ( AsciiSPrint (&Buf[Offset], Size - Offset, ", LSL #%d]", (OpCode32 >> 4) & 3);
}
return;
-
+
case LDM_REG_IMM12:
// <rt>, [<rn>, {, #<imm12>]}
Offset += AsciiSPrint (&Buf[Offset], Size - Offset, " %a, [%a", gReg[Rt], gReg[Rn]);
@@ -810,7 +810,7 @@ DisassembleThumbInstruction ( case LDRD_REG_IMM8_SIGNED:
// LDRD <rt>, <rt2>, [<rn>, {, #<imm8>]}{!}
P = (OpCode32 & BIT24) == BIT24; // index = P
- U = (OpCode32 & BIT23) == BIT23;
+ U = (OpCode32 & BIT23) == BIT23;
W = (OpCode32 & BIT21) == BIT21;
Offset += AsciiSPrint (&Buf[Offset], Size - Offset, " %a, %a, [%a", gReg[Rt], gReg[Rt2], gReg[Rn]);
if (P) {
@@ -826,9 +826,9 @@ DisassembleThumbInstruction ( }
return;
- case LDRD_REG_IMM8:
- // LDRD <rt>, <rt2>, <label>
- Target = (OpCode32 & 0xff) << 2;
+ case LDRD_REG_IMM8:
+ // LDRD <rt>, <rt2>, <label>
+ Target = (OpCode32 & 0xff) << 2;
if ((OpCode32 & BIT23) == 0) {
// U == 0 means subtrack, U == 1 means add
Target = -Target;
@@ -845,7 +845,7 @@ DisassembleThumbInstruction ( // LDREXD <Rt>, <Rt2>, [<Rn>]
AsciiSPrint (&Buf[Offset], Size - Offset, " %a, ,%a, [%a]", gReg[Rt], gReg[Rt2], gReg[Rn]);
return;
-
+
case SRS_FORMAT:
// SP{!}, #<mode>
W = (OpCode32 & BIT21) == BIT21;
@@ -857,14 +857,14 @@ DisassembleThumbInstruction ( W = (OpCode32 & BIT21) == BIT21;
AsciiSPrint (&Buf[Offset], Size - Offset, " %a%a, #0x%x", gReg[Rn], W?"!":"");
return;
-
+
case ADD_IMM12:
// ADD{S} <Rd>, <Rn>, #<const> i:imm3:imm8
if ((OpCode32 & BIT20) == BIT20) {
Buf[Offset - 3] = 'S'; // assume %-6a
}
Target = (OpCode32 & 0xff) | ((OpCode32 >> 4) & 0x700) | ((OpCode & BIT26) == BIT26 ? BIT11 : 0);
- AsciiSPrint (&Buf[Offset], Size - Offset, " %a, %a, #0x%x", gReg[Rd], gReg[Rn], Target);
+ AsciiSPrint (&Buf[Offset], Size - Offset, " %a, %a, #0x%x", gReg[Rd], gReg[Rn], Target);
return;
case ADD_IMM12_1REG:
@@ -873,14 +873,14 @@ DisassembleThumbInstruction ( Buf[Offset - 3] = 'S'; // assume %-6a
}
Target = (OpCode32 & 0xff) | ((OpCode32 >> 4) & 0x700) | ((OpCode & BIT26) == BIT26 ? BIT11 : 0);
- AsciiSPrint (&Buf[Offset], Size - Offset, " %a, #0x%x", gReg[Rd], Target);
+ AsciiSPrint (&Buf[Offset], Size - Offset, " %a, #0x%x", gReg[Rd], Target);
return;
case THUMB2_IMM16:
// MOVW <Rd>, #<const> i:imm3:imm8
Target = (OpCode32 & 0xff) | ((OpCode32 >> 4) & 0x700) | ((OpCode & BIT26) == BIT26 ? BIT11 : 0);
Target |= ((OpCode32 >> 4) & 0xf0000);
- AsciiSPrint (&Buf[Offset], Size - Offset, " %a, #0x%x", gReg[Rd], Target);
+ AsciiSPrint (&Buf[Offset], Size - Offset, " %a, #0x%x", gReg[Rd], Target);
return;
case ADD_IMM5:
@@ -889,18 +889,18 @@ DisassembleThumbInstruction ( Buf[Offset - 3] = 'S'; // assume %-6a
}
Target = ((OpCode32 >> 6) & 3) | ((OpCode32 >> 10) & 0x1c0);
- Offset += AsciiSPrint (&Buf[Offset], Size - Offset, " %a, %a, %a", gReg[Rd], gReg[Rn], gReg[Rm]);
+ Offset += AsciiSPrint (&Buf[Offset], Size - Offset, " %a, %a, %a", gReg[Rd], gReg[Rn], gReg[Rm]);
if (Target != 0) {
- AsciiSPrint (&Buf[Offset], Size - Offset, ", LSL %d", gShiftType[(OpCode >> 5) & 3], Target);
+ AsciiSPrint (&Buf[Offset], Size - Offset, ", LSL %d", gShiftType[(OpCode >> 5) & 3], Target);
}
return;
case ADD_IMM5_2REG:
// CMP <Rn>, <Rm> {,LSL #<const>} imm3:imm2
Target = ((OpCode32 >> 6) & 3) | ((OpCode32 >> 10) & 0x1c0);
- Offset += AsciiSPrint (&Buf[Offset], Size - Offset, " %a, %a", gReg[Rn], gReg[Rm]);
+ Offset += AsciiSPrint (&Buf[Offset], Size - Offset, " %a, %a", gReg[Rn], gReg[Rm]);
if (Target != 0) {
- AsciiSPrint (&Buf[Offset], Size - Offset, ", LSL %d", gShiftType[(OpCode >> 5) & 3], Target);
+ AsciiSPrint (&Buf[Offset], Size - Offset, ", LSL %d", gShiftType[(OpCode >> 5) & 3], Target);
}
@@ -910,7 +910,7 @@ DisassembleThumbInstruction ( Buf[Offset - 3] = 'S'; // assume %-6a
}
Target = ((OpCode32 >> 6) & 3) | ((OpCode32 >> 10) & 0x1c0);
- AsciiSPrint (&Buf[Offset], Size - Offset, " %a, %a #%d", gReg[Rd], gReg[Rm], Target);
+ AsciiSPrint (&Buf[Offset], Size - Offset, " %a, %a #%d", gReg[Rd], gReg[Rm], Target);
return;
case ASR_3REG:
@@ -918,7 +918,7 @@ DisassembleThumbInstruction ( if ((OpCode32 & BIT20) == BIT20) {
Buf[Offset - 3] = 'S'; // assume %-6a
}
- AsciiSPrint (&Buf[Offset], Size - Offset, " %a, %a %a", gReg[Rd], gReg[Rn], gReg[Rm]);
+ AsciiSPrint (&Buf[Offset], Size - Offset, " %a, %a %a", gReg[Rd], gReg[Rn], gReg[Rm]);
return;
case ADR_THUMB2:
@@ -929,13 +929,13 @@ DisassembleThumbInstruction ( } else {
Target = PCAlign4 (PC) + Target;
}
- AsciiSPrint (&Buf[Offset], Size - Offset, " %a, 0x%08x", gReg[Rd], Target);
+ AsciiSPrint (&Buf[Offset], Size - Offset, " %a, 0x%08x", gReg[Rd], Target);
return;
case CMN_THUMB2:
// CMN <Rn>, #<const>}
Target = (OpCode32 & 0xff) | ((OpCode >> 4) && 0x700) | ((OpCode & BIT26) == BIT26 ? BIT11 : 0);
- AsciiSPrint (&Buf[Offset], Size - Offset, " %a, #0x%x", gReg[Rn], Target);
+ AsciiSPrint (&Buf[Offset], Size - Offset, " %a, #0x%x", gReg[Rn], Target);
return;
case BFC_THUMB2:
@@ -944,11 +944,11 @@ DisassembleThumbInstruction ( lsbit = ((OpCode32 >> 6) & 3) | ((OpCode >> 10) & 0x1c);
if ((Rn == 0xf) & (AsciiStrCmp (gOpThumb2[Index].Start, "BFC") == 0)){
// BFC <Rd>, #<lsb>, #<width>
- AsciiSPrint (&Buf[Offset], Size - Offset, " %a, #%d, #%d", gReg[Rd], lsbit, msbit - lsbit + 1);
+ AsciiSPrint (&Buf[Offset], Size - Offset, " %a, #%d, #%d", gReg[Rd], lsbit, msbit - lsbit + 1);
} else if (AsciiStrCmp (gOpThumb2[Index].Start, "BFI") == 0) {
- AsciiSPrint (&Buf[Offset], Size - Offset, " %a, %a, #%d, #%d", gReg[Rd], gReg[Rn], lsbit, msbit - lsbit + 1);
+ AsciiSPrint (&Buf[Offset], Size - Offset, " %a, %a, #%d, #%d", gReg[Rd], gReg[Rn], lsbit, msbit - lsbit + 1);
} else {
- AsciiSPrint (&Buf[Offset], Size - Offset, " %a, %a, #%d, #%d", gReg[Rd], gReg[Rn], lsbit, msbit + 1);
+ AsciiSPrint (&Buf[Offset], Size - Offset, " %a, %a, #%d, #%d", gReg[Rd], gReg[Rn], lsbit, msbit + 1);
}
return;
@@ -977,7 +977,7 @@ DisassembleThumbInstruction ( if (opc2 != 0) {
AsciiSPrint (&Buf[Offset], Size - Offset, ",#%d,", opc2);
}
- return;
+ return;
case MRRC_THUMB2:
// MRC <coproc>,<opc1>,<Rt>,<Rt2>,<CRm>,<opc2>
@@ -986,7 +986,7 @@ DisassembleThumbInstruction ( CRn = (OpCode32 >> 16) & 0xf;
CRm = OpCode32 & 0xf;
Offset += AsciiSPrint (&Buf[Offset], Size - Offset, " p%d,#%d,%a,%a,c%d", coproc, opc1, gReg[Rt], gReg[Rt2], CRm);
- return;
+ return;
case THUMB2_2REGS:
// <Rd>, <Rm>
@@ -1002,7 +1002,7 @@ DisassembleThumbInstruction ( // MRS <Rd>, CPSR
AsciiSPrint (&Buf[Offset], Size - Offset, " %a, CPSR", gReg[Rd]);
return;
-
+
case THUMB2_MSR:
// MRS CPSR_<fields>, <Rd>
Target = (OpCode32 >> 10) & 3;
@@ -1031,19 +1031,19 @@ DisassembleArmInstruction ( /**
- Place a dissasembly of of **OpCodePtr into buffer, and update OpCodePtr to
- point to next instructin.
-
- We cheat and only decode instructions that access
+ Place a dissasembly of of **OpCodePtr into buffer, and update OpCodePtr to
+ point to next instructin.
+
+ We cheat and only decode instructions that access
memory. If the instruction is not found we dump the instruction in hex.
-
- @param OpCodePtrPtr Pointer to pointer of ARM Thumb instruction to disassemble.
+
+ @param OpCodePtrPtr Pointer to pointer of ARM Thumb instruction to disassemble.
@param Thumb TRUE for Thumb(2), FALSE for ARM instruction stream
@param Extended TRUE dump hex for instruction too.
@param ItBlock Size of IT Block
@param Buf Buffer to sprintf disassembly into.
- @param Size Size of Buf in bytes.
-
+ @param Size Size of Buf in bytes.
+
**/
VOID
DisassembleInstruction (
@@ -1061,4 +1061,4 @@ DisassembleInstruction ( DisassembleArmInstruction ((UINT32 **)OpCodePtr, Buf, Size, Extended);
}
}
-
+
diff --git a/ArmPkg/Library/ArmDmaLib/ArmDmaLib.c b/ArmPkg/Library/ArmDmaLib/ArmDmaLib.c index e803304295..12b194046a 100755 --- a/ArmPkg/Library/ArmDmaLib/ArmDmaLib.c +++ b/ArmPkg/Library/ArmDmaLib/ArmDmaLib.c @@ -2,7 +2,7 @@ Generic ARM implementation of DmaLib.h
Copyright (c) 2008 - 2010, Apple Inc. All rights reserved.<BR>
-
+
This program and the accompanying materials
are licensed and made available under the terms and conditions of the BSD License
which accompanies this distribution. The full text of the license may be found at
@@ -39,25 +39,25 @@ typedef struct { EFI_CPU_ARCH_PROTOCOL *gCpu;
UINTN gCacheAlignment = 0;
-/**
+/**
Provides the DMA controller-specific addresses needed to access system memory.
-
+
Operation is relative to the DMA bus master.
-
+
@param Operation Indicates if the bus master is going to read or write to system memory.
@param HostAddress The system memory address to map to the DMA controller.
@param NumberOfBytes On input the number of bytes to map. On output the number of bytes
- that were mapped.
+ that were mapped.
@param DeviceAddress The resulting map address for the bus master controller to use to
- access the hosts HostAddress.
+ access the hosts HostAddress.
@param Mapping A resulting value to pass to Unmap().
-
+
@retval EFI_SUCCESS The range was mapped for the returned NumberOfBytes.
- @retval EFI_UNSUPPORTED The HostAddress cannot be mapped as a common buffer.
+ @retval EFI_UNSUPPORTED The HostAddress cannot be mapped as a common buffer.
@retval EFI_INVALID_PARAMETER One or more parameters are invalid.
@retval EFI_OUT_OF_RESOURCES The request could not be completed due to a lack of resources.
@retval EFI_DEVICE_ERROR The system hardware could not map the requested address.
-
+
**/
EFI_STATUS
EFIAPI
@@ -89,7 +89,7 @@ DmaMap ( if (Map == NULL) {
return EFI_OUT_OF_RESOURCES;
}
-
+
*Mapping = Map;
if ((((UINTN)HostAddress & (gCacheAlignment - 1)) != 0) ||
@@ -145,15 +145,15 @@ DmaMap ( }
-/**
+/**
Completes the DmaMapBusMasterRead(), DmaMapBusMasterWrite(), or DmaMapBusMasterCommonBuffer()
operation and releases any corresponding resources.
-
+
@param Mapping The mapping value returned from DmaMap*().
-
+
@retval EFI_SUCCESS The range was unmapped.
@retval EFI_DEVICE_ERROR The data was not committed to the target system memory.
-
+
**/
EFI_STATUS
EFIAPI
@@ -162,21 +162,21 @@ DmaUnmap ( )
{
MAP_INFO_INSTANCE *Map;
-
+
if (Mapping == NULL) {
ASSERT (FALSE);
return EFI_INVALID_PARAMETER;
}
-
+
Map = (MAP_INFO_INSTANCE *)Mapping;
-
+
if (Map->DoubleBuffer) {
if ((Map->Operation == MapOperationBusMasterWrite) || (Map->Operation == MapOperationBusMasterCommonBuffer)) {
CopyMem ((VOID *)(UINTN)Map->HostAddress, (VOID *)(UINTN)Map->DeviceAddress, Map->NumberOfBytes);
}
-
+
DmaFreeBuffer (EFI_SIZE_TO_PAGES (Map->NumberOfBytes), (VOID *)(UINTN)Map->DeviceAddress);
-
+
} else {
if (Map->Operation == MapOperationBusMasterWrite) {
//
@@ -185,28 +185,28 @@ DmaUnmap ( gCpu->FlushDataCache (gCpu, Map->HostAddress, Map->NumberOfBytes, EfiCpuFlushTypeInvalidate);
}
}
-
+
FreePool (Map);
return EFI_SUCCESS;
}
-/**
+/**
Allocates pages that are suitable for an DmaMap() of type MapOperationBusMasterCommonBuffer.
- mapping.
-
+ mapping.
+
@param MemoryType The type of memory to allocate, EfiBootServicesData or
- EfiRuntimeServicesData.
- @param Pages The number of pages to allocate.
+ EfiRuntimeServicesData.
+ @param Pages The number of pages to allocate.
@param HostAddress A pointer to store the base system memory address of the
- allocated range.
+ allocated range.
@retval EFI_SUCCESS The requested memory pages were allocated.
@retval EFI_UNSUPPORTED Attributes is unsupported. The only legal attribute bits are
- MEMORY_WRITE_COMBINE and MEMORY_CACHED.
+ MEMORY_WRITE_COMBINE and MEMORY_CACHED.
@retval EFI_INVALID_PARAMETER One or more parameters are invalid.
- @retval EFI_OUT_OF_RESOURCES The memory pages could not be allocated.
-
+ @retval EFI_OUT_OF_RESOURCES The memory pages could not be allocated.
+
**/
EFI_STATUS
EFIAPI
@@ -237,16 +237,16 @@ DmaAllocateBuffer ( }
-/**
+/**
Frees memory that was allocated with DmaAllocateBuffer().
-
- @param Pages The number of pages to free.
- @param HostAddress The base system memory address of the allocated range.
-
+
+ @param Pages The number of pages to free.
+ @param HostAddress The base system memory address of the allocated range.
+
@retval EFI_SUCCESS The requested memory pages were freed.
@retval EFI_INVALID_PARAMETER The memory range specified by HostAddress and Pages
was not allocated with DmaAllocateBuffer().
-
+
**/
EFI_STATUS
EFIAPI
@@ -257,8 +257,8 @@ DmaFreeBuffer ( {
if (HostAddress == NULL) {
return EFI_INVALID_PARAMETER;
- }
-
+ }
+
UncachedFreePages (HostAddress, Pages);
return EFI_SUCCESS;
}
@@ -278,7 +278,7 @@ ArmDmaLibConstructor ( ASSERT_EFI_ERROR(Status);
gCacheAlignment = ArmDataCacheLineLength ();
-
+
return Status;
}
diff --git a/ArmPkg/Library/ArmDmaLib/ArmDmaLib.inf b/ArmPkg/Library/ArmDmaLib/ArmDmaLib.inf index 5465695115..20228d2864 100755 --- a/ArmPkg/Library/ArmDmaLib/ArmDmaLib.inf +++ b/ArmPkg/Library/ArmDmaLib/ArmDmaLib.inf @@ -1,14 +1,14 @@ #/** @file
-#
+#
# Copyright (c) 2008 - 2010, Apple Inc. All rights reserved.<BR>
# This program and the accompanying materials
# are licensed and made available under the terms and conditions of the BSD License
# which accompanies this distribution. The full text of the license may be found at
# http://opensource.org/licenses/bsd-license.php
-#
+#
# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
-#
+#
#**/
[Defines]
@@ -17,7 +17,7 @@ FILE_GUID = F1BD6B36-B705-43aa-8A28-33F58ED85EFB
MODULE_TYPE = UEFI_DRIVER
VERSION_STRING = 1.0
- LIBRARY_CLASS = DmaLib
+ LIBRARY_CLASS = DmaLib
CONSTRUCTOR = ArmDmaLibConstructor
[Sources.common]
@@ -27,7 +27,7 @@ MdePkg/MdePkg.dec
EmbeddedPkg/EmbeddedPkg.dec
ArmPkg/ArmPkg.dec
-
+
[LibraryClasses]
DebugLib
@@ -37,14 +37,14 @@ IoLib
BaseMemoryLib
ArmLib
-
-
+
+
[Protocols]
gEfiCpuArchProtocolGuid
-
+
[Guids]
-
+
[Pcd]
[Depex]
- gEfiCpuArchProtocolGuid
\ No newline at end of file + gEfiCpuArchProtocolGuid
diff --git a/ArmPkg/Library/ArmLib/Arm11/Arm11Lib.c b/ArmPkg/Library/ArmLib/Arm11/Arm11Lib.c index 1f353d477f..8c54b6cc8f 100644 --- a/ArmPkg/Library/ArmLib/Arm11/Arm11Lib.c +++ b/ArmPkg/Library/ArmLib/Arm11/Arm11Lib.c @@ -2,7 +2,7 @@ Copyright (c) 2008 - 2009, Apple Inc. All rights reserved.<BR>
Copyright (c) 2011 - 2014, ARM Limited. All rights reserved.
-
+
This program and the accompanying materials
are licensed and made available under the terms and conditions of the BSD License
which accompanies this distribution. The full text of the license may be found at
diff --git a/ArmPkg/Library/ArmLib/Arm11/Arm11Lib.inf b/ArmPkg/Library/ArmLib/Arm11/Arm11Lib.inf index 5f24ffaf3c..32d9299629 100644 --- a/ArmPkg/Library/ArmLib/Arm11/Arm11Lib.inf +++ b/ArmPkg/Library/ArmLib/Arm11/Arm11Lib.inf @@ -25,11 +25,11 @@ ../Common/Arm/ArmLibSupport.S | GCC
../Common/Arm/ArmLibSupport.asm | RVCT
../Common/ArmLib.c
-
+
Arm11Support.S | GCC
Arm11Support.asm | RVCT
- Arm11Lib.c
+ Arm11Lib.c
Arm11LibMem.c
../Arm9/Arm9CacheInformation.c
@@ -39,7 +39,7 @@ [LibraryClasses]
MemoryAllocationLib
-
+
[Protocols]
gEfiCpuArchProtocolGuid
diff --git a/ArmPkg/Library/ArmLib/Arm11/Arm11LibMem.c b/ArmPkg/Library/ArmLib/Arm11/Arm11LibMem.c index 6b94c41862..0f89801525 100644 --- a/ArmPkg/Library/ArmLib/Arm11/Arm11LibMem.c +++ b/ArmPkg/Library/ArmLib/Arm11/Arm11LibMem.c @@ -2,7 +2,7 @@ Copyright (c) 2008 - 2009, Apple Inc. All rights reserved.<BR>
Copyright (c) 2011 - 2013, ARM Limited. All rights reserved.
-
+
This program and the accompanying materials
are licensed and made available under the terms and conditions of the BSD License
which accompanies this distribution. The full text of the license may be found at
@@ -29,7 +29,7 @@ FillTranslationTable ( UINTN Index;
UINT32 Attributes;
UINT32 PhysicalBase = MemoryRegion->PhysicalBase;
-
+
switch (MemoryRegion->Attributes) {
case ARM_MEMORY_REGION_ATTRIBUTE_WRITE_BACK:
Attributes = TT_DESCRIPTOR_SECTION_WRITE_BACK(0);
@@ -53,10 +53,10 @@ FillTranslationTable ( Attributes = TT_DESCRIPTOR_SECTION_UNCACHED(0);
break;
}
-
+
Entry = TRANSLATION_TABLE_ENTRY_FOR_VIRTUAL_ADDRESS(TranslationTable, MemoryRegion->VirtualBase);
Sections = ((( MemoryRegion->Length - 1 ) / TT_DESCRIPTOR_SECTION_SIZE ) + 1 );
-
+
for (Index = 0; Index < Sections; Index++)
{
*Entry++ = TT_DESCRIPTOR_SECTION_BASE_ADDRESS(PhysicalBase) | Attributes;
@@ -84,7 +84,7 @@ ArmConfigureMmu ( if (TranslationTableBase != NULL) {
*TranslationTableBase = TranslationTable;
}
-
+
if (TranslationTableBase != NULL) {
*TranslationTableSize = TRANSLATION_TABLE_SIZE;
}
@@ -109,7 +109,7 @@ ArmConfigureMmu ( }
ArmSetTTBR0(TranslationTable);
-
+
ArmSetDomainAccessControl(DOMAIN_ACCESS_CONTROL_NONE(15) |
DOMAIN_ACCESS_CONTROL_NONE(14) |
DOMAIN_ACCESS_CONTROL_NONE(13) |
@@ -126,7 +126,7 @@ ArmConfigureMmu ( DOMAIN_ACCESS_CONTROL_NONE( 2) |
DOMAIN_ACCESS_CONTROL_NONE( 1) |
DOMAIN_ACCESS_CONTROL_MANAGER(0));
-
+
ArmEnableInstructionCache();
ArmEnableDataCache();
ArmEnableMmu();
diff --git a/ArmPkg/Library/ArmLib/Arm11/Arm11LibPrePi.inf b/ArmPkg/Library/ArmLib/Arm11/Arm11LibPrePi.inf index 7239aceaf9..94dd03d82c 100644 --- a/ArmPkg/Library/ArmLib/Arm11/Arm11LibPrePi.inf +++ b/ArmPkg/Library/ArmLib/Arm11/Arm11LibPrePi.inf @@ -25,11 +25,11 @@ ../Common/Arm/ArmLibSupport.S | GCC
../Common/Arm/ArmLibSupport.asm | RVCT
../Common/ArmLib.c
-
+
Arm11Support.S | GCC
Arm11Support.asm | RVCT
- Arm11Lib.c
+ Arm11Lib.c
Arm11LibMem.c
../Arm9/Arm9CacheInformation.c
@@ -39,7 +39,7 @@ [LibraryClasses]
PrePiLib
-
+
[Protocols]
gEfiCpuArchProtocolGuid
diff --git a/ArmPkg/Library/ArmLib/Arm11/Arm11LibSec.inf b/ArmPkg/Library/ArmLib/Arm11/Arm11LibSec.inf index e693c46dc4..69763ed4ff 100644 --- a/ArmPkg/Library/ArmLib/Arm11/Arm11LibSec.inf +++ b/ArmPkg/Library/ArmLib/Arm11/Arm11LibSec.inf @@ -25,10 +25,10 @@ ../Common/Arm/ArmLibSupport.S | GCC
../Common/Arm/ArmLibSupport.asm | RVCT
../Common/ArmLib.c
-
+
Arm11Support.S | GCC
Arm11Support.asm | RVCT
-
+
Arm11Lib.c
../Arm9/Arm9CacheInformation.c
diff --git a/ArmPkg/Library/ArmLib/Arm11/Arm11Support.S b/ArmPkg/Library/ArmLib/Arm11/Arm11Support.S index 2f4be7e93f..7fb454c3dd 100644 --- a/ArmPkg/Library/ArmLib/Arm11/Arm11Support.S +++ b/ArmPkg/Library/ArmLib/Arm11/Arm11Support.S @@ -1,4 +1,4 @@ -#------------------------------------------------------------------------------
+#------------------------------------------------------------------------------
#
# Copyright (c) 2008 - 2009, Apple Inc. All rights reserved.<BR>
# Copyright (c) 2011, ARM Limited. All rights reserved.
@@ -73,12 +73,12 @@ ASM_PFX(ArmInvalidateInstructionAndDataTlb): bx lr
ASM_PFX(ArmInvalidateDataCacheEntryByMVA):
- mcr p15, 0, r0, c7, c6, 1 @invalidate single data cache line
+ mcr p15, 0, r0, c7, c6, 1 @invalidate single data cache line
bx lr
ASM_PFX(ArmCleanDataCacheEntryByMVA):
- mcr p15, 0, r0, c7, c10, 1 @clean single data cache line
+ mcr p15, 0, r0, c7, c10, 1 @clean single data cache line
bx lr
@@ -135,7 +135,7 @@ ASM_PFX(ArmEnableDataCache): orr R0,R0,R1 @Set C bit
mcr p15,0,r0,c1,c0,0 @Write control register configuration data
bx LR
-
+
ASM_PFX(ArmDisableDataCache):
LoadConstantToReg(DC_ON, R1) @ldr R1,=DC_ON
mrc p15,0,R0,c1,c0,0 @Read control register configuration data
@@ -149,7 +149,7 @@ ASM_PFX(ArmEnableInstructionCache): orr R0,R0,R1 @Set I bit
mcr p15,0,r0,c1,c0,0 @Write control register configuration data
bx LR
-
+
ASM_PFX(ArmDisableInstructionCache):
ldr R1,=IC_ON
mrc p15,0,R0,c1,c0,0 @Read control register configuration data
@@ -171,17 +171,17 @@ ASM_PFX(ArmDisableBranchPrediction): ASM_PFX(ArmDataMemoryBarrier):
mov R0, #0
- mcr P15, #0, R0, C7, C10, #5
+ mcr P15, #0, R0, C7, C10, #5
bx LR
-
+
ASM_PFX(ArmDataSyncronizationBarrier):
mov R0, #0
- mcr P15, #0, R0, C7, C10, #4
+ mcr P15, #0, R0, C7, C10, #4
bx LR
-
+
ASM_PFX(ArmInstructionSynchronizationBarrier):
mov R0, #0
- mcr P15, #0, R0, C7, C5, #4
+ mcr P15, #0, R0, C7, C5, #4
bx LR
ASM_PFX(ArmSetLowVectors):
@@ -206,7 +206,7 @@ ASM_PFX(ArmIsMpCore): cmp r0, r1
movne r0, #0
pop { r1 }
- bx lr
+ bx lr
ASM_PFX(ArmCallWFI):
wfi
diff --git a/ArmPkg/Library/ArmLib/Arm11/Arm11Support.asm b/ArmPkg/Library/ArmLib/Arm11/Arm11Support.asm index 8c27093045..53283d1eea 100644 --- a/ArmPkg/Library/ArmLib/Arm11/Arm11Support.asm +++ b/ArmPkg/Library/ArmLib/Arm11/Arm11Support.asm @@ -1,4 +1,4 @@ -//------------------------------------------------------------------------------
+//------------------------------------------------------------------------------
//
// Copyright (c) 2008 - 2009, Apple Inc. All rights reserved.<BR>
//
@@ -43,12 +43,12 @@ XP_ON EQU ( 0x1:SHL:23 ) ArmInvalidateDataCacheEntryByMVA
- mcr p15, 0, r0, c7, c6, 1 ; invalidate single data cache line
+ mcr p15, 0, r0, c7, c6, 1 ; invalidate single data cache line
bx lr
ArmCleanDataCacheEntryByMVA
- mcr p15, 0, r0, c7, c10, 1 ; clean single data cache line
+ mcr p15, 0, r0, c7, c10, 1 ; clean single data cache line
bx lr
@@ -105,7 +105,7 @@ ArmEnableDataCache ORR R0,R0,R1 ;Set C bit
MCR p15,0,r0,c1,c0,0 ;Write control register configuration data
BX LR
-
+
ArmDisableDataCache
LDR R1,=DC_ON
MRC p15,0,R0,c1,c0,0 ;Read control register configuration data
@@ -119,7 +119,7 @@ ArmEnableInstructionCache ORR R0,R0,R1 ;Set I bit
MCR p15,0,r0,c1,c0,0 ;Write control register configuration data
BX LR
-
+
ArmDisableInstructionCache
LDR R1,=IC_ON
MRC p15,0,R0,c1,c0,0 ;Read control register configuration data
@@ -141,17 +141,17 @@ ArmDisableBranchPrediction ASM_PFX(ArmDataMemoryBarrier):
mov R0, #0
- mcr P15, #0, R0, C7, C10, #5
+ mcr P15, #0, R0, C7, C10, #5
bx LR
-
+
ASM_PFX(ArmDataSyncronizationBarrier):
mov R0, #0
- mcr P15, #0, R0, C7, C10, #4
+ mcr P15, #0, R0, C7, C10, #4
bx LR
-
+
ASM_PFX(ArmInstructionSynchronizationBarrier):
MOV R0, #0
- MCR P15, #0, R0, C7, C5, #4
+ MCR P15, #0, R0, C7, C5, #4
bx LR
END
diff --git a/ArmPkg/Library/ArmLib/Arm9/Arm9ArmLib.inf b/ArmPkg/Library/ArmLib/Arm9/Arm9ArmLib.inf index e962ca40aa..81661b2391 100644 --- a/ArmPkg/Library/ArmLib/Arm9/Arm9ArmLib.inf +++ b/ArmPkg/Library/ArmLib/Arm9/Arm9ArmLib.inf @@ -28,7 +28,7 @@ Arm9Support.S | GCC
Arm9Support.asm | RVCT
-
+
Arm9Lib.c
Arm9CacheInformation.c
@@ -38,7 +38,7 @@ [LibraryClasses]
MemoryAllocationLib
-
+
[Protocols]
gEfiCpuArchProtocolGuid
diff --git a/ArmPkg/Library/ArmLib/Arm9/Arm9ArmLibPrePi.inf b/ArmPkg/Library/ArmLib/Arm9/Arm9ArmLibPrePi.inf index 4c57001930..0730487cfb 100644 --- a/ArmPkg/Library/ArmLib/Arm9/Arm9ArmLibPrePi.inf +++ b/ArmPkg/Library/ArmLib/Arm9/Arm9ArmLibPrePi.inf @@ -28,7 +28,7 @@ Arm9Support.S | GCC
Arm9Support.asm | RVCT
-
+
Arm9Lib.c
Arm9CacheInformation.c
diff --git a/ArmPkg/Library/ArmLib/Arm9/Arm9CacheInformation.c b/ArmPkg/Library/ArmLib/Arm9/Arm9CacheInformation.c index 19da4db258..f0b5060249 100644 --- a/ArmPkg/Library/ArmLib/Arm9/Arm9CacheInformation.c +++ b/ArmPkg/Library/ArmLib/Arm9/Arm9CacheInformation.c @@ -56,7 +56,7 @@ ArmDataCachePresent ( default: return FALSE;
}
}
-
+
UINTN
EFIAPI
ArmDataCacheSize (
@@ -65,16 +65,16 @@ ArmDataCacheSize ( {
switch (DATA_CACHE_SIZE (ArmCacheInfo ()))
{
- case CACHE_SIZE_4_KB: return 4 * 1024;
+ case CACHE_SIZE_4_KB: return 4 * 1024;
case CACHE_SIZE_8_KB: return 8 * 1024;
- case CACHE_SIZE_16_KB: return 16 * 1024;
+ case CACHE_SIZE_16_KB: return 16 * 1024;
case CACHE_SIZE_32_KB: return 32 * 1024;
case CACHE_SIZE_64_KB: return 64 * 1024;
case CACHE_SIZE_128_KB: return 128 * 1024;
default: return 0;
}
}
-
+
UINTN
EFIAPI
ArmDataCacheAssociativity (
@@ -88,7 +88,7 @@ ArmDataCacheAssociativity ( default: return 0;
}
}
-
+
UINTN
EFIAPI
ArmDataCacheLineLength (
@@ -101,7 +101,7 @@ ArmDataCacheLineLength ( default: return 0;
}
}
-
+
BOOLEAN
EFIAPI
ArmInstructionCachePresent (
@@ -115,7 +115,7 @@ ArmInstructionCachePresent ( default: return FALSE;
}
}
-
+
UINTN
EFIAPI
ArmInstructionCacheSize (
@@ -124,16 +124,16 @@ ArmInstructionCacheSize ( {
switch (INSTRUCTION_CACHE_SIZE (ArmCacheInfo ()))
{
- case CACHE_SIZE_4_KB: return 4 * 1024;
+ case CACHE_SIZE_4_KB: return 4 * 1024;
case CACHE_SIZE_8_KB: return 8 * 1024;
- case CACHE_SIZE_16_KB: return 16 * 1024;
+ case CACHE_SIZE_16_KB: return 16 * 1024;
case CACHE_SIZE_32_KB: return 32 * 1024;
case CACHE_SIZE_64_KB: return 64 * 1024;
case CACHE_SIZE_128_KB: return 128 * 1024;
default: return 0;
}
}
-
+
UINTN
EFIAPI
ArmInstructionCacheAssociativity (
@@ -148,7 +148,7 @@ ArmInstructionCacheAssociativity ( default: return 0;
}
}
-
+
UINTN
EFIAPI
ArmInstructionCacheLineLength (
diff --git a/ArmPkg/Library/ArmLib/Arm9/Arm9Lib.c b/ArmPkg/Library/ArmLib/Arm9/Arm9Lib.c index 1acb158019..7432f7b678 100644 --- a/ArmPkg/Library/ArmLib/Arm9/Arm9Lib.c +++ b/ArmPkg/Library/ArmLib/Arm9/Arm9Lib.c @@ -2,7 +2,7 @@ Copyright (c) 2008 - 2009, Apple Inc. All rights reserved.<BR>
Copyright (c) 2011 - 2013, ARM Limited. All rights reserved.
-
+
This program and the accompanying materials
are licensed and made available under the terms and conditions of the BSD License
which accompanies this distribution. The full text of the license may be found at
@@ -30,7 +30,7 @@ FillTranslationTable ( UINTN Index;
UINT32 Attributes;
UINT32 PhysicalBase = MemoryRegion->PhysicalBase;
-
+
switch (MemoryRegion->Attributes) {
case ARM_MEMORY_REGION_ATTRIBUTE_WRITE_BACK:
Attributes = TT_DESCRIPTOR_SECTION_WRITE_BACK;
@@ -49,13 +49,13 @@ FillTranslationTable ( Attributes = TT_DESCRIPTOR_SECTION_UNCACHED_UNBUFFERED;
break;
}
-
+
Entry = TRANSLATION_TABLE_ENTRY_FOR_VIRTUAL_ADDRESS(TranslationTable, MemoryRegion->VirtualBase);
Sections = MemoryRegion->Length / TT_DESCRIPTOR_SECTION_SIZE;
-
+
// The current code does not support memory region size that is not aligned on TT_DESCRIPTOR_SECTION_SIZE boundary
ASSERT (MemoryRegion->Length % TT_DESCRIPTOR_SECTION_SIZE == 0);
-
+
for (Index = 0; Index < Sections; Index++)
{
*Entry++ = TT_DESCRIPTOR_SECTION_BASE_ADDRESS(PhysicalBase) | Attributes;
@@ -83,7 +83,7 @@ ArmConfigureMmu ( if (TranslationTableBase != NULL) {
*TranslationTableBase = TranslationTable;
}
-
+
if (TranslationTableBase != NULL) {
*TranslationTableSize = TRANSLATION_TABLE_SIZE;
}
@@ -108,7 +108,7 @@ ArmConfigureMmu ( }
ArmSetTTBR0(TranslationTable);
-
+
ArmSetDomainAccessControl(DOMAIN_ACCESS_CONTROL_NONE(15) |
DOMAIN_ACCESS_CONTROL_NONE(14) |
DOMAIN_ACCESS_CONTROL_NONE(13) |
@@ -125,7 +125,7 @@ ArmConfigureMmu ( DOMAIN_ACCESS_CONTROL_NONE( 2) |
DOMAIN_ACCESS_CONTROL_NONE( 1) |
DOMAIN_ACCESS_CONTROL_MANAGER(0));
-
+
ArmEnableInstructionCache();
ArmEnableDataCache();
ArmEnableMmu();
diff --git a/ArmPkg/Library/ArmLib/Arm9/Arm9Support.S b/ArmPkg/Library/ArmLib/Arm9/Arm9Support.S index 28cc5b6e6c..c708d212a9 100644 --- a/ArmPkg/Library/ArmLib/Arm9/Arm9Support.S +++ b/ArmPkg/Library/ArmLib/Arm9/Arm9Support.S @@ -1,4 +1,4 @@ -#------------------------------------------------------------------------------
+#------------------------------------------------------------------------------
#
# Copyright (c) 2008 - 2009, Apple Inc. All rights reserved.<BR>
#
@@ -41,11 +41,11 @@ GCC_ASM_EXPORT(ArmInstructionSynchronizationBarrier) #------------------------------------------------------------------------------
ASM_PFX(ArmInvalidateDataCacheEntryByMVA):
- mcr p15, 0, r0, c7, c6, 1 @ invalidate single data cache line
+ mcr p15, 0, r0, c7, c6, 1 @ invalidate single data cache line
bx lr
ASM_PFX(ArmCleanDataCacheEntryByMVA):
- mcr p15, 0, r0, c7, c10, 1 @ clean single data cache line
+ mcr p15, 0, r0, c7, c10, 1 @ clean single data cache line
bx lr
ASM_PFX(ArmCleanInvalidateDataCacheEntryByMVA):
@@ -58,17 +58,17 @@ ASM_PFX(ArmEnableInstructionCache): orr r0,r0,r1 @Set I bit
mcr p15,0,r0,c1,c0,0 @Write control register configuration data
bx LR
-
+
ASM_PFX(ArmDisableInstructionCache):
ldr r1,=IC_ON
mrc p15,0,r0,c1,c0,0 @Read control register configuration data
bic r0,r0,r1 @Clear I bit.
mcr p15,0,r0,c1,c0,0 @Write control register configuration data
bx LR
-
+
ASM_PFX(ArmInvalidateInstructionCache):
mov r0,#0
- mcr p15,0,r0,c7,c5,0 @Invalidate entire Instruction cache.
+ mcr p15,0,r0,c7,c5,0 @Invalidate entire Instruction cache.
@Also flushes the branch target cache.
mov r0,#0
mcr p15,0,r0,c7,c10,4 @Data write buffer
@@ -99,7 +99,7 @@ ASM_PFX(ArmEnableDataCache): orr R0,R0,R1 @Set C bit
mcr p15,0,r0,c1,c0,0 @Write control register configuration data
bx LR
-
+
ASM_PFX(ArmDisableDataCache):
ldr R1,=DC_ON
mrc p15,0,R0,c1,c0,0 @Read control register configuration data
@@ -113,7 +113,7 @@ ASM_PFX(ArmCleanDataCache): mov R0,#0
mcr p15,0,R0,c7,c10,4 @Drain write buffer
bx LR
-
+
ASM_PFX(ArmInvalidateDataCache):
mov R0,#0
mcr p15,0,R0,c7,c6,0 @Invalidate entire data cache
@@ -138,12 +138,12 @@ ASM_PFX(ArmDataMemoryBarrier): mov R0, #0
mcr P15, #0, R0, C7, C10, #5 @ check if this is OK?
bx LR
-
+
ASM_PFX(ArmDataSyncronizationBarrier):
mov R0, #0
mcr P15, #0, R0, C7, C10, #4 @ check if this is OK?
bx LR
-
+
ASM_PFX(ArmInstructionSynchronizationBarrier):
mov R0, #0
mcr P15, #0, R0, C7, C5, #4 @ check if this is OK?
diff --git a/ArmPkg/Library/ArmLib/Arm9/Arm9Support.asm b/ArmPkg/Library/ArmLib/Arm9/Arm9Support.asm index fc87828e20..4aaa546ca0 100644 --- a/ArmPkg/Library/ArmLib/Arm9/Arm9Support.asm +++ b/ArmPkg/Library/ArmLib/Arm9/Arm9Support.asm @@ -1,4 +1,4 @@ -//------------------------------------------------------------------------------
+//------------------------------------------------------------------------------
//
// Copyright (c) 2008 - 2009, Apple Inc. All rights reserved.<BR>
//
@@ -41,12 +41,12 @@ IC_ON EQU ( 0x1:SHL:12 ) ArmInvalidateDataCacheEntryByMVA
- MCR p15, 0, r0, c7, c6, 1 ; invalidate single data cache line
+ MCR p15, 0, r0, c7, c6, 1 ; invalidate single data cache line
BX lr
ArmCleanDataCacheEntryByMVA
- MCR p15, 0, r0, c7, c10, 1 ; clean single data cache line
+ MCR p15, 0, r0, c7, c10, 1 ; clean single data cache line
BX lr
@@ -60,7 +60,7 @@ ArmEnableInstructionCache ORR R0,R0,R1 ;Set I bit
MCR p15,0,r0,c1,c0,0 ;Write control register configuration data
BX LR
-
+
ArmDisableInstructionCache
LDR R1,=IC_ON
MRC p15,0,R0,c1,c0,0 ;Read control register configuration data
@@ -100,7 +100,7 @@ ArmEnableDataCache ORR R0,R0,R1 ;Set C bit
MCR p15,0,r0,c1,c0,0 ;Write control register configuration data
BX LR
-
+
ArmDisableDataCache
LDR R1,=DC_ON
MRC p15,0,R0,c1,c0,0 ;Read control register configuration data
@@ -121,7 +121,7 @@ ArmInvalidateDataCache MOV R0,#0
MCR p15,0,R0,c7,c10,4 ;Drain write buffer
BX LR
-
+
ArmCleanInvalidateDataCache
MRC p15,0,r15,c7,c14,3
BNE ArmCleanInvalidateDataCache
@@ -139,12 +139,12 @@ ASM_PFX(ArmDataMemoryBarrier): mov R0, #0
mcr P15, #0, R0, C7, C10, #5 ; Check to see if this is correct
bx LR
-
+
ASM_PFX(ArmDataSyncronizationBarrier):
mov R0, #0
mcr P15, #0, R0, C7, C10, #4 ; Check to see if this is correct
bx LR
-
+
ASM_PFX(ArmInstructionSynchronizationBarrier):
MOV R0, #0
MCR P15, #0, R0, C7, C5, #4 ; Check to see if this is correct
diff --git a/ArmPkg/Library/ArmLib/ArmV7/ArmLibSupportV7.S b/ArmPkg/Library/ArmLib/ArmV7/ArmLibSupportV7.S index 5ee8b25675..333827a992 100644 --- a/ArmPkg/Library/ArmLib/ArmV7/ArmLibSupportV7.S +++ b/ArmPkg/Library/ArmLib/ArmV7/ArmLibSupportV7.S @@ -1,4 +1,4 @@ -#------------------------------------------------------------------------------
+#------------------------------------------------------------------------------
#
# Copyright (c) 2008 - 2009, Apple Inc. All rights reserved.<BR>
# Copyright (c) 2011-2013, ARM Limited. All rights reserved.
@@ -81,21 +81,21 @@ ASM_PFX(ArmDisableInterrupts): cpsid if
isb
bx LR
-
-// UINT32
+
+// UINT32
// ReadCCSIDR (
// IN UINT32 CSSELR
-// )
+// )
ASM_PFX(ReadCCSIDR):
mcr p15,2,r0,c0,c0,0 @ Write Cache Size Selection Register (CSSELR)
isb
mrc p15,1,r0,c0,c0,0 @ Read current CP15 Cache Size ID Register (CCSIDR)
bx lr
-
-// UINT32
+
+// UINT32
// ReadCLIDR (
// IN UINT32 CSSELR
-// )
+// )
ASM_PFX(ReadCLIDR):
mrc p15,1,r0,c0,c0,1 @ Read CP15 Cache Level ID Register
bx lr
diff --git a/ArmPkg/Library/ArmLib/ArmV7/ArmLibSupportV7.asm b/ArmPkg/Library/ArmLib/ArmV7/ArmLibSupportV7.asm index 6af662bda5..d60d4ed213 100644 --- a/ArmPkg/Library/ArmLib/ArmV7/ArmLibSupportV7.asm +++ b/ArmPkg/Library/ArmLib/ArmV7/ArmLibSupportV7.asm @@ -1,4 +1,4 @@ -//------------------------------------------------------------------------------
+//------------------------------------------------------------------------------
//
// Copyright (c) 2008 - 2010, Apple Inc. All rights reserved.<BR>
// Copyright (c) 2011-2013, ARM Limited. All rights reserved.
@@ -80,21 +80,21 @@ ArmDisableInterrupts cpsid if
isb
bx LR
-
-// UINT32
+
+// UINT32
// ReadCCSIDR (
// IN UINT32 CSSELR
-// )
+// )
ReadCCSIDR
mcr p15,2,r0,c0,c0,0 ; Write Cache Size Selection Register (CSSELR)
isb
mrc p15,1,r0,c0,c0,0 ; Read current CP15 Cache Size ID Register (CCSIDR)
bx lr
-
-// UINT32
+
+// UINT32
// ReadCLIDR (
// IN UINT32 CSSELR
-// )
+// )
ReadCLIDR
mrc p15,1,r0,c0,c0,1 ; Read CP15 Cache Level ID Register
bx lr
diff --git a/ArmPkg/Library/ArmLib/ArmV7/ArmV7ArchTimer.c b/ArmPkg/Library/ArmLib/ArmV7/ArmV7ArchTimer.c index fd82ef927b..79083f56b7 100644 --- a/ArmPkg/Library/ArmLib/ArmV7/ArmV7ArchTimer.c +++ b/ArmPkg/Library/ArmLib/ArmV7/ArmV7ArchTimer.c @@ -1,14 +1,14 @@ /** @file
*
* Copyright (c) 2011 - 2014, ARM Limited. All rights reserved.
-*
-* This program and the accompanying materials
-* are licensed and made available under the terms and conditions of the BSD License
-* which accompanies this distribution. The full text of the license may be found at
-* http://opensource.org/licenses/bsd-license.php
*
-* THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
-* WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
+* This program and the accompanying materials
+* are licensed and made available under the terms and conditions of the BSD License
+* which accompanies this distribution. The full text of the license may be found at
+* http://opensource.org/licenses/bsd-license.php
+*
+* THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
+* WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
*
**/
diff --git a/ArmPkg/Library/ArmLib/ArmV7/ArmV7ArchTimerSupport.S b/ArmPkg/Library/ArmLib/ArmV7/ArmV7ArchTimerSupport.S index 531d8fd1e0..ec4ede5250 100644 --- a/ArmPkg/Library/ArmLib/ArmV7/ArmV7ArchTimerSupport.S +++ b/ArmPkg/Library/ArmLib/ArmV7/ArmV7ArchTimerSupport.S @@ -1,4 +1,4 @@ -#------------------------------------------------------------------------------
+#------------------------------------------------------------------------------
#
# Copyright (c) 2011, ARM Limited. All rights reserved.
#
diff --git a/ArmPkg/Library/ArmLib/ArmV7/ArmV7ArchTimerSupport.asm b/ArmPkg/Library/ArmLib/ArmV7/ArmV7ArchTimerSupport.asm index fc0be1966b..514830d28f 100644 --- a/ArmPkg/Library/ArmLib/ArmV7/ArmV7ArchTimerSupport.asm +++ b/ArmPkg/Library/ArmLib/ArmV7/ArmV7ArchTimerSupport.asm @@ -1,4 +1,4 @@ -//------------------------------------------------------------------------------
+//------------------------------------------------------------------------------
//
// Copyright (c) 2011, ARM Limited. All rights reserved.
//
diff --git a/ArmPkg/Library/ArmLib/ArmV7/ArmV7Lib.c b/ArmPkg/Library/ArmLib/ArmV7/ArmV7Lib.c index 65709780ed..feb60881bd 100644 --- a/ArmPkg/Library/ArmLib/ArmV7/ArmV7Lib.c +++ b/ArmPkg/Library/ArmLib/ArmV7/ArmV7Lib.c @@ -2,7 +2,7 @@ Copyright (c) 2008 - 2009, Apple Inc. All rights reserved.<BR>
Copyright (c) 2011 - 2014, ARM Limited. All rights reserved.
-
+
This program and the accompanying materials
are licensed and made available under the terms and conditions of the BSD License
which accompanies this distribution. The full text of the license may be found at
@@ -47,7 +47,7 @@ ArmDataCachePresent ( )
{
UINT32 CLIDR = ReadCLIDR ();
-
+
if ((CLIDR & 0x2) == 0x2) {
// Instruction cache exists
return TRUE;
@@ -56,10 +56,10 @@ ArmDataCachePresent ( // Unified cache
return TRUE;
}
-
+
return FALSE;
}
-
+
UINTN
EFIAPI
ArmDataCacheSize (
@@ -70,15 +70,15 @@ ArmDataCacheSize ( UINT32 Associativity;
UINT32 LineSize;
UINT32 CCSIDR = ReadCCSIDR (0);
-
+
LineSize = (1 << ((CCSIDR & 0x7) + 2));
Associativity = ((CCSIDR >> 3) & 0x3ff) + 1;
NumSets = ((CCSIDR >> 13) & 0x7fff) + 1;
// LineSize is in words (4 byte chunks)
- return NumSets * Associativity * LineSize * 4;
+ return NumSets * Associativity * LineSize * 4;
}
-
+
UINTN
EFIAPI
ArmDataCacheAssociativity (
@@ -89,14 +89,14 @@ ArmDataCacheAssociativity ( return ((CCSIDR >> 3) & 0x3ff) + 1;
}
-
+
UINTN
ArmDataCacheSets (
VOID
)
{
UINT32 CCSIDR = ReadCCSIDR (0);
-
+
return ((CCSIDR >> 13) & 0x7fff) + 1;
}
@@ -111,7 +111,7 @@ ArmDataCacheLineLength ( // * 4 converts to bytes
return (1 << (CCSIDR + 2)) * 4;
}
-
+
BOOLEAN
EFIAPI
ArmInstructionCachePresent (
@@ -119,7 +119,7 @@ ArmInstructionCachePresent ( )
{
UINT32 CLIDR = ReadCLIDR ();
-
+
if ((CLIDR & 1) == 1) {
// Instruction cache exists
return TRUE;
@@ -128,10 +128,10 @@ ArmInstructionCachePresent ( // Unified cache
return TRUE;
}
-
+
return FALSE;
}
-
+
UINTN
EFIAPI
ArmInstructionCacheSize (
@@ -142,15 +142,15 @@ ArmInstructionCacheSize ( UINT32 Associativity;
UINT32 LineSize;
UINT32 CCSIDR = ReadCCSIDR (1);
-
+
LineSize = (1 << ((CCSIDR & 0x7) + 2));
Associativity = ((CCSIDR >> 3) & 0x3ff) + 1;
NumSets = ((CCSIDR >> 13) & 0x7fff) + 1;
// LineSize is in words (4 byte chunks)
- return NumSets * Associativity * LineSize * 4;
+ return NumSets * Associativity * LineSize * 4;
}
-
+
UINTN
EFIAPI
ArmInstructionCacheAssociativity (
@@ -162,7 +162,7 @@ ArmInstructionCacheAssociativity ( return ((CCSIDR >> 3) & 0x3ff) + 1;
// return 4;
}
-
+
UINTN
EFIAPI
ArmInstructionCacheSets (
@@ -170,7 +170,7 @@ ArmInstructionCacheSets ( )
{
UINT32 CCSIDR = ReadCCSIDR (1);
-
+
return ((CCSIDR >> 13) & 0x7fff) + 1;
}
@@ -198,11 +198,11 @@ ArmV7DataCacheOperation ( SavedInterruptState = ArmGetInterruptState ();
ArmDisableInterrupts ();
-
+
ArmV7AllDataCachesOperation (DataCacheOperation);
-
+
ArmDrainWriteBuffer ();
-
+
if (SavedInterruptState) {
ArmEnableInterrupts ();
}
@@ -218,11 +218,11 @@ ArmV7PoUDataCacheOperation ( SavedInterruptState = ArmGetInterruptState ();
ArmDisableInterrupts ();
-
+
ArmV7PerformPoUDataCacheOperation (DataCacheOperation);
-
+
ArmDrainWriteBuffer ();
-
+
if (SavedInterruptState) {
ArmEnableInterrupts ();
}
diff --git a/ArmPkg/Library/ArmLib/ArmV7/ArmV7Lib.h b/ArmPkg/Library/ArmLib/ArmV7/ArmV7Lib.h index f183a1cca3..1398d75071 100644 --- a/ArmPkg/Library/ArmLib/ArmV7/ArmV7Lib.h +++ b/ArmPkg/Library/ArmLib/ArmV7/ArmV7Lib.h @@ -27,6 +27,6 @@ VOID ArmV7AllDataCachesOperation (
IN ARM_V7_CACHE_OPERATION DataCacheOperation
);
-
+
#endif // __ARM_V7_LIB_H__
diff --git a/ArmPkg/Library/ArmLib/ArmV7/ArmV7Lib.inf b/ArmPkg/Library/ArmLib/ArmV7/ArmV7Lib.inf index ec2a0bae89..55c0ec661a 100644 --- a/ArmPkg/Library/ArmLib/ArmV7/ArmV7Lib.inf +++ b/ArmPkg/Library/ArmLib/ArmV7/ArmV7Lib.inf @@ -28,10 +28,10 @@ ../Common/Arm/ArmLibSupport.S | GCC
../Common/Arm/ArmLibSupport.asm | RVCT
../Common/ArmLib.c
-
+
ArmV7Support.S | GCC
ArmV7Support.asm | RVCT
-
+
ArmV7Lib.c
ArmV7Mmu.c
@@ -45,7 +45,7 @@ [LibraryClasses]
MemoryAllocationLib
-
+
[Protocols]
gEfiCpuArchProtocolGuid
diff --git a/ArmPkg/Library/ArmLib/ArmV7/ArmV7LibPrePi.inf b/ArmPkg/Library/ArmLib/ArmV7/ArmV7LibPrePi.inf index be5b8e4930..bc403d5613 100644 --- a/ArmPkg/Library/ArmLib/ArmV7/ArmV7LibPrePi.inf +++ b/ArmPkg/Library/ArmLib/ArmV7/ArmV7LibPrePi.inf @@ -28,13 +28,13 @@ ../Common/Arm/ArmLibSupport.S | GCC
../Common/Arm/ArmLibSupport.asm | RVCT
../Common/ArmLib.c
-
+
ArmV7Support.S | GCC
ArmV7Support.asm | RVCT
-
+
ArmV7Lib.c
ArmV7Mmu.c
-
+
ArmV7ArchTimer.c
ArmV7ArchTimerSupport.S | GCC
ArmV7ArchTimerSupport.asm | RVCT
@@ -45,7 +45,7 @@ [LibraryClasses]
PrePiLib
-
+
[Protocols]
gEfiCpuArchProtocolGuid
diff --git a/ArmPkg/Library/ArmLib/ArmV7/ArmV7LibSec.inf b/ArmPkg/Library/ArmLib/ArmV7/ArmV7LibSec.inf index c1f97bb12d..4081d1a3e5 100644 --- a/ArmPkg/Library/ArmLib/ArmV7/ArmV7LibSec.inf +++ b/ArmPkg/Library/ArmLib/ArmV7/ArmV7LibSec.inf @@ -1,13 +1,13 @@ #/* @file
# Copyright (c) 2011, ARM Limited. All rights reserved.
-#
-# This program and the accompanying materials
-# are licensed and made available under the terms and conditions of the BSD License
-# which accompanies this distribution. The full text of the license may be found at
-# http://opensource.org/licenses/bsd-license.php
#
-# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
-# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
+# This program and the accompanying materials
+# are licensed and made available under the terms and conditions of the BSD License
+# which accompanies this distribution. The full text of the license may be found at
+# http://opensource.org/licenses/bsd-license.php
+#
+# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
+# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
#
#*/
@@ -26,12 +26,12 @@ ../Common/Arm/ArmLibSupport.S | GCC
../Common/Arm/ArmLibSupport.asm | RVCT
../Common/ArmLib.c
-
+
ArmV7Support.S | GCC
ArmV7Support.asm | RVCT
ArmV7Lib.c
-
+
ArmV7ArchTimer.c
ArmV7ArchTimerSupport.S | GCC
ArmV7ArchTimerSupport.asm | RVCT
diff --git a/ArmPkg/Library/ArmLib/ArmV7/ArmV7Mmu.c b/ArmPkg/Library/ArmLib/ArmV7/ArmV7Mmu.c index 1a5d982022..d035ff3caa 100644 --- a/ArmPkg/Library/ArmLib/ArmV7/ArmV7Mmu.c +++ b/ArmPkg/Library/ArmLib/ArmV7/ArmV7Mmu.c @@ -2,18 +2,18 @@ * File managing the MMU for ARMv7 architecture
*
* Copyright (c) 2011-2013, ARM Limited. All rights reserved.
-*
-* This program and the accompanying materials
-* are licensed and made available under the terms and conditions of the BSD License
-* which accompanies this distribution. The full text of the license may be found at
-* http://opensource.org/licenses/bsd-license.php
*
-* THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
-* WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
+* This program and the accompanying materials
+* are licensed and made available under the terms and conditions of the BSD License
+* which accompanies this distribution. The full text of the license may be found at
+* http://opensource.org/licenses/bsd-license.php
+*
+* THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
+* WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
*
**/
-#include <Uefi.h>
+#include <Uefi.h>
#include <Chipset/ArmV7.h>
#include <Library/BaseMemoryLib.h>
#include <Library/MemoryAllocationLib.h>
@@ -145,7 +145,7 @@ FillTranslationTable ( UINT32 Attributes;
UINT32 PhysicalBase = MemoryRegion->PhysicalBase;
UINT32 RemainLength = MemoryRegion->Length;
-
+
ASSERT(MemoryRegion->Length > 0);
switch (MemoryRegion->Attributes) {
@@ -177,7 +177,7 @@ FillTranslationTable ( Attributes = TT_DESCRIPTOR_SECTION_UNCACHED(0);
break;
}
-
+
// Get the first section entry for this mapping
SectionEntry = TRANSLATION_TABLE_ENTRY_FOR_VIRTUAL_ADDRESS(TranslationTable, MemoryRegion->VirtualBase);
@@ -231,7 +231,7 @@ ArmConfigureMmu ( if (TranslationTableBase != NULL) {
*TranslationTableBase = TranslationTable;
}
-
+
if (TranslationTableSize != NULL) {
*TranslationTableSize = TRANSLATION_TABLE_SECTION_SIZE;
}
@@ -251,13 +251,13 @@ ArmConfigureMmu ( }
// Translate the Memory Attributes into Translation Table Register Attributes
- if ((TranslationTableAttribute == ARM_MEMORY_REGION_ATTRIBUTE_UNCACHED_UNBUFFERED) ||
+ if ((TranslationTableAttribute == ARM_MEMORY_REGION_ATTRIBUTE_UNCACHED_UNBUFFERED) ||
(TranslationTableAttribute == ARM_MEMORY_REGION_ATTRIBUTE_NONSECURE_UNCACHED_UNBUFFERED)) {
TTBRAttributes = TTBR_NON_CACHEABLE;
- } else if ((TranslationTableAttribute == ARM_MEMORY_REGION_ATTRIBUTE_WRITE_BACK) ||
+ } else if ((TranslationTableAttribute == ARM_MEMORY_REGION_ATTRIBUTE_WRITE_BACK) ||
(TranslationTableAttribute == ARM_MEMORY_REGION_ATTRIBUTE_NONSECURE_WRITE_BACK)) {
TTBRAttributes = TTBR_WRITE_BACK_ALLOC;
- } else if ((TranslationTableAttribute == ARM_MEMORY_REGION_ATTRIBUTE_WRITE_THROUGH) ||
+ } else if ((TranslationTableAttribute == ARM_MEMORY_REGION_ATTRIBUTE_WRITE_THROUGH) ||
(TranslationTableAttribute == ARM_MEMORY_REGION_ATTRIBUTE_NONSECURE_WRITE_THROUGH)) {
TTBRAttributes = TTBR_WRITE_THROUGH_NO_ALLOC;
} else {
@@ -278,7 +278,7 @@ ArmConfigureMmu ( ArmInvalidateInstructionCache ();
ArmSetTTBR0 ((VOID *)(UINTN)(((UINTN)TranslationTable & ~TRANSLATION_TABLE_SECTION_ALIGNMENT_MASK) | (TTBRAttributes & 0x7F)));
-
+
ArmSetDomainAccessControl (DOMAIN_ACCESS_CONTROL_NONE(15) |
DOMAIN_ACCESS_CONTROL_NONE(14) |
DOMAIN_ACCESS_CONTROL_NONE(13) |
@@ -295,7 +295,7 @@ ArmConfigureMmu ( DOMAIN_ACCESS_CONTROL_NONE( 2) |
DOMAIN_ACCESS_CONTROL_NONE( 1) |
DOMAIN_ACCESS_CONTROL_MANAGER(0));
-
+
ArmEnableInstructionCache();
ArmEnableDataCache();
ArmEnableMmu();
diff --git a/ArmPkg/Library/ArmLib/ArmV7/ArmV7Support.S b/ArmPkg/Library/ArmLib/ArmV7/ArmV7Support.S index 954762717c..c31d49bcfb 100644 --- a/ArmPkg/Library/ArmLib/ArmV7/ArmV7Support.S +++ b/ArmPkg/Library/ArmLib/ArmV7/ArmV7Support.S @@ -1,4 +1,4 @@ -#------------------------------------------------------------------------------
+#------------------------------------------------------------------------------
#
# Copyright (c) 2008 - 2010, Apple Inc. All rights reserved.<BR>
# Copyright (c) 2011 - 2014, ARM Limited. All rights reserved.
@@ -63,13 +63,13 @@ GCC_ASM_EXPORT (ArmReadIdPfr1) ASM_PFX(ArmInvalidateDataCacheEntryByMVA):
- mcr p15, 0, r0, c7, c6, 1 @invalidate single data cache line
+ mcr p15, 0, r0, c7, c6, 1 @invalidate single data cache line
dsb
isb
bx lr
ASM_PFX(ArmCleanDataCacheEntryByMVA):
- mcr p15, 0, r0, c7, c10, 1 @clean single data cache line
+ mcr p15, 0, r0, c7, c10, 1 @clean single data cache line
dsb
isb
bx lr
@@ -83,21 +83,21 @@ ASM_PFX(ArmCleanInvalidateDataCacheEntryByMVA): ASM_PFX(ArmInvalidateDataCacheEntryBySetWay):
- mcr p15, 0, r0, c7, c6, 2 @ Invalidate this line
+ mcr p15, 0, r0, c7, c6, 2 @ Invalidate this line
dsb
isb
bx lr
ASM_PFX(ArmCleanInvalidateDataCacheEntryBySetWay):
- mcr p15, 0, r0, c7, c14, 2 @ Clean and Invalidate this line
+ mcr p15, 0, r0, c7, c14, 2 @ Clean and Invalidate this line
dsb
isb
bx lr
ASM_PFX(ArmCleanDataCacheEntryBySetWay):
- mcr p15, 0, r0, c7, c10, 2 @ Clean this line
+ mcr p15, 0, r0, c7, c10, 2 @ Clean this line
dsb
isb
bx lr
@@ -141,7 +141,7 @@ ASM_PFX(ArmDisableCachesAndMmu): ASM_PFX(ArmMmuEnabled):
mrc p15,0,R0,c1,c0,0
and R0,R0,#1
- bx LR
+ bx LR
ASM_PFX(ArmEnableDataCache):
ldr R1,=DC_ON
@@ -151,7 +151,7 @@ ASM_PFX(ArmEnableDataCache): dsb
isb
bx LR
-
+
ASM_PFX(ArmDisableDataCache):
ldr R1,=DC_ON
mrc p15,0,R0,c1,c0,0 @Read control register configuration data
@@ -169,7 +169,7 @@ ASM_PFX(ArmEnableInstructionCache): dsb
isb
bx LR
-
+
ASM_PFX(ArmDisableInstructionCache):
ldr R1,=IC_ON
mrc p15,0,R0,c1,c0,0 @Read control register configuration data
@@ -225,14 +225,14 @@ ASM_PFX(ArmV7AllDataCachesOperation): beq L_Finished
mov R10, #0
-Loop1:
+Loop1:
add R2, R10, R10, LSR #1 @ Work out 3xcachelevel
mov R12, R6, LSR R2 @ bottom 3 bits are the Cache type for this level
and R12, R12, #7 @ get those 3 bits alone
cmp R12, #2
blt L_Skip @ no cache or only instruction cache at this level
mcr p15, 2, R10, c0, c0, 0 @ write the Cache Size selection register (CSSELR) // OR in 1 for Instruction
- isb @ isb to sync the change to the CacheSizeID reg
+ isb @ isb to sync the change to the CacheSizeID reg
mrc p15, 1, R12, c0, c0, 0 @ reads current Cache Size ID register (CCSIDR)
and R2, R12, #0x7 @ extract the line length field
add R2, R2, #4 @ add 4 for the line length offset (log2 16 bytes)
@@ -246,10 +246,10 @@ Loop1: sub R7, R7, #1
ands R7, R7, R12, LSR #13 @ R7 is the max number of the index size (right aligned)
-Loop2:
+Loop2:
mov R9, R4 @ R9 working copy of the max way size (right aligned)
-Loop3:
+Loop3:
orr R0, R10, R9, LSL R5 @ factor in the way number and cache number into R11
orr R0, R0, R7, LSL R2 @ factor in the index number
@@ -259,11 +259,11 @@ Loop3: bge Loop3
subs R7, R7, #1 @ decrement the index
bge Loop2
-L_Skip:
+L_Skip:
add R10, R10, #2 @ increment the cache number
cmp R3, R10
bgt Loop1
-
+
L_Finished:
dsb
ldmfd SP!, {r4-r12, lr}
@@ -285,7 +285,7 @@ Loop4: cmp R12, #2
blt Skip2 @ no cache or only instruction cache at this level
mcr p15, 2, R10, c0, c0, 0 @ write the Cache Size selection register (CSSELR) // OR in 1 for Instruction
- isb @ isb to sync the change to the CacheSizeID reg
+ isb @ isb to sync the change to the CacheSizeID reg
mrc p15, 1, R12, c0, c0, 0 @ reads current Cache Size ID register (CCSIDR)
and R2, R12, #0x7 @ extract the line length field
add R2, R2, #4 @ add 4 for the line length offset (log2 16 bytes)
@@ -312,7 +312,7 @@ Skip2: add R10, R10, #2 @ increment the cache number
cmp R3, R10
bgt Loop4
-
+
Finished2:
dsb
ldmfd SP!, {r4-r12, lr}
@@ -321,12 +321,12 @@ Finished2: ASM_PFX(ArmDataMemoryBarrier):
dmb
bx LR
-
+
ASM_PFX(ArmDataSyncronizationBarrier):
ASM_PFX(ArmDrainWriteBuffer):
dsb
bx LR
-
+
ASM_PFX(ArmInstructionSynchronizationBarrier):
isb
bx LR
@@ -338,7 +338,7 @@ ASM_PFX(ArmReadVBar): ASM_PFX(ArmWriteVBar):
# Set the Address of the Vector Table in the VBAR register
- mcr p15, 0, r0, c12, c0, 0
+ mcr p15, 0, r0, c12, c0, 0
# Ensure the SCTLR.V bit is clear
mrc p15, 0, r0, c1, c0, 0 @ Read SCTLR into R0 (Read control register configuration data)
bic r0, r0, #0x00002000 @ clear V bit
@@ -376,7 +376,7 @@ ASM_PFX(ArmInvalidateInstructionAndDataTlb): ASM_PFX(ArmReadMpidr):
mrc p15, 0, r0, c0, c0, 5 @ read MPIDR
bx lr
-
+
ASM_PFX(ArmReadTpidrurw):
mrc p15, 0, r0, c13, c0, 2 @ read TPIDRURW
bx lr
diff --git a/ArmPkg/Library/ArmLib/ArmV7/ArmV7Support.asm b/ArmPkg/Library/ArmLib/ArmV7/ArmV7Support.asm index 4808c7ba74..368138933a 100644 --- a/ArmPkg/Library/ArmLib/ArmV7/ArmV7Support.asm +++ b/ArmPkg/Library/ArmLib/ArmV7/ArmV7Support.asm @@ -1,4 +1,4 @@ -//------------------------------------------------------------------------------
+//------------------------------------------------------------------------------
//
// Copyright (c) 2008 - 2010, Apple Inc. All rights reserved.<BR>
// Copyright (c) 2011 - 2014, ARM Limited. All rights reserved.
@@ -63,13 +63,13 @@ CTRL_I_BIT EQU (1 << 12) ArmInvalidateDataCacheEntryByMVA
- mcr p15, 0, r0, c7, c6, 1 ; invalidate single data cache line
+ mcr p15, 0, r0, c7, c6, 1 ; invalidate single data cache line
dsb
isb
bx lr
ArmCleanDataCacheEntryByMVA
- mcr p15, 0, r0, c7, c10, 1 ; clean single data cache line
+ mcr p15, 0, r0, c7, c10, 1 ; clean single data cache line
dsb
isb
bx lr
@@ -83,21 +83,21 @@ ArmCleanInvalidateDataCacheEntryByMVA ArmInvalidateDataCacheEntryBySetWay
- mcr p15, 0, r0, c7, c6, 2 ; Invalidate this line
+ mcr p15, 0, r0, c7, c6, 2 ; Invalidate this line
dsb
isb
bx lr
ArmCleanInvalidateDataCacheEntryBySetWay
- mcr p15, 0, r0, c7, c14, 2 ; Clean and Invalidate this line
+ mcr p15, 0, r0, c7, c14, 2 ; Clean and Invalidate this line
dsb
isb
bx lr
ArmCleanDataCacheEntryBySetWay
- mcr p15, 0, r0, c7, c10, 2 ; Clean this line
+ mcr p15, 0, r0, c7, c10, 2 ; Clean this line
dsb
isb
bx lr
@@ -150,7 +150,7 @@ ArmEnableDataCache dsb
isb
bx LR
-
+
ArmDisableDataCache
ldr R1,=DC_ON ; Specify SCTLR.C bit : (Data) Cache enable bit
mrc p15,0,R0,c1,c0,0 ; Read SCTLR into R0 (Read control register configuration data)
@@ -168,7 +168,7 @@ ArmEnableInstructionCache dsb
isb
bx LR
-
+
ArmDisableInstructionCache
ldr R1,=IC_ON ; Specify SCTLR.I bit : Instruction cache enable bit
mrc p15,0,R0,c1,c0,0 ; Read SCTLR into R0 (Read control register configuration data)
@@ -223,14 +223,14 @@ ArmV7AllDataCachesOperation beq Finished
mov R10, #0
-Loop1
+Loop1
add R2, R10, R10, LSR #1 ; Work out 3xcachelevel
mov R12, R6, LSR R2 ; bottom 3 bits are the Cache type for this level
and R12, R12, #7 ; get those 3 bits alone
cmp R12, #2
blt Skip ; no cache or only instruction cache at this level
mcr p15, 2, R10, c0, c0, 0 ; write the Cache Size selection register (CSSELR) // OR in 1 for Instruction
- isb ; isb to sync the change to the CacheSizeID reg
+ isb ; isb to sync the change to the CacheSizeID reg
mrc p15, 1, R12, c0, c0, 0 ; reads current Cache Size ID register (CCSIDR)
and R2, R12, #&7 ; extract the line length field
add R2, R2, #4 ; add 4 for the line length offset (log2 16 bytes)
@@ -240,10 +240,10 @@ Loop1 ldr R7, =0x00007FFF
ands R7, R7, R12, LSR #13 ; R7 is the max number of the index size (right aligned)
-Loop2
+Loop2
mov R9, R4 ; R9 working copy of the max way size (right aligned)
-Loop3
+Loop3
orr R0, R10, R9, LSL R5 ; factor in the way number and cache number into R11
orr R0, R0, R7, LSL R2 ; factor in the index number
@@ -253,11 +253,11 @@ Loop3 bge Loop3
subs R7, R7, #1 ; decrement the index
bge Loop2
-Skip
+Skip
add R10, R10, #2 ; increment the cache number
cmp R3, R10
bgt Loop1
-
+
Finished
dsb
ldmfd SP!, {r4-r12, lr}
@@ -272,14 +272,14 @@ ArmV7PerformPoUDataCacheOperation beq Finished2
mov R10, #0
-Loop4
+Loop4
add R2, R10, R10, LSR #1 ; Work out 3xcachelevel
mov R12, R6, LSR R2 ; bottom 3 bits are the Cache type for this level
and R12, R12, #7 ; get those 3 bits alone
cmp R12, #2
blt Skip2 ; no cache or only instruction cache at this level
mcr p15, 2, R10, c0, c0, 0 ; write the Cache Size selection register (CSSELR) // OR in 1 for Instruction
- isb ; isb to sync the change to the CacheSizeID reg
+ isb ; isb to sync the change to the CacheSizeID reg
mrc p15, 1, R12, c0, c0, 0 ; reads current Cache Size ID register (CCSIDR)
and R2, R12, #&7 ; extract the line length field
add R2, R2, #4 ; add 4 for the line length offset (log2 16 bytes)
@@ -289,10 +289,10 @@ Loop4 ldr R7, =0x00007FFF
ands R7, R7, R12, LSR #13 ; R7 is the max number of the index size (right aligned)
-Loop5
+Loop5
mov R9, R4 ; R9 working copy of the max way size (right aligned)
-Loop6
+Loop6
orr R0, R10, R9, LSL R5 ; factor in the way number and cache number into R11
orr R0, R0, R7, LSL R2 ; factor in the index number
@@ -302,11 +302,11 @@ Loop6 bge Loop6
subs R7, R7, #1 ; decrement the index
bge Loop5
-Skip2
+Skip2
add R10, R10, #2 ; increment the cache number
cmp R3, R10
bgt Loop4
-
+
Finished2
dsb
ldmfd SP!, {r4-r12, lr}
@@ -315,12 +315,12 @@ Finished2 ArmDataMemoryBarrier
dmb
bx LR
-
+
ArmDataSyncronizationBarrier
ArmDrainWriteBuffer
dsb
bx LR
-
+
ArmInstructionSynchronizationBarrier
isb
bx LR
@@ -332,7 +332,7 @@ ArmReadVBar ArmWriteVBar
// Set the Address of the Vector Table in the VBAR register
- mcr p15, 0, r0, c12, c0, 0
+ mcr p15, 0, r0, c12, c0, 0
// Ensure the SCTLR.V bit is clear
mrc p15, 0, r0, c1, c0, 0 ; Read SCTLR into R0 (Read control register configuration data)
bic r0, r0, #0x00002000 ; clear V bit
diff --git a/ArmPkg/Library/ArmLib/Common/Arm/ArmLibSupport.S b/ArmPkg/Library/ArmLib/Common/Arm/ArmLibSupport.S index 08a433cc82..43842f325e 100644 --- a/ArmPkg/Library/ArmLib/Common/Arm/ArmLibSupport.S +++ b/ArmPkg/Library/ArmLib/Common/Arm/ArmLibSupport.S @@ -1,4 +1,4 @@ -#------------------------------------------------------------------------------
+#------------------------------------------------------------------------------
#
# Copyright (c) 2008 - 2009, Apple Inc. All rights reserved.<BR>
# Copyright (c) 2011 - 2014, ARM Limited. All rights reserved.
@@ -110,7 +110,7 @@ ASM_PFX(ArmWriteAuxCr): ASM_PFX(ArmReadAuxCr):
mrc p15, 0, r0, c1, c0, 1
- bx lr
+ bx lr
ASM_PFX(ArmSetTTBR0):
mcr p15,0,r0,c2,c0,0
@@ -133,7 +133,7 @@ ASM_PFX(ArmGetTTBR0BaseAddress): ASM_PFX(ArmUpdateTranslationTableEntry):
mcr p15,0,R0,c7,c14,1 @ DCCIMVAC Clean data cache by MVA
dsb
- mcr p15,0,R1,c8,c7,1 @ TLBIMVA TLB Invalidate MVA
+ mcr p15,0,R1,c8,c7,1 @ TLBIMVA TLB Invalidate MVA
mcr p15,0,R9,c7,c5,6 @ BPIALL Invalidate Branch predictor array. R9 == NoOp
dsb
isb
diff --git a/ArmPkg/Library/ArmLib/Common/Arm/ArmLibSupport.asm b/ArmPkg/Library/ArmLib/Common/Arm/ArmLibSupport.asm index 9e6d57ef6f..6d6665b3ce 100644 --- a/ArmPkg/Library/ArmLib/Common/Arm/ArmLibSupport.asm +++ b/ArmPkg/Library/ArmLib/Common/Arm/ArmLibSupport.asm @@ -1,4 +1,4 @@ -//------------------------------------------------------------------------------
+//------------------------------------------------------------------------------
//
// Copyright (c) 2008 - 2009, Apple Inc. All rights reserved.<BR>
// Copyright (c) 2011 - 2014, ARM Limited. All rights reserved.
@@ -14,7 +14,7 @@ //------------------------------------------------------------------------------
#include <AsmMacroIoLib.h>
-
+
INCLUDE AsmMacroIoLib.inc
#ifdef ARM_CPU_ARMv6
@@ -110,7 +110,7 @@ ArmWriteAuxCr ArmReadAuxCr
mrc p15, 0, r0, c1, c0, 1
- bx lr
+ bx lr
ArmSetTTBR0
mcr p15,0,r0,c2,c0,0
@@ -170,7 +170,7 @@ ArmReadMVBar ArmWriteMVBar
mcr p15, 0, r0, c12, c0, 1
bx lr
-
+
ArmCallWFE
wfe
bx lr
diff --git a/ArmPkg/Library/ArmLib/Common/ArmLib.c b/ArmPkg/Library/ArmLib/Common/ArmLib.c index 72d5af4a55..d7316972b7 100644 --- a/ArmPkg/Library/ArmLib/Common/ArmLib.c +++ b/ArmPkg/Library/ArmLib/Common/ArmLib.c @@ -2,7 +2,7 @@ Copyright (c) 2008 - 2009, Apple Inc. All rights reserved.<BR>
Copyright (c) 2011 - 2014, ARM Ltd. All rights reserved.<BR>
-
+
This program and the accompanying materials
are licensed and made available under the terms and conditions of the BSD License
which accompanies this distribution. The full text of the license may be found at
diff --git a/ArmPkg/Library/ArmLib/Common/ArmLibPrivate.h b/ArmPkg/Library/ArmLib/Common/ArmLibPrivate.h index 25a043d03b..fdd5a26ba0 100644 --- a/ArmPkg/Library/ArmLib/Common/ArmLibPrivate.h +++ b/ArmPkg/Library/ArmLib/Common/ArmLibPrivate.h @@ -67,11 +67,11 @@ CPSRRead ( VOID
);
-UINT32
+UINT32
ReadCCSIDR (
IN UINT32 CSSELR
- );
-
+ );
+
UINT32
ReadCLIDR (
VOID
diff --git a/ArmPkg/Library/ArmLib/Null/NullArmCacheInformation.c b/ArmPkg/Library/ArmLib/Null/NullArmCacheInformation.c index 3ee0b9cf00..2eeb42e1b7 100644 --- a/ArmPkg/Library/ArmLib/Null/NullArmCacheInformation.c +++ b/ArmPkg/Library/ArmLib/Null/NullArmCacheInformation.c @@ -1,7 +1,7 @@ /** @file
Copyright (c) 2008 - 2009, Apple Inc. All rights reserved.<BR>
-
+
This program and the accompanying materials
are licensed and made available under the terms and conditions of the BSD License
which accompanies this distribution. The full text of the license may be found at
@@ -41,16 +41,16 @@ ArmDataCachePresent ( {
return FALSE;
}
-
+
UINTN
EFIAPI
ArmDataCacheSize (
VOID
)
{
- return 0;
+ return 0;
}
-
+
UINTN
EFIAPI
ArmDataCacheAssociativity (
@@ -59,7 +59,7 @@ ArmDataCacheAssociativity ( {
return 0;
}
-
+
UINTN
EFIAPI
ArmDataCacheLineLength (
@@ -68,7 +68,7 @@ ArmDataCacheLineLength ( {
return 0;
}
-
+
BOOLEAN
EFIAPI
ArmInstructionCachePresent (
@@ -77,16 +77,16 @@ ArmInstructionCachePresent ( {
return FALSE;
}
-
+
UINTN
EFIAPI
ArmInstructionCacheSize (
VOID
)
{
- return 0;
+ return 0;
}
-
+
UINTN
EFIAPI
ArmInstructionCacheAssociativity (
@@ -95,7 +95,7 @@ ArmInstructionCacheAssociativity ( {
return 0;
}
-
+
UINTN
EFIAPI
ArmInstructionCacheLineLength (
diff --git a/ArmPkg/Library/ArmLib/Null/NullArmLib.c b/ArmPkg/Library/ArmLib/Null/NullArmLib.c index a9c85a1740..e7e9c52547 100644 --- a/ArmPkg/Library/ArmLib/Null/NullArmLib.c +++ b/ArmPkg/Library/ArmLib/Null/NullArmLib.c @@ -1,7 +1,7 @@ /** @file
Copyright (c) 2008 - 2009, Apple Inc. All rights reserved.<BR>
-
+
This program and the accompanying materials
are licensed and made available under the terms and conditions of the BSD License
which accompanies this distribution. The full text of the license may be found at
diff --git a/ArmPkg/Library/ArmSmcLib/ArmSmcLib.inf b/ArmPkg/Library/ArmSmcLib/ArmSmcLib.inf index e4f64058dc..9f9ba72996 100644 --- a/ArmPkg/Library/ArmSmcLib/ArmSmcLib.inf +++ b/ArmPkg/Library/ArmSmcLib/ArmSmcLib.inf @@ -1,24 +1,24 @@ #/** @file
-#
+#
# Copyright (c) 2012-2013, ARM Ltd. All rights reserved.<BR>
# This program and the accompanying materials
# are licensed and made available under the terms and conditions of the BSD License
# which accompanies this distribution. The full text of the license may be found at
# http://opensource.org/licenses/bsd-license.php
-#
+#
# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
-#
+#
#**/
[Defines]
INF_VERSION = 0x00010005
BASE_NAME = ArmSmcLib
- FILE_GUID = eb3f17d5-a3cc-4eac-8912-84162d0f79da
+ FILE_GUID = eb3f17d5-a3cc-4eac-8912-84162d0f79da
MODULE_TYPE = BASE
VERSION_STRING = 1.0
LIBRARY_CLASS = ArmSmcLib
-
+
[Sources.ARM]
Arm/ArmSmc.asm | RVCT
Arm/ArmSmc.S | GCC
diff --git a/ArmPkg/Library/ArmSmcLibNull/ArmSmcLibNull.inf b/ArmPkg/Library/ArmSmcLibNull/ArmSmcLibNull.inf index ebe1ae14d6..6d75c28afb 100644 --- a/ArmPkg/Library/ArmSmcLibNull/ArmSmcLibNull.inf +++ b/ArmPkg/Library/ArmSmcLibNull/ArmSmcLibNull.inf @@ -1,5 +1,5 @@ #/** @file
-#
+#
# ArmSmcLib when no SMC support is desired (might be the case for CPU without the
# Trustzone support / ARM Security Extension)
#
@@ -8,7 +8,7 @@ # are licensed and made available under the terms and conditions of the BSD License
# which accompanies this distribution. The full text of the license may be found at
# http://opensource.org/licenses/bsd-license.php
-#
+#
# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
#
@@ -21,7 +21,7 @@ MODULE_TYPE = BASE
VERSION_STRING = 1.0
LIBRARY_CLASS = ArmSmcLib
-
+
[Sources.ARM]
Arm/ArmSmcNull.asm | RVCT
Arm/ArmSmcNull.S | GCC
diff --git a/ArmPkg/Library/BaseMemoryLibStm/Arm/CopyMem.S b/ArmPkg/Library/BaseMemoryLibStm/Arm/CopyMem.S index 4e0122bdec..7985b59279 100755 --- a/ArmPkg/Library/BaseMemoryLibStm/Arm/CopyMem.S +++ b/ArmPkg/Library/BaseMemoryLibStm/Arm/CopyMem.S @@ -1,10 +1,10 @@ -#------------------------------------------------------------------------------
+#------------------------------------------------------------------------------
#
# CopyMem() worker for ARM
#
# This file started out as C code that did 64 bit moves if the buffer was
# 32-bit aligned, else it does a byte copy. It also does a byte copy for
-# any trailing bytes. It was updated to do 32-byte copies using stm/ldm.
+# any trailing bytes. It was updated to do 32-byte copies using stm/ldm.
#
# Copyright (c) 2008 - 2010, Apple Inc. All rights reserved.<BR>
# This program and the accompanying materials
@@ -20,7 +20,7 @@ /**
Copy Length bytes from Source to Destination. Overlap is OK.
- This implementation
+ This implementation
@param Destination Target of copy
@param Source Place to copy from
@@ -48,7 +48,7 @@ ASM_PFX(InternalMemCopyMem): mov r10, r0
mov r12, r2
mov r14, r1
-
+
memcopy_check_overlapped:
cmp r11, r1
// If (dest < source)
@@ -61,10 +61,10 @@ memcopy_check_overlapped: cmp r12, r3
bcc memcopy_check_optim_default
- // If (length == 0)
+ // If (length == 0)
cmp r12, #0
beq memcopy_end
-
+
b memcopy_check_optim_overlap
memcopy_check_optim_default:
@@ -79,7 +79,7 @@ memcopy_check_optim_default: movls r0, #0
andhi r0, r3, #1
b memcopy_default
-
+
memcopy_check_optim_overlap:
// r10 = dest_end, r14 = source_end
add r10, r11, r12
@@ -94,12 +94,12 @@ memcopy_check_optim_overlap: tst r14, #0xF
movne r0, #0
b memcopy_overlapped
-
+
memcopy_overlapped_non_optim:
// We read 1 byte from the end of the source buffer
sub r3, r14, #1
sub r12, r12, #1
- ldrb r3, [r3, #0]
+ ldrb r3, [r3, #0]
sub r2, r10, #1
cmp r12, #0
// We write 1 byte at the end of the dest buffer
@@ -114,58 +114,58 @@ memcopy_overlapped: // Are we in the optimized case ?
cmp r0, #0
beq memcopy_overlapped_non_optim
-
+
// Optimized Overlapped - Read 32 bytes
sub r14, r14, #32
sub r12, r12, #32
cmp r12, #31
ldmia r14, {r2-r9}
-
+
// If length is less than 32 then disable optim
movls r0, #0
-
+
cmp r12, #0
-
- // Optimized Overlapped - Write 32 bytes
+
+ // Optimized Overlapped - Write 32 bytes
sub r10, r10, #32
stmia r10, {r2-r9}
-
+
// while (length != 0)
bne memcopy_overlapped
b memcopy_end
-
+
memcopy_default_non_optim:
// Byte copy
- ldrb r3, [r14], #1
+ ldrb r3, [r14], #1
sub r12, r12, #1
strb r3, [r10], #1
-
+
memcopy_default:
cmp r12, #0
beq memcopy_end
-
+
// r10 = dest, r14 = source
memcopy_default_loop:
cmp r0, #0
beq memcopy_default_non_optim
-
+
// Optimized memcopy - Read 32 Bytes
sub r12, r12, #32
cmp r12, #31
ldmia r14!, {r2-r9}
-
+
// If length is less than 32 then disable optim
movls r0, #0
-
+
cmp r12, #0
-
+
// Optimized memcopy - Write 32 Bytes
stmia r10!, {r2-r9}
// while (length != 0)
bne memcopy_default_loop
-
+
memcopy_end:
mov r0, r11
ldmfd sp!, {r4-r11, pc}
-
+
diff --git a/ArmPkg/Library/BaseMemoryLibStm/Arm/CopyMem.asm b/ArmPkg/Library/BaseMemoryLibStm/Arm/CopyMem.asm index d0faa00d1e..0d22d7577d 100755 --- a/ArmPkg/Library/BaseMemoryLibStm/Arm/CopyMem.asm +++ b/ArmPkg/Library/BaseMemoryLibStm/Arm/CopyMem.asm @@ -1,4 +1,4 @@ -;------------------------------------------------------------------------------
+;------------------------------------------------------------------------------
;
; CopyMem() worker for ARM
;
@@ -20,7 +20,7 @@ /**
Copy Length bytes from Source to Destination. Overlap is OK.
- This implementation
+ This implementation
@param Destination Target of copy
@param Source Place to copy from
@@ -48,7 +48,7 @@ InternalMemCopyMem mov r10, r0
mov r12, r2
mov r14, r1
-
+
memcopy_check_overlapped
cmp r11, r1
// If (dest < source)
@@ -61,10 +61,10 @@ memcopy_check_overlapped cmp r12, r3
bcc memcopy_check_optim_default
- // If (length == 0)
+ // If (length == 0)
cmp r12, #0
beq memcopy_end
-
+
b memcopy_check_optim_overlap
memcopy_check_optim_default
@@ -79,7 +79,7 @@ memcopy_check_optim_default movls r0, #0
andhi r0, r3, #1
b memcopy_default
-
+
memcopy_check_optim_overlap
// r10 = dest_end, r14 = source_end
add r10, r11, r12
@@ -94,12 +94,12 @@ memcopy_check_optim_overlap tst r14, #0xF
movne r0, #0
b memcopy_overlapped
-
+
memcopy_overlapped_non_optim
// We read 1 byte from the end of the source buffer
sub r3, r14, #1
sub r12, r12, #1
- ldrb r3, [r3, #0]
+ ldrb r3, [r3, #0]
sub r2, r10, #1
cmp r12, #0
// We write 1 byte at the end of the dest buffer
@@ -114,60 +114,60 @@ memcopy_overlapped // Are we in the optimized case ?
cmp r0, #0
beq memcopy_overlapped_non_optim
-
+
// Optimized Overlapped - Read 32 bytes
sub r14, r14, #32
sub r12, r12, #32
cmp r12, #31
ldmia r14, {r2-r9}
-
+
// If length is less than 32 then disable optim
movls r0, #0
-
+
cmp r12, #0
-
- // Optimized Overlapped - Write 32 bytes
+
+ // Optimized Overlapped - Write 32 bytes
sub r10, r10, #32
stmia r10, {r2-r9}
-
+
// while (length != 0)
bne memcopy_overlapped
b memcopy_end
-
+
memcopy_default_non_optim
// Byte copy
- ldrb r3, [r14], #1
+ ldrb r3, [r14], #1
sub r12, r12, #1
strb r3, [r10], #1
-
+
memcopy_default
cmp r12, #0
beq memcopy_end
-
+
// r10 = dest, r14 = source
memcopy_default_loop
cmp r0, #0
beq memcopy_default_non_optim
-
+
// Optimized memcopy - Read 32 Bytes
sub r12, r12, #32
cmp r12, #31
ldmia r14!, {r2-r9}
-
+
// If length is less than 32 then disable optim
movls r0, #0
-
+
cmp r12, #0
-
+
// Optimized memcopy - Write 32 Bytes
stmia r10!, {r2-r9}
// while (length != 0)
bne memcopy_default_loop
-
+
memcopy_end
mov r0, r11
ldmfd sp!, {r4-r11, pc}
-
+
END
-
+
diff --git a/ArmPkg/Library/BaseMemoryLibStm/Arm/SetMem.S b/ArmPkg/Library/BaseMemoryLibStm/Arm/SetMem.S index 49ebf3c2f5..c5b4cfe15f 100755 --- a/ArmPkg/Library/BaseMemoryLibStm/Arm/SetMem.S +++ b/ArmPkg/Library/BaseMemoryLibStm/Arm/SetMem.S @@ -1,10 +1,10 @@ -#------------------------------------------------------------------------------
+#------------------------------------------------------------------------------
#
# SemMem() worker for ARM
#
# This file started out as C code that did 64 bit moves if the buffer was
# 32-bit aligned, else it does a byte copy. It also does a byte copy for
-# any trailing bytes. It was updated to do 32-byte at a time.
+# any trailing bytes. It was updated to do 32-byte at a time.
#
# Copyright (c) 2008 - 2010, Apple Inc. All rights reserved.<BR>
# This program and the accompanying materials
@@ -34,7 +34,7 @@ InternalMemSetMem ( IN UINT8 Value
)
**/
-
+
.text
.align 2
GCC_ASM_EXPORT(InternalMemSetMem)
@@ -56,14 +56,14 @@ L32: L31:
and r4, r2, #0xff
orr r4, r4, r4, LSL #8
- orr r4, r4, r4, LSL #16
+ orr r4, r4, r4, LSL #16
mov r5, r4
mov r6, r4
- mov r7, r4
- mov r8, r4
- mov r9, r4
- mov r10, r4
- mov r11, r4
+ mov r7, r4
+ mov r8, r4
+ mov r9, r4
+ mov r10, r4
+ mov r11, r4
b L32
L34:
cmp lr, #0
@@ -78,4 +78,4 @@ L43: cmp r1, #0
bne L34
ldmfd sp!, {r4-r11, pc}
-
+
diff --git a/ArmPkg/Library/BaseMemoryLibStm/Arm/SetMem.asm b/ArmPkg/Library/BaseMemoryLibStm/Arm/SetMem.asm index 3cc753ccc6..a9f29e2306 100755 --- a/ArmPkg/Library/BaseMemoryLibStm/Arm/SetMem.asm +++ b/ArmPkg/Library/BaseMemoryLibStm/Arm/SetMem.asm @@ -1,4 +1,4 @@ -;------------------------------------------------------------------------------
+;------------------------------------------------------------------------------
;
; SetMem() worker for ARM
;
@@ -33,9 +33,9 @@ InternalMemSetMem ( IN UINT8 Value
)
**/
-
+
EXPORT InternalMemSetMem
-
+
AREA AsmMemStuff, CODE, READONLY
InternalMemSetMem
@@ -55,14 +55,14 @@ L32 L31
and r4, r2, #0xff
orr r4, r4, r4, LSL #8
- orr r4, r4, r4, LSL #16
+ orr r4, r4, r4, LSL #16
mov r5, r4
mov r6, r4
- mov r7, r4
- mov r8, r4
- mov r9, r4
- mov r10, r4
- mov r11, r4
+ mov r7, r4
+ mov r8, r4
+ mov r9, r4
+ mov r10, r4
+ mov r11, r4
b L32
L34
cmp lr, #0
@@ -77,5 +77,5 @@ L43 cmp r1, #0
bne L34
ldmfd sp!, {r4-r11, pc}
-
+
END
diff --git a/ArmPkg/Library/BaseMemoryLibStm/BaseMemoryLibStm.inf b/ArmPkg/Library/BaseMemoryLibStm/BaseMemoryLibStm.inf index a4d28036b6..c2f3e2f0b6 100755 --- a/ArmPkg/Library/BaseMemoryLibStm/BaseMemoryLibStm.inf +++ b/ArmPkg/Library/BaseMemoryLibStm/BaseMemoryLibStm.inf @@ -1,8 +1,8 @@ ## @file
# Instance of Base Memory Library with some ARM ldm/stm assembly.
#
-# This is a copy of the MdePkg BaseMemoryLib with the CopyMem and
-# SetMem worker functions replaced with assembler that uses
+# This is a copy of the MdePkg BaseMemoryLib with the CopyMem and
+# SetMem worker functions replaced with assembler that uses
# ldm/stm.
#
# Copyright (c) 2007 - 2010, Intel Corporation. All rights reserved.<BR>
@@ -25,7 +25,7 @@ FILE_GUID = 4D466AF3-2380-448D-A337-E4033F29F3F7
MODULE_TYPE = BASE
VERSION_STRING = 1.0
- LIBRARY_CLASS = BaseMemoryLib
+ LIBRARY_CLASS = BaseMemoryLib
#
@@ -46,7 +46,7 @@ SetMemWrapper.c
CopyMemWrapper.c
MemLibGeneric.c
- MemLibGuid.c
+ MemLibGuid.c
MemLibInternals.h
[Sources.ARM]
diff --git a/ArmPkg/Library/BaseMemoryLibStm/CompareMemWrapper.c b/ArmPkg/Library/BaseMemoryLibStm/CompareMemWrapper.c index 9695c5b51b..c83988f59e 100755 --- a/ArmPkg/Library/BaseMemoryLibStm/CompareMemWrapper.c +++ b/ArmPkg/Library/BaseMemoryLibStm/CompareMemWrapper.c @@ -31,7 +31,7 @@ WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED. If all Length bytes of the two buffers are identical, then 0 is returned. Otherwise, the
value returned is the first mismatched byte in SourceBuffer subtracted from the first
mismatched byte in DestinationBuffer.
-
+
If Length > 0 and DestinationBuffer is NULL, then ASSERT().
If Length > 0 and SourceBuffer is NULL, then ASSERT().
If Length is greater than (MAX_ADDRESS - DestinationBuffer + 1), then ASSERT().
@@ -44,7 +44,7 @@ WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED. @return 0 All Length bytes of the two buffers are identical.
@retval Non-zero The first mismatched byte in SourceBuffer subtracted from the first
mismatched byte in DestinationBuffer.
-
+
**/
INTN
EFIAPI
diff --git a/ArmPkg/Library/BaseMemoryLibStm/CopyMemWrapper.c b/ArmPkg/Library/BaseMemoryLibStm/CopyMemWrapper.c index 5fca133643..2adfb31149 100755 --- a/ArmPkg/Library/BaseMemoryLibStm/CopyMemWrapper.c +++ b/ArmPkg/Library/BaseMemoryLibStm/CopyMemWrapper.c @@ -2,7 +2,7 @@ CopyMem() implementation.
The following BaseMemoryLib instances contain the same copy of this file:
-
+
BaseMemoryLib
BaseMemoryLibMmx
BaseMemoryLibSse2
@@ -31,7 +31,7 @@ This function copies Length bytes from SourceBuffer to DestinationBuffer, and returns
DestinationBuffer. The implementation must be reentrant, and it must handle the case
where SourceBuffer overlaps DestinationBuffer.
-
+
If Length is greater than (MAX_ADDRESS - DestinationBuffer + 1), then ASSERT().
If Length is greater than (MAX_ADDRESS - SourceBuffer + 1), then ASSERT().
diff --git a/ArmPkg/Library/BaseMemoryLibStm/MemLibGuid.c b/ArmPkg/Library/BaseMemoryLibStm/MemLibGuid.c index 1d90a8bca2..2b4ed57755 100755 --- a/ArmPkg/Library/BaseMemoryLibStm/MemLibGuid.c +++ b/ArmPkg/Library/BaseMemoryLibStm/MemLibGuid.c @@ -2,7 +2,7 @@ Implementation of GUID functions.
The following BaseMemoryLib instances contain the same copy of this file:
-
+
BaseMemoryLib
BaseMemoryLibMmx
BaseMemoryLibSse2
@@ -30,7 +30,7 @@ This function copies the contents of the 128-bit GUID specified by SourceGuid to
DestinationGuid, and returns DestinationGuid.
-
+
If DestinationGuid is NULL, then ASSERT().
If SourceGuid is NULL, then ASSERT().
@@ -63,7 +63,7 @@ CopyGuid ( This function compares Guid1 to Guid2. If the GUIDs are identical then TRUE is returned.
If there are any bit differences in the two GUIDs, then FALSE is returned.
-
+
If Guid1 is NULL, then ASSERT().
If Guid2 is NULL, then ASSERT().
@@ -93,7 +93,7 @@ CompareGuid ( GUID value that matches Guid. If a match is found, then a pointer to the matching
GUID in the target buffer is returned. If no match is found, then NULL is returned.
If Length is 0, then NULL is returned.
-
+
If Length > 0 and Buffer is NULL, then ASSERT().
If Buffer is not aligned on a 32-bit boundary, then ASSERT().
If Length is not aligned on a 128-bit boundary, then ASSERT().
diff --git a/ArmPkg/Library/BaseMemoryLibStm/ScanMem16Wrapper.c b/ArmPkg/Library/BaseMemoryLibStm/ScanMem16Wrapper.c index 3dc2d291c1..1c727b3e80 100755 --- a/ArmPkg/Library/BaseMemoryLibStm/ScanMem16Wrapper.c +++ b/ArmPkg/Library/BaseMemoryLibStm/ScanMem16Wrapper.c @@ -33,7 +33,7 @@ address to the highest address for a 16-bit value that matches Value. If a match is found,
then a pointer to the matching byte in the target buffer is returned. If no match is found,
then NULL is returned. If Length is 0, then NULL is returned.
-
+
If Length > 0 and Buffer is NULL, then ASSERT().
If Buffer is not aligned on a 16-bit boundary, then ASSERT().
If Length is not aligned on a 16-bit boundary, then ASSERT().
diff --git a/ArmPkg/Library/BaseMemoryLibStm/ScanMem32Wrapper.c b/ArmPkg/Library/BaseMemoryLibStm/ScanMem32Wrapper.c index 1c47131b59..79ab60ced8 100755 --- a/ArmPkg/Library/BaseMemoryLibStm/ScanMem32Wrapper.c +++ b/ArmPkg/Library/BaseMemoryLibStm/ScanMem32Wrapper.c @@ -32,7 +32,7 @@ address to the highest address for a 32-bit value that matches Value. If a match is found,
then a pointer to the matching byte in the target buffer is returned. If no match is found,
then NULL is returned. If Length is 0, then NULL is returned.
-
+
If Length > 0 and Buffer is NULL, then ASSERT().
If Buffer is not aligned on a 32-bit boundary, then ASSERT().
If Length is not aligned on a 32-bit boundary, then ASSERT().
diff --git a/ArmPkg/Library/BaseMemoryLibStm/ScanMem64Wrapper.c b/ArmPkg/Library/BaseMemoryLibStm/ScanMem64Wrapper.c index 5161b29cad..d11e50b9d5 100755 --- a/ArmPkg/Library/BaseMemoryLibStm/ScanMem64Wrapper.c +++ b/ArmPkg/Library/BaseMemoryLibStm/ScanMem64Wrapper.c @@ -33,7 +33,7 @@ address to the highest address for a 64-bit value that matches Value. If a match is found,
then a pointer to the matching byte in the target buffer is returned. If no match is found,
then NULL is returned. If Length is 0, then NULL is returned.
-
+
If Length > 0 and Buffer is NULL, then ASSERT().
If Buffer is not aligned on a 64-bit boundary, then ASSERT().
If Length is not aligned on a 64-bit boundary, then ASSERT().
diff --git a/ArmPkg/Library/BaseMemoryLibStm/ScanMem8Wrapper.c b/ArmPkg/Library/BaseMemoryLibStm/ScanMem8Wrapper.c index c547cb46e1..c6c6d5f39b 100755 --- a/ArmPkg/Library/BaseMemoryLibStm/ScanMem8Wrapper.c +++ b/ArmPkg/Library/BaseMemoryLibStm/ScanMem8Wrapper.c @@ -33,7 +33,7 @@ address to the highest address for an 8-bit value that matches Value. If a match is found,
then a pointer to the matching byte in the target buffer is returned. If no match is found,
then NULL is returned. If Length is 0, then NULL is returned.
-
+
If Length > 0 and Buffer is NULL, then ASSERT().
If Length is greater than (MAX_ADDRESS - Buffer + 1), then ASSERT().
@@ -57,19 +57,19 @@ ScanMem8 ( }
ASSERT (Buffer != NULL);
ASSERT ((Length - 1) <= (MAX_ADDRESS - (UINTN)Buffer));
-
+
return (VOID*)InternalMemScanMem8 (Buffer, Length, Value);
}
/**
- Scans a target buffer for a UINTN sized value, and returns a pointer to the matching
+ Scans a target buffer for a UINTN sized value, and returns a pointer to the matching
UINTN sized value in the target buffer.
This function searches the target buffer specified by Buffer and Length from the lowest
address to the highest address for a UINTN sized value that matches Value. If a match is found,
then a pointer to the matching byte in the target buffer is returned. If no match is found,
then NULL is returned. If Length is 0, then NULL is returned.
-
+
If Length > 0 and Buffer is NULL, then ASSERT().
If Buffer is not aligned on a UINTN boundary, then ASSERT().
If Length is not aligned on a UINTN boundary, then ASSERT().
diff --git a/ArmPkg/Library/BaseMemoryLibStm/SetMemWrapper.c b/ArmPkg/Library/BaseMemoryLibStm/SetMemWrapper.c index 6d6ec38ae2..9240c89e8b 100755 --- a/ArmPkg/Library/BaseMemoryLibStm/SetMemWrapper.c +++ b/ArmPkg/Library/BaseMemoryLibStm/SetMemWrapper.c @@ -29,7 +29,7 @@ Fills a target buffer with a byte value, and returns the target buffer.
This function fills Length bytes of Buffer with Value, and returns Buffer.
-
+
If Length is greater than (MAX_ADDRESS - Buffer + 1), then ASSERT().
@param Buffer Memory to set.
diff --git a/ArmPkg/Library/BaseMemoryLibStm/ZeroMemWrapper.c b/ArmPkg/Library/BaseMemoryLibStm/ZeroMemWrapper.c index 89520348ba..d6c6279f68 100755 --- a/ArmPkg/Library/BaseMemoryLibStm/ZeroMemWrapper.c +++ b/ArmPkg/Library/BaseMemoryLibStm/ZeroMemWrapper.c @@ -11,7 +11,7 @@ BaseMemoryLibOptPei
PeiMemoryLib
UefiMemoryLib
-
+
Copyright (c) 2006 - 2009, Intel Corporation. All rights reserved.<BR>
This program and the accompanying materials
are licensed and made available under the terms and conditions of the BSD License
@@ -29,7 +29,7 @@ Fills a target buffer with zeros, and returns the target buffer.
This function fills Length bytes of Buffer with zeros, and returns Buffer.
-
+
If Length > 0 and Buffer is NULL, then ASSERT().
If Length is greater than (MAX_ADDRESS - Buffer + 1), then ASSERT().
diff --git a/ArmPkg/Library/BaseMemoryLibVstm/Arm/CopyMem.S b/ArmPkg/Library/BaseMemoryLibVstm/Arm/CopyMem.S index 8cfd9a9c50..0a6e039af9 100755 --- a/ArmPkg/Library/BaseMemoryLibVstm/Arm/CopyMem.S +++ b/ArmPkg/Library/BaseMemoryLibVstm/Arm/CopyMem.S @@ -1,4 +1,4 @@ -#------------------------------------------------------------------------------
+#------------------------------------------------------------------------------
#
# CopyMem() worker for ARM
#
@@ -20,7 +20,7 @@ /**
Copy Length bytes from Source to Destination. Overlap is OK.
- This implementation
+ This implementation
@param Destination Target of copy
@param Source Place to copy from
@@ -81,7 +81,7 @@ L16: bne L29
sub r3, lr, #1
sub ip, ip, #1
- ldrb r3, [r3, #0]
+ ldrb r3, [r3, #0]
sub r2, r9, #1
cmp ip, #0
sub r9, r9, #1
@@ -90,7 +90,7 @@ L16: bne L16
b L7
L11:
- ldrb r3, [lr], #1
+ ldrb r3, [lr], #1
sub ip, ip, #1
strb r3, [r9], #1
L26:
@@ -111,4 +111,4 @@ L7: mov r0, r4
ldmfd sp!, {r4, r9, pc}
-
+
diff --git a/ArmPkg/Library/BaseMemoryLibVstm/Arm/CopyMem.asm b/ArmPkg/Library/BaseMemoryLibVstm/Arm/CopyMem.asm index 5df7c6b794..17b79e58b7 100755 --- a/ArmPkg/Library/BaseMemoryLibVstm/Arm/CopyMem.asm +++ b/ArmPkg/Library/BaseMemoryLibVstm/Arm/CopyMem.asm @@ -1,4 +1,4 @@ -;------------------------------------------------------------------------------
+;------------------------------------------------------------------------------
;
; CopyMem() worker for ARM
;
@@ -20,7 +20,7 @@ /**
Copy Length bytes from Source to Destination. Overlap is OK.
- This implementation
+ This implementation
@param Destination Target of copy
@param Source Place to copy from
@@ -81,7 +81,7 @@ L16 bne L29
sub r3, lr, #1
sub ip, ip, #1
- ldrb r3, [r3, #0]
+ ldrb r3, [r3, #0]
sub r2, r9, #1
cmp ip, #0
sub r9, r9, #1
@@ -90,7 +90,7 @@ L16 bne L16
b L7
L11
- ldrb r3, [lr], #1
+ ldrb r3, [lr], #1
sub ip, ip, #1
strb r3, [r9], #1
L26
@@ -112,4 +112,4 @@ L7 ldmfd sp!, {r4, r9, pc}
END
-
+
diff --git a/ArmPkg/Library/BaseMemoryLibVstm/Arm/SetMem.S b/ArmPkg/Library/BaseMemoryLibVstm/Arm/SetMem.S index 0415ed7091..6a6bb20ec1 100755 --- a/ArmPkg/Library/BaseMemoryLibVstm/Arm/SetMem.S +++ b/ArmPkg/Library/BaseMemoryLibVstm/Arm/SetMem.S @@ -1,4 +1,4 @@ -#------------------------------------------------------------------------------
+#------------------------------------------------------------------------------
#
# SemMem() worker for ARM
#
@@ -34,7 +34,7 @@ InternalMemSetMem ( IN UINT8 Value
)
**/
-
+
.text
.align 2
GCC_ASM_EXPORT(InternalMemSetMem)
@@ -77,4 +77,3 @@ L43: cmp r1, #0
bne L34
ldmfd sp!, {pc}
-
\ No newline at end of file diff --git a/ArmPkg/Library/BaseMemoryLibVstm/Arm/SetMem.asm b/ArmPkg/Library/BaseMemoryLibVstm/Arm/SetMem.asm index de438d6c56..5226192371 100755 --- a/ArmPkg/Library/BaseMemoryLibVstm/Arm/SetMem.asm +++ b/ArmPkg/Library/BaseMemoryLibVstm/Arm/SetMem.asm @@ -1,4 +1,4 @@ -;------------------------------------------------------------------------------
+;------------------------------------------------------------------------------
;
; SetMem() worker for ARM
;
@@ -33,9 +33,9 @@ InternalMemSetMem ( IN UINT8 Value
)
**/
-
+
EXPORT InternalMemSetMem
-
+
AREA AsmMemStuff, CODE, READONLY
InternalMemSetMem
@@ -75,6 +75,5 @@ L43 cmp r1, #0
bne L34
ldmfd sp!, {pc}
-
+
END
-
\ No newline at end of file diff --git a/ArmPkg/Library/BaseMemoryLibVstm/BaseMemoryLibVstm.inf b/ArmPkg/Library/BaseMemoryLibVstm/BaseMemoryLibVstm.inf index b4b3eb0a17..eaff180f09 100755 --- a/ArmPkg/Library/BaseMemoryLibVstm/BaseMemoryLibVstm.inf +++ b/ArmPkg/Library/BaseMemoryLibVstm/BaseMemoryLibVstm.inf @@ -1,8 +1,8 @@ ## @file
# Instance of Base Memory Library with some ARM vldm/vstm assembly.
#
-# This is a copy of the MdePkg BaseMemoryLib with the CopyMem and
-# SetMem worker functions replaced with assembler that uses
+# This is a copy of the MdePkg BaseMemoryLib with the CopyMem and
+# SetMem worker functions replaced with assembler that uses
# vldm/vstm (part of NEON SIMD, optional in ARMv7-A).
#
# Note: You need to enable NEON in SEC to use this library
@@ -32,7 +32,7 @@ FILE_GUID = 09EE1E8D-7A2E-4573-8117-68A18569C1F5
MODULE_TYPE = BASE
VERSION_STRING = 1.0
- LIBRARY_CLASS = BaseMemoryLib
+ LIBRARY_CLASS = BaseMemoryLib
#
@@ -52,7 +52,7 @@ SetMemWrapper.c
CopyMemWrapper.c
MemLibGeneric.c
- MemLibGuid.c
+ MemLibGuid.c
MemLibInternals.h
Arm/CopyMem.asm
Arm/CopyMem.S
diff --git a/ArmPkg/Library/BaseMemoryLibVstm/CompareMemWrapper.c b/ArmPkg/Library/BaseMemoryLibVstm/CompareMemWrapper.c index 9695c5b51b..c83988f59e 100755 --- a/ArmPkg/Library/BaseMemoryLibVstm/CompareMemWrapper.c +++ b/ArmPkg/Library/BaseMemoryLibVstm/CompareMemWrapper.c @@ -31,7 +31,7 @@ WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED. If all Length bytes of the two buffers are identical, then 0 is returned. Otherwise, the
value returned is the first mismatched byte in SourceBuffer subtracted from the first
mismatched byte in DestinationBuffer.
-
+
If Length > 0 and DestinationBuffer is NULL, then ASSERT().
If Length > 0 and SourceBuffer is NULL, then ASSERT().
If Length is greater than (MAX_ADDRESS - DestinationBuffer + 1), then ASSERT().
@@ -44,7 +44,7 @@ WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED. @return 0 All Length bytes of the two buffers are identical.
@retval Non-zero The first mismatched byte in SourceBuffer subtracted from the first
mismatched byte in DestinationBuffer.
-
+
**/
INTN
EFIAPI
diff --git a/ArmPkg/Library/BaseMemoryLibVstm/CopyMemWrapper.c b/ArmPkg/Library/BaseMemoryLibVstm/CopyMemWrapper.c index 5fca133643..2adfb31149 100755 --- a/ArmPkg/Library/BaseMemoryLibVstm/CopyMemWrapper.c +++ b/ArmPkg/Library/BaseMemoryLibVstm/CopyMemWrapper.c @@ -2,7 +2,7 @@ CopyMem() implementation.
The following BaseMemoryLib instances contain the same copy of this file:
-
+
BaseMemoryLib
BaseMemoryLibMmx
BaseMemoryLibSse2
@@ -31,7 +31,7 @@ This function copies Length bytes from SourceBuffer to DestinationBuffer, and returns
DestinationBuffer. The implementation must be reentrant, and it must handle the case
where SourceBuffer overlaps DestinationBuffer.
-
+
If Length is greater than (MAX_ADDRESS - DestinationBuffer + 1), then ASSERT().
If Length is greater than (MAX_ADDRESS - SourceBuffer + 1), then ASSERT().
diff --git a/ArmPkg/Library/BaseMemoryLibVstm/MemLibGuid.c b/ArmPkg/Library/BaseMemoryLibVstm/MemLibGuid.c index 748c80eadd..dc9e2c319b 100755 --- a/ArmPkg/Library/BaseMemoryLibVstm/MemLibGuid.c +++ b/ArmPkg/Library/BaseMemoryLibVstm/MemLibGuid.c @@ -2,7 +2,7 @@ Implementation of GUID functions.
The following BaseMemoryLib instances contain the same copy of this file:
-
+
BaseMemoryLib
BaseMemoryLibMmx
BaseMemoryLibSse2
@@ -30,7 +30,7 @@ This function copies the contents of the 128-bit GUID specified by SourceGuid to
DestinationGuid, and returns DestinationGuid.
-
+
If DestinationGuid is NULL, then ASSERT().
If SourceGuid is NULL, then ASSERT().
@@ -63,7 +63,7 @@ CopyGuid ( This function compares Guid1 to Guid2. If the GUIDs are identical then TRUE is returned.
If there are any bit differences in the two GUIDs, then FALSE is returned.
-
+
If Guid1 is NULL, then ASSERT().
If Guid2 is NULL, then ASSERT().
@@ -93,7 +93,7 @@ CompareGuid ( GUID value that matches Guid. If a match is found, then a pointer to the matching
GUID in the target buffer is returned. If no match is found, then NULL is returned.
If Length is 0, then NULL is returned.
-
+
If Length > 0 and Buffer is NULL, then ASSERT().
If Buffer is not aligned on a 32-bit boundary, then ASSERT().
If Length is not aligned on a 128-bit boundary, then ASSERT().
diff --git a/ArmPkg/Library/BaseMemoryLibVstm/ScanMem16Wrapper.c b/ArmPkg/Library/BaseMemoryLibVstm/ScanMem16Wrapper.c index 3dc2d291c1..1c727b3e80 100755 --- a/ArmPkg/Library/BaseMemoryLibVstm/ScanMem16Wrapper.c +++ b/ArmPkg/Library/BaseMemoryLibVstm/ScanMem16Wrapper.c @@ -33,7 +33,7 @@ address to the highest address for a 16-bit value that matches Value. If a match is found,
then a pointer to the matching byte in the target buffer is returned. If no match is found,
then NULL is returned. If Length is 0, then NULL is returned.
-
+
If Length > 0 and Buffer is NULL, then ASSERT().
If Buffer is not aligned on a 16-bit boundary, then ASSERT().
If Length is not aligned on a 16-bit boundary, then ASSERT().
diff --git a/ArmPkg/Library/BaseMemoryLibVstm/ScanMem32Wrapper.c b/ArmPkg/Library/BaseMemoryLibVstm/ScanMem32Wrapper.c index 1c47131b59..79ab60ced8 100755 --- a/ArmPkg/Library/BaseMemoryLibVstm/ScanMem32Wrapper.c +++ b/ArmPkg/Library/BaseMemoryLibVstm/ScanMem32Wrapper.c @@ -32,7 +32,7 @@ address to the highest address for a 32-bit value that matches Value. If a match is found,
then a pointer to the matching byte in the target buffer is returned. If no match is found,
then NULL is returned. If Length is 0, then NULL is returned.
-
+
If Length > 0 and Buffer is NULL, then ASSERT().
If Buffer is not aligned on a 32-bit boundary, then ASSERT().
If Length is not aligned on a 32-bit boundary, then ASSERT().
diff --git a/ArmPkg/Library/BaseMemoryLibVstm/ScanMem64Wrapper.c b/ArmPkg/Library/BaseMemoryLibVstm/ScanMem64Wrapper.c index 5161b29cad..d11e50b9d5 100755 --- a/ArmPkg/Library/BaseMemoryLibVstm/ScanMem64Wrapper.c +++ b/ArmPkg/Library/BaseMemoryLibVstm/ScanMem64Wrapper.c @@ -33,7 +33,7 @@ address to the highest address for a 64-bit value that matches Value. If a match is found,
then a pointer to the matching byte in the target buffer is returned. If no match is found,
then NULL is returned. If Length is 0, then NULL is returned.
-
+
If Length > 0 and Buffer is NULL, then ASSERT().
If Buffer is not aligned on a 64-bit boundary, then ASSERT().
If Length is not aligned on a 64-bit boundary, then ASSERT().
diff --git a/ArmPkg/Library/BaseMemoryLibVstm/ScanMem8Wrapper.c b/ArmPkg/Library/BaseMemoryLibVstm/ScanMem8Wrapper.c index c547cb46e1..c6c6d5f39b 100755 --- a/ArmPkg/Library/BaseMemoryLibVstm/ScanMem8Wrapper.c +++ b/ArmPkg/Library/BaseMemoryLibVstm/ScanMem8Wrapper.c @@ -33,7 +33,7 @@ address to the highest address for an 8-bit value that matches Value. If a match is found,
then a pointer to the matching byte in the target buffer is returned. If no match is found,
then NULL is returned. If Length is 0, then NULL is returned.
-
+
If Length > 0 and Buffer is NULL, then ASSERT().
If Length is greater than (MAX_ADDRESS - Buffer + 1), then ASSERT().
@@ -57,19 +57,19 @@ ScanMem8 ( }
ASSERT (Buffer != NULL);
ASSERT ((Length - 1) <= (MAX_ADDRESS - (UINTN)Buffer));
-
+
return (VOID*)InternalMemScanMem8 (Buffer, Length, Value);
}
/**
- Scans a target buffer for a UINTN sized value, and returns a pointer to the matching
+ Scans a target buffer for a UINTN sized value, and returns a pointer to the matching
UINTN sized value in the target buffer.
This function searches the target buffer specified by Buffer and Length from the lowest
address to the highest address for a UINTN sized value that matches Value. If a match is found,
then a pointer to the matching byte in the target buffer is returned. If no match is found,
then NULL is returned. If Length is 0, then NULL is returned.
-
+
If Length > 0 and Buffer is NULL, then ASSERT().
If Buffer is not aligned on a UINTN boundary, then ASSERT().
If Length is not aligned on a UINTN boundary, then ASSERT().
diff --git a/ArmPkg/Library/BaseMemoryLibVstm/SetMemWrapper.c b/ArmPkg/Library/BaseMemoryLibVstm/SetMemWrapper.c index 6d6ec38ae2..9240c89e8b 100755 --- a/ArmPkg/Library/BaseMemoryLibVstm/SetMemWrapper.c +++ b/ArmPkg/Library/BaseMemoryLibVstm/SetMemWrapper.c @@ -29,7 +29,7 @@ Fills a target buffer with a byte value, and returns the target buffer.
This function fills Length bytes of Buffer with Value, and returns Buffer.
-
+
If Length is greater than (MAX_ADDRESS - Buffer + 1), then ASSERT().
@param Buffer Memory to set.
diff --git a/ArmPkg/Library/BaseMemoryLibVstm/ZeroMemWrapper.c b/ArmPkg/Library/BaseMemoryLibVstm/ZeroMemWrapper.c index 89520348ba..d6c6279f68 100755 --- a/ArmPkg/Library/BaseMemoryLibVstm/ZeroMemWrapper.c +++ b/ArmPkg/Library/BaseMemoryLibVstm/ZeroMemWrapper.c @@ -11,7 +11,7 @@ BaseMemoryLibOptPei
PeiMemoryLib
UefiMemoryLib
-
+
Copyright (c) 2006 - 2009, Intel Corporation. All rights reserved.<BR>
This program and the accompanying materials
are licensed and made available under the terms and conditions of the BSD License
@@ -29,7 +29,7 @@ Fills a target buffer with zeros, and returns the target buffer.
This function fills Length bytes of Buffer with zeros, and returns Buffer.
-
+
If Length > 0 and Buffer is NULL, then ASSERT().
If Length is greater than (MAX_ADDRESS - Buffer + 1), then ASSERT().
diff --git a/ArmPkg/Library/BdsLib/Arm/BdsLinuxAtag.c b/ArmPkg/Library/BdsLib/Arm/BdsLinuxAtag.c index 8946b14236..33c27988ad 100644 --- a/ArmPkg/Library/BdsLib/Arm/BdsLinuxAtag.c +++ b/ArmPkg/Library/BdsLib/Arm/BdsLinuxAtag.c @@ -1,14 +1,14 @@ /** @file
*
* Copyright (c) 2011-2012, ARM Limited. All rights reserved.
-*
-* This program and the accompanying materials
-* are licensed and made available under the terms and conditions of the BSD License
-* which accompanies this distribution. The full text of the license may be found at
-* http://opensource.org/licenses/bsd-license.php
*
-* THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
-* WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
+* This program and the accompanying materials
+* are licensed and made available under the terms and conditions of the BSD License
+* which accompanies this distribution. The full text of the license may be found at
+* http://opensource.org/licenses/bsd-license.php
+*
+* THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
+* WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
*
**/
diff --git a/ArmPkg/Library/BdsLib/Arm/BdsLinuxLoader.c b/ArmPkg/Library/BdsLib/Arm/BdsLinuxLoader.c index 0e8113cb31..d85547b589 100644 --- a/ArmPkg/Library/BdsLib/Arm/BdsLinuxLoader.c +++ b/ArmPkg/Library/BdsLib/Arm/BdsLinuxLoader.c @@ -1,14 +1,14 @@ /** @file
*
* Copyright (c) 2011-2012, ARM Limited. All rights reserved.
-*
-* This program and the accompanying materials
-* are licensed and made available under the terms and conditions of the BSD License
-* which accompanies this distribution. The full text of the license may be found at
-* http://opensource.org/licenses/bsd-license.php
*
-* THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
-* WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
+* This program and the accompanying materials
+* are licensed and made available under the terms and conditions of the BSD License
+* which accompanies this distribution. The full text of the license may be found at
+* http://opensource.org/licenses/bsd-license.php
+*
+* THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
+* WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
*
**/
@@ -175,7 +175,7 @@ BdsBootLinuxAtag ( Print (L"ERROR: Did not find initrd image.\n");
goto EXIT_FREE_LINUX;
}
-
+
// Check if the initrd is a uInitrd
if (*(UINT32*)((UINTN)InitrdImageBase) == LINUX_UIMAGE_SIGNATURE) {
// Skip the 64-byte image header
@@ -190,7 +190,7 @@ BdsBootLinuxAtag ( //
// Setup the Linux Kernel Parameters
//
-
+
// By setting address=0 we leave the memory allocation to the function
Status = PrepareAtagList (CommandLineArguments, InitrdImage, InitrdImageSize, &AtagBase, &AtagSize);
if (EFI_ERROR(Status)) {
diff --git a/ArmPkg/Library/BdsLib/BdsFilePath.c b/ArmPkg/Library/BdsLib/BdsFilePath.c index f754b8899b..710821cd05 100644 --- a/ArmPkg/Library/BdsLib/BdsFilePath.c +++ b/ArmPkg/Library/BdsLib/BdsFilePath.c @@ -1,14 +1,14 @@ /** @file
*
* Copyright (c) 2011-2014, ARM Limited. All rights reserved.
-*
-* This program and the accompanying materials
-* are licensed and made available under the terms and conditions of the BSD License
-* which accompanies this distribution. The full text of the license may be found at
-* http://opensource.org/licenses/bsd-license.php
*
-* THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
-* WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
+* This program and the accompanying materials
+* are licensed and made available under the terms and conditions of the BSD License
+* which accompanies this distribution. The full text of the license may be found at
+* http://opensource.org/licenses/bsd-license.php
+*
+* THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
+* WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
*
**/
diff --git a/ArmPkg/Library/BdsLib/BdsInternal.h b/ArmPkg/Library/BdsLib/BdsInternal.h index 5ae46f86e8..88117016ce 100644 --- a/ArmPkg/Library/BdsLib/BdsInternal.h +++ b/ArmPkg/Library/BdsLib/BdsInternal.h @@ -1,14 +1,14 @@ /** @file
*
* Copyright (c) 2011-2012, ARM Limited. All rights reserved.
-*
-* This program and the accompanying materials
-* are licensed and made available under the terms and conditions of the BSD License
-* which accompanies this distribution. The full text of the license may be found at
-* http://opensource.org/licenses/bsd-license.php
*
-* THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
-* WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
+* This program and the accompanying materials
+* are licensed and made available under the terms and conditions of the BSD License
+* which accompanies this distribution. The full text of the license may be found at
+* http://opensource.org/licenses/bsd-license.php
+*
+* THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
+* WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
*
**/
diff --git a/ArmPkg/Library/BdsLib/BdsLib.inf b/ArmPkg/Library/BdsLib/BdsLib.inf index 4b9f664ea1..2796268015 100644 --- a/ArmPkg/Library/BdsLib/BdsLib.inf +++ b/ArmPkg/Library/BdsLib/BdsLib.inf @@ -1,14 +1,14 @@ #/* @file
-#
+#
# Copyright (c) 2011-2014, ARM Limited. All rights reserved.
-#
-# This program and the accompanying materials
-# are licensed and made available under the terms and conditions of the BSD License
-# which accompanies this distribution. The full text of the license may be found at
-# http://opensource.org/licenses/bsd-license.php
#
-# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
-# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
+# This program and the accompanying materials
+# are licensed and made available under the terms and conditions of the BSD License
+# which accompanies this distribution. The full text of the license may be found at
+# http://opensource.org/licenses/bsd-license.php
+#
+# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
+# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
#
#*/
@@ -62,7 +62,7 @@ gArmGlobalVariableGuid
[Protocols]
- gEfiBdsArchProtocolGuid
+ gEfiBdsArchProtocolGuid
gEfiDevicePathProtocolGuid
gEfiDevicePathFromTextProtocolGuid
gEfiSimpleFileSystemProtocolGuid
diff --git a/ArmPkg/Library/BdsLib/BdsLinuxLoader.h b/ArmPkg/Library/BdsLib/BdsLinuxLoader.h index 8949cfa981..b78f606129 100644 --- a/ArmPkg/Library/BdsLib/BdsLinuxLoader.h +++ b/ArmPkg/Library/BdsLib/BdsLinuxLoader.h @@ -1,14 +1,14 @@ /** @file
*
* Copyright (c) 2011-2013, ARM Limited. All rights reserved.
-*
-* This program and the accompanying materials
-* are licensed and made available under the terms and conditions of the BSD License
-* which accompanies this distribution. The full text of the license may be found at
-* http://opensource.org/licenses/bsd-license.php
*
-* THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
-* WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
+* This program and the accompanying materials
+* are licensed and made available under the terms and conditions of the BSD License
+* which accompanies this distribution. The full text of the license may be found at
+* http://opensource.org/licenses/bsd-license.php
+*
+* THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
+* WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
*
**/
diff --git a/ArmPkg/Library/CompilerIntrinsicsLib/Arm/Llvm_int_lib.h b/ArmPkg/Library/CompilerIntrinsicsLib/Arm/Llvm_int_lib.h index 6e42dcd14e..78d3e218ed 100644 --- a/ArmPkg/Library/CompilerIntrinsicsLib/Arm/Llvm_int_lib.h +++ b/ArmPkg/Library/CompilerIntrinsicsLib/Arm/Llvm_int_lib.h @@ -14,37 +14,37 @@ /**
University of Illinois/NCSA
Open Source License
-
+
Copyright (c) 2003-2008 University of Illinois at Urbana-Champaign.
All rights reserved.
-
+
Developed by:
-
+
LLVM Team
-
+
University of Illinois at Urbana-Champaign
-
+
http://llvm.org
-
+
Permission is hereby granted, free of charge, to any person obtaining a copy of
this software and associated documentation files (the "Software"), to deal with
the Software without restriction, including without limitation the rights to
use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies
of the Software, and to permit persons to whom the Software is furnished to do
so, subject to the following conditions:
-
+
* Redistributions of source code must retain the above copyright notice,
this list of conditions and the following disclaimers.
-
+
* Redistributions in binary form must reproduce the above copyright notice,
this list of conditions and the following disclaimers in the
documentation and/or other materials provided with the distribution.
-
+
* Neither the names of the LLVM Team, University of Illinois at
Urbana-Champaign, nor the names of its contributors may be used to
endorse or promote products derived from this Software without specific
prior written permission.
-
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS
FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
diff --git a/ArmPkg/Library/CompilerIntrinsicsLib/Arm/ashldi3.S b/ArmPkg/Library/CompilerIntrinsicsLib/Arm/ashldi3.S index cec0c55f1e..74960b1df1 100644 --- a/ArmPkg/Library/CompilerIntrinsicsLib/Arm/ashldi3.S +++ b/ArmPkg/Library/CompilerIntrinsicsLib/Arm/ashldi3.S @@ -1,4 +1,4 @@ -#------------------------------------------------------------------------------
+#------------------------------------------------------------------------------
#
# Copyright (c) 2008 - 2009, Apple Inc. All rights reserved.<BR>
#
@@ -15,7 +15,7 @@ .text
.align 2
GCC_ASM_EXPORT(__ashldi3)
-
+
ASM_PFX(__ashldi3):
cmp r2, #31
bls L2
diff --git a/ArmPkg/Library/CompilerIntrinsicsLib/Arm/ashldi3.c b/ArmPkg/Library/CompilerIntrinsicsLib/Arm/ashldi3.c index 526fcab65c..e13ea016f5 100644 --- a/ArmPkg/Library/CompilerIntrinsicsLib/Arm/ashldi3.c +++ b/ArmPkg/Library/CompilerIntrinsicsLib/Arm/ashldi3.c @@ -1,7 +1,7 @@ /** @file
Copyright (c) 2008 - 2009, Apple Inc. All rights reserved.<BR>
-
+
This program and the accompanying materials
are licensed and made available under the terms and conditions of the BSD License
which accompanies this distribution. The full text of the license may be found at
@@ -14,37 +14,37 @@ /**
University of Illinois/NCSA
Open Source License
-
+
Copyright (c) 2003-2008 University of Illinois at Urbana-Champaign.
All rights reserved.
-
+
Developed by:
-
+
LLVM Team
-
+
University of Illinois at Urbana-Champaign
-
+
http://llvm.org
-
+
Permission is hereby granted, free of charge, to any person obtaining a copy of
this software and associated documentation files (the "Software"), to deal with
the Software without restriction, including without limitation the rights to
use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies
of the Software, and to permit persons to whom the Software is furnished to do
so, subject to the following conditions:
-
+
* Redistributions of source code must retain the above copyright notice,
this list of conditions and the following disclaimers.
-
+
* Redistributions in binary form must reproduce the above copyright notice,
this list of conditions and the following disclaimers in the
documentation and/or other materials provided with the distribution.
-
+
* Neither the names of the LLVM Team, University of Illinois at
Urbana-Champaign, nor the names of its contributors may be used to
endorse or promote products derived from this Software without specific
prior written permission.
-
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS
FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
diff --git a/ArmPkg/Library/CompilerIntrinsicsLib/Arm/ashrdi3.S b/ArmPkg/Library/CompilerIntrinsicsLib/Arm/ashrdi3.S index 09c927ca6b..3cee2c1085 100644 --- a/ArmPkg/Library/CompilerIntrinsicsLib/Arm/ashrdi3.S +++ b/ArmPkg/Library/CompilerIntrinsicsLib/Arm/ashrdi3.S @@ -1,4 +1,4 @@ -#------------------------------------------------------------------------------
+#------------------------------------------------------------------------------
#
# Copyright (c) 2008 - 2009, Apple Inc. All rights reserved.<BR>
#
diff --git a/ArmPkg/Library/CompilerIntrinsicsLib/Arm/ashrdi3.c b/ArmPkg/Library/CompilerIntrinsicsLib/Arm/ashrdi3.c index 229531ed26..1617543ef5 100644 --- a/ArmPkg/Library/CompilerIntrinsicsLib/Arm/ashrdi3.c +++ b/ArmPkg/Library/CompilerIntrinsicsLib/Arm/ashrdi3.c @@ -1,7 +1,7 @@ /** @file
Copyright (c) 2008 - 2009, Apple Inc. All rights reserved.<BR>
-
+
This program and the accompanying materials
are licensed and made available under the terms and conditions of the BSD License
which accompanies this distribution. The full text of the license may be found at
@@ -14,37 +14,37 @@ /**
University of Illinois/NCSA
Open Source License
-
+
Copyright (c) 2003-2008 University of Illinois at Urbana-Champaign.
All rights reserved.
-
+
Developed by:
-
+
LLVM Team
-
+
University of Illinois at Urbana-Champaign
-
+
http://llvm.org
-
+
Permission is hereby granted, free of charge, to any person obtaining a copy of
this software and associated documentation files (the "Software"), to deal with
the Software without restriction, including without limitation the rights to
use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies
of the Software, and to permit persons to whom the Software is furnished to do
so, subject to the following conditions:
-
+
* Redistributions of source code must retain the above copyright notice,
this list of conditions and the following disclaimers.
-
+
* Redistributions in binary form must reproduce the above copyright notice,
this list of conditions and the following disclaimers in the
documentation and/or other materials provided with the distribution.
-
+
* Neither the names of the LLVM Team, University of Illinois at
Urbana-Champaign, nor the names of its contributors may be used to
endorse or promote products derived from this Software without specific
prior written permission.
-
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS
FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
diff --git a/ArmPkg/Library/CompilerIntrinsicsLib/Arm/clzsi2.S b/ArmPkg/Library/CompilerIntrinsicsLib/Arm/clzsi2.S index 942344674a..4cef265757 100644 --- a/ArmPkg/Library/CompilerIntrinsicsLib/Arm/clzsi2.S +++ b/ArmPkg/Library/CompilerIntrinsicsLib/Arm/clzsi2.S @@ -1,4 +1,4 @@ -#------------------------------------------------------------------------------
+#------------------------------------------------------------------------------
#
# Copyright (c) 2008 - 2010, Apple Inc. All rights reserved.<BR>
#
diff --git a/ArmPkg/Library/CompilerIntrinsicsLib/Arm/clzsi2.c b/ArmPkg/Library/CompilerIntrinsicsLib/Arm/clzsi2.c index 50ae87a6cc..5c2a3ea2b4 100644 --- a/ArmPkg/Library/CompilerIntrinsicsLib/Arm/clzsi2.c +++ b/ArmPkg/Library/CompilerIntrinsicsLib/Arm/clzsi2.c @@ -2,7 +2,7 @@ Compiler intrinsic to return the number of leading zeros, ported from LLVM code.
Copyright (c) 2008 - 2009, Apple Inc. All rights reserved.<BR>
-
+
This program and the accompanying materials
are licensed and made available under the terms and conditions of the BSD License
which accompanies this distribution. The full text of the license may be found at
@@ -15,37 +15,37 @@ /**
University of Illinois/NCSA
Open Source License
-
+
Copyright (c) 2003-2008 University of Illinois at Urbana-Champaign.
All rights reserved.
-
+
Developed by:
-
+
LLVM Team
-
+
University of Illinois at Urbana-Champaign
-
+
http://llvm.org
-
+
Permission is hereby granted, free of charge, to any person obtaining a copy of
this software and associated documentation files (the "Software"), to deal with
the Software without restriction, including without limitation the rights to
use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies
of the Software, and to permit persons to whom the Software is furnished to do
so, subject to the following conditions:
-
+
* Redistributions of source code must retain the above copyright notice,
this list of conditions and the following disclaimers.
-
+
* Redistributions in binary form must reproduce the above copyright notice,
this list of conditions and the following disclaimers in the
documentation and/or other materials provided with the distribution.
-
+
* Neither the names of the LLVM Team, University of Illinois at
Urbana-Champaign, nor the names of its contributors may be used to
endorse or promote products derived from this Software without specific
prior written permission.
-
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS
FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
diff --git a/ArmPkg/Library/CompilerIntrinsicsLib/Arm/ctzsi2.S b/ArmPkg/Library/CompilerIntrinsicsLib/Arm/ctzsi2.S index d530025a1d..108072eef7 100644 --- a/ArmPkg/Library/CompilerIntrinsicsLib/Arm/ctzsi2.S +++ b/ArmPkg/Library/CompilerIntrinsicsLib/Arm/ctzsi2.S @@ -1,4 +1,4 @@ -#------------------------------------------------------------------------------
+#------------------------------------------------------------------------------
#
# Copyright (c) 2008 - 2010, Apple Inc. All rights reserved.<BR>
#
@@ -15,7 +15,7 @@ .text
.align 2
GCC_ASM_EXPORT(__ctzsi2)
-
+
ASM_PFX(__ctzsi2):
uxth r3, r0
cmp r3, #0
diff --git a/ArmPkg/Library/CompilerIntrinsicsLib/Arm/ctzsi2.c b/ArmPkg/Library/CompilerIntrinsicsLib/Arm/ctzsi2.c index 71f303b344..12cad92da7 100644 --- a/ArmPkg/Library/CompilerIntrinsicsLib/Arm/ctzsi2.c +++ b/ArmPkg/Library/CompilerIntrinsicsLib/Arm/ctzsi2.c @@ -14,37 +14,37 @@ /**
University of Illinois/NCSA
Open Source License
-
+
Copyright (c) 2003-2008 University of Illinois at Urbana-Champaign.
All rights reserved.
-
+
Developed by:
-
+
LLVM Team
-
+
University of Illinois at Urbana-Champaign
-
+
http://llvm.org
-
+
Permission is hereby granted, free of charge, to any person obtaining a copy of
this software and associated documentation files (the "Software"), to deal with
the Software without restriction, including without limitation the rights to
use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies
of the Software, and to permit persons to whom the Software is furnished to do
so, subject to the following conditions:
-
+
* Redistributions of source code must retain the above copyright notice,
this list of conditions and the following disclaimers.
-
+
* Redistributions in binary form must reproduce the above copyright notice,
this list of conditions and the following disclaimers in the
documentation and/or other materials provided with the distribution.
-
+
* Neither the names of the LLVM Team, University of Illinois at
Urbana-Champaign, nor the names of its contributors may be used to
endorse or promote products derived from this Software without specific
prior written permission.
-
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS
FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
diff --git a/ArmPkg/Library/CompilerIntrinsicsLib/Arm/div.asm b/ArmPkg/Library/CompilerIntrinsicsLib/Arm/div.asm index 13f701358e..b539e51689 100644 --- a/ArmPkg/Library/CompilerIntrinsicsLib/Arm/div.asm +++ b/ArmPkg/Library/CompilerIntrinsicsLib/Arm/div.asm @@ -1,4 +1,4 @@ -//------------------------------------------------------------------------------
+//------------------------------------------------------------------------------
//
// Copyright (c) 2008 - 2009, Apple Inc. All rights reserved.<BR>
//
@@ -17,7 +17,7 @@ EXPORT __aeabi_uidivmod
EXPORT __aeabi_idiv
EXPORT __aeabi_idivmod
-
+
AREA Math, CODE, READONLY
;
@@ -150,6 +150,6 @@ label1 ; What to do about division by zero? For now, just return.
__aeabi_idiv0
BX r14
-
+
END
diff --git a/ArmPkg/Library/CompilerIntrinsicsLib/Arm/divdi3.S b/ArmPkg/Library/CompilerIntrinsicsLib/Arm/divdi3.S index 7be2e2886a..23c8e8ffbf 100644 --- a/ArmPkg/Library/CompilerIntrinsicsLib/Arm/divdi3.S +++ b/ArmPkg/Library/CompilerIntrinsicsLib/Arm/divdi3.S @@ -1,4 +1,4 @@ -#------------------------------------------------------------------------------
+#------------------------------------------------------------------------------
#
# Copyright (c) 2008 - 2009, Apple Inc. All rights reserved.<BR>
#
@@ -15,7 +15,7 @@ .text
.align 2
GCC_ASM_EXPORT(__divdi3)
-
+
ASM_PFX(__divdi3):
@ args = 0, pretend = 0, frame = 0
@ frame_needed = 1, uses_anonymous_args = 0
diff --git a/ArmPkg/Library/CompilerIntrinsicsLib/Arm/divdi3.c b/ArmPkg/Library/CompilerIntrinsicsLib/Arm/divdi3.c index e86bd1361e..c7916b8009 100644 --- a/ArmPkg/Library/CompilerIntrinsicsLib/Arm/divdi3.c +++ b/ArmPkg/Library/CompilerIntrinsicsLib/Arm/divdi3.c @@ -2,7 +2,7 @@ Compiler intrinsic for 64-bit compare, ported from LLVM code.
Copyright (c) 2008 - 2009, Apple Inc. All rights reserved.<BR>
-
+
This program and the accompanying materials
are licensed and made available under the terms and conditions of the BSD License
which accompanies this distribution. The full text of the license may be found at
@@ -15,37 +15,37 @@ /**
University of Illinois/NCSA
Open Source License
-
+
Copyright (c) 2003-2008 University of Illinois at Urbana-Champaign.
All rights reserved.
-
+
Developed by:
-
+
LLVM Team
-
+
University of Illinois at Urbana-Champaign
-
+
http://llvm.org
-
+
Permission is hereby granted, free of charge, to any person obtaining a copy of
this software and associated documentation files (the "Software"), to deal with
the Software without restriction, including without limitation the rights to
use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies
of the Software, and to permit persons to whom the Software is furnished to do
so, subject to the following conditions:
-
+
* Redistributions of source code must retain the above copyright notice,
this list of conditions and the following disclaimers.
-
+
* Redistributions in binary form must reproduce the above copyright notice,
this list of conditions and the following disclaimers in the
documentation and/or other materials provided with the distribution.
-
+
* Neither the names of the LLVM Team, University of Illinois at
Urbana-Champaign, nor the names of its contributors may be used to
endorse or promote products derived from this Software without specific
prior written permission.
-
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS
FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
diff --git a/ArmPkg/Library/CompilerIntrinsicsLib/Arm/divsi3.S b/ArmPkg/Library/CompilerIntrinsicsLib/Arm/divsi3.S index b74cbb6439..d585146878 100644 --- a/ArmPkg/Library/CompilerIntrinsicsLib/Arm/divsi3.S +++ b/ArmPkg/Library/CompilerIntrinsicsLib/Arm/divsi3.S @@ -1,4 +1,4 @@ -#------------------------------------------------------------------------------
+#------------------------------------------------------------------------------
#
# Copyright (c) 2008 - 2009, Apple Inc. All rights reserved.<BR>
#
@@ -15,7 +15,7 @@ .text
.align 2
GCC_ASM_EXPORT(__divsi3)
-
+
ASM_PFX(__divsi3):
eor r3, r0, r0, asr #31
eor r2, r1, r1, asr #31
diff --git a/ArmPkg/Library/CompilerIntrinsicsLib/Arm/divsi3.c b/ArmPkg/Library/CompilerIntrinsicsLib/Arm/divsi3.c index b322f9a57a..24e43dd6d7 100644 --- a/ArmPkg/Library/CompilerIntrinsicsLib/Arm/divsi3.c +++ b/ArmPkg/Library/CompilerIntrinsicsLib/Arm/divsi3.c @@ -3,7 +3,7 @@ Copyright (c) 2008 - 2009, Apple Inc. All rights reserved.<BR>
-
+
This program and the accompanying materials
are licensed and made available under the terms and conditions of the BSD License
which accompanies this distribution. The full text of the license may be found at
@@ -16,37 +16,37 @@ /**
University of Illinois/NCSA
Open Source License
-
+
Copyright (c) 2003-2008 University of Illinois at Urbana-Champaign.
All rights reserved.
-
+
Developed by:
-
+
LLVM Team
-
+
University of Illinois at Urbana-Champaign
-
+
http://llvm.org
-
+
Permission is hereby granted, free of charge, to any person obtaining a copy of
this software and associated documentation files (the "Software"), to deal with
the Software without restriction, including without limitation the rights to
use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies
of the Software, and to permit persons to whom the Software is furnished to do
so, subject to the following conditions:
-
+
* Redistributions of source code must retain the above copyright notice,
this list of conditions and the following disclaimers.
-
+
* Redistributions in binary form must reproduce the above copyright notice,
this list of conditions and the following disclaimers in the
documentation and/or other materials provided with the distribution.
-
+
* Neither the names of the LLVM Team, University of Illinois at
Urbana-Champaign, nor the names of its contributors may be used to
endorse or promote products derived from this Software without specific
prior written permission.
-
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS
FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
diff --git a/ArmPkg/Library/CompilerIntrinsicsLib/Arm/lasr.asm b/ArmPkg/Library/CompilerIntrinsicsLib/Arm/lasr.asm index 069438c920..feb267a65e 100644 --- a/ArmPkg/Library/CompilerIntrinsicsLib/Arm/lasr.asm +++ b/ArmPkg/Library/CompilerIntrinsicsLib/Arm/lasr.asm @@ -1,4 +1,4 @@ -//------------------------------------------------------------------------------
+//------------------------------------------------------------------------------
//
// Copyright (c) 2008 - 2009, Apple Inc. All rights reserved.<BR>
//
@@ -14,7 +14,7 @@ EXPORT __aeabi_lasr
-
+
AREA Math, CODE, READONLY
;
@@ -36,6 +36,6 @@ __aeabi_lasr ASR r0,r1,r3
ASR r1,r1,#31
BX lr
-
+
END
diff --git a/ArmPkg/Library/CompilerIntrinsicsLib/Arm/ldivmod.S b/ArmPkg/Library/CompilerIntrinsicsLib/Arm/ldivmod.S index 510778ab07..e7a05de589 100755 --- a/ArmPkg/Library/CompilerIntrinsicsLib/Arm/ldivmod.S +++ b/ArmPkg/Library/CompilerIntrinsicsLib/Arm/ldivmod.S @@ -1,4 +1,4 @@ -//------------------------------------------------------------------------------
+//------------------------------------------------------------------------------
//
// Copyright (c) 2008 - 2009, Apple Inc. All rights reserved.<BR>
//
@@ -18,7 +18,7 @@ GCC_ASM_EXPORT(__aeabi_ldivmod)
//
-// A pair of (unsigned) long longs is returned in {{r0, r1}, {r2, r3}},
+// A pair of (unsigned) long longs is returned in {{r0, r1}, {r2, r3}},
// the quotient in {r0, r1}, and the remainder in {r2, r3}.
//
//__value_in_regs lldiv_t
@@ -42,7 +42,7 @@ L_Test1: rsbs r2,r2,#0
rsc r3,r3,#0
L_Test2:
- bl ASM_PFX(__aeabi_uldivmod)
+ bl ASM_PFX(__aeabi_uldivmod)
tst r4,#0x40000000
beq L_Test3
rsbs r0,r0,#0
@@ -54,6 +54,6 @@ L_Test3: rsc r3,r3,#0
L_Exit:
pop {r4,pc}
-
+
diff --git a/ArmPkg/Library/CompilerIntrinsicsLib/Arm/ldivmod.asm b/ArmPkg/Library/CompilerIntrinsicsLib/Arm/ldivmod.asm index 0059c2f6f9..9c14e89a01 100644 --- a/ArmPkg/Library/CompilerIntrinsicsLib/Arm/ldivmod.asm +++ b/ArmPkg/Library/CompilerIntrinsicsLib/Arm/ldivmod.asm @@ -1,4 +1,4 @@ -//------------------------------------------------------------------------------
+//------------------------------------------------------------------------------
//
// Copyright (c) 2008 - 2009, Apple Inc. All rights reserved.<BR>
//
@@ -15,7 +15,7 @@ EXPORT __aeabi_ldivmod
EXTERN __aeabi_uldivmod
-
+
AREA Math, CODE, READONLY
;
@@ -52,7 +52,7 @@ L_Test3 RSC r3,r3,#0
L_Exit
POP {r4,pc}
-
+
END
diff --git a/ArmPkg/Library/CompilerIntrinsicsLib/Arm/llsl.asm b/ArmPkg/Library/CompilerIntrinsicsLib/Arm/llsl.asm index 43d9e729cf..f6fc208dee 100644 --- a/ArmPkg/Library/CompilerIntrinsicsLib/Arm/llsl.asm +++ b/ArmPkg/Library/CompilerIntrinsicsLib/Arm/llsl.asm @@ -1,4 +1,4 @@ -//------------------------------------------------------------------------------
+//------------------------------------------------------------------------------
//
// Copyright (c) 2008 - 2009, Apple Inc. All rights reserved.<BR>
//
diff --git a/ArmPkg/Library/CompilerIntrinsicsLib/Arm/llsr.asm b/ArmPkg/Library/CompilerIntrinsicsLib/Arm/llsr.asm index de9a2186c2..829c871d94 100644 --- a/ArmPkg/Library/CompilerIntrinsicsLib/Arm/llsr.asm +++ b/ArmPkg/Library/CompilerIntrinsicsLib/Arm/llsr.asm @@ -1,4 +1,4 @@ -//------------------------------------------------------------------------------
+//------------------------------------------------------------------------------
//
// Copyright (c) 2008 - 2009, Apple Inc. All rights reserved.<BR>
//
diff --git a/ArmPkg/Library/CompilerIntrinsicsLib/Arm/lshrdi3.S b/ArmPkg/Library/CompilerIntrinsicsLib/Arm/lshrdi3.S index efec070c01..a3133206a5 100644 --- a/ArmPkg/Library/CompilerIntrinsicsLib/Arm/lshrdi3.S +++ b/ArmPkg/Library/CompilerIntrinsicsLib/Arm/lshrdi3.S @@ -1,4 +1,4 @@ -#------------------------------------------------------------------------------
+#------------------------------------------------------------------------------
#
# Copyright (c) 2008 - 2009, Apple Inc. All rights reserved.<BR>
#
@@ -15,7 +15,7 @@ .text
.align 2
GCC_ASM_EXPORT(__lshrdi3)
-
+
ASM_PFX(__lshrdi3):
cmp r2, #31
bls L2
diff --git a/ArmPkg/Library/CompilerIntrinsicsLib/Arm/lshrdi3.c b/ArmPkg/Library/CompilerIntrinsicsLib/Arm/lshrdi3.c index 47c80c2d23..2175cd9b54 100644 --- a/ArmPkg/Library/CompilerIntrinsicsLib/Arm/lshrdi3.c +++ b/ArmPkg/Library/CompilerIntrinsicsLib/Arm/lshrdi3.c @@ -1,7 +1,7 @@ /** @file
Copyright (c) 2008 - 2009, Apple Inc. All rights reserved.<BR>
-
+
This program and the accompanying materials
are licensed and made available under the terms and conditions of the BSD License
which accompanies this distribution. The full text of the license may be found at
@@ -14,37 +14,37 @@ /**
University of Illinois/NCSA
Open Source License
-
+
Copyright (c) 2003-2008 University of Illinois at Urbana-Champaign.
All rights reserved.
-
+
Developed by:
-
+
LLVM Team
-
+
University of Illinois at Urbana-Champaign
-
+
http://llvm.org
-
+
Permission is hereby granted, free of charge, to any person obtaining a copy of
this software and associated documentation files (the "Software"), to deal with
the Software without restriction, including without limitation the rights to
use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies
of the Software, and to permit persons to whom the Software is furnished to do
so, subject to the following conditions:
-
+
* Redistributions of source code must retain the above copyright notice,
this list of conditions and the following disclaimers.
-
+
* Redistributions in binary form must reproduce the above copyright notice,
this list of conditions and the following disclaimers in the
documentation and/or other materials provided with the distribution.
-
+
* Neither the names of the LLVM Team, University of Illinois at
Urbana-Champaign, nor the names of its contributors may be used to
endorse or promote products derived from this Software without specific
prior written permission.
-
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS
FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
diff --git a/ArmPkg/Library/CompilerIntrinsicsLib/Arm/memcpy4.asm b/ArmPkg/Library/CompilerIntrinsicsLib/Arm/memcpy4.asm index 9780060c1c..ecaa86f51e 100644 --- a/ArmPkg/Library/CompilerIntrinsicsLib/Arm/memcpy4.asm +++ b/ArmPkg/Library/CompilerIntrinsicsLib/Arm/memcpy4.asm @@ -1,4 +1,4 @@ -//------------------------------------------------------------------------------
+//------------------------------------------------------------------------------
//
// Copyright (c) 2008 - 2009, Apple Inc. All rights reserved.<BR>
//
diff --git a/ArmPkg/Library/CompilerIntrinsicsLib/Arm/memmove.asm b/ArmPkg/Library/CompilerIntrinsicsLib/Arm/memmove.asm index ae5c990f57..ff7552d1c6 100755 --- a/ArmPkg/Library/CompilerIntrinsicsLib/Arm/memmove.asm +++ b/ArmPkg/Library/CompilerIntrinsicsLib/Arm/memmove.asm @@ -1,4 +1,4 @@ -//------------------------------------------------------------------------------
+//------------------------------------------------------------------------------
//
// Copyright (c) 2011, ARM Limited. All rights reserved.
//
diff --git a/ArmPkg/Library/CompilerIntrinsicsLib/Arm/memset.S b/ArmPkg/Library/CompilerIntrinsicsLib/Arm/memset.S index 7b1cf8d972..7290e85958 100644 --- a/ArmPkg/Library/CompilerIntrinsicsLib/Arm/memset.S +++ b/ArmPkg/Library/CompilerIntrinsicsLib/Arm/memset.S @@ -1,4 +1,4 @@ -#------------------------------------------------------------------------------
+#------------------------------------------------------------------------------
#
# Copyright (c) 2008 - 2009, Apple Inc. All rights reserved.<BR>
#
diff --git a/ArmPkg/Library/CompilerIntrinsicsLib/Arm/moddi3.S b/ArmPkg/Library/CompilerIntrinsicsLib/Arm/moddi3.S index e058ea4468..7b618eb06b 100644 --- a/ArmPkg/Library/CompilerIntrinsicsLib/Arm/moddi3.S +++ b/ArmPkg/Library/CompilerIntrinsicsLib/Arm/moddi3.S @@ -1,4 +1,4 @@ -#------------------------------------------------------------------------------
+#------------------------------------------------------------------------------
#
# Copyright (c) 2008 - 2009, Apple Inc. All rights reserved.<BR>
#
diff --git a/ArmPkg/Library/CompilerIntrinsicsLib/Arm/moddi3.c b/ArmPkg/Library/CompilerIntrinsicsLib/Arm/moddi3.c index 972fc065e9..04562de4c3 100644 --- a/ArmPkg/Library/CompilerIntrinsicsLib/Arm/moddi3.c +++ b/ArmPkg/Library/CompilerIntrinsicsLib/Arm/moddi3.c @@ -2,7 +2,7 @@ Compiler intrinsic for 64-bit mod, ported from LLVM code.
Copyright (c) 2008 - 2009, Apple Inc. All rights reserved.<BR>
-
+
This program and the accompanying materials
are licensed and made available under the terms and conditions of the BSD License
which accompanies this distribution. The full text of the license may be found at
@@ -15,37 +15,37 @@ /**
University of Illinois/NCSA
Open Source License
-
+
Copyright (c) 2003-2008 University of Illinois at Urbana-Champaign.
All rights reserved.
-
+
Developed by:
-
+
LLVM Team
-
+
University of Illinois at Urbana-Champaign
-
+
http://llvm.org
-
+
Permission is hereby granted, free of charge, to any person obtaining a copy of
this software and associated documentation files (the "Software"), to deal with
the Software without restriction, including without limitation the rights to
use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies
of the Software, and to permit persons to whom the Software is furnished to do
so, subject to the following conditions:
-
+
* Redistributions of source code must retain the above copyright notice,
this list of conditions and the following disclaimers.
-
+
* Redistributions in binary form must reproduce the above copyright notice,
this list of conditions and the following disclaimers in the
documentation and/or other materials provided with the distribution.
-
+
* Neither the names of the LLVM Team, University of Illinois at
Urbana-Champaign, nor the names of its contributors may be used to
endorse or promote products derived from this Software without specific
prior written permission.
-
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS
FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
diff --git a/ArmPkg/Library/CompilerIntrinsicsLib/Arm/modsi3.S b/ArmPkg/Library/CompilerIntrinsicsLib/Arm/modsi3.S index 07f8ef72f7..047501e929 100644 --- a/ArmPkg/Library/CompilerIntrinsicsLib/Arm/modsi3.S +++ b/ArmPkg/Library/CompilerIntrinsicsLib/Arm/modsi3.S @@ -1,4 +1,4 @@ -#------------------------------------------------------------------------------
+#------------------------------------------------------------------------------
#
# Copyright (c) 2008 - 2009, Apple Inc. All rights reserved.<BR>
#
diff --git a/ArmPkg/Library/CompilerIntrinsicsLib/Arm/modsi3.c b/ArmPkg/Library/CompilerIntrinsicsLib/Arm/modsi3.c index 9bdf077fbe..91ee6aa279 100644 --- a/ArmPkg/Library/CompilerIntrinsicsLib/Arm/modsi3.c +++ b/ArmPkg/Library/CompilerIntrinsicsLib/Arm/modsi3.c @@ -3,7 +3,7 @@ Copyright (c) 2008 - 2009, Apple Inc. All rights reserved.<BR>
-
+
This program and the accompanying materials
are licensed and made available under the terms and conditions of the BSD License
which accompanies this distribution. The full text of the license may be found at
@@ -16,37 +16,37 @@ /**
University of Illinois/NCSA
Open Source License
-
+
Copyright (c) 2003-2008 University of Illinois at Urbana-Champaign.
All rights reserved.
-
+
Developed by:
-
+
LLVM Team
-
+
University of Illinois at Urbana-Champaign
-
+
http://llvm.org
-
+
Permission is hereby granted, free of charge, to any person obtaining a copy of
this software and associated documentation files (the "Software"), to deal with
the Software without restriction, including without limitation the rights to
use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies
of the Software, and to permit persons to whom the Software is furnished to do
so, subject to the following conditions:
-
+
* Redistributions of source code must retain the above copyright notice,
this list of conditions and the following disclaimers.
-
+
* Redistributions in binary form must reproduce the above copyright notice,
this list of conditions and the following disclaimers in the
documentation and/or other materials provided with the distribution.
-
+
* Neither the names of the LLVM Team, University of Illinois at
Urbana-Champaign, nor the names of its contributors may be used to
endorse or promote products derived from this Software without specific
prior written permission.
-
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS
FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
diff --git a/ArmPkg/Library/CompilerIntrinsicsLib/Arm/muldi3.S b/ArmPkg/Library/CompilerIntrinsicsLib/Arm/muldi3.S index e8ac1ffffc..dff61ef7a4 100644 --- a/ArmPkg/Library/CompilerIntrinsicsLib/Arm/muldi3.S +++ b/ArmPkg/Library/CompilerIntrinsicsLib/Arm/muldi3.S @@ -1,4 +1,4 @@ -#------------------------------------------------------------------------------
+#------------------------------------------------------------------------------
#
# Copyright (c) 2008 - 2009, Apple Inc. All rights reserved.<BR>
#
diff --git a/ArmPkg/Library/CompilerIntrinsicsLib/Arm/muldi3.c b/ArmPkg/Library/CompilerIntrinsicsLib/Arm/muldi3.c index 67d0e4eed5..dbdda86c13 100644 --- a/ArmPkg/Library/CompilerIntrinsicsLib/Arm/muldi3.c +++ b/ArmPkg/Library/CompilerIntrinsicsLib/Arm/muldi3.c @@ -1,7 +1,7 @@ /** @file
Copyright (c) 2008 - 2009, Apple Inc. All rights reserved.<BR>
-
+
This program and the accompanying materials
are licensed and made available under the terms and conditions of the BSD License
which accompanies this distribution. The full text of the license may be found at
@@ -14,37 +14,37 @@ /**
University of Illinois/NCSA
Open Source License
-
+
Copyright (c) 2003-2008 University of Illinois at Urbana-Champaign.
All rights reserved.
-
+
Developed by:
-
+
LLVM Team
-
+
University of Illinois at Urbana-Champaign
-
+
http://llvm.org
-
+
Permission is hereby granted, free of charge, to any person obtaining a copy of
this software and associated documentation files (the "Software"), to deal with
the Software without restriction, including without limitation the rights to
use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies
of the Software, and to permit persons to whom the Software is furnished to do
so, subject to the following conditions:
-
+
* Redistributions of source code must retain the above copyright notice,
this list of conditions and the following disclaimers.
-
+
* Redistributions in binary form must reproduce the above copyright notice,
this list of conditions and the following disclaimers in the
documentation and/or other materials provided with the distribution.
-
+
* Neither the names of the LLVM Team, University of Illinois at
Urbana-Champaign, nor the names of its contributors may be used to
endorse or promote products derived from this Software without specific
prior written permission.
-
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS
FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
diff --git a/ArmPkg/Library/CompilerIntrinsicsLib/Arm/mullu.S b/ArmPkg/Library/CompilerIntrinsicsLib/Arm/mullu.S index bffe02b12e..e65355970b 100644 --- a/ArmPkg/Library/CompilerIntrinsicsLib/Arm/mullu.S +++ b/ArmPkg/Library/CompilerIntrinsicsLib/Arm/mullu.S @@ -1,4 +1,4 @@ -#------------------------------------------------------------------------------
+#------------------------------------------------------------------------------
#
# Copyright (c) 2008 - 2009, Apple Inc. All rights reserved.<BR>
#
diff --git a/ArmPkg/Library/CompilerIntrinsicsLib/Arm/mullu.asm b/ArmPkg/Library/CompilerIntrinsicsLib/Arm/mullu.asm index 4897636489..3451c2c943 100644 --- a/ArmPkg/Library/CompilerIntrinsicsLib/Arm/mullu.asm +++ b/ArmPkg/Library/CompilerIntrinsicsLib/Arm/mullu.asm @@ -1,4 +1,4 @@ -//------------------------------------------------------------------------------
+//------------------------------------------------------------------------------
//
// Copyright (c) 2008 - 2009, Apple Inc. All rights reserved.<BR>
//
@@ -15,7 +15,7 @@ EXPORT __ARM_ll_mullu
EXPORT __aeabi_lmul
-
+
AREA Math, CODE, READONLY
;
@@ -45,5 +45,5 @@ __aeabi_lmul mla r1, r2, r1, ip
mla r1, r3, lr, r1
ldmia sp!, {pc}
-
+
END
diff --git a/ArmPkg/Library/CompilerIntrinsicsLib/Arm/sourcery.S b/ArmPkg/Library/CompilerIntrinsicsLib/Arm/sourcery.S index 6101457a4c..1e0b524cfe 100755 --- a/ArmPkg/Library/CompilerIntrinsicsLib/Arm/sourcery.S +++ b/ArmPkg/Library/CompilerIntrinsicsLib/Arm/sourcery.S @@ -1,4 +1,4 @@ -#------s------------------------------------------------------------------------
+#------s------------------------------------------------------------------------
#
# Copyright (c) 2008 - 2010, Apple Inc. All rights reserved.<BR>
#
@@ -52,4 +52,4 @@ L17: cmp r2, r0
bhi L2
b L4
-
+
diff --git a/ArmPkg/Library/CompilerIntrinsicsLib/Arm/switch.asm b/ArmPkg/Library/CompilerIntrinsicsLib/Arm/switch.asm index 2c8a0318d5..e09c90cda4 100644 --- a/ArmPkg/Library/CompilerIntrinsicsLib/Arm/switch.asm +++ b/ArmPkg/Library/CompilerIntrinsicsLib/Arm/switch.asm @@ -1,4 +1,4 @@ -///------------------------------------------------------------------------------
+///------------------------------------------------------------------------------
//
// Copyright (c) 2008 - 2009, Apple Inc. All rights reserved.<BR>
//
@@ -17,7 +17,7 @@ EXPORT __ARM_switch8
AREA ArmSwitch, CODE, READONLY
-
+
__ARM_switch8
LDRB r12,[lr,#-1]
CMP r3,r12
@@ -25,5 +25,5 @@ __ARM_switch8 LDRBCS r3,[lr,r12]
ADD r12,lr,r3,LSL #1
BX r12
-
+
END
diff --git a/ArmPkg/Library/CompilerIntrinsicsLib/Arm/switch16.S b/ArmPkg/Library/CompilerIntrinsicsLib/Arm/switch16.S index ce6904e0c1..7f41353e01 100644 --- a/ArmPkg/Library/CompilerIntrinsicsLib/Arm/switch16.S +++ b/ArmPkg/Library/CompilerIntrinsicsLib/Arm/switch16.S @@ -11,7 +11,7 @@ # WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.;
#
#**/
-#
+#
.text
.p2align 2
diff --git a/ArmPkg/Library/CompilerIntrinsicsLib/Arm/switch32.S b/ArmPkg/Library/CompilerIntrinsicsLib/Arm/switch32.S index 63aed6e6b0..8675a4aeb7 100644 --- a/ArmPkg/Library/CompilerIntrinsicsLib/Arm/switch32.S +++ b/ArmPkg/Library/CompilerIntrinsicsLib/Arm/switch32.S @@ -11,14 +11,14 @@ # WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.;
#
#**/
-#
+#
.text
.p2align 2
GCC_ASM_EXPORT(__switch32)
-ASM_PFX(__switch32):
+ASM_PFX(__switch32):
ldr ip, [lr, #-1]
cmp r0, ip
add r0, lr, r0, lsl #2
diff --git a/ArmPkg/Library/CompilerIntrinsicsLib/Arm/switch8.S b/ArmPkg/Library/CompilerIntrinsicsLib/Arm/switch8.S index 688e106a96..27edccbf77 100644 --- a/ArmPkg/Library/CompilerIntrinsicsLib/Arm/switch8.S +++ b/ArmPkg/Library/CompilerIntrinsicsLib/Arm/switch8.S @@ -11,7 +11,7 @@ # WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.;
#
#**/
-#
+#
.text
.p2align 2
diff --git a/ArmPkg/Library/CompilerIntrinsicsLib/Arm/switchu8.S b/ArmPkg/Library/CompilerIntrinsicsLib/Arm/switchu8.S index 254b054353..39c4a7fdff 100644 --- a/ArmPkg/Library/CompilerIntrinsicsLib/Arm/switchu8.S +++ b/ArmPkg/Library/CompilerIntrinsicsLib/Arm/switchu8.S @@ -11,7 +11,7 @@ # WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.;
#
#**/
-#
+#
.text
.p2align 2
diff --git a/ArmPkg/Library/CompilerIntrinsicsLib/Arm/ucmpdi2.S b/ArmPkg/Library/CompilerIntrinsicsLib/Arm/ucmpdi2.S index f448ed58cc..da57423bf1 100644 --- a/ArmPkg/Library/CompilerIntrinsicsLib/Arm/ucmpdi2.S +++ b/ArmPkg/Library/CompilerIntrinsicsLib/Arm/ucmpdi2.S @@ -1,4 +1,4 @@ -#------------------------------------------------------------------------------
+#------------------------------------------------------------------------------
#
# Copyright (c) 2008 - 2010, Apple Inc. All rights reserved.<BR>
#
@@ -15,7 +15,7 @@ .text
.align 2
GCC_ASM_EXPORT(__ucmpdi2)
-
+
ASM_PFX(__ucmpdi2):
stmfd sp!, {r4, r5, r8, lr}
cmp r1, r3
diff --git a/ArmPkg/Library/CompilerIntrinsicsLib/Arm/ucmpdi2.c b/ArmPkg/Library/CompilerIntrinsicsLib/Arm/ucmpdi2.c index 70d5a531b9..aa03a3db39 100644 --- a/ArmPkg/Library/CompilerIntrinsicsLib/Arm/ucmpdi2.c +++ b/ArmPkg/Library/CompilerIntrinsicsLib/Arm/ucmpdi2.c @@ -2,7 +2,7 @@ Compiler intrinsic for 64-bit compare, ported from LLVM code.
Copyright (c) 2008-2009, Apple Inc. All rights reserved.<BR>
-
+
This program and the accompanying materials
are licensed and made available under the terms and conditions of the BSD License
which accompanies this distribution. The full text of the license may be found at
@@ -15,37 +15,37 @@ /**
University of Illinois/NCSA
Open Source License
-
+
Copyright (c) 2003-2008 University of Illinois at Urbana-Champaign.
All rights reserved.
-
+
Developed by:
-
+
LLVM Team
-
+
University of Illinois at Urbana-Champaign
-
+
http://llvm.org
-
+
Permission is hereby granted, free of charge, to any person obtaining a copy of
this software and associated documentation files (the "Software"), to deal with
the Software without restriction, including without limitation the rights to
use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies
of the Software, and to permit persons to whom the Software is furnished to do
so, subject to the following conditions:
-
+
* Redistributions of source code must retain the above copyright notice,
this list of conditions and the following disclaimers.
-
+
* Redistributions in binary form must reproduce the above copyright notice,
this list of conditions and the following disclaimers in the
documentation and/or other materials provided with the distribution.
-
+
* Neither the names of the LLVM Team, University of Illinois at
Urbana-Champaign, nor the names of its contributors may be used to
endorse or promote products derived from this Software without specific
prior written permission.
-
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS
FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
diff --git a/ArmPkg/Library/CompilerIntrinsicsLib/Arm/udivdi3.S b/ArmPkg/Library/CompilerIntrinsicsLib/Arm/udivdi3.S index f274901fa4..cbfb127350 100644 --- a/ArmPkg/Library/CompilerIntrinsicsLib/Arm/udivdi3.S +++ b/ArmPkg/Library/CompilerIntrinsicsLib/Arm/udivdi3.S @@ -1,4 +1,4 @@ -#------------------------------------------------------------------------------
+#------------------------------------------------------------------------------
#
# Copyright (c) 2008 - 2009, Apple Inc. All rights reserved.<BR>
#
diff --git a/ArmPkg/Library/CompilerIntrinsicsLib/Arm/udivdi3.c b/ArmPkg/Library/CompilerIntrinsicsLib/Arm/udivdi3.c index a8d9b09671..fc383b47e8 100644 --- a/ArmPkg/Library/CompilerIntrinsicsLib/Arm/udivdi3.c +++ b/ArmPkg/Library/CompilerIntrinsicsLib/Arm/udivdi3.c @@ -2,7 +2,7 @@ Compiler intrinsic for 64-bit unisigned div, ported from LLVM code.
Copyright (c) 2008-2009, Apple Inc. All rights reserved.<BR>
-
+
This program and the accompanying materials
are licensed and made available under the terms and conditions of the BSD License
which accompanies this distribution. The full text of the license may be found at
@@ -15,37 +15,37 @@ /**
University of Illinois/NCSA
Open Source License
-
+
Copyright (c) 2003-2008 University of Illinois at Urbana-Champaign.
All rights reserved.
-
+
Developed by:
-
+
LLVM Team
-
+
University of Illinois at Urbana-Champaign
-
+
http://llvm.org
-
+
Permission is hereby granted, free of charge, to any person obtaining a copy of
this software and associated documentation files (the "Software"), to deal with
the Software without restriction, including without limitation the rights to
use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies
of the Software, and to permit persons to whom the Software is furnished to do
so, subject to the following conditions:
-
+
* Redistributions of source code must retain the above copyright notice,
this list of conditions and the following disclaimers.
-
+
* Redistributions in binary form must reproduce the above copyright notice,
this list of conditions and the following disclaimers in the
documentation and/or other materials provided with the distribution.
-
+
* Neither the names of the LLVM Team, University of Illinois at
Urbana-Champaign, nor the names of its contributors may be used to
endorse or promote products derived from this Software without specific
prior written permission.
-
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS
FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
diff --git a/ArmPkg/Library/CompilerIntrinsicsLib/Arm/udivmoddi4.S b/ArmPkg/Library/CompilerIntrinsicsLib/Arm/udivmoddi4.S index 1c0f2eae67..4c0ef5a598 100644 --- a/ArmPkg/Library/CompilerIntrinsicsLib/Arm/udivmoddi4.S +++ b/ArmPkg/Library/CompilerIntrinsicsLib/Arm/udivmoddi4.S @@ -1,4 +1,4 @@ -#------------------------------------------------------------------------------
+#------------------------------------------------------------------------------
#
# Copyright (c) 2008 - 2009, Apple Inc. All rights reserved.<BR>
#
@@ -15,7 +15,7 @@ .text
.align 2
GCC_ASM_EXPORT(__udivmoddi4)
-
+
ASM_PFX(__udivmoddi4):
stmfd sp!, {r4, r5, r6, r7, lr}
add r7, sp, #12
diff --git a/ArmPkg/Library/CompilerIntrinsicsLib/Arm/udivmoddi4.c b/ArmPkg/Library/CompilerIntrinsicsLib/Arm/udivmoddi4.c index 829482ddf5..a268596a11 100644 --- a/ArmPkg/Library/CompilerIntrinsicsLib/Arm/udivmoddi4.c +++ b/ArmPkg/Library/CompilerIntrinsicsLib/Arm/udivmoddi4.c @@ -2,7 +2,7 @@ Compiler intrinsic for 64-bit compare, ported from LLVM code.
Copyright (c) 2008-2009, Apple Inc. All rights reserved.<BR>
-
+
This program and the accompanying materials
are licensed and made available under the terms and conditions of the BSD License
which accompanies this distribution. The full text of the license may be found at
@@ -15,37 +15,37 @@ /**
University of Illinois/NCSA
Open Source License
-
+
Copyright (c) 2003-2008 University of Illinois at Urbana-Champaign.
All rights reserved.
-
+
Developed by:
-
+
LLVM Team
-
+
University of Illinois at Urbana-Champaign
-
+
http://llvm.org
-
+
Permission is hereby granted, free of charge, to any person obtaining a copy of
this software and associated documentation files (the "Software"), to deal with
the Software without restriction, including without limitation the rights to
use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies
of the Software, and to permit persons to whom the Software is furnished to do
so, subject to the following conditions:
-
+
* Redistributions of source code must retain the above copyright notice,
this list of conditions and the following disclaimers.
-
+
* Redistributions in binary form must reproduce the above copyright notice,
this list of conditions and the following disclaimers in the
documentation and/or other materials provided with the distribution.
-
+
* Neither the names of the LLVM Team, University of Illinois at
Urbana-Champaign, nor the names of its contributors may be used to
endorse or promote products derived from this Software without specific
prior written permission.
-
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS
FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
@@ -75,12 +75,12 @@ __udivmoddi4 (UINT64 a, UINT64 b, UINT64* rem) udwords q;
udwords r;
unsigned sr;
-
+
if (b == 0) {
// ASSERT (FALSE);
return 0;
}
-
+
// special cases, X is unknown, K != 0
if (n.high == 0)
{
diff --git a/ArmPkg/Library/CompilerIntrinsicsLib/Arm/udivsi3.S b/ArmPkg/Library/CompilerIntrinsicsLib/Arm/udivsi3.S index a9223d7fb5..5e2d31cc11 100644 --- a/ArmPkg/Library/CompilerIntrinsicsLib/Arm/udivsi3.S +++ b/ArmPkg/Library/CompilerIntrinsicsLib/Arm/udivsi3.S @@ -1,4 +1,4 @@ -#------------------------------------------------------------------------------
+#------------------------------------------------------------------------------
#
# Copyright (c) 2008 - 2009, Apple Inc. All rights reserved.<BR>
#
diff --git a/ArmPkg/Library/CompilerIntrinsicsLib/Arm/udivsi3.c b/ArmPkg/Library/CompilerIntrinsicsLib/Arm/udivsi3.c index 020b3fadc5..8b9cb9f170 100644 --- a/ArmPkg/Library/CompilerIntrinsicsLib/Arm/udivsi3.c +++ b/ArmPkg/Library/CompilerIntrinsicsLib/Arm/udivsi3.c @@ -2,7 +2,7 @@ Compiler intrinsic for 32-bit unsigned div, ported from LLVM code.
Copyright (c) 2008 - 2009, Apple Inc. All rights reserved.<BR>
-
+
This program and the accompanying materials
are licensed and made available under the terms and conditions of the BSD License
which accompanies this distribution. The full text of the license may be found at
@@ -15,37 +15,37 @@ /**
University of Illinois/NCSA
Open Source License
-
+
Copyright (c) 2003-2008 University of Illinois at Urbana-Champaign.
All rights reserved.
-
+
Developed by:
-
+
LLVM Team
-
+
University of Illinois at Urbana-Champaign
-
+
http://llvm.org
-
+
Permission is hereby granted, free of charge, to any person obtaining a copy of
this software and associated documentation files (the "Software"), to deal with
the Software without restriction, including without limitation the rights to
use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies
of the Software, and to permit persons to whom the Software is furnished to do
so, subject to the following conditions:
-
+
* Redistributions of source code must retain the above copyright notice,
this list of conditions and the following disclaimers.
-
+
* Redistributions in binary form must reproduce the above copyright notice,
this list of conditions and the following disclaimers in the
documentation and/or other materials provided with the distribution.
-
+
* Neither the names of the LLVM Team, University of Illinois at
Urbana-Champaign, nor the names of its contributors may be used to
endorse or promote products derived from this Software without specific
prior written permission.
-
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS
FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
diff --git a/ArmPkg/Library/CompilerIntrinsicsLib/Arm/uldiv.S b/ArmPkg/Library/CompilerIntrinsicsLib/Arm/uldiv.S index 75b0bb93a0..4481c6d677 100755 --- a/ArmPkg/Library/CompilerIntrinsicsLib/Arm/uldiv.S +++ b/ArmPkg/Library/CompilerIntrinsicsLib/Arm/uldiv.S @@ -1,4 +1,4 @@ -//------------------------------------------------------------------------------
+//------------------------------------------------------------------------------
//
// Copyright (c) 2008 - 2009, Apple Inc. All rights reserved.<BR>
//
@@ -18,11 +18,11 @@ .align 2
GCC_ASM_EXPORT(__aeabi_uldivmod)
-//
+//
//UINT64
//EFIAPI
//__aeabi_uldivmod (
-// IN UINT64 Dividend
+// IN UINT64 Dividend
// IN UINT64 Divisor
// )
//
@@ -77,7 +77,7 @@ ASM_PFX(__aeabi_uldivmod_label2): mov ip, r3
mov lr, r2
b ASM_PFX(_ll_udiv_ginormous)
-
+
ASM_PFX(_ll_udiv_small):
cmp r4, ip, lsl #1
mov r3, #0 // 0x0
@@ -157,7 +157,7 @@ ASM_PFX(_ll_udiv_small_label5): add r1, r1, r3, lsl r6
mov r3, #0 // 0x0
ldmia sp!, {r4, r5, r6, pc}
-
+
ASM_PFX(_ll_udiv_big):
subs r0, r5, lr
mov r3, #0 // 0x0
@@ -245,7 +245,7 @@ ASM_PFX(_ll_udiv_big_label4): orr r2, r2, r4, ror r6
adc r1, r1, #0 // 0x0
ldmia sp!, {r4, r5, r6, pc}
-
+
ASM_PFX(_ll_udiv_ginormous):
subs r2, r5, lr
mov r1, #0 // 0x0
@@ -254,13 +254,13 @@ ASM_PFX(_ll_udiv_ginormous): movcc r2, r5
movcc r3, r4
ldmia sp!, {r4, r5, r6, pc}
-
+
ASM_PFX(_ll_div0):
ldmia sp!, {r4, r5, r6, lr}
mov r0, #0 // 0x0
mov r1, #0 // 0x0
b ASM_PFX(__aeabi_ldiv0)
-
+
ASM_PFX(__aeabi_ldiv0):
bx r14
diff --git a/ArmPkg/Library/CompilerIntrinsicsLib/Arm/uldiv.asm b/ArmPkg/Library/CompilerIntrinsicsLib/Arm/uldiv.asm index 393794c13a..aed649b151 100644 --- a/ArmPkg/Library/CompilerIntrinsicsLib/Arm/uldiv.asm +++ b/ArmPkg/Library/CompilerIntrinsicsLib/Arm/uldiv.asm @@ -1,4 +1,4 @@ -//------------------------------------------------------------------------------
+//------------------------------------------------------------------------------
//
// Copyright (c) 2008 - 2009, Apple Inc. All rights reserved.<BR>
//
@@ -18,11 +18,11 @@ AREA Uldivmod, CODE, READONLY
-;
+;
;UINT64
;EFIAPI
;__aeabi_uldivmod (
-; IN UINT64 Dividend
+; IN UINT64 Dividend
; IN UINT64 Divisor
; )
;
@@ -77,7 +77,7 @@ __aeabi_uldivmod_label2 mov ip, r3
mov lr, r2
b _ll_udiv_ginormous
-
+
_ll_udiv_small
cmp r4, ip, lsl #1
mov r3, #0 ; 0x0
@@ -157,7 +157,7 @@ _ll_udiv_small_label5 add r1, r1, r3, lsl r6
mov r3, #0 ; 0x0
ldmia sp!, {r4, r5, r6, pc}
-
+
_ll_udiv_big
subs r0, r5, lr
mov r3, #0 ; 0x0
@@ -245,7 +245,7 @@ _ll_udiv_big_label4 orr r2, r2, r4, ror r6
adc r1, r1, #0 ; 0x0
ldmia sp!, {r4, r5, r6, pc}
-
+
_ll_udiv_ginormous
subs r2, r5, lr
mov r1, #0 ; 0x0
@@ -254,13 +254,13 @@ _ll_udiv_ginormous movcc r2, r5
movcc r3, r4
ldmia sp!, {r4, r5, r6, pc}
-
+
_ll_div0
ldmia sp!, {r4, r5, r6, lr}
mov r0, #0 ; 0x0
mov r1, #0 ; 0x0
b __aeabi_ldiv0
-
+
__aeabi_ldiv0
BX r14
diff --git a/ArmPkg/Library/CompilerIntrinsicsLib/Arm/uldivmod.c b/ArmPkg/Library/CompilerIntrinsicsLib/Arm/uldivmod.c index feac60195d..8887938362 100755 --- a/ArmPkg/Library/CompilerIntrinsicsLib/Arm/uldivmod.c +++ b/ArmPkg/Library/CompilerIntrinsicsLib/Arm/uldivmod.c @@ -1,7 +1,7 @@ /** @file
Copyright (c) 2008 - 2010, Apple Inc. All rights reserved.<BR>
-
+
This program and the accompanying materials
are licensed and made available under the terms and conditions of the BSD License
which accompanies this distribution. The full text of the license may be found at
@@ -20,7 +20,7 @@ UINT32 __udivsi3(UINT32 n, UINT32 d); UINT32 __umodsi3(UINT32 a, UINT32 b);
-UINT64
+UINT64
__aeabi_uidivmod(unsigned numerator, unsigned denominator)
{
UINT64 Return;
@@ -32,7 +32,7 @@ __aeabi_uidivmod(unsigned numerator, unsigned denominator) }
unsigned
-__aeabi_uidiv (unsigned n, unsigned d)
+__aeabi_uidiv (unsigned n, unsigned d)
{
return __udivsi3 (n, d);
}
diff --git a/ArmPkg/Library/CompilerIntrinsicsLib/Arm/umoddi3.S b/ArmPkg/Library/CompilerIntrinsicsLib/Arm/umoddi3.S index 6e23057c25..6b718a6574 100644 --- a/ArmPkg/Library/CompilerIntrinsicsLib/Arm/umoddi3.S +++ b/ArmPkg/Library/CompilerIntrinsicsLib/Arm/umoddi3.S @@ -1,4 +1,4 @@ -#------------------------------------------------------------------------------
+#------------------------------------------------------------------------------
#
# Copyright (c) 2008 - 2009, Apple Inc. All rights reserved.<BR>
#
@@ -15,7 +15,7 @@ .text
.align 2
GCC_ASM_EXPORT(__umoddi3)
-
+
ASM_PFX(__umoddi3):
stmfd sp!, {r7, lr}
add r7, sp, #0
diff --git a/ArmPkg/Library/CompilerIntrinsicsLib/Arm/umoddi3.c b/ArmPkg/Library/CompilerIntrinsicsLib/Arm/umoddi3.c index ebd769755a..2a2ec61fd1 100644 --- a/ArmPkg/Library/CompilerIntrinsicsLib/Arm/umoddi3.c +++ b/ArmPkg/Library/CompilerIntrinsicsLib/Arm/umoddi3.c @@ -2,7 +2,7 @@ Compiler intrinsic for 64-bit unsigned mod, ported from LLVM code.
Copyright (c) 2008 - 2009, Apple Inc. All rights reserved.<BR>
-
+
This program and the accompanying materials
are licensed and made available under the terms and conditions of the BSD License
which accompanies this distribution. The full text of the license may be found at
@@ -15,37 +15,37 @@ /**
University of Illinois/NCSA
Open Source License
-
+
Copyright (c) 2003-2008 University of Illinois at Urbana-Champaign.
All rights reserved.
-
+
Developed by:
-
+
LLVM Team
-
+
University of Illinois at Urbana-Champaign
-
+
http://llvm.org
-
+
Permission is hereby granted, free of charge, to any person obtaining a copy of
this software and associated documentation files (the "Software"), to deal with
the Software without restriction, including without limitation the rights to
use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies
of the Software, and to permit persons to whom the Software is furnished to do
so, subject to the following conditions:
-
+
* Redistributions of source code must retain the above copyright notice,
this list of conditions and the following disclaimers.
-
+
* Redistributions in binary form must reproduce the above copyright notice,
this list of conditions and the following disclaimers in the
documentation and/or other materials provided with the distribution.
-
+
* Neither the names of the LLVM Team, University of Illinois at
Urbana-Champaign, nor the names of its contributors may be used to
endorse or promote products derived from this Software without specific
prior written permission.
-
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS
FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
diff --git a/ArmPkg/Library/CompilerIntrinsicsLib/Arm/umodsi3.S b/ArmPkg/Library/CompilerIntrinsicsLib/Arm/umodsi3.S index bd32fd1244..76c26beb0b 100644 --- a/ArmPkg/Library/CompilerIntrinsicsLib/Arm/umodsi3.S +++ b/ArmPkg/Library/CompilerIntrinsicsLib/Arm/umodsi3.S @@ -1,4 +1,4 @@ -#------------------------------------------------------------------------------
+#------------------------------------------------------------------------------
#
# Copyright (c) 2008 - 2009, Apple Inc. All rights reserved.<BR>
#
@@ -15,7 +15,7 @@ .text
.align 2
GCC_ASM_EXPORT(__umodsi3)
-
+
ASM_PFX(__umodsi3):
stmfd sp!, {r4, r5, r7, lr}
add r7, sp, #8
diff --git a/ArmPkg/Library/CompilerIntrinsicsLib/Arm/umodsi3.c b/ArmPkg/Library/CompilerIntrinsicsLib/Arm/umodsi3.c index e3aa4da87c..d0a5b76f40 100644 --- a/ArmPkg/Library/CompilerIntrinsicsLib/Arm/umodsi3.c +++ b/ArmPkg/Library/CompilerIntrinsicsLib/Arm/umodsi3.c @@ -2,7 +2,7 @@ Compiler intrinsic for 32-bit unsigned mod, ported from LLVM code.
Copyright (c) 2008 - 2009, Apple Inc. All rights reserved.<BR>
-
+
This program and the accompanying materials
are licensed and made available under the terms and conditions of the BSD License
which accompanies this distribution. The full text of the license may be found at
@@ -15,37 +15,37 @@ /**
University of Illinois/NCSA
Open Source License
-
+
Copyright (c) 2003-2008 University of Illinois at Urbana-Champaign.
All rights reserved.
-
+
Developed by:
-
+
LLVM Team
-
+
University of Illinois at Urbana-Champaign
-
+
http://llvm.org
-
+
Permission is hereby granted, free of charge, to any person obtaining a copy of
this software and associated documentation files (the "Software"), to deal with
the Software without restriction, including without limitation the rights to
use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies
of the Software, and to permit persons to whom the Software is furnished to do
so, subject to the following conditions:
-
+
* Redistributions of source code must retain the above copyright notice,
this list of conditions and the following disclaimers.
-
+
* Redistributions in binary form must reproduce the above copyright notice,
this list of conditions and the following disclaimers in the
documentation and/or other materials provided with the distribution.
-
+
* Neither the names of the LLVM Team, University of Illinois at
Urbana-Champaign, nor the names of its contributors may be used to
endorse or promote products derived from this Software without specific
prior written permission.
-
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS
FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
diff --git a/ArmPkg/Library/CompilerIntrinsicsLib/Arm/uread.asm b/ArmPkg/Library/CompilerIntrinsicsLib/Arm/uread.asm index 9aefa808de..0a0d06f528 100644 --- a/ArmPkg/Library/CompilerIntrinsicsLib/Arm/uread.asm +++ b/ArmPkg/Library/CompilerIntrinsicsLib/Arm/uread.asm @@ -1,4 +1,4 @@ -//------------------------------------------------------------------------------
+//------------------------------------------------------------------------------
//
// Copyright (c) 2008 - 2009, Apple Inc. All rights reserved.<BR>
//
diff --git a/ArmPkg/Library/CompilerIntrinsicsLib/Arm/uwrite.asm b/ArmPkg/Library/CompilerIntrinsicsLib/Arm/uwrite.asm index 0b79e3416b..85e1ba8d6d 100644 --- a/ArmPkg/Library/CompilerIntrinsicsLib/Arm/uwrite.asm +++ b/ArmPkg/Library/CompilerIntrinsicsLib/Arm/uwrite.asm @@ -1,4 +1,4 @@ -//------------------------------------------------------------------------------
+//------------------------------------------------------------------------------
//
// Copyright (c) 2008 - 2009, Apple Inc. All rights reserved.<BR>
//
diff --git a/ArmPkg/Library/CompilerIntrinsicsLib/CompilerIntrinsicsLib.inf b/ArmPkg/Library/CompilerIntrinsicsLib/CompilerIntrinsicsLib.inf index ace30e82ff..a1c9ae65b0 100644 --- a/ArmPkg/Library/CompilerIntrinsicsLib/CompilerIntrinsicsLib.inf +++ b/ArmPkg/Library/CompilerIntrinsicsLib/CompilerIntrinsicsLib.inf @@ -20,7 +20,7 @@ FILE_GUID = 855274FA-3575-4C20-9709-C031DC5589FA
MODULE_TYPE = BASE
VERSION_STRING = 1.0
- LIBRARY_CLASS = CompilerIntrinsicsLib
+ LIBRARY_CLASS = CompilerIntrinsicsLib
[Sources.AARCH64]
AArch64/memcpy.S
@@ -41,7 +41,7 @@ Arm/div.asm | RVCT
Arm/uldiv.asm | RVCT
Arm/ldivmod.asm | RVCT
-
+
#
# Move .c to .s to work around LLVM issues
@@ -60,14 +60,14 @@ Arm/memcpy.S | GCC
Arm/memset.S | GCC
-
+
# Arm/modsi3.c | GCC
# Arm/moddi3.c | GCC
-# Arm/muldi3.c | GCC
+# Arm/muldi3.c | GCC
Arm/modsi3.S | GCC
Arm/moddi3.S | GCC
Arm/muldi3.S | GCC
- Arm/mullu.S | GCC
+ Arm/mullu.S | GCC
# Arm/udivsi3.c | GCC
# Arm/umodsi3.c | GCC
diff --git a/ArmPkg/Library/DebugAgentSymbolsBaseLib/Arm/DebugAgentException.S b/ArmPkg/Library/DebugAgentSymbolsBaseLib/Arm/DebugAgentException.S index d92acfeacb..0566a89e2c 100644 --- a/ArmPkg/Library/DebugAgentSymbolsBaseLib/Arm/DebugAgentException.S +++ b/ArmPkg/Library/DebugAgentSymbolsBaseLib/Arm/DebugAgentException.S @@ -81,7 +81,7 @@ ASM_PFX(ResetEntry): stmfd SP!,{LR} @ Store the link register for the current mode
sub SP,SP,#0x20 @ Save space for SP, LR, PC, IFAR - CPSR
stmfd SP!,{R0-R12} @ Store the register state
-
+
mov R0,#0 @ ExceptionType
ldr R1,ASM_PFX(CommonExceptionEntry)
bx R1
diff --git a/ArmPkg/Library/DebugAgentSymbolsBaseLib/Arm/DebugAgentException.asm b/ArmPkg/Library/DebugAgentSymbolsBaseLib/Arm/DebugAgentException.asm index f281c0603f..b879142f27 100644 --- a/ArmPkg/Library/DebugAgentSymbolsBaseLib/Arm/DebugAgentException.asm +++ b/ArmPkg/Library/DebugAgentSymbolsBaseLib/Arm/DebugAgentException.asm @@ -44,7 +44,7 @@ This is the stack constructed by the exception handler (low address to high addr IFAR 0x50
LR 0x54 # SVC Link register (we need to restore it)
-
+
LR 0x58 # pushed by srsfd
CPSR 0x5c
@@ -77,7 +77,7 @@ ResetEntry stmfd SP!,{LR} ; Store the link register for the current mode
sub SP,SP,#0x20 ; Save space for SP, LR, PC, IFAR - CPSR
stmfd SP!,{R0-R12} ; Store the register state
-
+
mov R0,#0 ; ExceptionType
ldr R1,CommonExceptionEntry
bx R1
diff --git a/ArmPkg/Library/DebugAgentSymbolsBaseLib/DebugAgentSymbolsBaseLib.inf b/ArmPkg/Library/DebugAgentSymbolsBaseLib/DebugAgentSymbolsBaseLib.inf index 578bc71bb7..6b784f749b 100644 --- a/ArmPkg/Library/DebugAgentSymbolsBaseLib/DebugAgentSymbolsBaseLib.inf +++ b/ArmPkg/Library/DebugAgentSymbolsBaseLib/DebugAgentSymbolsBaseLib.inf @@ -1,14 +1,14 @@ -#
+#
# Copyright (c) 2011-2012, ARM Limited. All rights reserved.
-#
-# This program and the accompanying materials
-# are licensed and made available under the terms and conditions of the BSD License
-# which accompanies this distribution. The full text of the license may be found at
-# http://opensource.org/licenses/bsd-license.php
#
-# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
-# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
-#
+# This program and the accompanying materials
+# are licensed and made available under the terms and conditions of the BSD License
+# which accompanies this distribution. The full text of the license may be found at
+# http://opensource.org/licenses/bsd-license.php
+#
+# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
+# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
+#
#
[Defines]
diff --git a/ArmPkg/Library/DebugPeCoffExtraActionLib/DebugPeCoffExtraActionLib.c b/ArmPkg/Library/DebugPeCoffExtraActionLib/DebugPeCoffExtraActionLib.c index 0758af8ac6..41018decab 100755 --- a/ArmPkg/Library/DebugPeCoffExtraActionLib/DebugPeCoffExtraActionLib.c +++ b/ArmPkg/Library/DebugPeCoffExtraActionLib/DebugPeCoffExtraActionLib.c @@ -25,7 +25,7 @@ WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED. /**
- If the build is done on cygwin the paths are cygpaths.
+ If the build is done on cygwin the paths are cygpaths.
/cygdrive/c/tmp.txt vs c:\tmp.txt so we need to convert
them to work with RVD commands
@@ -42,12 +42,12 @@ DeCygwinPathIfNeeded ( CHAR8 *Ptr;
UINTN Index;
UINTN Index2;
-
+
Ptr = AsciiStrStr (Name, "/cygdrive/");
if (Ptr == NULL) {
return Name;
}
-
+
for (Index = 9, Index2 = 0; (Index < (Size + 9)) && (Ptr[Index] != '\0'); Index++, Index2++) {
Temp[Index2] = Ptr[Index];
if (Temp[Index2] == '/') {
@@ -79,7 +79,7 @@ PeCoffLoaderRelocateImageExtraAction ( IN OUT PE_COFF_LOADER_IMAGE_CONTEXT *ImageContext
)
{
-#if !defined(MDEPKG_NDEBUG)
+#if !defined(MDEPKG_NDEBUG)
CHAR8 Temp[512];
#endif
@@ -108,9 +108,9 @@ PeCoffLoaderRelocateImageExtraAction ( /**
Performs additional actions just before a PE/COFF image is unloaded. Any resources
that were allocated by PeCoffLoaderRelocateImageExtraAction() must be freed.
-
+
If ImageContext is NULL, then ASSERT().
-
+
@param ImageContext Pointer to the image context structure that describes the
PE/COFF image that is being unloaded.
@@ -124,7 +124,7 @@ PeCoffLoaderUnloadImageExtraAction ( #if !defined(MDEPKG_NDEBUG)
CHAR8 Temp[512];
#endif
-
+
if (ImageContext->PdbPointer) {
#ifdef __CC_ARM
// Print out the command for the RVD debugger to load symbols for this image
diff --git a/ArmPkg/Library/DebugUncachedMemoryAllocationLib/DebugUncachedMemoryAllocationLib.c b/ArmPkg/Library/DebugUncachedMemoryAllocationLib/DebugUncachedMemoryAllocationLib.c index 6253c0d5c7..00e01a905c 100644 --- a/ArmPkg/Library/DebugUncachedMemoryAllocationLib/DebugUncachedMemoryAllocationLib.c +++ b/ArmPkg/Library/DebugUncachedMemoryAllocationLib/DebugUncachedMemoryAllocationLib.c @@ -1,7 +1,7 @@ /** @file
Debug version of the UncachedMemoryAllocation lib that uses the VirtualUncachedPages
protocol, produced by the DXE CPU driver, to produce debuggable uncached memory buffers.
-
+
The DMA rules for EFI contain the concept of a PCI (DMA master) address for memory and
a CPU (C code) address for the memory buffer that don't have to be the same. There seem to
be common errors out there with folks mixing up the two addresses. This library causes
@@ -11,7 +11,7 @@ PcdArmUncachedMemoryMask ored into the physical address.
Copyright (c) 2008 - 2010, Apple Inc. All rights reserved.<BR>
-
+
This program and the accompanying materials
are licensed and made available under the terms and conditions of the BSD License
which accompanies this distribution. The full text of the license may be found at
@@ -37,18 +37,18 @@ VOID *
UncachedInternalAllocatePages (
- IN EFI_MEMORY_TYPE MemoryType,
+ IN EFI_MEMORY_TYPE MemoryType,
IN UINTN Pages
);
VOID *
UncachedInternalAllocateAlignedPages (
- IN EFI_MEMORY_TYPE MemoryType,
+ IN EFI_MEMORY_TYPE MemoryType,
IN UINTN Pages,
IN UINTN Alignment
);
-
-
+
+
EFI_CPU_ARCH_PROTOCOL *gDebugUncachedCpu;
VIRTUAL_UNCACHED_PAGES_PROTOCOL *gVirtualUncachedPages;
@@ -75,13 +75,13 @@ AddPagesToList ( )
{
FREE_PAGE_NODE *NewNode;
-
+
NewNode = AllocatePool (sizeof (LIST_ENTRY));
if (NewNode == NULL) {
ASSERT (FALSE);
return;
}
-
+
NewNode->Buffer = Buffer;
NewNode->Allocation = Allocation;
NewNode->Pages = Pages;
@@ -102,13 +102,13 @@ RemovePagesFromList ( *Allocation = NULL;
*Pages = 0;
-
+
for (Link = mPageList.ForwardLink; Link != &mPageList; Link = Link->ForwardLink) {
OldNode = BASE_CR (Link, FREE_PAGE_NODE, Link);
if (OldNode->Buffer == Buffer) {
*Allocation = OldNode->Allocation;
*Pages = OldNode->Pages;
-
+
RemoveEntryList (&OldNode->Link);
FreePool (OldNode);
return;
@@ -127,9 +127,9 @@ ConvertToPhysicalAddress ( {
UINTN UncachedMemoryMask = (UINTN)PcdGet64 (PcdArmUncachedMemoryMask);
UINTN PhysicalAddress;
-
+
PhysicalAddress = (UINTN)VirtualAddress & ~UncachedMemoryMask;
-
+
return (EFI_PHYSICAL_ADDRESS)PhysicalAddress;
}
@@ -141,9 +141,9 @@ ConvertToUncachedAddress ( {
UINTN UncachedMemoryMask = (UINTN)PcdGet64 (PcdArmUncachedMemoryMask);
UINTN UncachedAddress;
-
+
UncachedAddress = (UINTN)Address | UncachedMemoryMask;
-
+
return (VOID *)UncachedAddress;
}
@@ -151,7 +151,7 @@ ConvertToUncachedAddress ( VOID *
UncachedInternalAllocatePages (
- IN EFI_MEMORY_TYPE MemoryType,
+ IN EFI_MEMORY_TYPE MemoryType,
IN UINTN Pages
)
{
@@ -202,7 +202,7 @@ UncachedFreePages ( VOID *
UncachedInternalAllocateAlignedPages (
- IN EFI_MEMORY_TYPE MemoryType,
+ IN EFI_MEMORY_TYPE MemoryType,
IN UINTN Pages,
IN UINTN Alignment
)
@@ -218,7 +218,7 @@ UncachedInternalAllocateAlignedPages ( // Alignment must be a power of two or zero.
//
ASSERT ((Alignment & (Alignment - 1)) == 0);
-
+
if (Pages == 0) {
return NULL;
}
@@ -232,7 +232,7 @@ UncachedInternalAllocateAlignedPages ( // Make sure that Pages plus EFI_SIZE_TO_PAGES (Alignment) does not overflow.
//
ASSERT (RealPages > Pages);
-
+
Status = gBS->AllocatePages (AllocateAnyPages, MemoryType, RealPages, &Memory);
if (EFI_ERROR (Status)) {
return NULL;
@@ -265,14 +265,14 @@ UncachedInternalAllocateAlignedPages ( }
AlignedMemory = (UINTN) Memory;
}
-
+
Status = gVirtualUncachedPages->ConvertPages (gVirtualUncachedPages, AlignedMemory, Pages * EFI_PAGE_SIZE, PcdGet64 (PcdArmUncachedMemoryMask), &gAttributes);
if (EFI_ERROR (Status)) {
return NULL;
}
-
+
AlignedMemory = (EFI_PHYSICAL_ADDRESS)(UINTN)ConvertToUncachedAddress ((VOID *)(UINTN)AlignedMemory);
-
+
return (VOID *)(UINTN)AlignedMemory;
}
@@ -285,15 +285,15 @@ UncachedFreeAlignedPages ( )
{
EFI_STATUS Status;
- EFI_PHYSICAL_ADDRESS Memory;
+ EFI_PHYSICAL_ADDRESS Memory;
ASSERT (Pages != 0);
-
+
Memory = ConvertToPhysicalAddress (Buffer);
-
+
Status = gVirtualUncachedPages->RevertPages (gVirtualUncachedPages, Memory, Pages * EFI_PAGE_SIZE, PcdGet64 (PcdArmUncachedMemoryMask), gAttributes);
-
+
Status = gBS->FreePages ((EFI_PHYSICAL_ADDRESS) (UINTN) Memory, Pages);
ASSERT_EFI_ERROR (Status);
}
@@ -309,7 +309,7 @@ UncachedInternalAllocateAlignedPool ( )
{
VOID *AlignedAddress;
-
+
//
// Alignment must be a power of two or zero.
//
@@ -318,7 +318,7 @@ UncachedInternalAllocateAlignedPool ( if (Alignment < EFI_PAGE_SIZE) {
Alignment = EFI_PAGE_SIZE;
}
-
+
AlignedAddress = UncachedInternalAllocateAlignedPages (PoolType, EFI_SIZE_TO_PAGES (AllocationSize), Alignment);
if (AlignedAddress == NULL) {
return NULL;
@@ -413,7 +413,7 @@ UncachedInternalAllocateAlignedCopyPool ( )
{
VOID *Memory;
-
+
ASSERT (Buffer != NULL);
ASSERT (AllocationSize <= (MAX_ADDRESS - (UINTN) Buffer + 1));
@@ -465,7 +465,7 @@ UncachedFreeAlignedPool ( {
VOID *Allocation;
UINTN Pages;
-
+
RemovePagesFromList (Buffer, &Allocation, &Pages);
UncachedFreePages (Allocation, Pages);
@@ -473,7 +473,7 @@ UncachedFreeAlignedPool ( VOID *
UncachedInternalAllocatePool (
- IN EFI_MEMORY_TYPE MemoryType,
+ IN EFI_MEMORY_TYPE MemoryType,
IN UINTN AllocationSize
)
{
@@ -510,9 +510,9 @@ UncachedAllocateReservedPool ( VOID *
UncachedInternalAllocateZeroPool (
- IN EFI_MEMORY_TYPE PoolType,
+ IN EFI_MEMORY_TYPE PoolType,
IN UINTN AllocationSize
- )
+ )
{
VOID *Memory;
@@ -552,10 +552,10 @@ UncachedAllocateReservedZeroPool ( VOID *
UncachedInternalAllocateCopyPool (
- IN EFI_MEMORY_TYPE PoolType,
+ IN EFI_MEMORY_TYPE PoolType,
IN UINTN AllocationSize,
IN CONST VOID *Buffer
- )
+ )
{
VOID *Memory;
@@ -567,7 +567,7 @@ UncachedInternalAllocateCopyPool ( Memory = CopyMem (Memory, Buffer, AllocationSize);
}
return Memory;
-}
+}
VOID *
EFIAPI
@@ -642,7 +642,7 @@ DebugUncachedMemoryAllocationLibConstructor ( )
{
EFI_STATUS Status;
-
+
Status = gBS->LocateProtocol (&gEfiCpuArchProtocolGuid, NULL, (VOID **)&gDebugUncachedCpu);
ASSERT_EFI_ERROR(Status);
diff --git a/ArmPkg/Library/DebugUncachedMemoryAllocationLib/DebugUncachedMemoryAllocationLib.inf b/ArmPkg/Library/DebugUncachedMemoryAllocationLib/DebugUncachedMemoryAllocationLib.inf index b5e9fd8e90..213188ac2c 100644 --- a/ArmPkg/Library/DebugUncachedMemoryAllocationLib/DebugUncachedMemoryAllocationLib.inf +++ b/ArmPkg/Library/DebugUncachedMemoryAllocationLib/DebugUncachedMemoryAllocationLib.inf @@ -1,5 +1,5 @@ #/** @file
-#
+#
#
# Copyright (c) 2008 - 2010, Apple Inc. All rights reserved.<BR>
#
@@ -41,7 +41,7 @@ [FixedPcd]
gArmTokenSpaceGuid.PcdArmUncachedMemoryMask
-
-
+
+
[Depex]
- gEfiCpuArchProtocolGuid AND gVirtualUncachedPagesProtocolGuid
\ No newline at end of file + gEfiCpuArchProtocolGuid AND gVirtualUncachedPagesProtocolGuid
diff --git a/ArmPkg/Library/DefaultExceptionHandlerLib/Arm/DefaultExceptionHandler.c b/ArmPkg/Library/DefaultExceptionHandlerLib/Arm/DefaultExceptionHandler.c index 74e2a7602c..0be21a6211 100644 --- a/ArmPkg/Library/DefaultExceptionHandlerLib/Arm/DefaultExceptionHandler.c +++ b/ArmPkg/Library/DefaultExceptionHandlerLib/Arm/DefaultExceptionHandler.c @@ -3,7 +3,7 @@ Copyright (c) 2008 - 2010, Apple Inc. All rights reserved.<BR>
Copyright (c) 2012, ARM Ltd. All rights reserved.<BR>
-
+
This program and the accompanying materials
are licensed and made available under the terms and conditions of the BSD License
which accompanies this distribution. The full text of the license may be found at
@@ -42,9 +42,9 @@ GetImageName ( );
/**
- Convert the Current Program Status Register (CPSR) to a string. The string is
- a defacto standard in the ARM world.
-
+ Convert the Current Program Status Register (CPSR) to a string. The string is
+ a defacto standard in the ARM world.
+
It is possible to add extra bits by adding them to CpsrChar array.
@param Cpsr ARM CPSR register value
@@ -73,7 +73,7 @@ CpsrString ( { 5, 't' },
{ 0, '?' }
};
-
+
Str = ReturnStr;
for (Index = 0; CpsrChar[Index].BIT != 0; Index++, Str++) {
@@ -83,10 +83,10 @@ CpsrString ( *Str &= ~0x20;
}
}
-
+
*Str++ = '_';
*Str = '\0';
-
+
switch (Cpsr & 0x1f) {
case 0x10:
ModeStr = "usr";
@@ -112,15 +112,15 @@ CpsrString ( case 0x1f:
ModeStr = "sys";
break;
-
+
default:
ModeStr = "???";
break;
}
-
+
AsciiStrCat (Str, ModeStr);
return;
-}
+}
CHAR8 *
FaultStatusToString (
@@ -164,7 +164,7 @@ STATIC CHAR8 *gExceptionTypeString[] = { /**
This is the default action to take on an unexpected exception
-
+
Since this is exception context don't do anything crazy like try to allcoate memory.
@param ExceptionType Type of the exception
@@ -198,31 +198,31 @@ DefaultExceptionHandler ( CHAR8 Buffer[80];
UINT8 *DisAsm;
UINT32 ItBlock;
-
+
CpsrString (SystemContext.SystemContextArm->CPSR, CpsrStr);
DEBUG ((EFI_D_ERROR, "%a\n", CpsrStr));
-
+
Pdb = GetImageName (SystemContext.SystemContextArm->PC, &ImageBase, &PeCoffSizeOfHeader);
Offset = SystemContext.SystemContextArm->PC - ImageBase;
if (Pdb != NULL) {
DEBUG ((EFI_D_ERROR, "%a\n", Pdb));
//
- // A PE/COFF image loads its headers into memory so the headers are
+ // A PE/COFF image loads its headers into memory so the headers are
// included in the linked addresses. ELF and Mach-O images do not
// include the headers so the first byte of the image is usually
// text (code). If you look at link maps from ELF or Mach-O images
// you need to subtract out the size of the PE/COFF header to get
- // get the offset that matches the link map.
+ // get the offset that matches the link map.
//
DEBUG ((EFI_D_ERROR, "loaded at 0x%08x (PE/COFF offset) 0x%x (ELF or Mach-O offset) 0x%x", ImageBase, Offset, Offset - PeCoffSizeOfHeader));
-
+
// If we come from an image it is safe to show the instruction. We know it should not fault
DisAsm = (UINT8 *)(UINTN)SystemContext.SystemContextArm->PC;
ItBlock = 0;
DisassembleInstruction (&DisAsm, (SystemContext.SystemContextArm->CPSR & BIT5) == BIT5, TRUE, &ItBlock, Buffer, sizeof (Buffer));
DEBUG ((EFI_D_ERROR, "\n%a", Buffer));
-
+
switch (ExceptionType) {
case EXCEPT_ARM_UNDEFINED_INSTRUCTION:
case EXCEPT_ARM_SOFTWARE_INTERRUPT:
@@ -231,7 +231,7 @@ DefaultExceptionHandler ( // advance PC past the faulting instruction
PcAdjust = (UINTN)DisAsm - SystemContext.SystemContextArm->PC;
break;
-
+
default:
break;
}
@@ -258,11 +258,11 @@ DefaultExceptionHandler ( DEBUG ((EFI_D_ERROR, "\n"));
ASSERT (FALSE);
-
+
// Clear the error registers that we have already displayed incase some one wants to keep going
SystemContext.SystemContextArm->DFSR = 0;
SystemContext.SystemContextArm->IFSR = 0;
- // If some one is stepping past the exception handler adjust the PC to point to the next instruction
+ // If some one is stepping past the exception handler adjust the PC to point to the next instruction
SystemContext.SystemContextArm->PC += PcAdjust;
}
diff --git a/ArmPkg/Library/PeiServicesTablePointerLib/PeiServicesTablePointer.c b/ArmPkg/Library/PeiServicesTablePointerLib/PeiServicesTablePointer.c index 0b140e4fdc..c2a4a354ba 100644 --- a/ArmPkg/Library/PeiServicesTablePointerLib/PeiServicesTablePointer.c +++ b/ArmPkg/Library/PeiServicesTablePointerLib/PeiServicesTablePointer.c @@ -1,6 +1,6 @@ /** @file
PEI Services Table Pointer Library.
-
+
This library is used for PEIM which does executed from flash device directly but
executed in memory.
@@ -22,13 +22,13 @@ #include <Library/DebugLib.h>
/**
- Caches a pointer PEI Services Table.
-
- Caches the pointer to the PEI Services Table specified by PeiServicesTablePointer
+ Caches a pointer PEI Services Table.
+
+ Caches the pointer to the PEI Services Table specified by PeiServicesTablePointer
in a platform specific manner.
-
+
If PeiServicesTablePointer is NULL, then ASSERT().
-
+
@param PeiServicesTablePointer The address of PeiServices pointer.
**/
VOID
@@ -43,10 +43,10 @@ SetPeiServicesTablePointer ( /**
Retrieves the cached value of the PEI Services Table pointer.
- Returns the cached value of the PEI Services Table pointer in a CPU specific manner
- as specified in the CPU binding section of the Platform Initialization Pre-EFI
+ Returns the cached value of the PEI Services Table pointer in a CPU specific manner
+ as specified in the CPU binding section of the Platform Initialization Pre-EFI
Initialization Core Interface Specification.
-
+
If the cached PEI Services Table pointer is NULL, then ASSERT().
@return The pointer to PeiServices.
diff --git a/ArmPkg/Library/PeiServicesTablePointerLib/PeiServicesTablePointerLib.inf b/ArmPkg/Library/PeiServicesTablePointerLib/PeiServicesTablePointerLib.inf index 297b95d9a5..fd75977769 100644 --- a/ArmPkg/Library/PeiServicesTablePointerLib/PeiServicesTablePointerLib.inf +++ b/ArmPkg/Library/PeiServicesTablePointerLib/PeiServicesTablePointerLib.inf @@ -40,6 +40,6 @@ [LibraryClasses]
ArmLib
DebugLib
-
+
[Pcd]
-
+
diff --git a/ArmPkg/Library/RvdPeCoffExtraActionLib/RvdPeCoffExtraActionLib.c b/ArmPkg/Library/RvdPeCoffExtraActionLib/RvdPeCoffExtraActionLib.c index d55608b45b..dc66abd513 100644 --- a/ArmPkg/Library/RvdPeCoffExtraActionLib/RvdPeCoffExtraActionLib.c +++ b/ArmPkg/Library/RvdPeCoffExtraActionLib/RvdPeCoffExtraActionLib.c @@ -25,7 +25,7 @@ WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED. #include <Library/PrintLib.h>
/**
- Append string to debugger script file, create file if needed.
+ Append string to debugger script file, create file if needed.
This library can show up in mulitple places so we need to append the file every time we write to it.
For example Sec can use this to load the DXE core, and the DXE core would use this to load all the
@@ -41,8 +41,8 @@ WriteStringToFile ( )
{
// Working around and issue with the code that is commented out. For now send it to the console.
- // You can copy the console into a file and source the file as a script and you get symbols.
- // This gets you all the symbols except for SEC. To get SEC symbols you need to copy the
+ // You can copy the console into a file and source the file as a script and you get symbols.
+ // This gets you all the symbols except for SEC. To get SEC symbols you need to copy the
// debug print in the SEC into the debugger manually
SemihostWriteString (Buffer);
/*
@@ -59,7 +59,7 @@ WriteStringToFile ( /**
- If the build is done on cygwin the paths are cygpaths.
+ If the build is done on cygwin the paths are cygpaths.
/cygdrive/c/tmp.txt vs c:\tmp.txt so we need to convert
them to work with RVD commands
@@ -74,14 +74,14 @@ DeCygwinPathIfNeeded ( CHAR8 *Ptr;
UINTN Index;
UINTN Len;
-
+
Ptr = AsciiStrStr (Name, "/cygdrive/");
if (Ptr == NULL) {
return Name;
}
-
+
Len = AsciiStrLen (Ptr);
-
+
// convert "/cygdrive" to spaces
for (Index = 0; Index < 9; Index++) {
Ptr[Index] = ' ';
@@ -90,7 +90,7 @@ DeCygwinPathIfNeeded ( // convert /c to c:
Ptr[9] = Ptr[10];
Ptr[10] = ':';
-
+
// switch path separators
for (Index = 11; Index < Len; Index++) {
if (Ptr[Index] == '/') {
@@ -118,14 +118,14 @@ PeCoffLoaderRelocateImageExtraAction ( )
{
CHAR8 Buffer[256];
-
+
#if (__ARMCC_VERSION < 500000)
AsciiSPrint (Buffer, sizeof(Buffer), "load /a /ni /np \"%a\" &0x%08x\n", ImageContext->PdbPointer, (UINTN)(ImageContext->ImageAddress + ImageContext->SizeOfHeaders));
#else
AsciiSPrint (Buffer, sizeof(Buffer), "add-symbol-file %a 0x%08x\n", ImageContext->PdbPointer, (UINTN)(ImageContext->ImageAddress + ImageContext->SizeOfHeaders));
#endif
DeCygwinPathIfNeeded (&Buffer[16]);
-
+
WriteStringToFile (Buffer, AsciiStrSize (Buffer));
}
@@ -134,9 +134,9 @@ PeCoffLoaderRelocateImageExtraAction ( /**
Performs additional actions just before a PE/COFF image is unloaded. Any resources
that were allocated by PeCoffLoaderRelocateImageExtraAction() must be freed.
-
+
If ImageContext is NULL, then ASSERT().
-
+
@param ImageContext Pointer to the image context structure that describes the
PE/COFF image that is being unloaded.
@@ -148,9 +148,9 @@ PeCoffLoaderUnloadImageExtraAction ( )
{
CHAR8 Buffer[256];
-
+
AsciiSPrint (Buffer, sizeof(Buffer), "unload symbols_only \"%a\"\n", ImageContext->PdbPointer);
DeCygwinPathIfNeeded (Buffer);
-
+
WriteStringToFile (Buffer, AsciiStrSize (Buffer));
}
diff --git a/ArmPkg/Library/SemiHostingDebugLib/DebugLib.c b/ArmPkg/Library/SemiHostingDebugLib/DebugLib.c index f60a19f882..ec03edb774 100644 --- a/ArmPkg/Library/SemiHostingDebugLib/DebugLib.c +++ b/ArmPkg/Library/SemiHostingDebugLib/DebugLib.c @@ -3,13 +3,13 @@ Copyright (c) 2006 - 2007, Intel Corporation. All rights reserved.<BR>
Portions copyright (c) 2008 - 2009, Apple Inc. All rights reserved.<BR>
- This program and the accompanying materials
- are licensed and made available under the terms and conditions of the BSD License
- which accompanies this distribution. The full text of the license may be found at
- http://opensource.org/licenses/bsd-license.php
+ This program and the accompanying materials
+ are licensed and made available under the terms and conditions of the BSD License
+ which accompanies this distribution. The full text of the license may be found at
+ http://opensource.org/licenses/bsd-license.php
- THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
- WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
+ THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
+ WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
**/
@@ -23,7 +23,7 @@ #include <Library/SemihostLib.h>
//
-// Define the maximum debug and assert message length that this library supports
+// Define the maximum debug and assert message length that this library supports
//
#define MAX_DEBUG_MESSAGE_LENGTH 0x100
@@ -31,8 +31,8 @@ Prints a debug message to the debug output device if the specified error level is enabled.
- If any bit in ErrorLevel is also set in PcdDebugPrintErrorLevel, then print
- the message specified by Format and the associated variable argument list to
+ If any bit in ErrorLevel is also set in PcdDebugPrintErrorLevel, then print
+ the message specified by Format and the associated variable argument list to
the debug output device.
If Format is NULL, then ASSERT().
@@ -77,14 +77,14 @@ DebugPrint ( /**
- Prints an assert message containing a filename, line number, and description.
+ Prints an assert message containing a filename, line number, and description.
This may be followed by a breakpoint or a dead loop.
- Print a message of the form "ASSERT <FileName>(<LineNumber>): <Description>\n"
- to the debug output device. If DEBUG_PROPERTY_ASSERT_BREAKPOINT_ENABLED bit of
- PcdDebugProperyMask is set then CpuBreakpoint() is called. Otherwise, if
- DEBUG_PROPERTY_ASSERT_DEADLOOP_ENABLED bit of PcdDebugProperyMask is set then
- CpuDeadLoop() is called. If neither of these bits are set, then this function
+ Print a message of the form "ASSERT <FileName>(<LineNumber>): <Description>\n"
+ to the debug output device. If DEBUG_PROPERTY_ASSERT_BREAKPOINT_ENABLED bit of
+ PcdDebugProperyMask is set then CpuBreakpoint() is called. Otherwise, if
+ DEBUG_PROPERTY_ASSERT_DEADLOOP_ENABLED bit of PcdDebugProperyMask is set then
+ CpuDeadLoop() is called. If neither of these bits are set, then this function
returns immediately after the message is printed to the debug output device.
DebugAssert() must actively prevent recusrsion. If DebugAssert() is called while
processing another DebugAssert(), then DebugAssert() must return immediately.
@@ -130,15 +130,15 @@ DebugAssert ( Fills a target buffer with PcdDebugClearMemoryValue, and returns the target buffer.
- This function fills Length bytes of Buffer with the value specified by
+ This function fills Length bytes of Buffer with the value specified by
PcdDebugClearMemoryValue, and returns Buffer.
If Buffer is NULL, then ASSERT().
- If Length is greater than (MAX_ADDRESS ? Buffer + 1), then ASSERT().
+ If Length is greater than (MAX_ADDRESS ? Buffer + 1), then ASSERT().
@param Buffer Pointer to the target buffer to fill with PcdDebugClearMemoryValue.
- @param Length Number of bytes in Buffer to fill with zeros PcdDebugClearMemoryValue.
+ @param Length Number of bytes in Buffer to fill with zeros PcdDebugClearMemoryValue.
@return Buffer
@@ -163,10 +163,10 @@ DebugClearMemory ( /**
-
+
Returns TRUE if ASSERT() macros are enabled.
- This function returns TRUE if the DEBUG_PROPERTY_DEBUG_ASSERT_ENABLED bit of
+ This function returns TRUE if the DEBUG_PROPERTY_DEBUG_ASSERT_ENABLED bit of
PcdDebugProperyMask is set. Otherwise FALSE is returned.
@retval TRUE The DEBUG_PROPERTY_DEBUG_ASSERT_ENABLED bit of PcdDebugProperyMask is set.
@@ -184,10 +184,10 @@ DebugAssertEnabled ( /**
-
+
Returns TRUE if DEBUG()macros are enabled.
- This function returns TRUE if the DEBUG_PROPERTY_DEBUG_PRINT_ENABLED bit of
+ This function returns TRUE if the DEBUG_PROPERTY_DEBUG_PRINT_ENABLED bit of
PcdDebugProperyMask is set. Otherwise FALSE is returned.
@retval TRUE The DEBUG_PROPERTY_DEBUG_PRINT_ENABLED bit of PcdDebugProperyMask is set.
@@ -205,10 +205,10 @@ DebugPrintEnabled ( /**
-
+
Returns TRUE if DEBUG_CODE()macros are enabled.
- This function returns TRUE if the DEBUG_PROPERTY_DEBUG_CODE_ENABLED bit of
+ This function returns TRUE if the DEBUG_PROPERTY_DEBUG_CODE_ENABLED bit of
PcdDebugProperyMask is set. Otherwise FALSE is returned.
@retval TRUE The DEBUG_PROPERTY_DEBUG_CODE_ENABLED bit of PcdDebugProperyMask is set.
@@ -226,10 +226,10 @@ DebugCodeEnabled ( /**
-
+
Returns TRUE if DEBUG_CLEAR_MEMORY()macro is enabled.
- This function returns TRUE if the DEBUG_PROPERTY_DEBUG_CLEAR_MEMORY_ENABLED bit of
+ This function returns TRUE if the DEBUG_PROPERTY_DEBUG_CLEAR_MEMORY_ENABLED bit of
PcdDebugProperyMask is set. Otherwise FALSE is returned.
@retval TRUE The DEBUG_PROPERTY_DEBUG_CLEAR_MEMORY_ENABLED bit of PcdDebugProperyMask is set.
diff --git a/ArmPkg/Library/SemiHostingDebugLib/SemiHostingDebugLib.inf b/ArmPkg/Library/SemiHostingDebugLib/SemiHostingDebugLib.inf index cfdbb32443..4c2c5ff383 100644 --- a/ArmPkg/Library/SemiHostingDebugLib/SemiHostingDebugLib.inf +++ b/ArmPkg/Library/SemiHostingDebugLib/SemiHostingDebugLib.inf @@ -21,7 +21,7 @@ FILE_GUID = 2A8D3FC4-8DB1-4D27-A3F3-780AF03CF848
MODULE_TYPE = BASE
VERSION_STRING = 1.0
- LIBRARY_CLASS = DebugLib|BASE SEC DXE_CORE DXE_DRIVER DXE_RUNTIME_DRIVER DXE_SAL_DRIVER DXE_SMM_DRIVER UEFI_APPLICATION UEFI_DRIVER
+ LIBRARY_CLASS = DebugLib|BASE SEC DXE_CORE DXE_DRIVER DXE_RUNTIME_DRIVER DXE_SAL_DRIVER DXE_SMM_DRIVER UEFI_APPLICATION UEFI_DRIVER
[Sources.common]
diff --git a/ArmPkg/Library/SemiHostingSerialPortLib/SerialPortLib.c b/ArmPkg/Library/SemiHostingSerialPortLib/SerialPortLib.c index 60d8930d6c..bc4d691523 100644 --- a/ArmPkg/Library/SemiHostingSerialPortLib/SerialPortLib.c +++ b/ArmPkg/Library/SemiHostingSerialPortLib/SerialPortLib.c @@ -2,7 +2,7 @@ Serial I/O Port library functions with no library constructor/destructor
Copyright (c) 2008 - 2009, Apple Inc. All rights reserved.<BR>
-
+
This program and the accompanying materials
are licensed and made available under the terms and conditions of the BSD License
which accompanies this distribution. The full text of the license may be found at
@@ -68,7 +68,7 @@ SerialPortWrite ( while (SourceIndex < NumberOfBytes)
{
CurrentCharacter = Buffer[SourceIndex++];
-
+
switch (CurrentCharacter)
{
case '\r':
@@ -91,7 +91,7 @@ SerialPortWrite ( DestinationIndex = 0;
}
}
-
+
if (DestinationIndex > 0)
{
PrintBuffer[DestinationIndex] = '\0';
diff --git a/ArmPkg/Library/SemihostLib/Arm/GccSemihost.S b/ArmPkg/Library/SemihostLib/Arm/GccSemihost.S index 4aa886182f..c9d13183f6 100755 --- a/ArmPkg/Library/SemihostLib/Arm/GccSemihost.S +++ b/ArmPkg/Library/SemihostLib/Arm/GccSemihost.S @@ -1,4 +1,4 @@ -#------------------------------------------------------------------------------
+#------------------------------------------------------------------------------
#
# Copyright (c) 2008 - 2010, Apple Inc. All rights reserved.<BR>
#
@@ -20,21 +20,21 @@ INTERWORK_FUNC(GccSemihostCall) /*
Semihosting operation request mechanism
-
+
SVC 0x123456 in ARM state (for all architectures)
SVC 0xAB in Thumb state (excluding ARMv7-M)
BKPT 0xAB for ARMv7-M (Thumb-2 only)
-
- R0 - operation type
+
+ R0 - operation type
R1 - block containing all other parametes
-
- lr - must be saved as svc instruction will cause an svc exception and write
+
+ lr - must be saved as svc instruction will cause an svc exception and write
the svc lr register. That happens to be the one we are using, so we must
- save it or we will not be able to return.
+ save it or we will not be able to return.
*/
ASM_PFX(GccSemihostCall):
- stmfd sp!, {lr}
- svc #0x123456
+ stmfd sp!, {lr}
+ svc #0x123456
ldmfd sp!, {lr}
bx lr
diff --git a/ArmPkg/Library/SemihostLib/SemihostLib.c b/ArmPkg/Library/SemihostLib/SemihostLib.c index 53405edd7a..f93d7991d2 100644 --- a/ArmPkg/Library/SemihostLib/SemihostLib.c +++ b/ArmPkg/Library/SemihostLib/SemihostLib.c @@ -220,7 +220,7 @@ SemihostWriteString ( {
Semihost_SYS_WRITE0(String);
}
-
+
UINT32
SemihostSystem (
IN CHAR8 *CommandLine
diff --git a/ArmPkg/Library/SemihostLib/SemihostPrivate.h b/ArmPkg/Library/SemihostLib/SemihostPrivate.h index c4bc4c0ec4..bb0a026d4e 100644 --- a/ArmPkg/Library/SemihostLib/SemihostPrivate.h +++ b/ArmPkg/Library/SemihostLib/SemihostPrivate.h @@ -43,7 +43,7 @@ typedef struct { UINTN CommandLength;
} SEMIHOST_SYSTEM_BLOCK;
-#if defined(__CC_ARM)
+#if defined(__CC_ARM)
#if defined(__thumb__)
#define SWI 0xAB
diff --git a/ArmPkg/Library/UncachedMemoryAllocationLib/UncachedMemoryAllocationLib.c b/ArmPkg/Library/UncachedMemoryAllocationLib/UncachedMemoryAllocationLib.c index a24300312e..1209b926c1 100644 --- a/ArmPkg/Library/UncachedMemoryAllocationLib/UncachedMemoryAllocationLib.c +++ b/ArmPkg/Library/UncachedMemoryAllocationLib/UncachedMemoryAllocationLib.c @@ -3,7 +3,7 @@ a buffer.
Copyright (c) 2008 - 2010, Apple Inc. All rights reserved.<BR>
-
+
This program and the accompanying materials
are licensed and made available under the terms and conditions of the BSD License
which accompanies this distribution. The full text of the license may be found at
@@ -27,18 +27,18 @@ VOID *
UncachedInternalAllocatePages (
- IN EFI_MEMORY_TYPE MemoryType,
+ IN EFI_MEMORY_TYPE MemoryType,
IN UINTN Pages
);
VOID *
UncachedInternalAllocateAlignedPages (
- IN EFI_MEMORY_TYPE MemoryType,
+ IN EFI_MEMORY_TYPE MemoryType,
IN UINTN Pages,
IN UINTN Alignment
);
-
-
+
+
//
// Assume all of memory has the same cache attributes, unless we do our magic
@@ -60,16 +60,16 @@ AddPagesToList ( )
{
FREE_PAGE_NODE *NewNode;
-
+
NewNode = AllocatePool (sizeof (LIST_ENTRY));
if (NewNode == NULL) {
ASSERT (FALSE);
return;
}
-
+
NewNode->Allocation = Allocation;
NewNode->Pages = Pages;
-
+
InsertTailList (&mPageList, &NewNode->Link);
}
@@ -84,12 +84,12 @@ RemovePagesFromList ( FREE_PAGE_NODE *OldNode;
*Pages = 0;
-
+
for (Link = mPageList.ForwardLink; Link != &mPageList; Link = Link->ForwardLink) {
OldNode = BASE_CR (Link, FREE_PAGE_NODE, Link);
if (OldNode->Allocation == Allocation) {
*Pages = OldNode->Pages;
-
+
RemoveEntryList (&OldNode->Link);
FreePool (OldNode);
return;
@@ -119,7 +119,7 @@ ConvertToPhysicalAddress ( VOID *
UncachedInternalAllocatePages (
- IN EFI_MEMORY_TYPE MemoryType,
+ IN EFI_MEMORY_TYPE MemoryType,
IN UINTN Pages
)
{
@@ -170,7 +170,7 @@ UncachedFreePages ( VOID *
UncachedInternalAllocateAlignedPages (
- IN EFI_MEMORY_TYPE MemoryType,
+ IN EFI_MEMORY_TYPE MemoryType,
IN UINTN Pages,
IN UINTN Alignment
)
@@ -187,7 +187,7 @@ UncachedInternalAllocateAlignedPages ( // Alignment must be a power of two or zero.
//
ASSERT ((Alignment & (Alignment - 1)) == 0);
-
+
if (Pages == 0) {
return NULL;
}
@@ -201,7 +201,7 @@ UncachedInternalAllocateAlignedPages ( // Make sure that Pages plus EFI_SIZE_TO_PAGES (Alignment) does not overflow.
//
ASSERT (RealPages > Pages);
-
+
Status = gBS->AllocatePages (AllocateAnyPages, MemoryType, RealPages, &Memory);
if (EFI_ERROR (Status)) {
return NULL;
@@ -234,16 +234,16 @@ UncachedInternalAllocateAlignedPages ( }
AlignedMemory = (UINTN) Memory;
}
-
+
Status = gDS->GetMemorySpaceDescriptor (Memory, &Descriptor);
if (!EFI_ERROR (Status)) {
// We are making an assumption that all of memory has the same default attributes
gAttributes = Descriptor.Attributes;
}
-
+
Status = gDS->SetMemorySpaceAttributes (Memory, EFI_PAGES_TO_SIZE (Pages), EFI_MEMORY_WC);
ASSERT_EFI_ERROR (Status);
-
+
return (VOID *)(UINTN)Memory;
}
@@ -256,13 +256,13 @@ UncachedFreeAlignedPages ( )
{
EFI_STATUS Status;
- EFI_PHYSICAL_ADDRESS Memory;
+ EFI_PHYSICAL_ADDRESS Memory;
ASSERT (Pages != 0);
-
+
Memory = (EFI_PHYSICAL_ADDRESS) (UINTN) Buffer;
Status = gDS->SetMemorySpaceAttributes (Memory, EFI_PAGES_TO_SIZE (Pages), gAttributes);
-
+
Status = gBS->FreePages (Memory, Pages);
ASSERT_EFI_ERROR (Status);
}
@@ -278,7 +278,7 @@ UncachedInternalAllocateAlignedPool ( )
{
VOID *AlignedAddress;
-
+
//
// Alignment must be a power of two or zero.
//
@@ -287,7 +287,7 @@ UncachedInternalAllocateAlignedPool ( if (Alignment < EFI_PAGE_SIZE) {
Alignment = EFI_PAGE_SIZE;
}
-
+
AlignedAddress = UncachedInternalAllocateAlignedPages (PoolType, EFI_SIZE_TO_PAGES (AllocationSize), Alignment);
if (AlignedAddress == NULL) {
return NULL;
@@ -382,7 +382,7 @@ UncachedInternalAllocateAlignedCopyPool ( )
{
VOID *Memory;
-
+
ASSERT (Buffer != NULL);
ASSERT (AllocationSize <= (MAX_ADDRESS - (UINTN) Buffer + 1));
@@ -433,7 +433,7 @@ UncachedFreeAlignedPool ( )
{
UINTN Pages;
-
+
RemovePagesFromList (Allocation, &Pages);
UncachedFreePages (Allocation, Pages);
@@ -441,7 +441,7 @@ UncachedFreeAlignedPool ( VOID *
UncachedInternalAllocatePool (
- IN EFI_MEMORY_TYPE MemoryType,
+ IN EFI_MEMORY_TYPE MemoryType,
IN UINTN AllocationSize
)
{
@@ -478,9 +478,9 @@ UncachedAllocateReservedPool ( VOID *
UncachedInternalAllocateZeroPool (
- IN EFI_MEMORY_TYPE PoolType,
+ IN EFI_MEMORY_TYPE PoolType,
IN UINTN AllocationSize
- )
+ )
{
VOID *Memory;
@@ -520,10 +520,10 @@ UncachedAllocateReservedZeroPool ( VOID *
UncachedInternalAllocateCopyPool (
- IN EFI_MEMORY_TYPE PoolType,
+ IN EFI_MEMORY_TYPE PoolType,
IN UINTN AllocationSize,
IN CONST VOID *Buffer
- )
+ )
{
VOID *Memory;
@@ -535,7 +535,7 @@ UncachedInternalAllocateCopyPool ( Memory = CopyMem (Memory, Buffer, AllocationSize);
}
return Memory;
-}
+}
VOID *
EFIAPI
diff --git a/ArmPlatformPkg/ArmPlatformPkg-2ndstage.dsc b/ArmPlatformPkg/ArmPlatformPkg-2ndstage.dsc index 22d98882dc..ca717aeaed 100644 --- a/ArmPlatformPkg/ArmPlatformPkg-2ndstage.dsc +++ b/ArmPlatformPkg/ArmPlatformPkg-2ndstage.dsc @@ -17,7 +17,7 @@ ################################################################################
[Defines]
PLATFORM_NAME = ArmPlatform
- PLATFORM_GUID = 4fe82b83-9315-4ff3-8cc0-ab77ca93cb7f
+ PLATFORM_GUID = 4fe82b83-9315-4ff3-8cc0-ab77ca93cb7f
PLATFORM_VERSION = 0.1
DSC_SPECIFICATION = 0x00010005
OUTPUT_DIRECTORY = Build/$(PLATFORM_NAME)
@@ -38,7 +38,7 @@ # UncachedMemoryAllocationLib|ArmPkg/Library/DebugUncachedMemoryAllocationLib/DebugUncachedMemoryAllocationLib.inf
!endif
DebugPrintErrorLevelLib|MdePkg/Library/BaseDebugPrintErrorLevelLib/BaseDebugPrintErrorLevelLib.inf
-
+
BaseLib|MdePkg/Library/BaseLib/BaseLib.inf
SynchronizationLib|MdePkg/Library/BaseSynchronizationLib/BaseSynchronizationLib.inf
PerformanceLib|MdePkg/Library/BasePerformanceLibNull/BasePerformanceLibNull.inf
@@ -58,7 +58,7 @@ UefiDriverEntryPoint|MdePkg/Library/UefiDriverEntryPoint/UefiDriverEntryPoint.inf
UefiApplicationEntryPoint|MdePkg/Library/UefiApplicationEntryPoint/UefiApplicationEntryPoint.inf
HiiLib|MdeModulePkg/Library/UefiHiiLib/UefiHiiLib.inf
- UefiHiiServicesLib|MdeModulePkg/Library/UefiHiiServicesLib/UefiHiiServicesLib.inf
+ UefiHiiServicesLib|MdeModulePkg/Library/UefiHiiServicesLib/UefiHiiServicesLib.inf
UefiRuntimeLib|MdePkg/Library/UefiRuntimeLib/UefiRuntimeLib.inf
@@ -66,7 +66,7 @@ # Assume everything is fixed at build
#
PcdLib|MdePkg/Library/BasePcdLibNull/BasePcdLibNull.inf
-
+
# 1/123 faster than Stm or Vstm version
#BaseMemoryLib|MdePkg/Library/BaseMemoryLib/BaseMemoryLib.inf
BaseMemoryLib|ArmPkg/Library/BaseMemoryLibStm/BaseMemoryLibStm.inf
@@ -96,7 +96,7 @@ EblNetworkLib|EmbeddedPkg/Library/EblNetworkLib/EblNetworkLib.inf
#
- # Uncomment (and comment out the next line) For RealView Debugger. The Standard IO window
+ # Uncomment (and comment out the next line) For RealView Debugger. The Standard IO window
# in the debugger will show load and unload commands for symbols. You can cut and paste this
# into the command window to load symbols. We should be able to use a script to do this, but
# the version of RVD I have does not support scripts accessing system memory.
@@ -104,11 +104,11 @@ #PeCoffExtraActionLib|ArmPkg/Library/RvdPeCoffExtraActionLib/RvdPeCoffExtraActionLib.inf
PeCoffExtraActionLib|ArmPkg/Library/DebugPeCoffExtraActionLib/DebugPeCoffExtraActionLib.inf
#PeCoffExtraActionLib|MdePkg/Library/BasePeCoffExtraActionLibNull/BasePeCoffExtraActionLibNull.inf
-
+
DebugAgentLib|MdeModulePkg/Library/DebugAgentLibNull/DebugAgentLibNull.inf
DebugAgentTimerLib|EmbeddedPkg/Library/DebugAgentTimerLibNull/DebugAgentTimerLibNull.inf
- SemihostLib|ArmPkg/Library/SemihostLib/SemihostLib.inf
+ SemihostLib|ArmPkg/Library/SemihostLib/SemihostLib.inf
# BDS Libraries
BdsLib|ArmPkg/Library/BdsLib/BdsLib.inf
@@ -125,10 +125,10 @@ [LibraryClasses.common.SEC]
ArmPlatformGlobalVariableLib|ArmPlatformPkg/Library/ArmPlatformGlobalVariableLib/PrePi/PrePiArmPlatformGlobalVariableLib.inf
- ArmPlatformSecExtraActionLib|ArmPlatformPkg/Library/DebugSecExtraActionLib/DebugSecExtraActionLib.inf
+ ArmPlatformSecExtraActionLib|ArmPlatformPkg/Library/DebugSecExtraActionLib/DebugSecExtraActionLib.inf
DebugAgentLib|ArmPkg/Library/DebugAgentSymbolsBaseLib/DebugAgentSymbolsBaseLib.inf
DefaultExceptionHandlerLib|ArmPkg/Library/DefaultExceptionHandlerLib/DefaultExceptionHandlerLibBase.inf
-
+
PrePiLib|EmbeddedPkg/Library/PrePiLib/PrePiLib.inf
ExtractGuidedSectionLib|EmbeddedPkg/Library/PrePiExtractGuidedSectionLib/PrePiExtractGuidedSectionLib.inf
LzmaDecompressLib|IntelFrameworkModulePkg/Library/LzmaCustomDecompressLib/LzmaCustomDecompressLib.inf
@@ -202,11 +202,11 @@ gEfiMdePkgTokenSpaceGuid.PcdDriverDiagnosticsDisable|TRUE
gEfiMdePkgTokenSpaceGuid.PcdComponentName2Disable|TRUE
gEfiMdePkgTokenSpaceGuid.PcdDriverDiagnostics2Disable|TRUE
-
+
#
# Control what commands are supported from the UI
# Turn these on and off to add features or save size
- #
+ #
gEmbeddedTokenSpaceGuid.PcdEmbeddedMacBoot|TRUE
gEmbeddedTokenSpaceGuid.PcdEmbeddedDirCmd|TRUE
gEmbeddedTokenSpaceGuid.PcdEmbeddedHobCmd|TRUE
@@ -216,17 +216,17 @@ gEmbeddedTokenSpaceGuid.PcdEmbeddedScriptCmd|FALSE
gEmbeddedTokenSpaceGuid.PcdCacheEnable|TRUE
-
+
# Use the Vector Table location in CpuDxe. We will not copy the Vector Table at PcdCpuVectorBaseAddress
gArmTokenSpaceGuid.PcdRelocateVectorTable|FALSE
-
+
gEmbeddedTokenSpaceGuid.PcdPrePiProduceMemoryTypeInformationHob|TRUE
-
+
gEfiMdeModulePkgTokenSpaceGuid.PcdTurnOffUsbLegacySupport|TRUE
[PcdsFixedAtBuild.common]
gArmPlatformTokenSpaceGuid.PcdFirmwareVendor|"ARM Platform"
-
+
gEmbeddedTokenSpaceGuid.PcdEmbeddedPrompt|"ArmPlatform"
gEfiMdePkgTokenSpaceGuid.PcdMaximumUnicodeStringLength|1000000
gEfiMdePkgTokenSpaceGuid.PcdMaximumAsciiStringLength|1000000
@@ -272,12 +272,12 @@ gEmbeddedTokenSpaceGuid.PcdEmbeddedAutomaticBootCommand|""
gEmbeddedTokenSpaceGuid.PcdEmbeddedDefaultTextColor|0x07
gEmbeddedTokenSpaceGuid.PcdEmbeddedMemVariableStoreSize|0x10000
-
+
#
# Optional feature to help prevent EFI memory map fragments
# Turned on and off via: PcdPrePiProduceMemoryTypeInformationHob
- # Values are in EFI Pages (4K). DXE Core will make sure that
- # at least this much of each type of memory can be allocated
+ # Values are in EFI Pages (4K). DXE Core will make sure that
+ # at least this much of each type of memory can be allocated
# from a single memory range. This way you only end up with
# maximum of two fragements for each type in the memory map
# (the memory used, and the free memory that was prereserved
@@ -292,12 +292,12 @@ gEmbeddedTokenSpaceGuid.PcdMemoryTypeEfiBootServicesData|20000
gEmbeddedTokenSpaceGuid.PcdMemoryTypeEfiLoaderCode|20
gEmbeddedTokenSpaceGuid.PcdMemoryTypeEfiLoaderData|0
-
+
#
# ARM Pcds
#
gArmTokenSpaceGuid.PcdArmUncachedMemoryMask|0x0000000000000000
-
+
gArmTokenSpaceGuid.PcdSystemMemoryBase|0
gArmTokenSpaceGuid.PcdSystemMemorySize|0
@@ -307,7 +307,7 @@ #
################################################################################
[Components.common]
-
+
#
# PEI Phase modules
#
@@ -325,37 +325,37 @@ #
# Architectural Protocols
#
- ArmPkg/Drivers/CpuDxe/CpuDxe.inf
+ ArmPkg/Drivers/CpuDxe/CpuDxe.inf
MdeModulePkg/Core/RuntimeDxe/RuntimeDxe.inf
MdeModulePkg/Universal/SecurityStubDxe/SecurityStubDxe.inf
MdeModulePkg/Universal/WatchdogTimerDxe/WatchdogTimer.inf
MdeModulePkg/Universal/CapsuleRuntimeDxe/CapsuleRuntimeDxe.inf
MdeModulePkg/Universal/Variable/EmuRuntimeDxe/EmuVariableRuntimeDxe.inf
- EmbeddedPkg/EmbeddedMonotonicCounter/EmbeddedMonotonicCounter.inf
-
+ EmbeddedPkg/EmbeddedMonotonicCounter/EmbeddedMonotonicCounter.inf
+
EmbeddedPkg/ResetRuntimeDxe/ResetRuntimeDxe.inf
EmbeddedPkg/RealTimeClockRuntimeDxe/RealTimeClockRuntimeDxe.inf
EmbeddedPkg/MetronomeDxe/MetronomeDxe.inf
-
+
# Simple TextIn/TextOut for UEFI Terminal
EmbeddedPkg/SimpleTextInOutSerial/SimpleTextInOutSerial.inf
-
+
#
#
# Semi-hosting filesystem
#
ArmPkg/Filesystem/SemihostFs/SemihostFs.inf
-
+
#
# FAT filesystem + GPT/MBR partitioning
#
MdeModulePkg/Universal/Disk/DiskIoDxe/DiskIoDxe.inf
MdeModulePkg/Universal/Disk/PartitionDxe/PartitionDxe.inf
MdeModulePkg/Universal/Disk/UnicodeCollation/EnglishDxe/EnglishDxe.inf
-
+
#
# Application
- #
+ #
EmbeddedPkg/Ebl/Ebl.inf
#
@@ -363,4 +363,4 @@ #
MdeModulePkg/Universal/DevicePathDxe/DevicePathDxe.inf
ArmPlatformPkg/Bds/Bds.inf
-
+
diff --git a/ArmPlatformPkg/ArmPlatformPkg-2ndstage.fdf b/ArmPlatformPkg/ArmPlatformPkg-2ndstage.fdf index de6ad0bed3..eae41158b6 100644 --- a/ArmPlatformPkg/ArmPlatformPkg-2ndstage.fdf +++ b/ArmPlatformPkg/ArmPlatformPkg-2ndstage.fdf @@ -85,10 +85,10 @@ READ_STATUS = TRUE READ_LOCK_CAP = TRUE
READ_LOCK_STATUS = TRUE
- INF MdeModulePkg/Core/Dxe/DxeMain.inf
+ INF MdeModulePkg/Core/Dxe/DxeMain.inf
#
- # PI DXE Drivers producing Architectural Protocols (EFI Services)
+ # PI DXE Drivers producing Architectural Protocols (EFI Services)
#
INF ArmPkg/Drivers/CpuDxe/CpuDxe.inf
INF MdeModulePkg/Core/RuntimeDxe/RuntimeDxe.inf
@@ -103,12 +103,12 @@ READ_LOCK_STATUS = TRUE # Simple TextIn/TextOut for UEFI Terminal
INF EmbeddedPkg/SimpleTextInOutSerial/SimpleTextInOutSerial.inf
-
+
#
# Semi-hosting filesystem (Required the Hardware Debugger to be connected)
#
INF ArmPkg/Filesystem/SemihostFs/SemihostFs.inf
-
+
#
# FAT filesystem + GPT/MBR partitioning
#
@@ -116,12 +116,12 @@ READ_LOCK_STATUS = TRUE INF MdeModulePkg/Universal/Disk/PartitionDxe/PartitionDxe.inf
INF FatBinPkg/EnhancedFatDxe/Fat.inf
INF MdeModulePkg/Universal/Disk/UnicodeCollation/EnglishDxe/EnglishDxe.inf
-
+
+ #
+ # UEFI application (Shell Embedded Boot Loader)
#
- # UEFI application (Shell Embedded Boot Loader)
- #
INF EmbeddedPkg/Ebl/Ebl.inf
-
+
#
# Bds
#
@@ -148,7 +148,7 @@ READ_LOCK_CAP = TRUE READ_LOCK_STATUS = TRUE
INF ArmPlatformPkg/PrePi/PeiUniCore.inf
-
+
FILE FV_IMAGE = 9E21FD93-9C72-4c15-8C4B-E77F1DB2D792 {
SECTION GUIDED EE4E5898-3914-4259-9D6E-DC7BD79403CF PROCESSING_REQUIRED = TRUE {
SECTION FV_IMAGE = FVMAIN
@@ -167,7 +167,7 @@ READ_LOCK_STATUS = TRUE ############################################################################
-# Example of a DXE_DRIVER FFS file with a Checksum encapsulation section #
+# Example of a DXE_DRIVER FFS file with a Checksum encapsulation section #
############################################################################
#
#[Rule.Common.DXE_DRIVER]
@@ -255,6 +255,6 @@ READ_LOCK_STATUS = TRUE [Rule.Common.UEFI_APPLICATION]
FILE APPLICATION = $(NAMED_GUID) {
- UI STRING ="$(MODULE_NAME)" Optional
+ UI STRING ="$(MODULE_NAME)" Optional
PE32 PE32 $(INF_OUTPUT)/$(MODULE_NAME).efi
}
diff --git a/ArmPlatformPkg/ArmPlatformPkg.dec b/ArmPlatformPkg/ArmPlatformPkg.dec index 26f8418087..555c9284bc 100644 --- a/ArmPlatformPkg/ArmPlatformPkg.dec +++ b/ArmPlatformPkg/ArmPlatformPkg.dec @@ -1,21 +1,21 @@ #/** @file
#
# Copyright (c) 2011-2014, ARM Limited. All rights reserved.
-#
-# This program and the accompanying materials
-# are licensed and made available under the terms and conditions of the BSD License
-# which accompanies this distribution. The full text of the license may be found at
-# http://opensource.org/licenses/bsd-license.php
#
-# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
-# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
+# This program and the accompanying materials
+# are licensed and made available under the terms and conditions of the BSD License
+# which accompanies this distribution. The full text of the license may be found at
+# http://opensource.org/licenses/bsd-license.php
+#
+# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
+# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
#
#**/
[Defines]
DEC_SPECIFICATION = 0x00010005
PACKAGE_NAME = ArmPlatformPkg
- PACKAGE_GUID = 3308e0a0-1d94-11e0-915c-0002a5d5c51b
+ PACKAGE_GUID = 3308e0a0-1d94-11e0-915c-0002a5d5c51b
PACKAGE_VERSION = 0.1
################################################################################
@@ -47,7 +47,7 @@ [PcdsFeatureFlag.common]
# Set this PCD to TRUE to map NORFlash at 0x0. FALSE means the DRAM is mapped at 0x0.
gArmPlatformTokenSpaceGuid.PcdNorFlashRemapping|FALSE|BOOLEAN|0x00000012
-
+
gArmPlatformTokenSpaceGuid.PcdStandalone|TRUE|BOOLEAN|0x00000001
gArmPlatformTokenSpaceGuid.PcdSystemMemoryInitializeInSec|FALSE|BOOLEAN|0x00000002
gArmPlatformTokenSpaceGuid.PcdSendSgiToBringUpSecondaryCores|FALSE|BOOLEAN|0x00000004
@@ -61,7 +61,7 @@ [PcdsFixedAtBuild.common]
gArmPlatformTokenSpaceGuid.PcdCoreCount|1|UINT32|0x00000039
gArmPlatformTokenSpaceGuid.PcdClusterCount|1|UINT32|0x00000038
-
+
# Stack for CPU Cores in Secure Mode
gArmPlatformTokenSpaceGuid.PcdCPUCoresSecStackBase|0|UINT32|0x00000005
gArmPlatformTokenSpaceGuid.PcdCPUCoreSecPrimaryStackSize|0x10000|UINT32|0x00000036
@@ -71,7 +71,7 @@ gArmPlatformTokenSpaceGuid.PcdCPUCoresStackBase|0|UINT32|0x00000009
gArmPlatformTokenSpaceGuid.PcdCPUCorePrimaryStackSize|0x10000|UINT32|0x00000037
gArmPlatformTokenSpaceGuid.PcdCPUCoreSecondaryStackSize|0x1000|UINT32|0x0000000A
-
+
# Size of the region used by UEFI in permanent memory (Reserved 128MB by default)
gArmPlatformTokenSpaceGuid.PcdSystemMemoryUefiRegionSize|0x08000000|UINT32|0x00000015
@@ -79,7 +79,7 @@ # = sizeof(UINTN) /* PcdPeiServicePtr or HobListPtr */
gArmPlatformTokenSpaceGuid.PcdPeiGlobalVariableSize|0x4|UINT32|0x00000016
# PeiServicePtr and HobListPtr shares the same location in the PEI Global Variable list
- # PeiServicePtr is only valid with PEI Core and HobListPtr only when the PEI Core is skipped.
+ # PeiServicePtr is only valid with PEI Core and HobListPtr only when the PEI Core is skipped.
gArmPlatformTokenSpaceGuid.PcdPeiServicePtrGlobalOffset|0x0|UINT32|0x00000017
gArmPlatformTokenSpaceGuid.PcdHobListPtrGlobalOffset|0x0|UINT32|0x00000018
@@ -115,11 +115,11 @@ ## PL061 GPIO
gArmPlatformTokenSpaceGuid.PcdPL061GpioBase|0x0|UINT32|0x00000025
-
+
## PL111 Lcd & HdLcd
gArmPlatformTokenSpaceGuid.PcdPL111LcdBase|0x0|UINT32|0x00000026
gArmPlatformTokenSpaceGuid.PcdArmHdLcdBase|0x0|UINT32|0x00000027
-
+
## PL180 MCI
gArmPlatformTokenSpaceGuid.PcdPL180SysMciRegAddress|0x00000000|UINT32|0x00000028
gArmPlatformTokenSpaceGuid.PcdPL180MciBaseAddress|0x00000000|UINT32|0x00000029
@@ -132,17 +132,17 @@ gArmPlatformTokenSpaceGuid.PcdDefaultBootDevicePath|L""|VOID*|0x0000000D
gArmPlatformTokenSpaceGuid.PcdDefaultBootInitrdPath|L""|VOID*|0x0000000E
gArmPlatformTokenSpaceGuid.PcdDefaultBootArgument|L""|VOID*|0x000000F
- # PcdDefaultBootType define the type of the binary pointed by PcdDefaultBootDevicePath:
+ # PcdDefaultBootType define the type of the binary pointed by PcdDefaultBootDevicePath:
# - 0 = an EFI application
# - 1 = a Linux kernel with ATAG support
# - 2 = a Linux kernel with FDT support
gArmPlatformTokenSpaceGuid.PcdDefaultBootType|0|UINT32|0x00000010
gArmPlatformTokenSpaceGuid.PcdFdtDevicePath|L""|VOID*|0x00000011
-
+
## Timeout value for displaying progressing bar in before boot OS.
# According to UEFI 2.0 spec, the default TimeOut should be 0xffff.
gArmPlatformTokenSpaceGuid.PcdPlatformBootTimeOut|0xffff|UINT16|0x0000001A
-
+
gArmPlatformTokenSpaceGuid.PcdDefaultConInPaths|L""|VOID*|0x0000001B
gArmPlatformTokenSpaceGuid.PcdDefaultConOutPaths|L""|VOID*|0x0000001C
diff --git a/ArmPlatformPkg/ArmPlatformPkg.dsc b/ArmPlatformPkg/ArmPlatformPkg.dsc index 7854c037ea..c4725ee649 100644 --- a/ArmPlatformPkg/ArmPlatformPkg.dsc +++ b/ArmPlatformPkg/ArmPlatformPkg.dsc @@ -17,7 +17,7 @@ ################################################################################
[Defines]
PLATFORM_NAME = ArmPlatform
- PLATFORM_GUID = 4fe82b83-9315-4ff3-8cc0-ab77ca93cb7f
+ PLATFORM_GUID = 4fe82b83-9315-4ff3-8cc0-ab77ca93cb7f
PLATFORM_VERSION = 0.1
DSC_SPECIFICATION = 0x00010005
OUTPUT_DIRECTORY = Build/$(PLATFORM_NAME)
@@ -38,7 +38,7 @@ # UncachedMemoryAllocationLib|ArmPkg/Library/DebugUncachedMemoryAllocationLib/DebugUncachedMemoryAllocationLib.inf
!endif
DebugPrintErrorLevelLib|MdePkg/Library/BaseDebugPrintErrorLevelLib/BaseDebugPrintErrorLevelLib.inf
-
+
BaseLib|MdePkg/Library/BaseLib/BaseLib.inf
SynchronizationLib|MdePkg/Library/BaseSynchronizationLib/BaseSynchronizationLib.inf
PerformanceLib|MdePkg/Library/BasePerformanceLibNull/BasePerformanceLibNull.inf
@@ -58,7 +58,7 @@ UefiDriverEntryPoint|MdePkg/Library/UefiDriverEntryPoint/UefiDriverEntryPoint.inf
UefiApplicationEntryPoint|MdePkg/Library/UefiApplicationEntryPoint/UefiApplicationEntryPoint.inf
HiiLib|MdeModulePkg/Library/UefiHiiLib/UefiHiiLib.inf
- UefiHiiServicesLib|MdeModulePkg/Library/UefiHiiServicesLib/UefiHiiServicesLib.inf
+ UefiHiiServicesLib|MdeModulePkg/Library/UefiHiiServicesLib/UefiHiiServicesLib.inf
UefiRuntimeLib|MdePkg/Library/UefiRuntimeLib/UefiRuntimeLib.inf
@@ -66,7 +66,7 @@ # Assume everything is fixed at build
#
PcdLib|MdePkg/Library/BasePcdLibNull/BasePcdLibNull.inf
-
+
# 1/123 faster than Stm or Vstm version
#BaseMemoryLib|MdePkg/Library/BaseMemoryLib/BaseMemoryLib.inf
BaseMemoryLib|ArmPkg/Library/BaseMemoryLibStm/BaseMemoryLibStm.inf
@@ -95,7 +95,7 @@ EblNetworkLib|EmbeddedPkg/Library/EblNetworkLib/EblNetworkLib.inf
#
- # Uncomment (and comment out the next line) For RealView Debugger. The Standard IO window
+ # Uncomment (and comment out the next line) For RealView Debugger. The Standard IO window
# in the debugger will show load and unload commands for symbols. You can cut and paste this
# into the command window to load symbols. We should be able to use a script to do this, but
# the version of RVD I have does not support scripts accessing system memory.
@@ -103,11 +103,11 @@ #PeCoffExtraActionLib|ArmPkg/Library/RvdPeCoffExtraActionLib/RvdPeCoffExtraActionLib.inf
PeCoffExtraActionLib|ArmPkg/Library/DebugPeCoffExtraActionLib/DebugPeCoffExtraActionLib.inf
#PeCoffExtraActionLib|MdePkg/Library/BasePeCoffExtraActionLibNull/BasePeCoffExtraActionLibNull.inf
-
+
DebugAgentLib|MdeModulePkg/Library/DebugAgentLibNull/DebugAgentLibNull.inf
DebugAgentTimerLib|EmbeddedPkg/Library/DebugAgentTimerLibNull/DebugAgentTimerLibNull.inf
- SemihostLib|ArmPkg/Library/SemihostLib/SemihostLib.inf
+ SemihostLib|ArmPkg/Library/SemihostLib/SemihostLib.inf
# BDS Libraries
BdsLib|ArmPkg/Library/BdsLib/BdsLib.inf
@@ -128,7 +128,7 @@ ArmPlatformSecExtraActionLib|ArmPlatformPkg/Library/DebugSecExtraActionLib/DebugSecExtraActionLib.inf
ArmPlatformGlobalVariableLib|ArmPlatformPkg/Library/ArmPlatformGlobalVariableLib/Sec/SecArmPlatformGlobalVariableLib.inf
-
+
DebugAgentLib|ArmPkg/Library/DebugAgentSymbolsBaseLib/DebugAgentSymbolsBaseLib.inf
DefaultExceptionHandlerLib|ArmPkg/Library/DefaultExceptionHandlerLib/DefaultExceptionHandlerLibBase.inf
@@ -149,10 +149,10 @@ PeCoffGetEntryPointLib|MdePkg/Library/BasePeCoffGetEntryPointLib/BasePeCoffGetEntryPointLib.inf
UefiDecompressLib|MdePkg/Library/BaseUefiDecompressLib/BaseUefiDecompressLib.inf
ExtractGuidedSectionLib|MdePkg/Library/PeiExtractGuidedSectionLib/PeiExtractGuidedSectionLib.inf
-
+
ArmPlatformGlobalVariableLib|ArmPlatformPkg/Library/ArmPlatformGlobalVariableLib/Pei/PeiArmPlatformGlobalVariableLib.inf
PeiServicesTablePointerLib|ArmPlatformPkg/Library/PeiServicesTablePointerLib/PeiServicesTablePointerLib.inf
-
+
[LibraryClasses.common.PEIM]
HobLib|MdePkg/Library/PeiHobLib/PeiHobLib.inf
PeiServicesLib|MdePkg/Library/PeiServicesLib/PeiServicesLib.inf
@@ -235,11 +235,11 @@ gEfiMdePkgTokenSpaceGuid.PcdDriverDiagnosticsDisable|TRUE
gEfiMdePkgTokenSpaceGuid.PcdComponentName2Disable|TRUE
gEfiMdePkgTokenSpaceGuid.PcdDriverDiagnostics2Disable|TRUE
-
+
#
# Control what commands are supported from the UI
# Turn these on and off to add features or save size
- #
+ #
gEmbeddedTokenSpaceGuid.PcdEmbeddedMacBoot|TRUE
gEmbeddedTokenSpaceGuid.PcdEmbeddedDirCmd|TRUE
gEmbeddedTokenSpaceGuid.PcdEmbeddedHobCmd|TRUE
@@ -249,17 +249,17 @@ gEmbeddedTokenSpaceGuid.PcdEmbeddedScriptCmd|FALSE
gEmbeddedTokenSpaceGuid.PcdCacheEnable|TRUE
-
+
# Use the Vector Table location in CpuDxe. We will not copy the Vector Table at PcdCpuVectorBaseAddress
gArmTokenSpaceGuid.PcdRelocateVectorTable|FALSE
-
+
gEmbeddedTokenSpaceGuid.PcdPrePiProduceMemoryTypeInformationHob|TRUE
-
+
gEfiMdeModulePkgTokenSpaceGuid.PcdTurnOffUsbLegacySupport|TRUE
[PcdsFixedAtBuild.common]
gArmPlatformTokenSpaceGuid.PcdFirmwareVendor|"ARM Platform"
-
+
gEmbeddedTokenSpaceGuid.PcdEmbeddedPrompt|"ArmPlatform"
gEfiMdePkgTokenSpaceGuid.PcdMaximumUnicodeStringLength|1000000
gEfiMdePkgTokenSpaceGuid.PcdMaximumAsciiStringLength|1000000
@@ -305,12 +305,12 @@ gEmbeddedTokenSpaceGuid.PcdEmbeddedAutomaticBootCommand|""
gEmbeddedTokenSpaceGuid.PcdEmbeddedDefaultTextColor|0x07
gEmbeddedTokenSpaceGuid.PcdEmbeddedMemVariableStoreSize|0x10000
-
+
#
# Optional feature to help prevent EFI memory map fragments
# Turned on and off via: PcdPrePiProduceMemoryTypeInformationHob
- # Values are in EFI Pages (4K). DXE Core will make sure that
- # at least this much of each type of memory can be allocated
+ # Values are in EFI Pages (4K). DXE Core will make sure that
+ # at least this much of each type of memory can be allocated
# from a single memory range. This way you only end up with
# maximum of two fragements for each type in the memory map
# (the memory used, and the free memory that was prereserved
@@ -325,12 +325,12 @@ gEmbeddedTokenSpaceGuid.PcdMemoryTypeEfiBootServicesData|20000
gEmbeddedTokenSpaceGuid.PcdMemoryTypeEfiLoaderCode|20
gEmbeddedTokenSpaceGuid.PcdMemoryTypeEfiLoaderData|0
-
+
#
# ARM Pcds
#
gArmTokenSpaceGuid.PcdArmUncachedMemoryMask|0x0000000000000000
-
+
# Stacks for MPCores in Secure World
gArmPlatformTokenSpaceGuid.PcdCPUCoresSecStackBase|0
# Stacks for MPCores in Monitor Mode
@@ -347,7 +347,7 @@ #
################################################################################
[Components.common]
-
+
#
# SEC
#
@@ -356,7 +356,7 @@ # Use the implementation which set the Secure bits
ArmGicLib|ArmPkg/Drivers/ArmGic/ArmGicSecLib.inf
}
-
+
#
# PEI Phase modules
#
@@ -392,36 +392,36 @@ #
# Architectural Protocols
#
- ArmPkg/Drivers/CpuDxe/CpuDxe.inf
+ ArmPkg/Drivers/CpuDxe/CpuDxe.inf
MdeModulePkg/Core/RuntimeDxe/RuntimeDxe.inf
MdeModulePkg/Universal/SecurityStubDxe/SecurityStubDxe.inf
MdeModulePkg/Universal/WatchdogTimerDxe/WatchdogTimer.inf
MdeModulePkg/Universal/CapsuleRuntimeDxe/CapsuleRuntimeDxe.inf
MdeModulePkg/Universal/Variable/EmuRuntimeDxe/EmuVariableRuntimeDxe.inf
- EmbeddedPkg/EmbeddedMonotonicCounter/EmbeddedMonotonicCounter.inf
-
+ EmbeddedPkg/EmbeddedMonotonicCounter/EmbeddedMonotonicCounter.inf
+
EmbeddedPkg/ResetRuntimeDxe/ResetRuntimeDxe.inf
EmbeddedPkg/RealTimeClockRuntimeDxe/RealTimeClockRuntimeDxe.inf
EmbeddedPkg/MetronomeDxe/MetronomeDxe.inf
-
+
# Simple TextIn/TextOut for UEFI Terminal
EmbeddedPkg/SimpleTextInOutSerial/SimpleTextInOutSerial.inf
-
+
#
# Semi-hosting filesystem
#
ArmPkg/Filesystem/SemihostFs/SemihostFs.inf
-
+
#
# FAT filesystem + GPT/MBR partitioning
#
MdeModulePkg/Universal/Disk/DiskIoDxe/DiskIoDxe.inf
MdeModulePkg/Universal/Disk/PartitionDxe/PartitionDxe.inf
MdeModulePkg/Universal/Disk/UnicodeCollation/EnglishDxe/EnglishDxe.inf
-
+
#
# Application
- #
+ #
EmbeddedPkg/Ebl/Ebl.inf
#
diff --git a/ArmPlatformPkg/ArmPlatformPkg.fdf b/ArmPlatformPkg/ArmPlatformPkg.fdf index 0eda603ecd..100b0a29f0 100644 --- a/ArmPlatformPkg/ArmPlatformPkg.fdf +++ b/ArmPlatformPkg/ArmPlatformPkg.fdf @@ -134,10 +134,10 @@ READ_STATUS = TRUE READ_LOCK_CAP = TRUE
READ_LOCK_STATUS = TRUE
- INF MdeModulePkg/Core/Dxe/DxeMain.inf
+ INF MdeModulePkg/Core/Dxe/DxeMain.inf
#
- # PI DXE Drivers producing Architectural Protocols (EFI Services)
+ # PI DXE Drivers producing Architectural Protocols (EFI Services)
#
INF ArmPkg/Drivers/CpuDxe/CpuDxe.inf
INF MdeModulePkg/Core/RuntimeDxe/RuntimeDxe.inf
@@ -152,12 +152,12 @@ READ_LOCK_STATUS = TRUE # Simple TextIn/TextOut for UEFI Terminal
INF EmbeddedPkg/SimpleTextInOutSerial/SimpleTextInOutSerial.inf
-
+
#
# Semi-hosting filesystem (Required the Hardware Debugger to be connected)
#
INF ArmPkg/Filesystem/SemihostFs/SemihostFs.inf
-
+
#
# FAT filesystem + GPT/MBR partitioning
#
@@ -165,12 +165,12 @@ READ_LOCK_STATUS = TRUE INF MdeModulePkg/Universal/Disk/PartitionDxe/PartitionDxe.inf
INF FatBinPkg/EnhancedFatDxe/Fat.inf
INF MdeModulePkg/Universal/Disk/UnicodeCollation/EnglishDxe/EnglishDxe.inf
-
+
+ #
+ # UEFI application (Shell Embedded Boot Loader)
#
- # UEFI application (Shell Embedded Boot Loader)
- #
INF EmbeddedPkg/Ebl/Ebl.inf
-
+
#
# Bds
#
@@ -205,7 +205,7 @@ READ_LOCK_STATUS = TRUE INF IntelFrameworkModulePkg/Universal/StatusCode/Pei/StatusCodePei.inf
INF MdeModulePkg/Universal/Variable/Pei/VariablePei.inf
INF MdeModulePkg/Core/DxeIplPeim/DxeIpl.inf
-
+
FILE FV_IMAGE = 9E21FD93-9C72-4c15-8C4B-E77F1DB2D792 {
SECTION GUIDED EE4E5898-3914-4259-9D6E-DC7BD79403CF PROCESSING_REQUIRED = TRUE {
SECTION FV_IMAGE = FVMAIN
@@ -224,7 +224,7 @@ READ_LOCK_STATUS = TRUE ############################################################################
-# Example of a DXE_DRIVER FFS file with a Checksum encapsulation section #
+# Example of a DXE_DRIVER FFS file with a Checksum encapsulation section #
############################################################################
#
#[Rule.Common.DXE_DRIVER]
@@ -312,6 +312,6 @@ READ_LOCK_STATUS = TRUE [Rule.Common.UEFI_APPLICATION]
FILE APPLICATION = $(NAMED_GUID) {
- UI STRING ="$(MODULE_NAME)" Optional
+ UI STRING ="$(MODULE_NAME)" Optional
PE32 PE32 $(INF_OUTPUT)/$(MODULE_NAME).efi
}
diff --git a/ArmPlatformPkg/ArmRealViewEbPkg/ArmRealViewEb-RTSM-A8.dsc b/ArmPlatformPkg/ArmRealViewEbPkg/ArmRealViewEb-RTSM-A8.dsc index 2b1c7963c3..036e38997f 100644 --- a/ArmPlatformPkg/ArmRealViewEbPkg/ArmRealViewEb-RTSM-A8.dsc +++ b/ArmPlatformPkg/ArmRealViewEbPkg/ArmRealViewEb-RTSM-A8.dsc @@ -1,13 +1,13 @@ #
# Copyright (c) 2011-2014, ARM Limited. All rights reserved.
-#
-# This program and the accompanying materials
-# are licensed and made available under the terms and conditions of the BSD License
-# which accompanies this distribution. The full text of the license may be found at
-# http://opensource.org/licenses/bsd-license.php
#
-# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
-# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
+# This program and the accompanying materials
+# are licensed and made available under the terms and conditions of the BSD License
+# which accompanies this distribution. The full text of the license may be found at
+# http://opensource.org/licenses/bsd-license.php
+#
+# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
+# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
#
#
@@ -33,7 +33,7 @@ ArmLib|ArmPkg/Library/ArmLib/ArmV7/ArmV7Lib.inf
ArmCpuLib|ArmPkg/Drivers/ArmCpuLib/ArmCortexA8Lib/ArmCortexA8Lib.inf
ArmPlatformLib|ArmPlatformPkg/ArmRealViewEbPkg/Library/ArmRealViewEbLibRTSM/ArmRealViewEbLib.inf
-
+
[LibraryClasses.common.SEC]
ArmLib|ArmPkg/Library/ArmLib/ArmV7/ArmV7LibSec.inf
ArmPlatformSecLib|ArmPlatformPkg/ArmRealViewEbPkg/Library/ArmRealViewEbSecLibRTSM/ArmRealViewEbSecLib.inf
@@ -62,14 +62,14 @@ ## If TRUE, Graphics Output Protocol will be installed on virtual handle created by ConsplitterDxe.
# It could be set FALSE to save size.
gEfiMdeModulePkgTokenSpaceGuid.PcdConOutGopSupport|TRUE
-
+
# Install Debugger Exception Handlers.
gArmTokenSpaceGuid.PcdDebuggerExceptionSupport|TRUE
[PcdsFixedAtBuild.common]
gArmPlatformTokenSpaceGuid.PcdFirmwareVendor|"ARM RealView Emulation Board"
gEmbeddedTokenSpaceGuid.PcdEmbeddedPrompt|"ArmRealViewEb-A8"
-
+
#
# NV Storage PCDs. Use base of 0x43F00000 for NOR0
#
@@ -87,41 +87,41 @@ # Stack for CPU Cores in Non Secure Mode
gArmPlatformTokenSpaceGuid.PcdCPUCoresStackBase|0x48000000
- # System Memory (256MB)
+ # System Memory (256MB)
gArmTokenSpaceGuid.PcdSystemMemoryBase|0x70000000
gArmTokenSpaceGuid.PcdSystemMemorySize|0x10000000
-
+
# Size of the region used by UEFI in permanent memory (Reserved 64MB)
gArmPlatformTokenSpaceGuid.PcdSystemMemoryUefiRegionSize|0x04000000
-
+
#
# ARM Pcds
#
gArmTokenSpaceGuid.PcdArmUncachedMemoryMask|0x0000000040000000
-
+
#
# ARM PrimeCells
#
-
+
## SP804 Timer
gEmbeddedTokenSpaceGuid.PcdEmbeddedPerformanceCounterFrequencyInHz|1000000
gEmbeddedTokenSpaceGuid.PcdTimerPeriod|100000 # expressed in 100ns units, 100,000 x 100 ns = 10,000,000 ns = 10 ms
gArmPlatformTokenSpaceGuid.PcdSP804TimerPeriodicInterruptNum|36
- gArmPlatformTokenSpaceGuid.PcdSP804TimerPeriodicBase|0x10011000
+ gArmPlatformTokenSpaceGuid.PcdSP804TimerPeriodicBase|0x10011000
gArmPlatformTokenSpaceGuid.PcdSP804TimerMetronomeBase|0x10011020
gArmPlatformTokenSpaceGuid.PcdSP804TimerPerformanceBase|0x10012020
-
+
## PL031 RealTimeClock
gArmPlatformTokenSpaceGuid.PcdPL031RtcBase|0x10017000
-
+
## PL111 Lcd
gArmPlatformTokenSpaceGuid.PcdPL111LcdBase|0x10020000
-
+
#
# ARM PL011 - Serial Terminal
#
gEfiMdeModulePkgTokenSpaceGuid.PcdSerialRegisterBase|0x10009000
-
+
#
# ARM General Interrupt Controller
#
@@ -135,7 +135,7 @@ #
################################################################################
[Components.common]
-
+
#
# SEC
#
@@ -144,7 +144,7 @@ # Use the implementation which set the Secure bits
ArmGicLib|ArmPkg/Drivers/ArmGic/ArmGicSecLib.inf
}
-
+
#
# PEI Phase modules
#
@@ -189,15 +189,15 @@ #
# Architectural Protocols
#
- ArmPkg/Drivers/CpuDxe/CpuDxe.inf
+ ArmPkg/Drivers/CpuDxe/CpuDxe.inf
MdeModulePkg/Core/RuntimeDxe/RuntimeDxe.inf
MdeModulePkg/Universal/SecurityStubDxe/SecurityStubDxe.inf
MdeModulePkg/Universal/WatchdogTimerDxe/WatchdogTimer.inf
MdeModulePkg/Universal/CapsuleRuntimeDxe/CapsuleRuntimeDxe.inf
MdeModulePkg/Universal/Variable/RuntimeDxe/VariableRuntimeDxe.inf
MdeModulePkg/Universal/FaultTolerantWriteDxe/FaultTolerantWriteDxe.inf
- EmbeddedPkg/EmbeddedMonotonicCounter/EmbeddedMonotonicCounter.inf
-
+ EmbeddedPkg/EmbeddedMonotonicCounter/EmbeddedMonotonicCounter.inf
+
EmbeddedPkg/ResetRuntimeDxe/ResetRuntimeDxe.inf
EmbeddedPkg/RealTimeClockRuntimeDxe/RealTimeClockRuntimeDxe.inf
EmbeddedPkg/MetronomeDxe/MetronomeDxe.inf
@@ -213,21 +213,21 @@ ArmPkg/Drivers/ArmGic/ArmGicDxe.inf
ArmPlatformPkg/Drivers/SP804TimerDxe/SP804TimerDxe.inf
-
+
ArmPlatformPkg/Drivers/NorFlashDxe/NorFlashDxe.inf
#
# Semi-hosting filesystem
#
ArmPkg/Filesystem/SemihostFs/SemihostFs.inf
-
+
#
# FAT filesystem + GPT/MBR partitioning
#
MdeModulePkg/Universal/Disk/DiskIoDxe/DiskIoDxe.inf
MdeModulePkg/Universal/Disk/PartitionDxe/PartitionDxe.inf
MdeModulePkg/Universal/Disk/UnicodeCollation/EnglishDxe/EnglishDxe.inf
-
+
#
# Bds
#
diff --git a/ArmPlatformPkg/ArmRealViewEbPkg/ArmRealViewEb-RTSM-A9x2.dsc b/ArmPlatformPkg/ArmRealViewEbPkg/ArmRealViewEb-RTSM-A9x2.dsc index 612874dff1..a7aec05b8c 100644 --- a/ArmPlatformPkg/ArmRealViewEbPkg/ArmRealViewEb-RTSM-A9x2.dsc +++ b/ArmPlatformPkg/ArmRealViewEbPkg/ArmRealViewEb-RTSM-A9x2.dsc @@ -1,13 +1,13 @@ #
# Copyright (c) 2011-2014, ARM Limited. All rights reserved.
-#
-# This program and the accompanying materials
-# are licensed and made available under the terms and conditions of the BSD License
-# which accompanies this distribution. The full text of the license may be found at
-# http://opensource.org/licenses/bsd-license.php
#
-# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
-# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
+# This program and the accompanying materials
+# are licensed and made available under the terms and conditions of the BSD License
+# which accompanies this distribution. The full text of the license may be found at
+# http://opensource.org/licenses/bsd-license.php
+#
+# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
+# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
#
#
@@ -33,7 +33,7 @@ ArmLib|ArmPkg/Library/ArmLib/ArmV7/ArmV7Lib.inf
ArmCpuLib|ArmPkg/Drivers/ArmCpuLib/ArmCortexA9Lib/ArmCortexA9Lib.inf
ArmPlatformLib|ArmPlatformPkg/ArmRealViewEbPkg/Library/ArmRealViewEbLibRTSM/ArmRealViewEbLib.inf
-
+
[LibraryClasses.common.SEC]
ArmLib|ArmPkg/Library/ArmLib/ArmV7/ArmV7LibSec.inf
ArmPlatformSecLib|ArmPlatformPkg/ArmRealViewEbPkg/Library/ArmRealViewEbSecLibRTSM/ArmRealViewEbSecLib.inf
@@ -68,7 +68,7 @@ gEmbeddedTokenSpaceGuid.PcdEmbeddedPrompt|"ArmRealViewEb-A9x2"
gArmPlatformTokenSpaceGuid.PcdCoreCount|2
-
+
#
# NV Storage PCDs. Use base of 0x43F00000 for NOR0
#
@@ -86,41 +86,41 @@ # Stacks for MPCores in Normal World
gArmPlatformTokenSpaceGuid.PcdCPUCoresStackBase|0x48000000
- # System Memory (256MB)
+ # System Memory (256MB)
gArmTokenSpaceGuid.PcdSystemMemoryBase|0x70000000
gArmTokenSpaceGuid.PcdSystemMemorySize|0x10000000
-
+
# Size of the region used by UEFI in permanent memory (Reserved 64MB)
gArmPlatformTokenSpaceGuid.PcdSystemMemoryUefiRegionSize|0x04000000
-
+
#
# ARM Pcds
#
gArmTokenSpaceGuid.PcdArmUncachedMemoryMask|0x0000000040000000
-
+
#
# ARM PrimeCells
#
-
+
## SP804 Timer
gEmbeddedTokenSpaceGuid.PcdEmbeddedPerformanceCounterFrequencyInHz|1000000
gEmbeddedTokenSpaceGuid.PcdTimerPeriod|100000 # expressed in 100ns units, 100,000 x 100 ns = 10,000,000 ns = 10 ms
gArmPlatformTokenSpaceGuid.PcdSP804TimerPeriodicInterruptNum|33
- gArmPlatformTokenSpaceGuid.PcdSP804TimerPeriodicBase|0x10011000
+ gArmPlatformTokenSpaceGuid.PcdSP804TimerPeriodicBase|0x10011000
gArmPlatformTokenSpaceGuid.PcdSP804TimerMetronomeBase|0x10011020
gArmPlatformTokenSpaceGuid.PcdSP804TimerPerformanceBase|0x10012020
-
+
## PL031 RealTimeClock
gArmPlatformTokenSpaceGuid.PcdPL031RtcBase|0x10017000
-
+
## PL111 Lcd
gArmPlatformTokenSpaceGuid.PcdPL111LcdBase|0x10020000
-
+
#
# ARM PL011 - Serial Terminal
#
gEfiMdeModulePkgTokenSpaceGuid.PcdSerialRegisterBase|0x10009000
-
+
#
# ARM General Interrupt Controller
#
@@ -131,14 +131,14 @@ # ARM L2x0 PCDs
#
gArmTokenSpaceGuid.PcdL2x0ControllerBase|0x1F002000
-
+
################################################################################
#
# Components Section - list of all EDK II Modules needed by this Platform
#
################################################################################
[Components.common]
-
+
#
# SEC
#
@@ -147,7 +147,7 @@ # Use the implementation which set the Secure bits
ArmGicLib|ArmPkg/Drivers/ArmGic/ArmGicSecLib.inf
}
-
+
#
# PEI Phase modules
#
@@ -189,15 +189,15 @@ #
# Architectural Protocols
#
- ArmPkg/Drivers/CpuDxe/CpuDxe.inf
+ ArmPkg/Drivers/CpuDxe/CpuDxe.inf
MdeModulePkg/Core/RuntimeDxe/RuntimeDxe.inf
MdeModulePkg/Universal/SecurityStubDxe/SecurityStubDxe.inf
MdeModulePkg/Universal/WatchdogTimerDxe/WatchdogTimer.inf
MdeModulePkg/Universal/CapsuleRuntimeDxe/CapsuleRuntimeDxe.inf
MdeModulePkg/Universal/Variable/RuntimeDxe/VariableRuntimeDxe.inf
MdeModulePkg/Universal/FaultTolerantWriteDxe/FaultTolerantWriteDxe.inf
- EmbeddedPkg/EmbeddedMonotonicCounter/EmbeddedMonotonicCounter.inf
-
+ EmbeddedPkg/EmbeddedMonotonicCounter/EmbeddedMonotonicCounter.inf
+
EmbeddedPkg/ResetRuntimeDxe/ResetRuntimeDxe.inf
EmbeddedPkg/RealTimeClockRuntimeDxe/RealTimeClockRuntimeDxe.inf
EmbeddedPkg/MetronomeDxe/MetronomeDxe.inf
@@ -213,21 +213,21 @@ ArmPkg/Drivers/ArmGic/ArmGicDxe.inf
ArmPlatformPkg/Drivers/SP804TimerDxe/SP804TimerDxe.inf
-
+
ArmPlatformPkg/Drivers/NorFlashDxe/NorFlashDxe.inf
#
# Semi-hosting filesystem
#
ArmPkg/Filesystem/SemihostFs/SemihostFs.inf
-
+
#
# FAT filesystem + GPT/MBR partitioning
#
MdeModulePkg/Universal/Disk/DiskIoDxe/DiskIoDxe.inf
MdeModulePkg/Universal/Disk/PartitionDxe/PartitionDxe.inf
MdeModulePkg/Universal/Disk/UnicodeCollation/EnglishDxe/EnglishDxe.inf
-
+
#
# Bds
#
diff --git a/ArmPlatformPkg/ArmRealViewEbPkg/ArmRealViewEb-RTSM-MPCore.fdf b/ArmPlatformPkg/ArmRealViewEbPkg/ArmRealViewEb-RTSM-MPCore.fdf index 1d286616d7..8382d27623 100644 --- a/ArmPlatformPkg/ArmRealViewEbPkg/ArmRealViewEb-RTSM-MPCore.fdf +++ b/ArmPlatformPkg/ArmRealViewEbPkg/ArmRealViewEb-RTSM-MPCore.fdf @@ -1,14 +1,14 @@ # FLASH layout file for ARM RealView EB.
#
# Copyright (c) 2011-2014, ARM Limited. All rights reserved.
-#
-# This program and the accompanying materials
-# are licensed and made available under the terms and conditions of the BSD License
-# which accompanies this distribution. The full text of the license may be found at
-# http://opensource.org/licenses/bsd-license.php
#
-# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
-# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
+# This program and the accompanying materials
+# are licensed and made available under the terms and conditions of the BSD License
+# which accompanies this distribution. The full text of the license may be found at
+# http://opensource.org/licenses/bsd-license.php
+#
+# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
+# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
#
################################################################################
@@ -109,10 +109,10 @@ READ_STATUS = TRUE READ_LOCK_CAP = TRUE
READ_LOCK_STATUS = TRUE
- INF MdeModulePkg/Core/Dxe/DxeMain.inf
+ INF MdeModulePkg/Core/Dxe/DxeMain.inf
#
- # PI DXE Drivers producing Architectural Protocols (EFI Services)
+ # PI DXE Drivers producing Architectural Protocols (EFI Services)
#
INF ArmPkg/Drivers/CpuDxe/CpuDxe.inf
INF MdeModulePkg/Core/RuntimeDxe/RuntimeDxe.inf
@@ -137,10 +137,10 @@ READ_LOCK_STATUS = TRUE INF MdeModulePkg/Universal/Console/GraphicsConsoleDxe/GraphicsConsoleDxe.inf
INF MdeModulePkg/Universal/Console/TerminalDxe/TerminalDxe.inf
INF EmbeddedPkg/SerialDxe/SerialDxe.inf
-
+
INF ArmPkg/Drivers/ArmGic/ArmGicDxe.inf
INF ArmPlatformPkg/Drivers/SP804TimerDxe/SP804TimerDxe.inf
-
+
INF ArmPlatformPkg/Drivers/NorFlashDxe/NorFlashDxe.inf
#
@@ -163,9 +163,9 @@ READ_LOCK_STATUS = TRUE INF MdeModulePkg/Universal/Disk/UnicodeCollation/EnglishDxe/EnglishDxe.inf
#
- # UEFI application (Shell Embedded Boot Loader)
- #
- INF ShellBinPkg/UefiShell/UefiShell.inf
+ # UEFI application (Shell Embedded Boot Loader)
+ #
+ INF ShellBinPkg/UefiShell/UefiShell.inf
#
# Bds
@@ -223,7 +223,7 @@ READ_LOCK_STATUS = TRUE ############################################################################
-# Example of a DXE_DRIVER FFS file with a Checksum encapsulation section #
+# Example of a DXE_DRIVER FFS file with a Checksum encapsulation section #
############################################################################
#
#[Rule.Common.DXE_DRIVER]
@@ -248,14 +248,14 @@ READ_LOCK_STATUS = TRUE [Rule.Common.PEI_CORE]
FILE PEI_CORE = $(NAMED_GUID) {
TE TE $(INF_OUTPUT)/$(MODULE_NAME).efi
- UI STRING ="$(MODULE_NAME)" Optional
+ UI STRING ="$(MODULE_NAME)" Optional
}
[Rule.Common.PEIM]
FILE PEIM = $(NAMED_GUID) {
PEI_DEPEX PEI_DEPEX Optional $(INF_OUTPUT)/$(MODULE_NAME).depex
TE TE $(INF_OUTPUT)/$(MODULE_NAME).efi
- UI STRING="$(MODULE_NAME)" Optional
+ UI STRING="$(MODULE_NAME)" Optional
}
[Rule.Common.PEIM.TIANOCOMPRESSED]
@@ -296,7 +296,7 @@ READ_LOCK_STATUS = TRUE [Rule.Common.UEFI_APPLICATION]
FILE APPLICATION = $(NAMED_GUID) {
- UI STRING ="$(MODULE_NAME)" Optional
+ UI STRING ="$(MODULE_NAME)" Optional
PE32 PE32 $(INF_OUTPUT)/$(MODULE_NAME).efi
}
diff --git a/ArmPlatformPkg/ArmRealViewEbPkg/ArmRealViewEb-RTSM-UniCore.fdf b/ArmPlatformPkg/ArmRealViewEbPkg/ArmRealViewEb-RTSM-UniCore.fdf index 5740eeba67..d5b4eb68e2 100644 --- a/ArmPlatformPkg/ArmRealViewEbPkg/ArmRealViewEb-RTSM-UniCore.fdf +++ b/ArmPlatformPkg/ArmRealViewEbPkg/ArmRealViewEb-RTSM-UniCore.fdf @@ -110,10 +110,10 @@ READ_STATUS = TRUE READ_LOCK_CAP = TRUE
READ_LOCK_STATUS = TRUE
- INF MdeModulePkg/Core/Dxe/DxeMain.inf
+ INF MdeModulePkg/Core/Dxe/DxeMain.inf
#
- # PI DXE Drivers producing Architectural Protocols (EFI Services)
+ # PI DXE Drivers producing Architectural Protocols (EFI Services)
#
INF ArmPkg/Drivers/CpuDxe/CpuDxe.inf
INF MdeModulePkg/Core/RuntimeDxe/RuntimeDxe.inf
@@ -138,10 +138,10 @@ READ_LOCK_STATUS = TRUE INF MdeModulePkg/Universal/Console/GraphicsConsoleDxe/GraphicsConsoleDxe.inf
INF MdeModulePkg/Universal/Console/TerminalDxe/TerminalDxe.inf
INF EmbeddedPkg/SerialDxe/SerialDxe.inf
-
+
INF ArmPkg/Drivers/ArmGic/ArmGicDxe.inf
INF ArmPlatformPkg/Drivers/SP804TimerDxe/SP804TimerDxe.inf
-
+
INF ArmPlatformPkg/Drivers/NorFlashDxe/NorFlashDxe.inf
#
@@ -164,9 +164,9 @@ READ_LOCK_STATUS = TRUE INF MdeModulePkg/Universal/Disk/UnicodeCollation/EnglishDxe/EnglishDxe.inf
#
- # UEFI application (Shell Embedded Boot Loader)
- #
- INF ShellBinPkg/UefiShell/UefiShell.inf
+ # UEFI application (Shell Embedded Boot Loader)
+ #
+ INF ShellBinPkg/UefiShell/UefiShell.inf
#
# Bds
@@ -224,7 +224,7 @@ READ_LOCK_STATUS = TRUE ############################################################################
-# Example of a DXE_DRIVER FFS file with a Checksum encapsulation section #
+# Example of a DXE_DRIVER FFS file with a Checksum encapsulation section #
############################################################################
#
#[Rule.Common.DXE_DRIVER]
@@ -249,14 +249,14 @@ READ_LOCK_STATUS = TRUE [Rule.Common.PEI_CORE]
FILE PEI_CORE = $(NAMED_GUID) {
TE TE $(INF_OUTPUT)/$(MODULE_NAME).efi
- UI STRING ="$(MODULE_NAME)" Optional
+ UI STRING ="$(MODULE_NAME)" Optional
}
[Rule.Common.PEIM]
FILE PEIM = $(NAMED_GUID) {
PEI_DEPEX PEI_DEPEX Optional $(INF_OUTPUT)/$(MODULE_NAME).depex
TE TE $(INF_OUTPUT)/$(MODULE_NAME).efi
- UI STRING="$(MODULE_NAME)" Optional
+ UI STRING="$(MODULE_NAME)" Optional
}
[Rule.Common.PEIM.TIANOCOMPRESSED]
@@ -297,7 +297,7 @@ READ_LOCK_STATUS = TRUE [Rule.Common.UEFI_APPLICATION]
FILE APPLICATION = $(NAMED_GUID) {
- UI STRING ="$(MODULE_NAME)" Optional
+ UI STRING ="$(MODULE_NAME)" Optional
PE32 PE32 $(INF_OUTPUT)/$(MODULE_NAME).efi
}
diff --git a/ArmPlatformPkg/ArmRealViewEbPkg/ArmRealViewEb.dsc.inc b/ArmPlatformPkg/ArmRealViewEbPkg/ArmRealViewEb.dsc.inc index 06c7b05a47..867a69ae21 100644 --- a/ArmPlatformPkg/ArmRealViewEbPkg/ArmRealViewEb.dsc.inc +++ b/ArmPlatformPkg/ArmRealViewEbPkg/ArmRealViewEb.dsc.inc @@ -1,13 +1,13 @@ #
# Copyright (c) 2011-2014, ARM Limited. All rights reserved.
-#
-# This program and the accompanying materials
-# are licensed and made available under the terms and conditions of the BSD License
-# which accompanies this distribution. The full text of the license may be found at
-# http://opensource.org/licenses/bsd-license.php
#
-# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
-# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
+# This program and the accompanying materials
+# are licensed and made available under the terms and conditions of the BSD License
+# which accompanies this distribution. The full text of the license may be found at
+# http://opensource.org/licenses/bsd-license.php
+#
+# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
+# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
#
#
@@ -41,7 +41,7 @@ UefiDriverEntryPoint|MdePkg/Library/UefiDriverEntryPoint/UefiDriverEntryPoint.inf
UefiApplicationEntryPoint|MdePkg/Library/UefiApplicationEntryPoint/UefiApplicationEntryPoint.inf
HiiLib|MdeModulePkg/Library/UefiHiiLib/UefiHiiLib.inf
- UefiHiiServicesLib|MdeModulePkg/Library/UefiHiiServicesLib/UefiHiiServicesLib.inf
+ UefiHiiServicesLib|MdeModulePkg/Library/UefiHiiServicesLib/UefiHiiServicesLib.inf
UefiRuntimeLib|MdePkg/Library/UefiRuntimeLib/UefiRuntimeLib.inf
@@ -85,7 +85,7 @@ EblNetworkLib|EmbeddedPkg/Library/EblNetworkLib/EblNetworkLib.inf
#
- # Uncomment (and comment out the next line) For RealView Debugger. The Standard IO window
+ # Uncomment (and comment out the next line) For RealView Debugger. The Standard IO window
# in the debugger will show load and unload commands for symbols. You can cut and paste this
# into the command window to load symbols. We should be able to use a script to do this, but
# the version of RVD I have does not support scripts accessing system memory.
@@ -93,12 +93,12 @@ #PeCoffExtraActionLib|ArmPkg/Library/RvdPeCoffExtraActionLib/RvdPeCoffExtraActionLib.inf
PeCoffExtraActionLib|ArmPkg/Library/DebugPeCoffExtraActionLib/DebugPeCoffExtraActionLib.inf
#PeCoffExtraActionLib|MdePkg/Library/BasePeCoffExtraActionLibNull/BasePeCoffExtraActionLibNull.inf
-
+
DebugAgentLib|MdeModulePkg/Library/DebugAgentLibNull/DebugAgentLibNull.inf
DebugAgentTimerLib|EmbeddedPkg/Library/DebugAgentTimerLibNull/DebugAgentTimerLibNull.inf
#DebugAgentTimerLib|ArmPlatformPkg/ArmRealViewEbPkg/Library/DebugAgentTimerLib/DebugAgentTimerLib.inf
- SemihostLib|ArmPkg/Library/SemihostLib/SemihostLib.inf
+ SemihostLib|ArmPkg/Library/SemihostLib/SemihostLib.inf
GdbSerialLib|ArmPlatformPkg/ArmRealViewEbPkg/Library/GdbSerialLib/GdbSerialLib.inf
@@ -113,9 +113,9 @@ DebugAgentLib|ArmPkg/Library/DebugAgentSymbolsBaseLib/DebugAgentSymbolsBaseLib.inf
DefaultExceptionHandlerLib|ArmPkg/Library/DefaultExceptionHandlerLib/DefaultExceptionHandlerLibBase.inf
- # Uncomment to turn on GDB stub in SEC.
+ # Uncomment to turn on GDB stub in SEC.
#DebugAgentLib|EmbeddedPkg/Library/GdbDebugAgent/GdbDebugAgent.inf
-
+
!ifdef $(EDK2_SKIP_PEICORE)
PrePiLib|EmbeddedPkg/Library/PrePiLib/PrePiLib.inf
ExtractGuidedSectionLib|EmbeddedPkg/Library/PrePiExtractGuidedSectionLib/PrePiExtractGuidedSectionLib.inf
@@ -223,9 +223,9 @@ gEfiMdePkgTokenSpaceGuid.PcdDriverDiagnosticsDisable|TRUE
gEfiMdePkgTokenSpaceGuid.PcdComponentName2Disable|TRUE
gEfiMdePkgTokenSpaceGuid.PcdDriverDiagnostics2Disable|TRUE
-
+
gEmbeddedTokenSpaceGuid.PcdCacheEnable|TRUE
-
+
# Use the Vector Table location in CpuDxe. We will not copy the Vector Table at PcdCpuVectorBaseAddress
gArmTokenSpaceGuid.PcdRelocateVectorTable|FALSE
@@ -272,16 +272,16 @@ gEfiMdePkgTokenSpaceGuid.PcdDebugPrintErrorLevel|0x8000000F
gEfiMdePkgTokenSpaceGuid.PcdReportStatusCodePropertyMask|0x07
-
+
gEmbeddedTokenSpaceGuid.PcdEmbeddedAutomaticBootCommand|""
gEmbeddedTokenSpaceGuid.PcdEmbeddedDefaultTextColor|0x07
gEmbeddedTokenSpaceGuid.PcdEmbeddedMemVariableStoreSize|0x10000
-
+
#
# Optional feature to help prevent EFI memory map fragments
# Turned on and off via: PcdPrePiProduceMemoryTypeInformationHob
- # Values are in EFI Pages (4K). DXE Core will make sure that
- # at least this much of each type of memory can be allocated
+ # Values are in EFI Pages (4K). DXE Core will make sure that
+ # at least this much of each type of memory can be allocated
# from a single memory range. This way you only end up with
# maximum of two fragements for each type in the memory map
# (the memory used, and the free memory that was prereserved
@@ -300,7 +300,7 @@ gArmPlatformTokenSpaceGuid.PcdDefaultBootDescription|L"SemiHosting"
gArmPlatformTokenSpaceGuid.PcdDefaultBootDevicePath|L"VenHw(C5B9C74A-6D72-4719-99AB-C59F199091EB)/zImage-RTSM"
gArmPlatformTokenSpaceGuid.PcdDefaultBootType|1
-
+
# Use the Serial console (ConIn & ConOut) and the Graphic driver (ConOut)
gArmPlatformTokenSpaceGuid.PcdDefaultConOutPaths|L"VenHw(D3987D4B-971A-435F-8CAF-4967EB627241)/Uart(115200,8,N,1)/VenPcAnsi();VenHw(407B4008-BF5B-11DF-9547-CF16E0D72085)"
gArmPlatformTokenSpaceGuid.PcdDefaultConInPaths|L"VenHw(D3987D4B-971A-435F-8CAF-4967EB627241)/Uart(115200,8,N,1)/VenPcAnsi()"
diff --git a/ArmPlatformPkg/ArmRealViewEbPkg/ArmRealViewEbPkg.dec b/ArmPlatformPkg/ArmRealViewEbPkg/ArmRealViewEbPkg.dec index 47292d2e41..501553251e 100644 --- a/ArmPlatformPkg/ArmRealViewEbPkg/ArmRealViewEbPkg.dec +++ b/ArmPlatformPkg/ArmRealViewEbPkg/ArmRealViewEbPkg.dec @@ -33,7 +33,7 @@ Include # Root include for the package
[Guids.common]
- gArmRealViewEbPkgTokenSpaceGuid = { 0x44577A0D, 0x361A, 0x45B2, { 0xb3, 0x3d, 0xbb, 0x9e, 0xe6, 0x0d, 0x5a, 0x4f} }
+ gArmRealViewEbPkgTokenSpaceGuid = { 0x44577A0D, 0x361A, 0x45B2, { 0xb3, 0x3d, 0xbb, 0x9e, 0xe6, 0x0d, 0x5a, 0x4f} }
[PcdsFixedAtBuild.common]
gArmRealViewEbPkgTokenSpaceGuid.PcdGdbUartBase|0|UINT32|0x00000001
diff --git a/ArmPlatformPkg/ArmRealViewEbPkg/Debugger_scripts/EfiFuncs.inc b/ArmPlatformPkg/ArmRealViewEbPkg/Debugger_scripts/EfiFuncs.inc index 0bbe045a96..82a32884c4 100644 --- a/ArmPlatformPkg/ArmRealViewEbPkg/Debugger_scripts/EfiFuncs.inc +++ b/ArmPlatformPkg/ArmRealViewEbPkg/Debugger_scripts/EfiFuncs.inc @@ -11,7 +11,7 @@ define /r GetMaxMem() define /r GetWord(Addr)
{
unsigned long data;
-
+
if( (Addr & 0x2) == 0 )
{
data = dword(Addr);
@@ -68,7 +68,7 @@ unsigned long imgstart; $printf "debug type is %x",debugtype$;
return;
}
-
+
debugrva = dword(imgstart + debugdirentryrva + 0x14);
dwarfsig = dword(imgstart + debugrva);
if(dwarfsig != 0x66727764)
@@ -81,7 +81,7 @@ unsigned long imgstart; baseofcode = imgstart + dword(filehdrstart + 0x28);
baseofdata = imgstart + dword(filehdrstart + 0x2c);
-
+
if( (baseofcode < baseofdata) && (baseofcode != 0) )
{
elfbase = baseofcode;
@@ -132,7 +132,7 @@ unsigned long imgstart; $printf "debug type is %x",debugtype$;
return;
}
-
+
debugrva = dword(imgstart + debugdirentryrva + 0x14);
debugrva = debugrva - strippedsize;
dwarfsig = dword(imgstart + debugrva);
@@ -142,16 +142,16 @@ unsigned long imgstart; $printf "found %x", dwarfsig$;
return;
}
-
+
if( dwarfsig == 0x66727764 )
{
elfpath = (char *)(imgstart + debugrva + 0xc);
- $printf "looking for elf path at 0x%x", elfpath$;
+ $printf "looking for elf path at 0x%x", elfpath$;
}
- else
+ else
{
elfpath = (char *)(imgstart + debugrva + 0x10);
- $printf "looking for elf path at 0x%x", elfpath$;
+ $printf "looking for elf path at 0x%x", elfpath$;
}
// elf base is baseofcode (we hope that for TE images it's not baseofdata)
@@ -181,7 +181,7 @@ unsigned long secstart; }
else if(sectiontype == 0x12) // TE
{
- ProcessTE(secstart+0x4);
+ ProcessTE(secstart+0x4);
}
}
.
@@ -247,7 +247,7 @@ define /r LoadPeiSec() $fopen 50, 'C:\loadfiles.inc'$;
fvlen = dword(fvbase + 0x20);
-
+
// first ffs file is after fv header, use headerlength field
//ffsoffset = (dword(fvbase + 0x30) & 0xffff0000) >> 16;
ffsoffset = (dword(fvbase + 0x30) & 0xffff0000) / 0x10000;
@@ -257,21 +257,21 @@ define /r LoadPeiSec() while(ffsoffset < (fvbase+fvlen))
{
// process ffs file and increment by ffs file size field
- ProcessFfsFile(ffsoffset);
+ ProcessFfsFile(ffsoffset);
ffsfilesize = (dword(ffsoffset + 0x14) & 0x00ffffff);
if(ffsfilesize == 0)
{
break;
}
ffsoffset = ffsoffset + ffsfilesize;
-
+
// align to next 8 byte boundary
if( (ffsoffset & 0x7) != 0 )
{
ffsoffset = ffsoffset + (0x8 - (ffsoffset & 0x7));
}
-
+
} // end fv ffs loop
$vclose 50$;
@@ -283,21 +283,21 @@ define /r FindSystemTable(TopOfRam) unsigned long TopOfRam;
{
unsigned long offset;
-
+
$printf "FindSystemTable"$;
$printf "top of mem is %x",TopOfRam$;
-
+
offset = TopOfRam;
-
+
// align to highest 4MB boundary
offset = offset & 0xFFC00000;
-
+
// start at top and look on 4MB boundaries for system table ptr structure
while(offset > 0)
{
//$printf "checking %x",offset$;
//$printf "value is %x",dword(offset)$;
-
+
// low signature match
if(dword(offset) == 0x20494249)
{
@@ -314,13 +314,13 @@ unsigned long TopOfRam; }
}
}
-
+
}
-
+
if(offset < 0x400000) break;
- offset = offset - 0x400000;
+ offset = offset - 0x400000;
}
-
+
return 0;
}
.
@@ -344,15 +344,15 @@ unsigned long SystemTable; unsigned long dbgptr;
unsigned long dbginfo;
unsigned long loadedimg;
-
+
$printf "FindDebugInfo"$;
-
+
dbgentries = 0;
CfgTableEntries = dword(SystemTable + 0x40);
ConfigTable = dword(SystemTable + 0x44);
-
+
$printf "config table is at %x (%d entries)", ConfigTable, CfgTableEntries$;
-
+
// now search for debug info entry with guid 49152E77-1ADA-4764-B7A2-7AFEFED95E8B
// 0x49152E77 0x47641ADA 0xFE7AA2B7 0x8B5ED9FE
for(i=0; i<CfgTableEntries; i++)
@@ -374,15 +374,15 @@ unsigned long SystemTable; }
}
}
-
+
if(dbgentries == 0)
{
$printf "no debug entries found"$;
return;
}
-
+
$printf "debug table at %x (%d entries)", dbgptr, dbgentries$;
-
+
for(i=0; i<dbgentries; i++)
{
dbginfo = dword(dbgptr + (i*4));
@@ -402,11 +402,11 @@ define /r LoadDxe() {
unsigned long maxmem;
unsigned long systbl;
-
+
$printf "LoadDxe"$;
-
+
$fopen 50, 'C:\loadfiles.inc'$;
-
+
maxmem = GetMaxMem();
systbl = FindSystemTable(maxmem);
if(systbl != 0)
@@ -414,7 +414,7 @@ define /r LoadDxe() $printf "found system table at %x",systbl$;
FindDebugInfo(systbl);
}
-
+
$vclose 50$;
}
.
@@ -432,19 +432,19 @@ define /r LoadRuntimeDxe() unsigned long RuntimeDebugInfo;
unsigned long DebugInfoOffset;
unsigned long imgbase;
-
+
$printf "LoadRuntimeDxe"$;
-
+
$fopen 50, 'C:\loadfiles.inc'$;
-
+
RuntimeDebugInfo = 0x80000010;
-
+
if(RuntimeDebugInfo != 0)
{
numentries = dword(RuntimeDebugInfo);
-
+
$printf "runtime debug info is at %x (%d entries)", RuntimeDebugInfo, numentries$;
-
+
DebugInfoOffset = RuntimeDebugInfo + 0x4;
for(i=0; i<numentries; i++)
{
@@ -457,7 +457,7 @@ define /r LoadRuntimeDxe() DebugInfoOffset = DebugInfoOffset + 0x4;
}
}
-
+
$vclose 50$;
}
.
diff --git a/ArmPlatformPkg/ArmRealViewEbPkg/Debugger_scripts/rvi_boot_from_ram.inc b/ArmPlatformPkg/ArmRealViewEbPkg/Debugger_scripts/rvi_boot_from_ram.inc index c691af69d7..a4e96747f8 100644 --- a/ArmPlatformPkg/ArmRealViewEbPkg/Debugger_scripts/rvi_boot_from_ram.inc +++ b/ArmPlatformPkg/ArmRealViewEbPkg/Debugger_scripts/rvi_boot_from_ram.inc @@ -1,6 +1,6 @@ //
// Copyright (c) 2008 - 2009, Apple Inc. All rights reserved.<BR>
-//
+//
// This program and the accompanying materials
// are licensed and made available under the terms and conditions of the BSD License
// which accompanies this distribution. The full text of the license may be found at
diff --git a/ArmPlatformPkg/ArmRealViewEbPkg/Debugger_scripts/rvi_hw_setup.inc b/ArmPlatformPkg/ArmRealViewEbPkg/Debugger_scripts/rvi_hw_setup.inc index f7c211f15a..dbce4dfdbd 100644 --- a/ArmPlatformPkg/ArmRealViewEbPkg/Debugger_scripts/rvi_hw_setup.inc +++ b/ArmPlatformPkg/ArmRealViewEbPkg/Debugger_scripts/rvi_hw_setup.inc @@ -1,6 +1,6 @@ //
// Copyright (c) 2008 - 2009, Apple Inc. All rights reserved.<BR>
-//
+//
// This program and the accompanying materials
// are licensed and made available under the terms and conditions of the BSD License
// which accompanies this distribution. The full text of the license may be found at
diff --git a/ArmPlatformPkg/ArmRealViewEbPkg/Debugger_scripts/rvi_load_symbols.inc b/ArmPlatformPkg/ArmRealViewEbPkg/Debugger_scripts/rvi_load_symbols.inc index e093ccbcb2..33e3eacac4 100644 --- a/ArmPlatformPkg/ArmRealViewEbPkg/Debugger_scripts/rvi_load_symbols.inc +++ b/ArmPlatformPkg/ArmRealViewEbPkg/Debugger_scripts/rvi_load_symbols.inc @@ -1,6 +1,6 @@ //
// Copyright (c) 2008 - 2009, Apple Inc. All rights reserved.<BR>
-//
+//
// This program and the accompanying materials
// are licensed and made available under the terms and conditions of the BSD License
// which accompanies this distribution. The full text of the license may be found at
diff --git a/ArmPlatformPkg/ArmRealViewEbPkg/Debugger_scripts/rvi_symbols_macros.inc b/ArmPlatformPkg/ArmRealViewEbPkg/Debugger_scripts/rvi_symbols_macros.inc index 97d465eaf2..0fc2c64b1a 100644 --- a/ArmPlatformPkg/ArmRealViewEbPkg/Debugger_scripts/rvi_symbols_macros.inc +++ b/ArmPlatformPkg/ArmRealViewEbPkg/Debugger_scripts/rvi_symbols_macros.inc @@ -1,6 +1,6 @@ //
// Copyright (c) 2008 - 2009, Apple Inc. All rights reserved.<BR>
-//
+//
// This program and the accompanying materials
// are licensed and made available under the terms and conditions of the BSD License
// which accompanies this distribution. The full text of the license may be found at
@@ -23,20 +23,20 @@ define /R unsigned char * find_system_table(mem_start, mem_size) unsigned long mem_size;
{
unsigned char *mem_ptr;
-
+
mem_ptr = mem_start + mem_size;
-
+
do
{
mem_ptr -= 0x400000; // 4 MB
-
+
if (strncmp(mem_ptr, "IBI SYST", 8) == 0)
{
return *(unsigned long *)(mem_ptr + 8); // EfiSystemTableBase
- }
-
+ }
+
} while (mem_ptr > mem_start);
-
+
return 0;
}
.
@@ -48,7 +48,7 @@ define /R unsigned char * find_debug_info_table_header(system_table) unsigned char *configuration_table;
unsigned long index;
unsigned char debug_table_guid[16];
-
+
// Fill in the debug table's guid
debug_table_guid[ 0] = 0x77;
debug_table_guid[ 1] = 0x2E;
@@ -66,20 +66,20 @@ define /R unsigned char * find_debug_info_table_header(system_table) debug_table_guid[13] = 0xD9;
debug_table_guid[14] = 0x5E;
debug_table_guid[15] = 0x8B;
-
+
configuration_table_entries = *(unsigned long *)(system_table + 64);
configuration_table = *(unsigned long *)(system_table + 68);
-
+
for (index = 0; index < configuration_table_entries; index++)
{
if (compare_guid(configuration_table, debug_table_guid) == 0)
{
return *(unsigned long *)(configuration_table + 16);
}
-
+
configuration_table += 20;
}
-
+
return 0;
}
.
@@ -94,7 +94,7 @@ define /R int valid_pe_header(header) {
return 1;
}
-
+
return 0;
}
.
@@ -103,9 +103,9 @@ define /R unsigned long pe_headersize(header) unsigned char *header;
{
unsigned long *size;
-
+
size = header + 0x00AC;
-
+
return *size;
}
.
@@ -115,15 +115,15 @@ define /R unsigned char *pe_filename(header) {
unsigned long *debugOffset;
unsigned char *stringOffset;
-
+
if (valid_pe_header(header))
{
debugOffset = header + 0x0128;
stringOffset = header + *debugOffset + 0x002C;
-
+
return stringOffset;
}
-
+
return 0;
}
.
@@ -141,7 +141,7 @@ define /R int char_is_valid(c) define /R write_symbols_file(filename, mem_start, mem_size)
unsigned char *filename;
unsigned char *mem_start;
- unsigned long mem_size;
+ unsigned long mem_size;
{
unsigned char *system_table;
unsigned char *debug_info_table_header;
@@ -154,40 +154,40 @@ define /R write_symbols_file(filename, mem_start, mem_size) unsigned char *debug_filename;
unsigned long header_size;
int status;
-
+
system_table = find_system_table(mem_start, mem_size);
if (system_table == 0)
{
return;
}
-
+
status = fopen(88, filename, "w");
-
+
debug_info_table_header = find_debug_info_table_header(system_table);
-
+
debug_info_table = *(unsigned long *)(debug_info_table_header + 8);
debug_info_table_size = *(unsigned long *)(debug_info_table_header + 4);
-
+
for (index = 0; index < (debug_info_table_size * 4); index += 4)
{
- debug_image_info = *(unsigned long *)(debug_info_table + index);
-
+ debug_image_info = *(unsigned long *)(debug_info_table + index);
+
if (debug_image_info == 0)
{
break;
}
-
+
loaded_image_protocol = *(unsigned long *)(debug_image_info + 4);
-
+
image_base = *(unsigned long *)(loaded_image_protocol + 32);
-
+
debug_filename = pe_filename(image_base);
header_size = pe_headersize(image_base);
-
+
$fprintf 88, "%s 0x%08x\n", debug_filename, image_base + header_size$;
}
-
-
+
+
fclose(88);
}
.
diff --git a/ArmPlatformPkg/ArmRealViewEbPkg/Debugger_scripts/rvi_unload_symbols.inc b/ArmPlatformPkg/ArmRealViewEbPkg/Debugger_scripts/rvi_unload_symbols.inc index f85f442c9c..b00a1322d4 100644 --- a/ArmPlatformPkg/ArmRealViewEbPkg/Debugger_scripts/rvi_unload_symbols.inc +++ b/ArmPlatformPkg/ArmRealViewEbPkg/Debugger_scripts/rvi_unload_symbols.inc @@ -1,6 +1,6 @@ //
// Copyright (c) 2008 - 2009, Apple Inc. All rights reserved.<BR>
-//
+//
// This program and the accompanying materials
// are licensed and made available under the terms and conditions of the BSD License
// which accompanies this distribution. The full text of the license may be found at
diff --git a/ArmPlatformPkg/ArmRealViewEbPkg/FvbDxe/FvbDxe.c b/ArmPlatformPkg/ArmRealViewEbPkg/FvbDxe/FvbDxe.c index 38bd2edb51..3fbbec73e2 100644 --- a/ArmPlatformPkg/ArmRealViewEbPkg/FvbDxe/FvbDxe.c +++ b/ArmPlatformPkg/ArmRealViewEbPkg/FvbDxe/FvbDxe.c @@ -1,14 +1,14 @@ /*++
RealView EB FVB DXE Driver
-Copyright (c) 2010, Apple Inc. All rights reserved.<BR>
-This program and the accompanying materials
-are licensed and made available under the terms and conditions of the BSD License
-which accompanies this distribution. The full text of the license may be found at
-http://opensource.org/licenses/bsd-license.php
-
-THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
-WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
+Copyright (c) 2010, Apple Inc. All rights reserved.<BR>
+This program and the accompanying materials
+are licensed and made available under the terms and conditions of the BSD License
+which accompanies this distribution. The full text of the license may be found at
+http://opensource.org/licenses/bsd-license.php
+
+THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
+WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
--*/
@@ -56,7 +56,7 @@ FvbGetAttributes ( /**
The SetAttributes() function sets configurable firmware volume
attributes and returns the new settings of the firmware volume.
-
+
@param This Indicates the EFI_FIRMWARE_VOLUME_BLOCK2_PROTOCOL instance.
@@ -67,7 +67,7 @@ FvbGetAttributes ( settings of the firmware volume. Type
EFI_FVB_ATTRIBUTES_2 is defined in
EFI_FIRMWARE_VOLUME_HEADER.
-
+
@retval EFI_SUCCESS The firmware volume attributes were returned.
@retval EFI_INVALID_PARAMETER The attributes requested are in
@@ -93,14 +93,14 @@ FvbSetAttributes ( only for memory-mapped firmware volumes.
@param This Indicates the EFI_FIRMWARE_VOLUME_BLOCK2_PROTOCOL instance.
-
+
@param Address Pointer to a caller-allocated
EFI_PHYSICAL_ADDRESS that, on successful
return from GetPhysicalAddress(), contains the
base address of the firmware volume.
-
+
@retval EFI_SUCCESS The firmware volume base address was returned.
-
+
@retval EFI_NOT_SUPPORTED The firmware volume is not memory mapped.
**/
@@ -135,9 +135,9 @@ FvbGetPhysicalAddress ( blocks in this range have a size of
BlockSize.
-
+
@retval EFI_SUCCESS The firmware volume base address was returned.
-
+
@retval EFI_INVALID_PARAMETER The requested LBA is out of range.
**/
@@ -172,7 +172,7 @@ FvbGetBlockSize ( aware that a read may be partially completed.
@param This Indicates the EFI_FIRMWARE_VOLUME_BLOCK2_PROTOCOL instance.
-
+
@param Lba The starting logical block index
from which to read.
@@ -188,15 +188,15 @@ FvbGetBlockSize ( @retval EFI_SUCCESS The firmware volume was read successfully,
and contents are in Buffer.
-
+
@retval EFI_BAD_BUFFER_SIZE Read attempted across an LBA
boundary. On output, NumBytes
contains the total number of bytes
returned in Buffer.
-
+
@retval EFI_ACCESS_DENIED The firmware volume is in the
ReadDisabled state.
-
+
@retval EFI_DEVICE_ERROR The block device is not
functioning correctly and could
not be read.
@@ -228,7 +228,7 @@ FvbRead ( unpredictability arises because, for a sticky-write firmware
volume, a write may negate a bit in the EFI_FVB_ERASE_POLARITY
state but cannot flip it back again. Before calling the
- Write() function, it is recommended for the caller to first call
+ Write() function, it is recommended for the caller to first call
the EraseBlocks() function to erase the specified block to
write. A block erase cycle will transition bits from the
(NOT)EFI_FVB_ERASE_POLARITY state back to the
@@ -247,29 +247,29 @@ FvbRead ( returns.
@param This Indicates the EFI_FIRMWARE_VOLUME_BLOCK2_PROTOCOL instance.
-
+
@param Lba The starting logical block index to write to.
-
+
@param Offset Offset into the block at which to begin writing.
-
+
@param NumBytes The pointer to a UINTN. At entry, *NumBytes
contains the total size of the buffer. At
exit, *NumBytes contains the total number of
bytes actually written.
-
+
@param Buffer The pointer to a caller-allocated buffer that
contains the source for the write.
-
+
@retval EFI_SUCCESS The firmware volume was written successfully.
-
+
@retval EFI_BAD_BUFFER_SIZE The write was attempted across an
LBA boundary. On output, NumBytes
contains the total number of bytes
actually written.
-
+
@retval EFI_ACCESS_DENIED The firmware volume is in the
WriteDisabled state.
-
+
@retval EFI_DEVICE_ERROR The block device is malfunctioning
and could not be written.
@@ -325,7 +325,7 @@ FvbWrite ( @retval EFI_SUCCESS The erase request successfully
completed.
-
+
@retval EFI_ACCESS_DENIED The firmware volume is in the
WriteDisabled state.
@retval EFI_DEVICE_ERROR The block device is not functioning
@@ -334,7 +334,7 @@ FvbWrite ( partially erased.
@retval EFI_INVALID_PARAMETER One or more of the LBAs listed
in the variable argument list do
- not exist in the firmware volume.
+ not exist in the firmware volume.
**/
EFI_STATUS
@@ -373,7 +373,7 @@ EFI_FIRMWARE_VOLUME_BLOCK_PROTOCOL gFvbProtocol = { FvbEraseBlocks,
///
/// The handle of the parent firmware volume.
- ///
+ ///
NULL
};
@@ -400,18 +400,18 @@ FvbDxeInitialize ( {
EFI_STATUS Status;
-
+
Status = gBS->InstallMultipleProtocolInterfaces (
&gFvbHandle,
&gEfiFirmwareVolumeBlockProtocolGuid, &gFvbProtocol,
NULL
);
ASSERT_EFI_ERROR (Status);
-
+
// SetVertAddressEvent ()
-
+
// GCD Map NAND as RT
-
+
return Status;
}
diff --git a/ArmPlatformPkg/ArmRealViewEbPkg/FvbDxe/FvbDxe.inf b/ArmPlatformPkg/ArmRealViewEbPkg/FvbDxe/FvbDxe.inf index b8e66fc8da..9eb3b90fa1 100644 --- a/ArmPlatformPkg/ArmRealViewEbPkg/FvbDxe/FvbDxe.inf +++ b/ArmPlatformPkg/ArmRealViewEbPkg/FvbDxe/FvbDxe.inf @@ -1,14 +1,14 @@ #/** @file
-#
+#
# Copyright (c) 2008 - 2010, Apple Inc. All rights reserved.<BR>
# This program and the accompanying materials
# are licensed and made available under the terms and conditions of the BSD License
# which accompanies this distribution. The full text of the license may be found at
# http://opensource.org/licenses/bsd-license.php
-#
+#
# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
-#
+#
#**/
[Defines]
@@ -40,7 +40,7 @@ IoLib
[Guids]
-
+
[Protocols]
gEfiFirmwareVolumeBlockProtocolGuid
diff --git a/ArmPlatformPkg/ArmRealViewEbPkg/Include/Platform/ArmPlatform.h b/ArmPlatformPkg/ArmRealViewEbPkg/Include/Platform/ArmPlatform.h index 291d676d30..f594d69881 100644 --- a/ArmPlatformPkg/ArmRealViewEbPkg/Include/Platform/ArmPlatform.h +++ b/ArmPlatformPkg/ArmRealViewEbPkg/Include/Platform/ArmPlatform.h @@ -2,14 +2,14 @@ * Header defining RealView EB constants (Base addresses, sizes, flags)
*
* Copyright (c) 2011, ARM Limited. All rights reserved.
-*
-* This program and the accompanying materials
-* are licensed and made available under the terms and conditions of the BSD License
-* which accompanies this distribution. The full text of the license may be found at
-* http://opensource.org/licenses/bsd-license.php
*
-* THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
-* WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
+* This program and the accompanying materials
+* are licensed and made available under the terms and conditions of the BSD License
+* which accompanies this distribution. The full text of the license may be found at
+* http://opensource.org/licenses/bsd-license.php
+*
+* THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
+* WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
*
**/
@@ -119,4 +119,4 @@ #define SYS_CFG_RTC VIRTUAL_SYS_CFG(ARM_EB_UNSUPPORTED,1)
-#endif
+#endif
diff --git a/ArmPlatformPkg/ArmRealViewEbPkg/InterruptDxe/InterruptDxe.c b/ArmPlatformPkg/ArmRealViewEbPkg/InterruptDxe/InterruptDxe.c index b9e8256f82..0e70e44aca 100644 --- a/ArmPlatformPkg/ArmRealViewEbPkg/InterruptDxe/InterruptDxe.c +++ b/ArmPlatformPkg/ArmRealViewEbPkg/InterruptDxe/InterruptDxe.c @@ -1,14 +1,14 @@ /*++
Copyright (c) 2009, Hewlett-Packard Company. All rights reserved.<BR>
-Portions copyright (c) 2010, Apple Inc. All rights reserved.<BR>
-This program and the accompanying materials
-are licensed and made available under the terms and conditions of the BSD License
-which accompanies this distribution. The full text of the license may be found at
-http://opensource.org/licenses/bsd-license.php
-
-THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
-WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
+Portions copyright (c) 2010, Apple Inc. All rights reserved.<BR>
+This program and the accompanying materials
+are licensed and made available under the terms and conditions of the BSD License
+which accompanies this distribution. The full text of the license may be found at
+http://opensource.org/licenses/bsd-license.php
+
+THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
+WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
Module Name:
@@ -47,7 +47,7 @@ Abstract: #define EB_GIC5_DIST_BASE 0x10071000
// number of interrupts sources supported by each GIC on the EB
-#define EB_NUM_GIC_INTERRUPTS 96
+#define EB_NUM_GIC_INTERRUPTS 96
// number of 32-bit registers needed to represent those interrupts as a bit
// (used for enable set, enable clear, pending set, pending clear, and active regs)
@@ -136,8 +136,8 @@ RegisterInterruptSource ( if (Source > EB_NUM_GIC_INTERRUPTS) {
ASSERT(FALSE);
return EFI_UNSUPPORTED;
- }
-
+ }
+
if ((Handler == NULL) && (gRegisteredInterruptHandlers[Source] == NULL)) {
return EFI_INVALID_PARAMETER;
}
@@ -170,19 +170,19 @@ EnableInterruptSource ( {
UINT32 RegOffset;
UINTN RegShift;
-
+
if (Source > EB_NUM_GIC_INTERRUPTS) {
ASSERT(FALSE);
return EFI_UNSUPPORTED;
}
-
+
// calculate enable register offset and bit position
RegOffset = Source / 32;
RegShift = Source % 32;
// write set-enable register
MmioWrite32 (EB_GIC1_DIST_BASE+GIC_ICDISER+(4*RegOffset), 1 << RegShift);
-
+
return EFI_SUCCESS;
}
@@ -206,19 +206,19 @@ DisableInterruptSource ( {
UINT32 RegOffset;
UINTN RegShift;
-
+
if (Source > EB_NUM_GIC_INTERRUPTS) {
ASSERT(FALSE);
return EFI_UNSUPPORTED;
}
-
+
// calculate enable register offset and bit position
RegOffset = Source / 32;
RegShift = Source % 32;
// write set-enable register
MmioWrite32 (EB_GIC1_DIST_BASE+GIC_ICDICER+(4*RegOffset), 1 << RegShift);
-
+
return EFI_SUCCESS;
}
@@ -245,27 +245,27 @@ GetInterruptSourceState ( {
UINT32 RegOffset;
UINTN RegShift;
-
+
if (Source > EB_NUM_GIC_INTERRUPTS) {
ASSERT(FALSE);
return EFI_UNSUPPORTED;
}
-
+
// calculate enable register offset and bit position
RegOffset = Source / 32;
RegShift = Source % 32;
-
+
if ((MmioRead32 (EB_GIC1_DIST_BASE+GIC_ICDISER+(4*RegOffset)) & (1<<RegShift)) == 0) {
*InterruptState = FALSE;
} else {
*InterruptState = TRUE;
}
-
+
return EFI_SUCCESS;
}
/**
- Signal to the hardware that the End Of Intrrupt state
+ Signal to the hardware that the End Of Intrrupt state
has been reached.
@param This Instance pointer for this protocol
@@ -317,7 +317,7 @@ IrqInterruptHandler ( if (GicInterrupt >= EB_NUM_GIC_INTERRUPTS) {
MmioWrite32 (EB_GIC1_CPU_INTF_BASE+GIC_ICCEIOR, GicInterrupt);
}
-
+
InterruptHandler = gRegisteredInterruptHandlers[GicInterrupt];
if (InterruptHandler != NULL) {
// Call the registered interrupt handler.
@@ -349,7 +349,7 @@ EFI_HARDWARE_INTERRUPT_PROTOCOL gHardwareInterruptProtocol = { /**
Shutdown our hardware
-
+
DXE Core will disable interrupts and turn off the timer and disable interrupts
after all the event handlers have run.
@@ -364,7 +364,7 @@ ExitBootServicesEvent ( )
{
UINTN i;
-
+
for (i = 0; i < EB_NUM_GIC_INTERRUPTS; i++) {
DisableInterruptSource (&gHardwareInterruptProtocol, i);
}
@@ -382,7 +382,7 @@ CpuProtocolInstalledNotification ( {
EFI_STATUS Status;
EFI_CPU_ARCH_PROTOCOL *Cpu;
-
+
//
// Get the cpu protocol that this driver requires.
//
@@ -424,19 +424,19 @@ InterruptDxeInitialize ( UINT32 RegOffset;
UINTN RegShift;
-
+
// Make sure the Interrupt Controller Protocol is not already installed in the system.
ASSERT_PROTOCOL_ALREADY_INSTALLED (NULL, &gHardwareInterruptProtocolGuid);
for (i = 0; i < EB_NUM_GIC_INTERRUPTS; i++) {
DisableInterruptSource (&gHardwareInterruptProtocol, i);
-
- // Set Priority
+
+ // Set Priority
RegOffset = i / 4;
RegShift = (i % 4) * 8;
MmioAndThenOr32 (
- EB_GIC1_DIST_BASE+GIC_ICDIPR+(4*RegOffset),
- ~(0xff << RegShift),
+ EB_GIC1_DIST_BASE+GIC_ICDIPR+(4*RegOffset),
+ ~(0xff << RegShift),
GIC_DEFAULT_PRIORITY << RegShift
);
}
@@ -451,25 +451,25 @@ InterruptDxeInitialize ( // set priority mask reg to 0xff to allow all priorities through
MmioWrite32 (EB_GIC1_CPU_INTF_BASE + GIC_ICCPMR, 0xff);
-
+
// enable gic cpu interface
MmioWrite32 (EB_GIC1_CPU_INTF_BASE + GIC_ICCICR, 0x1);
// enable gic distributor
MmioWrite32 (EB_GIC1_DIST_BASE + GIC_ICCICR, 0x1);
-
+
ZeroMem (&gRegisteredInterruptHandlers, sizeof (gRegisteredInterruptHandlers));
-
+
Status = gBS->InstallMultipleProtocolInterfaces (
&gHardwareInterruptHandle,
&gHardwareInterruptProtocolGuid, &gHardwareInterruptProtocol,
NULL
);
ASSERT_EFI_ERROR (Status);
-
+
// Set up to be notified when the Cpu protocol is installed.
- Status = gBS->CreateEvent (EVT_NOTIFY_SIGNAL, TPL_CALLBACK, CpuProtocolInstalledNotification, NULL, &CpuProtocolNotificationEvent);
+ Status = gBS->CreateEvent (EVT_NOTIFY_SIGNAL, TPL_CALLBACK, CpuProtocolInstalledNotification, NULL, &CpuProtocolNotificationEvent);
ASSERT_EFI_ERROR (Status);
Status = gBS->RegisterProtocolNotify (&gEfiCpuArchProtocolGuid, CpuProtocolNotificationEvent, (VOID *)&CpuProtocolNotificationToken);
diff --git a/ArmPlatformPkg/ArmRealViewEbPkg/InterruptDxe/InterruptDxe.inf b/ArmPlatformPkg/ArmRealViewEbPkg/InterruptDxe/InterruptDxe.inf index 17bfd4fd51..97739ea05a 100644 --- a/ArmPlatformPkg/ArmRealViewEbPkg/InterruptDxe/InterruptDxe.inf +++ b/ArmPlatformPkg/ArmRealViewEbPkg/InterruptDxe/InterruptDxe.inf @@ -1,14 +1,14 @@ #/** @file
-#
+#
# Copyright (c) 2008 - 2010, Apple Inc. All rights reserved.<BR>
# This program and the accompanying materials
# are licensed and made available under the terms and conditions of the BSD License
# which accompanies this distribution. The full text of the license may be found at
# http://opensource.org/licenses/bsd-license.php
-#
+#
# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
-#
+#
#**/
[Defines]
@@ -40,12 +40,12 @@ IoLib
[Guids]
-
+
[Protocols]
gHardwareInterruptProtocolGuid
gEfiCpuArchProtocolGuid
-
+
[FixedPcd.common]
gEmbeddedTokenSpaceGuid.PcdInterruptBaseAddress
diff --git a/ArmPlatformPkg/ArmRealViewEbPkg/Library/ArmRealViewEbLibRTSM/ArmRealViewEb.c b/ArmPlatformPkg/ArmRealViewEbPkg/Library/ArmRealViewEbLibRTSM/ArmRealViewEb.c index 8351b43d80..9ffcbee392 100644 --- a/ArmPlatformPkg/ArmRealViewEbPkg/Library/ArmRealViewEbLibRTSM/ArmRealViewEb.c +++ b/ArmPlatformPkg/ArmRealViewEbPkg/Library/ArmRealViewEbLibRTSM/ArmRealViewEb.c @@ -1,14 +1,14 @@ /** @file
*
* Copyright (c) 2011-2012, ARM Limited. All rights reserved.
-*
-* This program and the accompanying materials
-* are licensed and made available under the terms and conditions of the BSD License
-* which accompanies this distribution. The full text of the license may be found at
-* http://opensource.org/licenses/bsd-license.php
*
-* THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
-* WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
+* This program and the accompanying materials
+* are licensed and made available under the terms and conditions of the BSD License
+* which accompanies this distribution. The full text of the license may be found at
+* http://opensource.org/licenses/bsd-license.php
+*
+* THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
+* WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
*
**/
diff --git a/ArmPlatformPkg/ArmRealViewEbPkg/Library/ArmRealViewEbLibRTSM/ArmRealViewEbHelper.S b/ArmPlatformPkg/ArmRealViewEbPkg/Library/ArmRealViewEbLibRTSM/ArmRealViewEbHelper.S index 3baad66431..f324105e6b 100644 --- a/ArmPlatformPkg/ArmRealViewEbPkg/Library/ArmRealViewEbLibRTSM/ArmRealViewEbHelper.S +++ b/ArmPlatformPkg/ArmRealViewEbPkg/Library/ArmRealViewEbLibRTSM/ArmRealViewEbHelper.S @@ -14,7 +14,7 @@ #include <AsmMacroIoLib.h>
#include <Library/ArmLib.h>
-.text
+.text
.align 2
GCC_ASM_EXPORT(ArmPlatformPeiBootAction)
diff --git a/ArmPlatformPkg/ArmRealViewEbPkg/Library/ArmRealViewEbLibRTSM/ArmRealViewEbHelper.asm b/ArmPlatformPkg/ArmRealViewEbPkg/Library/ArmRealViewEbLibRTSM/ArmRealViewEbHelper.asm index 55b211ea12..6539470441 100644 --- a/ArmPlatformPkg/ArmRealViewEbPkg/Library/ArmRealViewEbLibRTSM/ArmRealViewEbHelper.asm +++ b/ArmPlatformPkg/ArmRealViewEbPkg/Library/ArmRealViewEbLibRTSM/ArmRealViewEbHelper.asm @@ -22,7 +22,7 @@ IMPORT _gPcd_FixedAtBuild_PcdArmPrimaryCore
IMPORT _gPcd_FixedAtBuild_PcdArmPrimaryCoreMask
-
+
AREA ArmRealViewEbHelper, CODE, READONLY
//UINTN
diff --git a/ArmPlatformPkg/ArmRealViewEbPkg/Library/ArmRealViewEbLibRTSM/ArmRealViewEbLib.inf b/ArmPlatformPkg/ArmRealViewEbPkg/Library/ArmRealViewEbLibRTSM/ArmRealViewEbLib.inf index a97ee41c4a..fa0887679d 100644 --- a/ArmPlatformPkg/ArmRealViewEbPkg/Library/ArmRealViewEbLibRTSM/ArmRealViewEbLib.inf +++ b/ArmPlatformPkg/ArmRealViewEbPkg/Library/ArmRealViewEbLibRTSM/ArmRealViewEbLib.inf @@ -1,13 +1,13 @@ #/* @file
# Copyright (c) 2011-2013, ARM Limited. All rights reserved.
-#
-# This program and the accompanying materials
-# are licensed and made available under the terms and conditions of the BSD License
-# which accompanies this distribution. The full text of the license may be found at
-# http://opensource.org/licenses/bsd-license.php
#
-# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
-# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
+# This program and the accompanying materials
+# are licensed and made available under the terms and conditions of the BSD License
+# which accompanies this distribution. The full text of the license may be found at
+# http://opensource.org/licenses/bsd-license.php
+#
+# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
+# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
#
#*/
diff --git a/ArmPlatformPkg/ArmRealViewEbPkg/Library/ArmRealViewEbLibRTSM/ArmRealViewEbLibSec.inf b/ArmPlatformPkg/ArmRealViewEbPkg/Library/ArmRealViewEbLibRTSM/ArmRealViewEbLibSec.inf index 9be6a3755d..bc73400adf 100644 --- a/ArmPlatformPkg/ArmRealViewEbPkg/Library/ArmRealViewEbLibRTSM/ArmRealViewEbLibSec.inf +++ b/ArmPlatformPkg/ArmRealViewEbPkg/Library/ArmRealViewEbLibRTSM/ArmRealViewEbLibSec.inf @@ -1,13 +1,13 @@ #/* @file
# Copyright (c) 2011-2012, ARM Limited. All rights reserved.
-#
-# This program and the accompanying materials
-# are licensed and made available under the terms and conditions of the BSD License
-# which accompanies this distribution. The full text of the license may be found at
-# http://opensource.org/licenses/bsd-license.php
#
-# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
-# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
+# This program and the accompanying materials
+# are licensed and made available under the terms and conditions of the BSD License
+# which accompanies this distribution. The full text of the license may be found at
+# http://opensource.org/licenses/bsd-license.php
+#
+# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
+# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
#
#*/
diff --git a/ArmPlatformPkg/ArmRealViewEbPkg/Library/ArmRealViewEbLibRTSM/ArmRealViewEbMem.c b/ArmPlatformPkg/ArmRealViewEbPkg/Library/ArmRealViewEbLibRTSM/ArmRealViewEbMem.c index 1ed2c47803..40055b2e52 100644 --- a/ArmPlatformPkg/ArmRealViewEbPkg/Library/ArmRealViewEbLibRTSM/ArmRealViewEbMem.c +++ b/ArmPlatformPkg/ArmRealViewEbPkg/Library/ArmRealViewEbLibRTSM/ArmRealViewEbMem.c @@ -1,14 +1,14 @@ /** @file
*
* Copyright (c) 2011, ARM Limited. All rights reserved.
-*
-* This program and the accompanying materials
-* are licensed and made available under the terms and conditions of the BSD License
-* which accompanies this distribution. The full text of the license may be found at
-* http://opensource.org/licenses/bsd-license.php
*
-* THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
-* WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
+* This program and the accompanying materials
+* are licensed and made available under the terms and conditions of the BSD License
+* which accompanies this distribution. The full text of the license may be found at
+* http://opensource.org/licenses/bsd-license.php
+*
+* THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
+* WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
*
**/
diff --git a/ArmPlatformPkg/ArmRealViewEbPkg/Library/ArmRealViewEbSecLibRTSM/ArmRealViewEbSec.c b/ArmPlatformPkg/ArmRealViewEbPkg/Library/ArmRealViewEbSecLibRTSM/ArmRealViewEbSec.c index 1d3233ec4a..14d8c81b1b 100644 --- a/ArmPlatformPkg/ArmRealViewEbPkg/Library/ArmRealViewEbSecLibRTSM/ArmRealViewEbSec.c +++ b/ArmPlatformPkg/ArmRealViewEbPkg/Library/ArmRealViewEbSecLibRTSM/ArmRealViewEbSec.c @@ -1,14 +1,14 @@ /** @file
*
* Copyright (c) 2011-2012, ARM Limited. All rights reserved.
-*
-* This program and the accompanying materials
-* are licensed and made available under the terms and conditions of the BSD License
-* which accompanies this distribution. The full text of the license may be found at
-* http://opensource.org/licenses/bsd-license.php
*
-* THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
-* WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
+* This program and the accompanying materials
+* are licensed and made available under the terms and conditions of the BSD License
+* which accompanies this distribution. The full text of the license may be found at
+* http://opensource.org/licenses/bsd-license.php
+*
+* THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
+* WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
*
**/
diff --git a/ArmPlatformPkg/ArmRealViewEbPkg/Library/ArmRealViewEbSecLibRTSM/ArmRealViewEbSecLib.inf b/ArmPlatformPkg/ArmRealViewEbPkg/Library/ArmRealViewEbSecLibRTSM/ArmRealViewEbSecLib.inf index 68e355594c..11466ac95a 100644 --- a/ArmPlatformPkg/ArmRealViewEbPkg/Library/ArmRealViewEbSecLibRTSM/ArmRealViewEbSecLib.inf +++ b/ArmPlatformPkg/ArmRealViewEbPkg/Library/ArmRealViewEbSecLibRTSM/ArmRealViewEbSecLib.inf @@ -1,13 +1,13 @@ #/* @file
# Copyright (c) 2011-2012, ARM Limited. All rights reserved.
-#
-# This program and the accompanying materials
-# are licensed and made available under the terms and conditions of the BSD License
-# which accompanies this distribution. The full text of the license may be found at
-# http://opensource.org/licenses/bsd-license.php
#
-# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
-# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
+# This program and the accompanying materials
+# are licensed and made available under the terms and conditions of the BSD License
+# which accompanies this distribution. The full text of the license may be found at
+# http://opensource.org/licenses/bsd-license.php
+#
+# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
+# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
#
#*/
diff --git a/ArmPlatformPkg/ArmRealViewEbPkg/Library/DebugAgentTimerLib/DebugAgentTimerLib.c b/ArmPlatformPkg/ArmRealViewEbPkg/Library/DebugAgentTimerLib/DebugAgentTimerLib.c index 51b669700d..1dd3153395 100644 --- a/ArmPlatformPkg/ArmRealViewEbPkg/Library/DebugAgentTimerLib/DebugAgentTimerLib.c +++ b/ArmPlatformPkg/ArmRealViewEbPkg/Library/DebugAgentTimerLib/DebugAgentTimerLib.c @@ -1,14 +1,14 @@ /** @file
- Template for ArmEb DebugAgentLib.
+ Template for ArmEb DebugAgentLib.
- For ARM we reserve FIQ for the Debug Agent Timer. We don't care about
- laytency as we only really need the timer to run a few times a second
+ For ARM we reserve FIQ for the Debug Agent Timer. We don't care about
+ laytency as we only really need the timer to run a few times a second
(how fast can some one type a ctrl-c?), but it works much better if
the interrupt we are using to break into the debugger is not being
- used, and masked, by the system.
+ used, and masked, by the system.
Copyright (c) 2008 - 2010, Apple Inc. All rights reserved.<BR>
-
+
This program and the accompanying materials
are licensed and made available under the terms and conditions of the BSD License
which accompanies this distribution. The full text of the license may be found at
@@ -28,7 +28,7 @@ /**
Setup all the hardware needed for the debug agents timer.
- This function is used to set up debug enviroment.
+ This function is used to set up debug enviroment.
**/
VOID
@@ -39,14 +39,14 @@ DebugAgentTimerIntialize ( {
// Map Timer to FIQ
}
-
-
+
+
/**
Set the period for the debug agent timer. Zero means disable the timer.
@param[in] TimerPeriodMilliseconds Frequency of the debug agent timer.
-**/
+**/
VOID
EFIAPI
DebugAgentTimerSetPeriod (
@@ -56,17 +56,17 @@ DebugAgentTimerSetPeriod ( if (TimerPeriodMilliseconds == 0) {
// Disable timer and Disable FIQ
return;
- }
+ }
// Set timer period and unmask FIQ
}
-
+
/**
- Perform End Of Interrupt for the debug agent timer. This is called in the
- interrupt handler after the interrupt has been processed.
+ Perform End Of Interrupt for the debug agent timer. This is called in the
+ interrupt handler after the interrupt has been processed.
-**/
+**/
VOID
EFIAPI
DebugAgentTimerEndOfInterrupt (
diff --git a/ArmPlatformPkg/ArmRealViewEbPkg/Library/GdbSerialLib/GdbSerialLib.c b/ArmPlatformPkg/ArmRealViewEbPkg/Library/GdbSerialLib/GdbSerialLib.c index bce88837a9..6d2892f6d7 100644 --- a/ArmPlatformPkg/ArmRealViewEbPkg/Library/GdbSerialLib/GdbSerialLib.c +++ b/ArmPlatformPkg/ArmRealViewEbPkg/Library/GdbSerialLib/GdbSerialLib.c @@ -2,7 +2,7 @@ Basic serial IO abstaction for GDB
Copyright (c) 2008 - 2009, Apple Inc. All rights reserved.<BR>
-
+
This program and the accompanying materials
are licensed and made available under the terms and conditions of the BSD License
which accompanies this distribution. The full text of the license may be found at
@@ -31,10 +31,10 @@ GdbSerialLibConstructor ( RETURN_STATUS
EFIAPI
GdbSerialInit (
- IN UINT64 BaudRate,
- IN UINT8 Parity,
- IN UINT8 DataBits,
- IN UINT8 StopBits
+ IN UINT64 BaudRate,
+ IN UINT8 Parity,
+ IN UINT8 DataBits,
+ IN UINT8 StopBits
)
{
if ((Parity != 0) || (DataBits != 8) || (StopBits != 1)) {
@@ -45,9 +45,9 @@ GdbSerialInit ( // Could add support for different Baud rates....
return RETURN_UNSUPPORTED;
}
-
+
UINT32 Base = PcdGet32 (PcdGdbUartBase);
-
+
// initialize baud rate generator to 115200 based on EB clock REFCLK24MHZ
MmioWrite32 (Base + UARTIBRD, UART_115200_IDIV);
MmioWrite32 (Base + UARTFBRD, UART_115200_FDIV);
@@ -68,7 +68,7 @@ BOOLEAN EFIAPI
GdbIsCharAvailable (
VOID
- )
+ )
{
UINT32 FR = PcdGet32 (PcdGdbUartBase) + UARTFR;
@@ -87,7 +87,7 @@ GdbGetChar ( {
UINT32 FR = PcdGet32 (PcdGdbUartBase) + UARTFR;
UINT32 DR = PcdGet32 (PcdGdbUartBase) + UARTDR;
-
+
while ((MmioRead32 (FR) & UART_RX_EMPTY_FLAG_MASK) == 0);
return MmioRead8 (DR);
}
diff --git a/ArmPlatformPkg/ArmRealViewEbPkg/Library/GdbSerialLib/GdbSerialLib.inf b/ArmPlatformPkg/ArmRealViewEbPkg/Library/GdbSerialLib/GdbSerialLib.inf index b81ec91ed6..38448ceaa6 100644 --- a/ArmPlatformPkg/ArmRealViewEbPkg/Library/GdbSerialLib/GdbSerialLib.inf +++ b/ArmPlatformPkg/ArmRealViewEbPkg/Library/GdbSerialLib/GdbSerialLib.inf @@ -1,14 +1,14 @@ #/** @file
-#
+#
# Copyright (c) 2008 - 2010, Apple Inc. All rights reserved.<BR>
# This program and the accompanying materials
# are licensed and made available under the terms and conditions of the BSD License
# which accompanies this distribution. The full text of the license may be found at
# http://opensource.org/licenses/bsd-license.php
-#
+#
# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
-#
+#
#**/
[Defines]
@@ -33,7 +33,7 @@ [LibraryClasses]
DebugLib
- IoLib
+ IoLib
[FixedPcd]
gArmRealViewEbPkgTokenSpaceGuid.PcdGdbUartBase
diff --git a/ArmPlatformPkg/ArmRealViewEbPkg/Library/NorFlashArmRealViewEbLib/NorFlashArmRealViewEbLib.inf b/ArmPlatformPkg/ArmRealViewEbPkg/Library/NorFlashArmRealViewEbLib/NorFlashArmRealViewEbLib.inf index 48dd960cf6..5f8c5c6b4f 100644 --- a/ArmPlatformPkg/ArmRealViewEbPkg/Library/NorFlashArmRealViewEbLib/NorFlashArmRealViewEbLib.inf +++ b/ArmPlatformPkg/ArmRealViewEbPkg/Library/NorFlashArmRealViewEbLib/NorFlashArmRealViewEbLib.inf @@ -1,17 +1,17 @@ #/** @file
-#
+#
# Component description file for NorFlashArmRealViewEbLib module
-#
+#
# Copyright (c) 2011-2012, ARM Ltd. All rights reserved.<BR>
#
# This program and the accompanying materials
# are licensed and made available under the terms and conditions of the BSD License
# which accompanies this distribution. The full text of the license may be found at
# http://opensource.org/licenses/bsd-license.php
-#
+#
# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
-#
+#
#**/
[Defines]
@@ -21,7 +21,7 @@ MODULE_TYPE = DXE_DRIVER
VERSION_STRING = 1.0
LIBRARY_CLASS = NorFlashPlatformLib
-
+
[Sources.common]
NorFlashArmRealViewEb.c
diff --git a/ArmPlatformPkg/ArmRealViewEbPkg/Library/PL111LcdArmRealViewEbLib/PL111LcdArmRealViewEbLib.inf b/ArmPlatformPkg/ArmRealViewEbPkg/Library/PL111LcdArmRealViewEbLib/PL111LcdArmRealViewEbLib.inf index b44e868c04..b94936bf34 100644 --- a/ArmPlatformPkg/ArmRealViewEbPkg/Library/PL111LcdArmRealViewEbLib/PL111LcdArmRealViewEbLib.inf +++ b/ArmPlatformPkg/ArmRealViewEbPkg/Library/PL111LcdArmRealViewEbLib/PL111LcdArmRealViewEbLib.inf @@ -1,16 +1,16 @@ #/** @file
-#
+#
# Component description file for ArmRealViewGraphicsDxe module
-#
+#
# Copyright (c) 2011-2012, ARM Ltd. All rights reserved.<BR>
# This program and the accompanying materials
# are licensed and made available under the terms and conditions of the BSD License
# which accompanies this distribution. The full text of the license may be found at
# http://opensource.org/licenses/bsd-license.php
-#
+#
# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
-#
+#
#**/
[Defines]
@@ -20,7 +20,7 @@ MODULE_TYPE = DXE_DRIVER
VERSION_STRING = 1.0
LIBRARY_CLASS = PL111LcdPlatformLib
-
+
[Sources.common]
PL111LcdArmRealViewEb.c
@@ -48,14 +48,14 @@ # 1 : 800 x 600 x 24 bpp
# 2 : 1024 x 768 x 24 bpp
# 3 : 640 x 480 x 16 bpp (565 RGB Mode)
- # 4 : 800 x 600 x 16 bpp (565 RGB Mode)
+ # 4 : 800 x 600 x 16 bpp (565 RGB Mode)
# 5 : 1024 x 768 x 16 bpp (565 RGB Mode)
# 6 : 640 x 480 x 15 bpp (555 RGB Mode)
- # 7 : 800 x 600 x 15 bpp (555 RGB Mode)
+ # 7 : 800 x 600 x 15 bpp (555 RGB Mode)
# 8 : 1024 x 768 x 15 bpp (555 RGB Mode)
# 9 : 1024 x 768 x 15 bpp (555 RGB Mode) - Linux driver settings
# 10 : 640 x 480 x 12 bpp (444 RGB Mode)
- # 11 : 800 x 600 x 12 bpp (444 RGB Mode)
+ # 11 : 800 x 600 x 12 bpp (444 RGB Mode)
# 12 : 1024 x 768 x 12 bpp (444 RGB Mode)
#
diff --git a/ArmPlatformPkg/ArmRealViewEbPkg/Library/ResetSystemLib/ResetSystemLib.c b/ArmPlatformPkg/ArmRealViewEbPkg/Library/ResetSystemLib/ResetSystemLib.c index 0c119561df..1bcc481cb4 100644 --- a/ArmPlatformPkg/ArmRealViewEbPkg/Library/ResetSystemLib/ResetSystemLib.c +++ b/ArmPlatformPkg/ArmRealViewEbPkg/Library/ResetSystemLib/ResetSystemLib.c @@ -1,11 +1,11 @@ /** @file
Template library implementation to support ResetSystem Runtime call.
-
+
Fill in the templates with what ever makes you system reset.
Copyright (c) 2008 - 2009, Apple Inc. All rights reserved.<BR>
-
+
This program and the accompanying materials
are licensed and made available under the terms and conditions of the BSD License
which accompanies this distribution. The full text of the license may be found at
@@ -63,7 +63,7 @@ LibResetSystem ( ASSERT (FALSE);
return EFI_DEVICE_ERROR;
}
-
+
/**
@@ -71,7 +71,7 @@ LibResetSystem ( @param ImageHandle The firmware allocated handle for the EFI image.
@param SystemTable A pointer to the EFI System Table.
-
+
@retval EFI_SUCCESS The constructor always returns EFI_SUCCESS.
**/
diff --git a/ArmPlatformPkg/ArmRealViewEbPkg/Library/SysConfigArmRealViewEbLib/SysConfigArmRealViewEbLib.inf b/ArmPlatformPkg/ArmRealViewEbPkg/Library/SysConfigArmRealViewEbLib/SysConfigArmRealViewEbLib.inf index e1a735345e..62cec295ad 100644 --- a/ArmPlatformPkg/ArmRealViewEbPkg/Library/SysConfigArmRealViewEbLib/SysConfigArmRealViewEbLib.inf +++ b/ArmPlatformPkg/ArmRealViewEbPkg/Library/SysConfigArmRealViewEbLib/SysConfigArmRealViewEbLib.inf @@ -1,17 +1,17 @@ #/** @file
-#
+#
# Component description file for SysConfigArmRealViewEbLib module
-#
+#
# Copyright (c) 2011-2012, ARM Ltd. All rights reserved.<BR>
#
# This program and the accompanying materials
# are licensed and made available under the terms and conditions of the BSD License
# which accompanies this distribution. The full text of the license may be found at
# http://opensource.org/licenses/bsd-license.php
-#
+#
# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
-#
+#
#**/
[Defines]
@@ -21,7 +21,7 @@ MODULE_TYPE = BASE
VERSION_STRING = 1.0
LIBRARY_CLASS = ArmPlatformSysConfigLib
-
+
[Sources.common]
SysConfigArmRealViewEb.c
diff --git a/ArmPlatformPkg/ArmVExpressPkg/ArmVExpress-CTA15-A7.dsc b/ArmPlatformPkg/ArmVExpressPkg/ArmVExpress-CTA15-A7.dsc index 56ae26aea4..a9c360e5ff 100644 --- a/ArmPlatformPkg/ArmVExpressPkg/ArmVExpress-CTA15-A7.dsc +++ b/ArmPlatformPkg/ArmVExpressPkg/ArmVExpress-CTA15-A7.dsc @@ -1,13 +1,13 @@ #
# Copyright (c) 2012-2014, ARM Limited. All rights reserved.
-#
-# This program and the accompanying materials
-# are licensed and made available under the terms and conditions of the BSD License
-# which accompanies this distribution. The full text of the license may be found at
-# http://opensource.org/licenses/bsd-license.php
#
-# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
-# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
+# This program and the accompanying materials
+# are licensed and made available under the terms and conditions of the BSD License
+# which accompanies this distribution. The full text of the license may be found at
+# http://opensource.org/licenses/bsd-license.php
+#
+# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
+# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
#
#
@@ -33,7 +33,7 @@ [LibraryClasses.common]
ArmLib|ArmPkg/Library/ArmLib/ArmV7/ArmV7Lib.inf
ArmPlatformLib|ArmPlatformPkg/ArmVExpressPkg/Library/ArmVExpressLibCTA15-A7/ArmVExpressLib.inf
-
+
ArmPlatformSysConfigLib|ArmPlatformPkg/ArmVExpressPkg/Library/ArmVExpressSysConfigLib/ArmVExpressSysConfigLib.inf
NorFlashPlatformLib|ArmPlatformPkg/ArmVExpressPkg/Library/NorFlashArmVExpressLib/NorFlashArmVExpressLib.inf
@@ -43,8 +43,8 @@ ArmGicLib|ArmPkg/Drivers/ArmGic/ArmGicLib.inf
LcdPlatformLib|ArmPlatformPkg/ArmVExpressPkg/Library/HdLcdArmVExpressLib/HdLcdArmVExpressLib.inf
-
- TimerLib|ArmPkg/Library/ArmArchTimerLib/ArmArchTimerLib.inf
+
+ TimerLib|ArmPkg/Library/ArmArchTimerLib/ArmArchTimerLib.inf
ArmSmcLib|ArmPkg/Library/ArmSmcLib/ArmSmcLib.inf
[BuildOptions]
@@ -59,7 +59,7 @@ RVCT:*_*_ARM_PLATFORM_FLAGS == --cpu Cortex-A15 -I$(WORKSPACE)/ArmPlatformPkg/ArmVExpressPkg/Include -I$(WORKSPACE)/ArmPlatformPkg/ArmVExpressPkg/Include/Platform/CTA15-A7
GCC:*_*_ARM_PLATFORM_FLAGS == -mcpu=cortex-a15 -I$(WORKSPACE)/ArmPlatformPkg/ArmVExpressPkg/Include -I$(WORKSPACE)/ArmPlatformPkg/ArmVExpressPkg/Include/Platform/CTA15-A7
-
+
XCODE:*_*_ARM_PLATFORM_FLAGS = -I$(WORKSPACE)/ArmPlatformPkg/ArmVExpressPkg/Include -I$(WORKSPACE)/ArmPlatformPkg/ArmVExpressPkg/Include/Platform/CTA15-A7
################################################################################
@@ -71,11 +71,11 @@ [PcdsFeatureFlag.common]
gArmPlatformTokenSpaceGuid.PcdSystemMemoryInitializeInSec|TRUE
gArmPlatformTokenSpaceGuid.PcdSendSgiToBringUpSecondaryCores|TRUE
-
+
## If TRUE, Graphics Output Protocol will be installed on virtual handle created by ConsplitterDxe.
# It could be set FALSE to save size.
gEfiMdeModulePkgTokenSpaceGuid.PcdConOutGopSupport|TRUE
-
+
[PcdsFixedAtBuild.common]
gArmPlatformTokenSpaceGuid.PcdFirmwareVendor|"ARM Versatile Express"
gEmbeddedTokenSpaceGuid.PcdEmbeddedPrompt|"ArmVExpress-CTA15-A7"
@@ -93,7 +93,7 @@ gEfiMdeModulePkgTokenSpaceGuid.PcdFlashNvStorageFtwSpareSize|0x00010000
gArmTokenSpaceGuid.PcdVFPEnabled|1
-
+
# Stacks for MPCores in Secure World
# SRAM (CS1) is only available between 0x14000000 and 0x14001000 on the model
# ZBT SRAM is available between 0x2E000000 and 0x2E010000 on the model
@@ -106,7 +106,7 @@ gArmPlatformTokenSpaceGuid.PcdCPUCoreSecSecondaryStackSize|0x1000
# Share Monitor stacks with Secure World
gArmPlatformTokenSpaceGuid.PcdCPUCoreSecMonStackSize|0
-
+
# System Memory (1GB) - An additional 1GB will be added if UEFI is running on a 2GB Test Chip
gArmTokenSpaceGuid.PcdSystemMemoryBase|0x80000000
gArmTokenSpaceGuid.PcdSystemMemorySize|0x40000000
@@ -123,24 +123,24 @@ # A7_2 = 0x102, GicCoreId = 4
gArmTokenSpaceGuid.PcdArmPrimaryCore|0x100
!endif
-
+
#
# SEC Phase Global Variables :
- # - 0x00-0x04: Debugger Exception Handler Pointer address
+ # - 0x00-0x04: Debugger Exception Handler Pointer address
# - 0x04-0x08: Normal Exception Handler Pointer
# - 0x0C-0x10: MpSafe Serial Console SpinLock
# - 0x10-0x20: KfScb 8 Bakery Locks of 2Bytes each
# - 0x20-0x30: CCI 8 Bakery Locks of 2Bytes each
# - 0x30-0x48: ARM SMC Events (8 cores * 3 max_event * sizeof(UINT8))
gArmPlatformTokenSpaceGuid.PcdSecGlobalVariableSize|0x48
-
+
#
# ARM PrimeCell
#
## SP805 Watchdog - Motherboard Watchdog
gArmPlatformTokenSpaceGuid.PcdSP805WatchdogBase|0x1C0F0000
-
+
## PL011 - Serial Terminal
gEfiMdeModulePkgTokenSpaceGuid.PcdSerialRegisterBase|0x1C090000
gEfiMdePkgTokenSpaceGuid.PcdUartDefaultBaudRate|38400
@@ -160,8 +160,8 @@ #
gArmPlatformTokenSpaceGuid.PcdPL180SysMciRegAddress|0x1C010048
gArmPlatformTokenSpaceGuid.PcdPL180MciBaseAddress|0x1C050000
-
-
+
+
#
# ARM General Interrupt Controller
#
@@ -177,7 +177,7 @@ #
# ARM OS Loader
#
- # Versatile Express machine type (ARM VERSATILE EXPRESS = 2272) required for ARM Linux:
+ # Versatile Express machine type (ARM VERSATILE EXPRESS = 2272) required for ARM Linux:
gArmTokenSpaceGuid.PcdArmMachineType|2272
gArmPlatformTokenSpaceGuid.PcdDefaultBootDescription|L"Linux from NorFlash"
gArmPlatformTokenSpaceGuid.PcdDefaultBootDevicePath|L"VenHw(1F15DA3C-37FF-4070-B471-BB4AF12A724A)/MemoryMapped(0x0,0xE000000,0xE800000)"
@@ -200,7 +200,7 @@ !else
gArmTokenSpaceGuid.PcdArmArchTimerFreqInHz|10000000
!endif
-
+
################################################################################
#
# Components Section - list of all EDK II Modules needed by this Platform
@@ -229,13 +229,13 @@ #
# Architectural Protocols
#
- ArmPkg/Drivers/CpuDxe/CpuDxe.inf
+ ArmPkg/Drivers/CpuDxe/CpuDxe.inf
MdeModulePkg/Core/RuntimeDxe/RuntimeDxe.inf
MdeModulePkg/Universal/SecurityStubDxe/SecurityStubDxe.inf
MdeModulePkg/Universal/CapsuleRuntimeDxe/CapsuleRuntimeDxe.inf
MdeModulePkg/Universal/Variable/RuntimeDxe/VariableRuntimeDxe.inf
MdeModulePkg/Universal/FaultTolerantWriteDxe/FaultTolerantWriteDxe.inf
- MdeModulePkg/Universal/MonotonicCounterRuntimeDxe/MonotonicCounterRuntimeDxe.inf
+ MdeModulePkg/Universal/MonotonicCounterRuntimeDxe/MonotonicCounterRuntimeDxe.inf
EmbeddedPkg/ResetRuntimeDxe/ResetRuntimeDxe.inf
EmbeddedPkg/RealTimeClockRuntimeDxe/RealTimeClockRuntimeDxe.inf
EmbeddedPkg/MetronomeDxe/MetronomeDxe.inf
@@ -266,7 +266,7 @@ !ifndef ARM_BIGLITTLE_TC2
ArmPkg/Filesystem/SemihostFs/SemihostFs.inf
!endif
-
+
#
# Multimedia Card Interface
#
diff --git a/ArmPlatformPkg/ArmVExpressPkg/ArmVExpress-CTA15-A7.fdf b/ArmPlatformPkg/ArmVExpressPkg/ArmVExpress-CTA15-A7.fdf index 9ba0a951ec..03815979cd 100644 --- a/ArmPlatformPkg/ArmVExpressPkg/ArmVExpress-CTA15-A7.fdf +++ b/ArmPlatformPkg/ArmVExpressPkg/ArmVExpress-CTA15-A7.fdf @@ -1,13 +1,13 @@ #
# Copyright (c) 2012-2014, ARM Limited. All rights reserved.
-#
-# This program and the accompanying materials
-# are licensed and made available under the terms and conditions of the BSD License
-# which accompanies this distribution. The full text of the license may be found at
-# http://opensource.org/licenses/bsd-license.php
#
-# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
-# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
+# This program and the accompanying materials
+# are licensed and made available under the terms and conditions of the BSD License
+# which accompanies this distribution. The full text of the license may be found at
+# http://opensource.org/licenses/bsd-license.php
+#
+# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
+# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
#
################################################################################
@@ -65,10 +65,10 @@ READ_STATUS = TRUE READ_LOCK_CAP = TRUE
READ_LOCK_STATUS = TRUE
- INF MdeModulePkg/Core/Dxe/DxeMain.inf
+ INF MdeModulePkg/Core/Dxe/DxeMain.inf
#
- # PI DXE Drivers producing Architectural Protocols (EFI Services)
+ # PI DXE Drivers producing Architectural Protocols (EFI Services)
#
INF ArmPkg/Drivers/CpuDxe/CpuDxe.inf
INF MdeModulePkg/Core/RuntimeDxe/RuntimeDxe.inf
@@ -82,7 +82,7 @@ READ_LOCK_STATUS = TRUE INF EmbeddedPkg/MetronomeDxe/MetronomeDxe.inf
INF MdeModulePkg/Universal/HiiDatabaseDxe/HiiDatabaseDxe.inf
-
+
#
# Multiple Console IO support
#
@@ -109,14 +109,14 @@ READ_LOCK_STATUS = TRUE #
INF EmbeddedPkg/Universal/MmcDxe/MmcDxe.inf
INF ArmPlatformPkg/Drivers/PL180MciDxe/PL180MciDxe.inf
-
+
#
# Filesystems
#
!ifndef $(ARM_BIGLITTLE_TC2)
INF ArmPkg/Filesystem/SemihostFs/SemihostFs.inf
!endif
-
+
#
# FAT filesystem + GPT/MBR partitioning
#
@@ -142,7 +142,7 @@ READ_LOCK_STATUS = TRUE # ACPI Support
INF MdeModulePkg/Universal/Acpi/AcpiTableDxe/AcpiTableDxe.inf
-
+
#
# Networking stack
#
@@ -159,10 +159,10 @@ READ_LOCK_STATUS = TRUE INF MdeModulePkg/Universal/Network/UefiPxeBcDxe/UefiPxeBcDxe.inf
INF MdeModulePkg/Universal/Network/IScsiDxe/IScsiDxe.inf
INF EmbeddedPkg/Drivers/Lan9118Dxe/Lan9118Dxe.inf
-
+
#
# UEFI application
- #
+ #
INF ShellBinPkg/UefiShell/UefiShell.inf
#
@@ -192,7 +192,7 @@ READ_LOCK_CAP = TRUE READ_LOCK_STATUS = TRUE
INF ArmPlatformPkg/PrePi/PeiMPCore.inf
-
+
FILE FV_IMAGE = 9E21FD93-9C72-4c15-8C4B-E77F1DB2D792 {
SECTION GUIDED EE4E5898-3914-4259-9D6E-DC7BD79403CF PROCESSING_REQUIRED = TRUE {
SECTION FV_IMAGE = FVMAIN
@@ -211,7 +211,7 @@ READ_LOCK_STATUS = TRUE ############################################################################
-# Example of a DXE_DRIVER FFS file with a Checksum encapsulation section #
+# Example of a DXE_DRIVER FFS file with a Checksum encapsulation section #
############################################################################
#
#[Rule.Common.DXE_DRIVER]
@@ -236,14 +236,14 @@ READ_LOCK_STATUS = TRUE [Rule.Common.PEI_CORE]
FILE PEI_CORE = $(NAMED_GUID) {
TE TE $(INF_OUTPUT)/$(MODULE_NAME).efi
- UI STRING ="$(MODULE_NAME)" Optional
+ UI STRING ="$(MODULE_NAME)" Optional
}
[Rule.Common.PEIM]
FILE PEIM = $(NAMED_GUID) {
PEI_DEPEX PEI_DEPEX Optional $(INF_OUTPUT)/$(MODULE_NAME).depex
TE TE $(INF_OUTPUT)/$(MODULE_NAME).efi
- UI STRING="$(MODULE_NAME)" Optional
+ UI STRING="$(MODULE_NAME)" Optional
}
[Rule.Common.PEIM.TIANOCOMPRESSED]
@@ -284,7 +284,7 @@ READ_LOCK_STATUS = TRUE [Rule.Common.UEFI_APPLICATION]
FILE APPLICATION = $(NAMED_GUID) {
- UI STRING ="$(MODULE_NAME)" Optional
+ UI STRING ="$(MODULE_NAME)" Optional
PE32 PE32 $(INF_OUTPUT)/$(MODULE_NAME).efi
}
diff --git a/ArmPlatformPkg/ArmVExpressPkg/ArmVExpress-CTA9x4.dsc b/ArmPlatformPkg/ArmVExpressPkg/ArmVExpress-CTA9x4.dsc index 69f51406fd..83774798a0 100644 --- a/ArmPlatformPkg/ArmVExpressPkg/ArmVExpress-CTA9x4.dsc +++ b/ArmPlatformPkg/ArmVExpressPkg/ArmVExpress-CTA9x4.dsc @@ -1,13 +1,13 @@ #
# Copyright (c) 2011-2014, ARM Limited. All rights reserved.
-#
-# This program and the accompanying materials
-# are licensed and made available under the terms and conditions of the BSD License
-# which accompanies this distribution. The full text of the license may be found at
-# http://opensource.org/licenses/bsd-license.php
#
-# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
-# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
+# This program and the accompanying materials
+# are licensed and made available under the terms and conditions of the BSD License
+# which accompanies this distribution. The full text of the license may be found at
+# http://opensource.org/licenses/bsd-license.php
+#
+# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
+# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
#
#
@@ -18,7 +18,7 @@ ################################################################################
[Defines]
PLATFORM_NAME = ArmVExpressPkg-CTA9x4
- PLATFORM_GUID = eb2bd5ff-2379-4a06-9c12-db905cdee9ea
+ PLATFORM_GUID = eb2bd5ff-2379-4a06-9c12-db905cdee9ea
PLATFORM_VERSION = 0.1
DSC_SPECIFICATION = 0x00010005
SUPPORTED_ARCHITECTURES = ARM
@@ -54,7 +54,7 @@ PL341DmcLib|ArmPlatformPkg/Drivers/PL34xDmc/PL341Dmc.inf
# ARM PL301 Axi Driver
PL301AxiLib|ArmPlatformPkg/Drivers/PL301Axi/PL301Axi.inf
-
+
ArmPlatformSysConfigLib|ArmPlatformPkg/ArmVExpressPkg/Library/ArmVExpressSysConfigLib/ArmVExpressSysConfigLib.inf
NorFlashPlatformLib|ArmPlatformPkg/ArmVExpressPkg/Library/NorFlashArmVExpressLib/NorFlashArmVExpressLib.inf
LcdPlatformLib|ArmPlatformPkg/ArmVExpressPkg/Library/PL111LcdArmVExpressLib/PL111LcdArmVExpressLib.inf
@@ -64,14 +64,14 @@ ArmPlatformSecLib|ArmPlatformPkg/ArmVExpressPkg/Library/ArmVExpressSecLibCTA9x4/ArmVExpressSecLib.inf
ArmPlatformLib|ArmPlatformPkg/ArmVExpressPkg/Library/ArmVExpressLibCTA9x4/ArmVExpressLibSec.inf
- # Uncomment to turn on GDB stub in SEC.
+ # Uncomment to turn on GDB stub in SEC.
#DebugAgentLib|EmbeddedPkg/Library/GdbDebugAgent/GdbDebugAgent.inf
[BuildOptions]
RVCT:*_*_ARM_PLATFORM_FLAGS == --cpu Cortex-A9 -I$(WORKSPACE)/ArmPlatformPkg/ArmVExpressPkg/Include -I$(WORKSPACE)/ArmPlatformPkg/ArmVExpressPkg/Include/Platform/CTA9x4
GCC:*_*_ARM_PLATFORM_FLAGS == -mcpu=cortex-a9 -I$(WORKSPACE)/ArmPlatformPkg/ArmVExpressPkg/Include -I$(WORKSPACE)/ArmPlatformPkg/ArmVExpressPkg/Include/Platform/CTA9x4
-
+
XCODE:*_*_ARM_PLATFORM_FLAGS == -mcpu=cortex-a9 -I$(WORKSPACE)/ArmPlatformPkg/ArmVExpressPkg/Include -I$(WORKSPACE)/ArmPlatformPkg/ArmVExpressPkg/Include/Platform/CTA9x4
################################################################################
@@ -93,13 +93,13 @@ gArmPlatformTokenSpaceGuid.PcdSystemMemoryInitializeInSec|TRUE
gArmPlatformTokenSpaceGuid.PcdSendSgiToBringUpSecondaryCores|TRUE
!endif
-
+
## If TRUE, Graphics Output Protocol will be installed on virtual handle created by ConsplitterDxe.
# It could be set FALSE to save size.
gEfiMdeModulePkgTokenSpaceGuid.PcdConOutGopSupport|TRUE
[PcdsFixedAtBuild.common]
- gArmPlatformTokenSpaceGuid.PcdFirmwareVendor|"ARM Versatile Express"
+ gArmPlatformTokenSpaceGuid.PcdFirmwareVendor|"ARM Versatile Express"
gEmbeddedTokenSpaceGuid.PcdEmbeddedPrompt|"ArmVExpress"
gArmPlatformTokenSpaceGuid.PcdCoreCount|4
@@ -115,7 +115,7 @@ gEfiMdeModulePkgTokenSpaceGuid.PcdFlashNvStorageFtwSpareSize|0x00010000
gArmTokenSpaceGuid.PcdVFPEnabled|1
-
+
# Stacks for MPCores in Secure World
gArmPlatformTokenSpaceGuid.PcdCPUCoresSecStackBase|0x49E00000
# Stacks for MPCores in Monitor Mode
@@ -123,15 +123,15 @@ # Stacks for MPCores in Normal World
gArmPlatformTokenSpaceGuid.PcdCPUCoresStackBase|0x48000000
- # System Memory (1GB)
+ # System Memory (1GB)
gArmTokenSpaceGuid.PcdSystemMemoryBase|0x60000000
gArmTokenSpaceGuid.PcdSystemMemorySize|0x40000000
-
+
#
# ARM Pcds
#
gArmTokenSpaceGuid.PcdArmUncachedMemoryMask|0x0000000040000000
-
+
#
# ARM PrimeCell
#
@@ -148,7 +148,7 @@ gArmPlatformTokenSpaceGuid.PcdSP805WatchdogBase|0x1000F000
## SP805 Watchdog - CoreTile Watchdog
#gArmPlatformTokenSpaceGuid.PcdSP805WatchdogBase|0x100E5000
-
+
## PL011 - Serial Terminal
gEfiMdeModulePkgTokenSpaceGuid.PcdSerialRegisterBase|0x10009000
gEfiMdePkgTokenSpaceGuid.PcdUartDefaultBaudRate|38400
@@ -165,7 +165,7 @@ ## PL180 MMC/SD card controller
gArmPlatformTokenSpaceGuid.PcdPL180SysMciRegAddress|0x10000048
gArmPlatformTokenSpaceGuid.PcdPL180MciBaseAddress|0x10005000
-
+
#
# ARM General Interrupt Controller
#
@@ -175,7 +175,7 @@ #
# ARM OS Loader
#
- # Versatile Express machine type (ARM VERSATILE EXPRESS = 2272) required for ARM Linux:
+ # Versatile Express machine type (ARM VERSATILE EXPRESS = 2272) required for ARM Linux:
gArmTokenSpaceGuid.PcdArmMachineType|2272
gArmPlatformTokenSpaceGuid.PcdDefaultBootDescription|L"NorFlash"
gArmPlatformTokenSpaceGuid.PcdDefaultBootDevicePath|L"VenHw(1F15DA3C-37FF-4070-B471-BB4AF12A724A)/MemoryMapped(0x0,0x46000000,0x46400000)"
@@ -202,7 +202,7 @@ #
################################################################################
[Components.common]
-
+
#
# SEC
#
@@ -211,7 +211,7 @@ # Use the implementation which set the Secure bits
ArmGicLib|ArmPkg/Drivers/ArmGic/ArmGicSecLib.inf
}
-
+
#
# PEI Phase modules
#
@@ -256,13 +256,13 @@ #
# Architectural Protocols
#
- ArmPkg/Drivers/CpuDxe/CpuDxe.inf
+ ArmPkg/Drivers/CpuDxe/CpuDxe.inf
MdeModulePkg/Core/RuntimeDxe/RuntimeDxe.inf
MdeModulePkg/Universal/SecurityStubDxe/SecurityStubDxe.inf
MdeModulePkg/Universal/CapsuleRuntimeDxe/CapsuleRuntimeDxe.inf
MdeModulePkg/Universal/Variable/RuntimeDxe/VariableRuntimeDxe.inf
MdeModulePkg/Universal/FaultTolerantWriteDxe/FaultTolerantWriteDxe.inf
- MdeModulePkg/Universal/MonotonicCounterRuntimeDxe/MonotonicCounterRuntimeDxe.inf
+ MdeModulePkg/Universal/MonotonicCounterRuntimeDxe/MonotonicCounterRuntimeDxe.inf
EmbeddedPkg/ResetRuntimeDxe/ResetRuntimeDxe.inf
EmbeddedPkg/RealTimeClockRuntimeDxe/RealTimeClockRuntimeDxe.inf
EmbeddedPkg/MetronomeDxe/MetronomeDxe.inf
@@ -272,7 +272,7 @@ MdeModulePkg/Universal/Console/GraphicsConsoleDxe/GraphicsConsoleDxe.inf
MdeModulePkg/Universal/Console/TerminalDxe/TerminalDxe.inf
EmbeddedPkg/SerialDxe/SerialDxe.inf
-
+
MdeModulePkg/Universal/HiiDatabaseDxe/HiiDatabaseDxe.inf
ArmPkg/Drivers/ArmGic/ArmGicDxe.inf
@@ -290,7 +290,7 @@ # Filesystems
#
ArmPkg/Filesystem/SemihostFs/SemihostFs.inf
-
+
#
# Multimedia Card Interface
#
diff --git a/ArmPlatformPkg/ArmVExpressPkg/ArmVExpress-CTA9x4.fdf b/ArmPlatformPkg/ArmVExpressPkg/ArmVExpress-CTA9x4.fdf index 545f3bdb0c..1bd1c967a7 100644 --- a/ArmPlatformPkg/ArmVExpressPkg/ArmVExpress-CTA9x4.fdf +++ b/ArmPlatformPkg/ArmVExpressPkg/ArmVExpress-CTA9x4.fdf @@ -1,13 +1,13 @@ #
# Copyright (c) 2011-2014, ARM Limited. All rights reserved.
-#
-# This program and the accompanying materials
-# are licensed and made available under the terms and conditions of the BSD License
-# which accompanies this distribution. The full text of the license may be found at
-# http://opensource.org/licenses/bsd-license.php
#
-# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
-# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
+# This program and the accompanying materials
+# are licensed and made available under the terms and conditions of the BSD License
+# which accompanies this distribution. The full text of the license may be found at
+# http://opensource.org/licenses/bsd-license.php
+#
+# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
+# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
#
################################################################################
@@ -138,10 +138,10 @@ READ_STATUS = TRUE READ_LOCK_CAP = TRUE
READ_LOCK_STATUS = TRUE
- INF MdeModulePkg/Core/Dxe/DxeMain.inf
+ INF MdeModulePkg/Core/Dxe/DxeMain.inf
#
- # PI DXE Drivers producing Architectural Protocols (EFI Services)
+ # PI DXE Drivers producing Architectural Protocols (EFI Services)
#
INF ArmPkg/Drivers/CpuDxe/CpuDxe.inf
INF MdeModulePkg/Core/RuntimeDxe/RuntimeDxe.inf
@@ -182,7 +182,7 @@ READ_LOCK_STATUS = TRUE #
INF ArmPkg/Filesystem/SemihostFs/SemihostFs.inf
!endif
-
+
#
# FAT filesystem + GPT/MBR partitioning
#
@@ -272,7 +272,7 @@ READ_LOCK_STATUS = TRUE INF MdeModulePkg/Universal/Variable/Pei/VariablePei.inf
INF MdeModulePkg/Core/DxeIplPeim/DxeIpl.inf
!endif
-
+
FILE FV_IMAGE = 9E21FD93-9C72-4c15-8C4B-E77F1DB2D792 {
SECTION GUIDED EE4E5898-3914-4259-9D6E-DC7BD79403CF PROCESSING_REQUIRED = TRUE {
SECTION FV_IMAGE = FVMAIN
@@ -291,7 +291,7 @@ READ_LOCK_STATUS = TRUE ############################################################################
-# Example of a DXE_DRIVER FFS file with a Checksum encapsulation section #
+# Example of a DXE_DRIVER FFS file with a Checksum encapsulation section #
############################################################################
#
#[Rule.Common.DXE_DRIVER]
@@ -316,14 +316,14 @@ READ_LOCK_STATUS = TRUE [Rule.Common.PEI_CORE]
FILE PEI_CORE = $(NAMED_GUID) {
TE TE $(INF_OUTPUT)/$(MODULE_NAME).efi
- UI STRING ="$(MODULE_NAME)" Optional
+ UI STRING ="$(MODULE_NAME)" Optional
}
[Rule.Common.PEIM]
FILE PEIM = $(NAMED_GUID) {
PEI_DEPEX PEI_DEPEX Optional $(INF_OUTPUT)/$(MODULE_NAME).depex
TE TE $(INF_OUTPUT)/$(MODULE_NAME).efi
- UI STRING="$(MODULE_NAME)" Optional
+ UI STRING="$(MODULE_NAME)" Optional
}
[Rule.Common.PEIM.TIANOCOMPRESSED]
@@ -364,7 +364,7 @@ READ_LOCK_STATUS = TRUE [Rule.Common.UEFI_APPLICATION]
FILE APPLICATION = $(NAMED_GUID) {
- UI STRING ="$(MODULE_NAME)" Optional
+ UI STRING ="$(MODULE_NAME)" Optional
PE32 PE32 $(INF_OUTPUT)/$(MODULE_NAME).efi
}
diff --git a/ArmPlatformPkg/ArmVExpressPkg/ArmVExpress-RTSM-A15.dsc b/ArmPlatformPkg/ArmVExpressPkg/ArmVExpress-RTSM-A15.dsc index 02b3bcf4b4..78f40779bd 100644 --- a/ArmPlatformPkg/ArmVExpressPkg/ArmVExpress-RTSM-A15.dsc +++ b/ArmPlatformPkg/ArmVExpressPkg/ArmVExpress-RTSM-A15.dsc @@ -1,13 +1,13 @@ #
# Copyright (c) 2011-2014, ARM Limited. All rights reserved.
-#
-# This program and the accompanying materials
-# are licensed and made available under the terms and conditions of the BSD License
-# which accompanies this distribution. The full text of the license may be found at
-# http://opensource.org/licenses/bsd-license.php
#
-# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
-# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
+# This program and the accompanying materials
+# are licensed and made available under the terms and conditions of the BSD License
+# which accompanies this distribution. The full text of the license may be found at
+# http://opensource.org/licenses/bsd-license.php
+#
+# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
+# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
#
#
@@ -33,14 +33,14 @@ ArmLib|ArmPkg/Library/ArmLib/ArmV7/ArmV7Lib.inf
ArmCpuLib|ArmPkg/Drivers/ArmCpuLib/ArmCortexA15Lib/ArmCortexA15Lib.inf
ArmPlatformLib|ArmPlatformPkg/ArmVExpressPkg/Library/ArmVExpressLibRTSM/ArmVExpressLib.inf
-
+
ArmPlatformSysConfigLib|ArmPlatformPkg/ArmVExpressPkg/Library/ArmVExpressSysConfigLib/ArmVExpressSysConfigLib.inf
NorFlashPlatformLib|ArmPlatformPkg/ArmVExpressPkg/Library/NorFlashArmVExpressLib/NorFlashArmVExpressLib.inf
LcdPlatformLib|ArmPlatformPkg/ArmVExpressPkg/Library/PL111LcdArmVExpressLib/PL111LcdArmVExpressLib.inf
#DebugAgentTimerLib|ArmPlatformPkg/ArmVExpressPkg/Library/DebugAgentTimerLib/DebugAgentTimerLib.inf
- TimerLib|ArmPkg/Library/ArmArchTimerLib/ArmArchTimerLib.inf
+ TimerLib|ArmPkg/Library/ArmArchTimerLib/ArmArchTimerLib.inf
# Virtio Support
VirtioLib|OvmfPkg/Library/VirtioLib/VirtioLib.inf
@@ -55,7 +55,7 @@ RVCT:*_*_ARM_PLATFORM_FLAGS == --cpu Cortex-A15 -I$(WORKSPACE)/ArmPlatformPkg/ArmVExpressPkg/Include -I$(WORKSPACE)/ArmPlatformPkg/ArmVExpressPkg/Include/Platform/RTSM
GCC:*_*_ARM_PLATFORM_FLAGS == -mcpu=cortex-a15 -I$(WORKSPACE)/ArmPlatformPkg/ArmVExpressPkg/Include -I$(WORKSPACE)/ArmPlatformPkg/ArmVExpressPkg/Include/Platform/RTSM
-
+
XCODE:*_*_ARM_PLATFORM_FLAGS = -I$(WORKSPACE)/ArmPlatformPkg/ArmVExpressPkg/Include -I$(WORKSPACE)/ArmPlatformPkg/ArmVExpressPkg/Include/Platform/RTSM
################################################################################
@@ -69,11 +69,11 @@ gArmPlatformTokenSpaceGuid.PcdSystemMemoryInitializeInSec|TRUE
gArmPlatformTokenSpaceGuid.PcdSendSgiToBringUpSecondaryCores|TRUE
!endif
-
+
## If TRUE, Graphics Output Protocol will be installed on virtual handle created by ConsplitterDxe.
# It could be set FALSE to save size.
gEfiMdeModulePkgTokenSpaceGuid.PcdConOutGopSupport|TRUE
-
+
[PcdsFixedAtBuild.common]
gArmPlatformTokenSpaceGuid.PcdFirmwareVendor|"ARM Versatile Express"
gEmbeddedTokenSpaceGuid.PcdEmbeddedPrompt|"ArmVExpress-RTSM"
@@ -99,38 +99,38 @@ !endif
gArmTokenSpaceGuid.PcdVFPEnabled|1
-
+
# Stacks for MPCores in Secure World
gArmPlatformTokenSpaceGuid.PcdCPUCoresSecStackBase|0x2E009000
gArmPlatformTokenSpaceGuid.PcdCPUCoreSecPrimaryStackSize|0x1000
-
+
# Stacks for MPCores in Monitor Mode
gArmPlatformTokenSpaceGuid.PcdCPUCoresSecMonStackBase|0x2E008000
gArmPlatformTokenSpaceGuid.PcdCPUCoreSecMonStackSize|0x100
-
+
# Stacks for MPCores in Normal World
gArmPlatformTokenSpaceGuid.PcdCPUCoresStackBase|0x2E000000
gArmPlatformTokenSpaceGuid.PcdCPUCorePrimaryStackSize|0x4000
-
- # System Memory (1GB)
+
+ # System Memory (1GB)
gArmTokenSpaceGuid.PcdSystemMemoryBase|0x80000000
gArmTokenSpaceGuid.PcdSystemMemorySize|0x40000000
-
+
# Size of the region used by UEFI in permanent memory (Reserved 64MB)
gArmPlatformTokenSpaceGuid.PcdSystemMemoryUefiRegionSize|0x04000000
-
+
#
# ARM Pcds
#
gArmTokenSpaceGuid.PcdArmUncachedMemoryMask|0x0000000040000000
-
+
#
# ARM PrimeCell
#
## SP805 Watchdog - Motherboard Watchdog
gArmPlatformTokenSpaceGuid.PcdSP805WatchdogBase|0x1C0F0000
-
+
## PL011 - Serial Terminal
gEfiMdeModulePkgTokenSpaceGuid.PcdSerialRegisterBase|0x1c090000
gEfiMdePkgTokenSpaceGuid.PcdUartDefaultBaudRate|38400
@@ -140,11 +140,11 @@ ## PL111 Versatile Express Motherboard controller
gArmPlatformTokenSpaceGuid.PcdPL111LcdBase|0x1C1F0000
-
+
## PL180 MMC/SD card controller
gArmPlatformTokenSpaceGuid.PcdPL180SysMciRegAddress|0x1C010048
gArmPlatformTokenSpaceGuid.PcdPL180MciBaseAddress|0x1C050000
-
+
#
# ARM General Interrupt Controller
#
@@ -154,7 +154,7 @@ #
# ARM OS Loader
#
- # Versatile Express machine type (ARM VERSATILE EXPRESS = 2272) required for ARM Linux:
+ # Versatile Express machine type (ARM VERSATILE EXPRESS = 2272) required for ARM Linux:
gArmTokenSpaceGuid.PcdArmMachineType|2272
gArmPlatformTokenSpaceGuid.PcdDefaultBootDescription|L"SemiHosting"
gArmPlatformTokenSpaceGuid.PcdDefaultBootDevicePath|L"VenHw(C5B9C74A-6D72-4719-99AB-C59F199091EB)/zImage"
@@ -177,7 +177,7 @@ #
################################################################################
[Components.common]
-
+
#
# SEC
#
@@ -186,7 +186,7 @@ # Use the implementation which set the Secure bits
ArmGicLib|ArmPkg/Drivers/ArmGic/ArmGicSecLib.inf
}
-
+
#
# PEI Phase modules
#
@@ -231,13 +231,13 @@ #
# Architectural Protocols
#
- ArmPkg/Drivers/CpuDxe/CpuDxe.inf
+ ArmPkg/Drivers/CpuDxe/CpuDxe.inf
MdeModulePkg/Core/RuntimeDxe/RuntimeDxe.inf
MdeModulePkg/Universal/SecurityStubDxe/SecurityStubDxe.inf
MdeModulePkg/Universal/CapsuleRuntimeDxe/CapsuleRuntimeDxe.inf
MdeModulePkg/Universal/Variable/RuntimeDxe/VariableRuntimeDxe.inf
MdeModulePkg/Universal/FaultTolerantWriteDxe/FaultTolerantWriteDxe.inf
- MdeModulePkg/Universal/MonotonicCounterRuntimeDxe/MonotonicCounterRuntimeDxe.inf
+ MdeModulePkg/Universal/MonotonicCounterRuntimeDxe/MonotonicCounterRuntimeDxe.inf
EmbeddedPkg/ResetRuntimeDxe/ResetRuntimeDxe.inf
EmbeddedPkg/RealTimeClockRuntimeDxe/RealTimeClockRuntimeDxe.inf
EmbeddedPkg/MetronomeDxe/MetronomeDxe.inf
@@ -255,12 +255,12 @@ ArmPkg/Drivers/TimerDxe/TimerDxe.inf
ArmPlatformPkg/Drivers/LcdGraphicsOutputDxe/PL111LcdGraphicsOutputDxe.inf
ArmPlatformPkg/Drivers/SP805WatchdogDxe/SP805WatchdogDxe.inf
-
+
#
# Semi-hosting filesystem
#
ArmPkg/Filesystem/SemihostFs/SemihostFs.inf
-
+
#
# Multimedia Card Interface
#
@@ -272,7 +272,7 @@ #
ArmPlatformPkg/ArmVExpressPkg/ArmVExpressDxe/ArmFvpDxe.inf
OvmfPkg/VirtioBlkDxe/VirtioBlk.inf
-
+
#
# FAT filesystem + GPT/MBR partitioning
#
diff --git a/ArmPlatformPkg/ArmVExpressPkg/ArmVExpress-RTSM-A15.fdf b/ArmPlatformPkg/ArmVExpressPkg/ArmVExpress-RTSM-A15.fdf index 0dcd76e788..5f41b62010 100644 --- a/ArmPlatformPkg/ArmVExpressPkg/ArmVExpress-RTSM-A15.fdf +++ b/ArmPlatformPkg/ArmVExpressPkg/ArmVExpress-RTSM-A15.fdf @@ -1,13 +1,13 @@ #
# Copyright (c) 2011-2014, ARM Limited. All rights reserved.
-#
-# This program and the accompanying materials
-# are licensed and made available under the terms and conditions of the BSD License
-# which accompanies this distribution. The full text of the license may be found at
-# http://opensource.org/licenses/bsd-license.php
#
-# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
-# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
+# This program and the accompanying materials
+# are licensed and made available under the terms and conditions of the BSD License
+# which accompanies this distribution. The full text of the license may be found at
+# http://opensource.org/licenses/bsd-license.php
+#
+# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
+# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
#
################################################################################
@@ -110,10 +110,10 @@ READ_STATUS = TRUE READ_LOCK_CAP = TRUE
READ_LOCK_STATUS = TRUE
- INF MdeModulePkg/Core/Dxe/DxeMain.inf
+ INF MdeModulePkg/Core/Dxe/DxeMain.inf
#
- # PI DXE Drivers producing Architectural Protocols (EFI Services)
+ # PI DXE Drivers producing Architectural Protocols (EFI Services)
#
INF ArmPkg/Drivers/CpuDxe/CpuDxe.inf
INF MdeModulePkg/Core/RuntimeDxe/RuntimeDxe.inf
@@ -143,7 +143,7 @@ READ_LOCK_STATUS = TRUE INF MdeModulePkg/Universal/Network/Udp4Dxe/Udp4Dxe.inf
INF MdeModulePkg/Universal/Network/UefiPxeBcDxe/UefiPxeBcDxe.inf
INF MdeModulePkg/Universal/Network/IScsiDxe/IScsiDxe.inf
-
+
#
# Multiple Console IO support
#
@@ -163,7 +163,7 @@ READ_LOCK_STATUS = TRUE # Semi-hosting filesystem
#
INF ArmPkg/Filesystem/SemihostFs/SemihostFs.inf
-
+
#
# FAT filesystem + GPT/MBR partitioning
#
@@ -188,10 +188,10 @@ READ_LOCK_STATUS = TRUE INF OvmfPkg/VirtioBlkDxe/VirtioBlk.inf
#
- # UEFI application (Shell Embedded Boot Loader)
- #
- INF ShellBinPkg/UefiShell/UefiShell.inf
-
+ # UEFI application (Shell Embedded Boot Loader)
+ #
+ INF ShellBinPkg/UefiShell/UefiShell.inf
+
#
# Bds
#
@@ -230,7 +230,7 @@ READ_LOCK_STATUS = TRUE INF MdeModulePkg/Universal/Variable/Pei/VariablePei.inf
INF MdeModulePkg/Core/DxeIplPeim/DxeIpl.inf
!endif
-
+
FILE FV_IMAGE = 9E21FD93-9C72-4c15-8C4B-E77F1DB2D792 {
SECTION GUIDED EE4E5898-3914-4259-9D6E-DC7BD79403CF PROCESSING_REQUIRED = TRUE {
SECTION FV_IMAGE = FVMAIN
@@ -249,7 +249,7 @@ READ_LOCK_STATUS = TRUE ############################################################################
-# Example of a DXE_DRIVER FFS file with a Checksum encapsulation section #
+# Example of a DXE_DRIVER FFS file with a Checksum encapsulation section #
############################################################################
#
#[Rule.Common.DXE_DRIVER]
@@ -274,14 +274,14 @@ READ_LOCK_STATUS = TRUE [Rule.Common.PEI_CORE]
FILE PEI_CORE = $(NAMED_GUID) {
TE TE $(INF_OUTPUT)/$(MODULE_NAME).efi
- UI STRING ="$(MODULE_NAME)" Optional
+ UI STRING ="$(MODULE_NAME)" Optional
}
[Rule.Common.PEIM]
FILE PEIM = $(NAMED_GUID) {
PEI_DEPEX PEI_DEPEX Optional $(INF_OUTPUT)/$(MODULE_NAME).depex
TE TE $(INF_OUTPUT)/$(MODULE_NAME).efi
- UI STRING="$(MODULE_NAME)" Optional
+ UI STRING="$(MODULE_NAME)" Optional
}
[Rule.Common.PEIM.TIANOCOMPRESSED]
@@ -322,7 +322,7 @@ READ_LOCK_STATUS = TRUE [Rule.Common.UEFI_APPLICATION]
FILE APPLICATION = $(NAMED_GUID) {
- UI STRING ="$(MODULE_NAME)" Optional
+ UI STRING ="$(MODULE_NAME)" Optional
PE32 PE32 $(INF_OUTPUT)/$(MODULE_NAME).efi
}
diff --git a/ArmPlatformPkg/ArmVExpressPkg/ArmVExpress-RTSM-A15_MPCore.dsc b/ArmPlatformPkg/ArmVExpressPkg/ArmVExpress-RTSM-A15_MPCore.dsc index a7f17f6e65..2a81c85c6f 100644 --- a/ArmPlatformPkg/ArmVExpressPkg/ArmVExpress-RTSM-A15_MPCore.dsc +++ b/ArmPlatformPkg/ArmVExpressPkg/ArmVExpress-RTSM-A15_MPCore.dsc @@ -1,13 +1,13 @@ #
# Copyright (c) 2011-2014, ARM Limited. All rights reserved.
-#
-# This program and the accompanying materials
-# are licensed and made available under the terms and conditions of the BSD License
-# which accompanies this distribution. The full text of the license may be found at
-# http://opensource.org/licenses/bsd-license.php
#
-# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
-# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
+# This program and the accompanying materials
+# are licensed and made available under the terms and conditions of the BSD License
+# which accompanies this distribution. The full text of the license may be found at
+# http://opensource.org/licenses/bsd-license.php
+#
+# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
+# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
#
#
@@ -33,14 +33,14 @@ ArmLib|ArmPkg/Library/ArmLib/ArmV7/ArmV7Lib.inf
ArmCpuLib|ArmPkg/Drivers/ArmCpuLib/ArmCortexA15Lib/ArmCortexA15Lib.inf
ArmPlatformLib|ArmPlatformPkg/ArmVExpressPkg/Library/ArmVExpressLibRTSM/ArmVExpressLib.inf
-
+
ArmPlatformSysConfigLib|ArmPlatformPkg/ArmVExpressPkg/Library/ArmVExpressSysConfigLib/ArmVExpressSysConfigLib.inf
NorFlashPlatformLib|ArmPlatformPkg/ArmVExpressPkg/Library/NorFlashArmVExpressLib/NorFlashArmVExpressLib.inf
LcdPlatformLib|ArmPlatformPkg/ArmVExpressPkg/Library/PL111LcdArmVExpressLib/PL111LcdArmVExpressLib.inf
#DebugAgentTimerLib|ArmPlatformPkg/ArmVExpressPkg/Library/DebugAgentTimerLib/DebugAgentTimerLib.inf
- TimerLib|ArmPkg/Library/ArmArchTimerLib/ArmArchTimerLib.inf
+ TimerLib|ArmPkg/Library/ArmArchTimerLib/ArmArchTimerLib.inf
# Virtio Support
VirtioLib|OvmfPkg/Library/VirtioLib/VirtioLib.inf
@@ -55,7 +55,7 @@ RVCT:*_*_ARM_PLATFORM_FLAGS == --cpu Cortex-A15 -I$(WORKSPACE)/ArmPlatformPkg/ArmVExpressPkg/Include -I$(WORKSPACE)/ArmPlatformPkg/ArmVExpressPkg/Include/Platform/RTSM
GCC:*_*_ARM_PLATFORM_FLAGS == -mcpu=cortex-a15 -I$(WORKSPACE)/ArmPlatformPkg/ArmVExpressPkg/Include -I$(WORKSPACE)/ArmPlatformPkg/ArmVExpressPkg/Include/Platform/RTSM
-
+
XCODE:*_*_ARM_PLATFORM_FLAGS = -I$(WORKSPACE)/ArmPlatformPkg/ArmVExpressPkg/Include -I$(WORKSPACE)/ArmPlatformPkg/ArmVExpressPkg/Include/Platform/RTSM
################################################################################
@@ -69,11 +69,11 @@ gArmPlatformTokenSpaceGuid.PcdSystemMemoryInitializeInSec|TRUE
gArmPlatformTokenSpaceGuid.PcdSendSgiToBringUpSecondaryCores|TRUE
!endif
-
+
## If TRUE, Graphics Output Protocol will be installed on virtual handle created by ConsplitterDxe.
# It could be set FALSE to save size.
gEfiMdeModulePkgTokenSpaceGuid.PcdConOutGopSupport|TRUE
-
+
[PcdsFixedAtBuild.common]
gArmPlatformTokenSpaceGuid.PcdFirmwareVendor|"ARM Versatile Express"
gEmbeddedTokenSpaceGuid.PcdEmbeddedPrompt|"ArmVExpress-RTSM"
@@ -101,38 +101,38 @@ !endif
gArmTokenSpaceGuid.PcdVFPEnabled|1
-
+
# Stacks for MPCores in Secure World
gArmPlatformTokenSpaceGuid.PcdCPUCoresSecStackBase|0x2E009000
gArmPlatformTokenSpaceGuid.PcdCPUCoreSecPrimaryStackSize|0x1000
-
+
# Stacks for MPCores in Monitor Mode
gArmPlatformTokenSpaceGuid.PcdCPUCoresSecMonStackBase|0x2E008000
gArmPlatformTokenSpaceGuid.PcdCPUCoreSecMonStackSize|0x100
-
+
# Stacks for MPCores in Normal World
gArmPlatformTokenSpaceGuid.PcdCPUCoresStackBase|0x2E000000
gArmPlatformTokenSpaceGuid.PcdCPUCorePrimaryStackSize|0x4000
-
- # System Memory (1GB)
+
+ # System Memory (1GB)
gArmTokenSpaceGuid.PcdSystemMemoryBase|0x80000000
gArmTokenSpaceGuid.PcdSystemMemorySize|0x40000000
-
+
# Size of the region used by UEFI in permanent memory (Reserved 64MB)
gArmPlatformTokenSpaceGuid.PcdSystemMemoryUefiRegionSize|0x04000000
-
+
#
# ARM Pcds
#
gArmTokenSpaceGuid.PcdArmUncachedMemoryMask|0x0000000040000000
-
+
#
# ARM PrimeCell
#
## SP805 Watchdog - Motherboard Watchdog
gArmPlatformTokenSpaceGuid.PcdSP805WatchdogBase|0x1C0F0000
-
+
## PL011 - Serial Terminal
gEfiMdeModulePkgTokenSpaceGuid.PcdSerialRegisterBase|0x1c090000
gEfiMdePkgTokenSpaceGuid.PcdUartDefaultBaudRate|38400
@@ -142,11 +142,11 @@ ## PL111 Versatile Express Motherboard controller
gArmPlatformTokenSpaceGuid.PcdPL111LcdBase|0x1C1F0000
-
+
## PL180 MMC/SD card controller
gArmPlatformTokenSpaceGuid.PcdPL180SysMciRegAddress|0x1C010048
gArmPlatformTokenSpaceGuid.PcdPL180MciBaseAddress|0x1C050000
-
+
#
# ARM General Interrupt Controller
#
@@ -156,7 +156,7 @@ #
# ARM OS Loader
#
- # Versatile Express machine type (ARM VERSATILE EXPRESS = 2272) required for ARM Linux:
+ # Versatile Express machine type (ARM VERSATILE EXPRESS = 2272) required for ARM Linux:
gArmTokenSpaceGuid.PcdArmMachineType|2272
gArmPlatformTokenSpaceGuid.PcdDefaultBootDescription|L"SemiHosting"
gArmPlatformTokenSpaceGuid.PcdDefaultBootDevicePath|L"VenHw(C5B9C74A-6D72-4719-99AB-C59F199091EB)/zImage"
@@ -171,15 +171,15 @@ # ARM Architectural Timer Frequency
#
gArmTokenSpaceGuid.PcdArmArchTimerFreqInHz|100000000
-
-
+
+
################################################################################
#
# Components Section - list of all EDK II Modules needed by this Platform
#
################################################################################
[Components.common]
-
+
#
# SEC
#
@@ -188,7 +188,7 @@ # Use the implementation which set the Secure bits
ArmGicLib|ArmPkg/Drivers/ArmGic/ArmGicSecLib.inf
}
-
+
#
# PEI Phase modules
#
@@ -233,13 +233,13 @@ #
# Architectural Protocols
#
- ArmPkg/Drivers/CpuDxe/CpuDxe.inf
+ ArmPkg/Drivers/CpuDxe/CpuDxe.inf
MdeModulePkg/Core/RuntimeDxe/RuntimeDxe.inf
MdeModulePkg/Universal/SecurityStubDxe/SecurityStubDxe.inf
MdeModulePkg/Universal/CapsuleRuntimeDxe/CapsuleRuntimeDxe.inf
MdeModulePkg/Universal/Variable/RuntimeDxe/VariableRuntimeDxe.inf
MdeModulePkg/Universal/FaultTolerantWriteDxe/FaultTolerantWriteDxe.inf
- MdeModulePkg/Universal/MonotonicCounterRuntimeDxe/MonotonicCounterRuntimeDxe.inf
+ MdeModulePkg/Universal/MonotonicCounterRuntimeDxe/MonotonicCounterRuntimeDxe.inf
EmbeddedPkg/ResetRuntimeDxe/ResetRuntimeDxe.inf
EmbeddedPkg/RealTimeClockRuntimeDxe/RealTimeClockRuntimeDxe.inf
EmbeddedPkg/MetronomeDxe/MetronomeDxe.inf
@@ -257,12 +257,12 @@ ArmPkg/Drivers/TimerDxe/TimerDxe.inf
ArmPlatformPkg/Drivers/LcdGraphicsOutputDxe/PL111LcdGraphicsOutputDxe.inf
ArmPlatformPkg/Drivers/SP805WatchdogDxe/SP805WatchdogDxe.inf
-
+
#
# Semi-hosting filesystem
#
ArmPkg/Filesystem/SemihostFs/SemihostFs.inf
-
+
#
# Multimedia Card Interface
#
@@ -274,7 +274,7 @@ #
ArmPlatformPkg/ArmVExpressPkg/ArmVExpressDxe/ArmFvpDxe.inf
OvmfPkg/VirtioBlkDxe/VirtioBlk.inf
-
+
#
# FAT filesystem + GPT/MBR partitioning
#
diff --git a/ArmPlatformPkg/ArmVExpressPkg/ArmVExpress-RTSM-A15_MPCore.fdf b/ArmPlatformPkg/ArmVExpressPkg/ArmVExpress-RTSM-A15_MPCore.fdf index d9736ed747..4638ef1347 100644 --- a/ArmPlatformPkg/ArmVExpressPkg/ArmVExpress-RTSM-A15_MPCore.fdf +++ b/ArmPlatformPkg/ArmVExpressPkg/ArmVExpress-RTSM-A15_MPCore.fdf @@ -1,13 +1,13 @@ #
# Copyright (c) 2011-2014, ARM Limited. All rights reserved.
-#
-# This program and the accompanying materials
-# are licensed and made available under the terms and conditions of the BSD License
-# which accompanies this distribution. The full text of the license may be found at
-# http://opensource.org/licenses/bsd-license.php
#
-# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
-# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
+# This program and the accompanying materials
+# are licensed and made available under the terms and conditions of the BSD License
+# which accompanies this distribution. The full text of the license may be found at
+# http://opensource.org/licenses/bsd-license.php
+#
+# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
+# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
#
################################################################################
@@ -110,10 +110,10 @@ READ_STATUS = TRUE READ_LOCK_CAP = TRUE
READ_LOCK_STATUS = TRUE
- INF MdeModulePkg/Core/Dxe/DxeMain.inf
+ INF MdeModulePkg/Core/Dxe/DxeMain.inf
#
- # PI DXE Drivers producing Architectural Protocols (EFI Services)
+ # PI DXE Drivers producing Architectural Protocols (EFI Services)
#
INF ArmPkg/Drivers/CpuDxe/CpuDxe.inf
INF MdeModulePkg/Core/RuntimeDxe/RuntimeDxe.inf
@@ -163,7 +163,7 @@ READ_LOCK_STATUS = TRUE # Semi-hosting filesystem
#
INF ArmPkg/Filesystem/SemihostFs/SemihostFs.inf
-
+
#
# FAT filesystem + GPT/MBR partitioning
#
@@ -188,10 +188,10 @@ READ_LOCK_STATUS = TRUE INF OvmfPkg/VirtioBlkDxe/VirtioBlk.inf
#
- # UEFI application (Shell Embedded Boot Loader)
- #
- INF ShellBinPkg/UefiShell/UefiShell.inf
-
+ # UEFI application (Shell Embedded Boot Loader)
+ #
+ INF ShellBinPkg/UefiShell/UefiShell.inf
+
#
# Bds
#
@@ -230,7 +230,7 @@ READ_LOCK_STATUS = TRUE INF MdeModulePkg/Universal/Variable/Pei/VariablePei.inf
INF MdeModulePkg/Core/DxeIplPeim/DxeIpl.inf
!endif
-
+
FILE FV_IMAGE = 9E21FD93-9C72-4c15-8C4B-E77F1DB2D792 {
SECTION GUIDED EE4E5898-3914-4259-9D6E-DC7BD79403CF PROCESSING_REQUIRED = TRUE {
SECTION FV_IMAGE = FVMAIN
@@ -249,7 +249,7 @@ READ_LOCK_STATUS = TRUE ############################################################################
-# Example of a DXE_DRIVER FFS file with a Checksum encapsulation section #
+# Example of a DXE_DRIVER FFS file with a Checksum encapsulation section #
############################################################################
#
#[Rule.Common.DXE_DRIVER]
@@ -274,14 +274,14 @@ READ_LOCK_STATUS = TRUE [Rule.Common.PEI_CORE]
FILE PEI_CORE = $(NAMED_GUID) {
TE TE $(INF_OUTPUT)/$(MODULE_NAME).efi
- UI STRING ="$(MODULE_NAME)" Optional
+ UI STRING ="$(MODULE_NAME)" Optional
}
[Rule.Common.PEIM]
FILE PEIM = $(NAMED_GUID) {
PEI_DEPEX PEI_DEPEX Optional $(INF_OUTPUT)/$(MODULE_NAME).depex
TE TE $(INF_OUTPUT)/$(MODULE_NAME).efi
- UI STRING="$(MODULE_NAME)" Optional
+ UI STRING="$(MODULE_NAME)" Optional
}
[Rule.Common.PEIM.TIANOCOMPRESSED]
@@ -322,7 +322,7 @@ READ_LOCK_STATUS = TRUE [Rule.Common.UEFI_APPLICATION]
FILE APPLICATION = $(NAMED_GUID) {
- UI STRING ="$(MODULE_NAME)" Optional
+ UI STRING ="$(MODULE_NAME)" Optional
PE32 PE32 $(INF_OUTPUT)/$(MODULE_NAME).efi
}
diff --git a/ArmPlatformPkg/ArmVExpressPkg/ArmVExpress-RTSM-A9x4.dsc b/ArmPlatformPkg/ArmVExpressPkg/ArmVExpress-RTSM-A9x4.dsc index e1d60ece3e..0923a1e3b6 100644 --- a/ArmPlatformPkg/ArmVExpressPkg/ArmVExpress-RTSM-A9x4.dsc +++ b/ArmPlatformPkg/ArmVExpressPkg/ArmVExpress-RTSM-A9x4.dsc @@ -1,13 +1,13 @@ #
# Copyright (c) 2011-2014, ARM Limited. All rights reserved.
-#
-# This program and the accompanying materials
-# are licensed and made available under the terms and conditions of the BSD License
-# which accompanies this distribution. The full text of the license may be found at
-# http://opensource.org/licenses/bsd-license.php
#
-# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
-# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
+# This program and the accompanying materials
+# are licensed and made available under the terms and conditions of the BSD License
+# which accompanies this distribution. The full text of the license may be found at
+# http://opensource.org/licenses/bsd-license.php
+#
+# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
+# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
#
#
@@ -33,7 +33,7 @@ ArmLib|ArmPkg/Library/ArmLib/ArmV7/ArmV7Lib.inf
ArmCpuLib|ArmPkg/Drivers/ArmCpuLib/ArmCortexA9Lib/ArmCortexA9Lib.inf
ArmPlatformLib|ArmPlatformPkg/ArmVExpressPkg/Library/ArmVExpressLibRTSM/ArmVExpressLib.inf
-
+
ArmPlatformSysConfigLib|ArmPlatformPkg/ArmVExpressPkg/Library/ArmVExpressSysConfigLib/ArmVExpressSysConfigLib.inf
NorFlashPlatformLib|ArmPlatformPkg/ArmVExpressPkg/Library/NorFlashArmVExpressLib/NorFlashArmVExpressLib.inf
LcdPlatformLib|ArmPlatformPkg/ArmVExpressPkg/Library/PL111LcdArmVExpressLib/PL111LcdArmVExpressLib.inf
@@ -50,14 +50,14 @@ ArmPlatformSecLib|ArmPlatformPkg/ArmVExpressPkg/Library/ArmVExpressSecLibRTSM/ArmVExpressSecLib.inf
ArmPlatformLib|ArmPlatformPkg/ArmVExpressPkg/Library/ArmVExpressLibRTSM/ArmVExpressLibSec.inf
- # Uncomment to turn on GDB stub in SEC.
+ # Uncomment to turn on GDB stub in SEC.
#DebugAgentLib|EmbeddedPkg/Library/GdbDebugAgent/GdbDebugAgent.inf
-
+
[BuildOptions]
RVCT:*_*_ARM_PLATFORM_FLAGS == --cpu Cortex-A9 -I$(WORKSPACE)/ArmPlatformPkg/ArmVExpressPkg/Include -I$(WORKSPACE)/ArmPlatformPkg/ArmVExpressPkg/Include/Platform/RTSM
GCC:*_*_ARM_PLATFORM_FLAGS == -mcpu=cortex-a9 -I$(WORKSPACE)/ArmPlatformPkg/ArmVExpressPkg/Include -I$(WORKSPACE)/ArmPlatformPkg/ArmVExpressPkg/Include/Platform/RTSM
-
+
XCODE:*_*_ARM_PLATFORM_FLAGS == -march=armv7-a -I$(WORKSPACE)/ArmPlatformPkg/ArmVExpressPkg/Include -I$(WORKSPACE)/ArmPlatformPkg/ArmVExpressPkg/Include/Platform/RTSM
################################################################################
@@ -72,11 +72,11 @@ gArmPlatformTokenSpaceGuid.PcdSystemMemoryInitializeInSec|TRUE
gArmPlatformTokenSpaceGuid.PcdSendSgiToBringUpSecondaryCores|TRUE
!endif
-
+
## If TRUE, Graphics Output Protocol will be installed on virtual handle created by ConsplitterDxe.
# It could be set FALSE to save size.
gEfiMdeModulePkgTokenSpaceGuid.PcdConOutGopSupport|TRUE
-
+
[PcdsFixedAtBuild.common]
gArmPlatformTokenSpaceGuid.PcdFirmwareVendor|"ARM Versatile Express"
gEmbeddedTokenSpaceGuid.PcdEmbeddedPrompt|"ArmVExpress-RTSM"
@@ -94,31 +94,31 @@ gEfiMdeModulePkgTokenSpaceGuid.PcdFlashNvStorageFtwSpareSize|0x00010000
gArmTokenSpaceGuid.PcdVFPEnabled|1
-
+
# Stacks for MPCores in Secure World
gArmPlatformTokenSpaceGuid.PcdCPUCoresSecStackBase|0x2E009000
gArmPlatformTokenSpaceGuid.PcdCPUCoreSecPrimaryStackSize|0x1000
-
+
# Stacks for MPCores in Monitor Mode
gArmPlatformTokenSpaceGuid.PcdCPUCoresSecMonStackBase|0x2E008000
gArmPlatformTokenSpaceGuid.PcdCPUCoreSecMonStackSize|0x100
-
+
# Stacks for MPCores in Normal World
gArmPlatformTokenSpaceGuid.PcdCPUCoresStackBase|0x2E000000
gArmPlatformTokenSpaceGuid.PcdCPUCorePrimaryStackSize|0x4000
- # System Memory (1GB)
+ # System Memory (1GB)
gArmTokenSpaceGuid.PcdSystemMemoryBase|0x80000000
gArmTokenSpaceGuid.PcdSystemMemorySize|0x40000000
-
+
# Size of the region used by UEFI in permanent memory (Reserved 64MB)
gArmPlatformTokenSpaceGuid.PcdSystemMemoryUefiRegionSize|0x04000000
-
+
#
# ARM Pcds
#
gArmTokenSpaceGuid.PcdArmUncachedMemoryMask|0x0000000040000000
-
+
#
# ARM PrimeCell
#
@@ -133,7 +133,7 @@ ## SP805 Watchdog - Motherboard Watchdog
gArmPlatformTokenSpaceGuid.PcdSP805WatchdogBase|0x1C0F0000
-
+
## PL011 - Serial Terminal
gEfiMdeModulePkgTokenSpaceGuid.PcdSerialRegisterBase|0x1c090000
gEfiMdePkgTokenSpaceGuid.PcdUartDefaultBaudRate|38400
@@ -147,7 +147,7 @@ ## PL180 MMC/SD card controller
gArmPlatformTokenSpaceGuid.PcdPL180SysMciRegAddress|0x1C010048
gArmPlatformTokenSpaceGuid.PcdPL180MciBaseAddress|0x1C050000
-
+
#
# ARM General Interrupt Controller
#
@@ -157,7 +157,7 @@ #
# ARM OS Loader
#
- # Versatile Express machine type (ARM VERSATILE EXPRESS = 2272) required for ARM Linux:
+ # Versatile Express machine type (ARM VERSATILE EXPRESS = 2272) required for ARM Linux:
gArmTokenSpaceGuid.PcdArmMachineType|2272
gArmPlatformTokenSpaceGuid.PcdDefaultBootDescription|L"SemiHosting"
gArmPlatformTokenSpaceGuid.PcdDefaultBootDevicePath|L"VenHw(C5B9C74A-6D72-4719-99AB-C59F199091EB)/zImage"
@@ -179,7 +179,7 @@ #
################################################################################
[Components.common]
-
+
#
# SEC
#
@@ -188,7 +188,7 @@ # Use the implementation which set the Secure bits
ArmGicLib|ArmPkg/Drivers/ArmGic/ArmGicSecLib.inf
}
-
+
#
# PEI Phase modules
#
@@ -233,13 +233,13 @@ #
# Architectural Protocols
#
- ArmPkg/Drivers/CpuDxe/CpuDxe.inf
+ ArmPkg/Drivers/CpuDxe/CpuDxe.inf
MdeModulePkg/Core/RuntimeDxe/RuntimeDxe.inf
MdeModulePkg/Universal/SecurityStubDxe/SecurityStubDxe.inf
MdeModulePkg/Universal/CapsuleRuntimeDxe/CapsuleRuntimeDxe.inf
MdeModulePkg/Universal/Variable/RuntimeDxe/VariableRuntimeDxe.inf
MdeModulePkg/Universal/FaultTolerantWriteDxe/FaultTolerantWriteDxe.inf
- MdeModulePkg/Universal/MonotonicCounterRuntimeDxe/MonotonicCounterRuntimeDxe.inf
+ MdeModulePkg/Universal/MonotonicCounterRuntimeDxe/MonotonicCounterRuntimeDxe.inf
EmbeddedPkg/ResetRuntimeDxe/ResetRuntimeDxe.inf
EmbeddedPkg/RealTimeClockRuntimeDxe/RealTimeClockRuntimeDxe.inf
EmbeddedPkg/MetronomeDxe/MetronomeDxe.inf
@@ -257,12 +257,12 @@ ArmPlatformPkg/Drivers/SP804TimerDxe/SP804TimerDxe.inf
ArmPlatformPkg/Drivers/LcdGraphicsOutputDxe/PL111LcdGraphicsOutputDxe.inf
ArmPlatformPkg/Drivers/SP805WatchdogDxe/SP805WatchdogDxe.inf
-
+
#
# Semi-hosting filesystem
#
ArmPkg/Filesystem/SemihostFs/SemihostFs.inf
-
+
#
# Multimedia Card Interface
#
@@ -274,7 +274,7 @@ #
ArmPlatformPkg/ArmVExpressPkg/ArmVExpressDxe/ArmFvpDxe.inf
OvmfPkg/VirtioBlkDxe/VirtioBlk.inf
-
+
#
# FAT filesystem + GPT/MBR partitioning
#
diff --git a/ArmPlatformPkg/ArmVExpressPkg/ArmVExpress-RTSM-A9x4.fdf b/ArmPlatformPkg/ArmVExpressPkg/ArmVExpress-RTSM-A9x4.fdf index d114b162c7..76d5750314 100644 --- a/ArmPlatformPkg/ArmVExpressPkg/ArmVExpress-RTSM-A9x4.fdf +++ b/ArmPlatformPkg/ArmVExpressPkg/ArmVExpress-RTSM-A9x4.fdf @@ -1,13 +1,13 @@ #
# Copyright (c) 2011-2014, ARM Limited. All rights reserved.
-#
-# This program and the accompanying materials
-# are licensed and made available under the terms and conditions of the BSD License
-# which accompanies this distribution. The full text of the license may be found at
-# http://opensource.org/licenses/bsd-license.php
#
-# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
-# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
+# This program and the accompanying materials
+# are licensed and made available under the terms and conditions of the BSD License
+# which accompanies this distribution. The full text of the license may be found at
+# http://opensource.org/licenses/bsd-license.php
+#
+# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
+# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
#
################################################################################
@@ -110,10 +110,10 @@ READ_STATUS = TRUE READ_LOCK_CAP = TRUE
READ_LOCK_STATUS = TRUE
- INF MdeModulePkg/Core/Dxe/DxeMain.inf
+ INF MdeModulePkg/Core/Dxe/DxeMain.inf
#
- # PI DXE Drivers producing Architectural Protocols (EFI Services)
+ # PI DXE Drivers producing Architectural Protocols (EFI Services)
#
INF ArmPkg/Drivers/CpuDxe/CpuDxe.inf
INF MdeModulePkg/Core/RuntimeDxe/RuntimeDxe.inf
@@ -127,7 +127,7 @@ READ_LOCK_STATUS = TRUE INF EmbeddedPkg/MetronomeDxe/MetronomeDxe.inf
INF MdeModulePkg/Universal/HiiDatabaseDxe/HiiDatabaseDxe.inf
-
+
#
# Multiple Console IO support
#
@@ -147,7 +147,7 @@ READ_LOCK_STATUS = TRUE # Semi-hosting filesystem
#
INF ArmPkg/Filesystem/SemihostFs/SemihostFs.inf
-
+
#
# Versatile Express FileSystem
#
@@ -160,7 +160,7 @@ READ_LOCK_STATUS = TRUE INF MdeModulePkg/Universal/Disk/PartitionDxe/PartitionDxe.inf
INF FatBinPkg/EnhancedFatDxe/Fat.inf
INF MdeModulePkg/Universal/Disk/UnicodeCollation/EnglishDxe/EnglishDxe.inf
-
+
#
# Multimedia Card Interface
#
@@ -174,10 +174,10 @@ READ_LOCK_STATUS = TRUE INF OvmfPkg/VirtioBlkDxe/VirtioBlk.inf
#
- # UEFI application (Shell Embedded Boot Loader)
- #
- INF ShellBinPkg/UefiShell/UefiShell.inf
-
+ # UEFI application (Shell Embedded Boot Loader)
+ #
+ INF ShellBinPkg/UefiShell/UefiShell.inf
+
#
# Bds
#
@@ -216,7 +216,7 @@ READ_LOCK_STATUS = TRUE INF MdeModulePkg/Universal/Variable/Pei/VariablePei.inf
INF MdeModulePkg/Core/DxeIplPeim/DxeIpl.inf
!endif
-
+
FILE FV_IMAGE = 9E21FD93-9C72-4c15-8C4B-E77F1DB2D792 {
SECTION GUIDED EE4E5898-3914-4259-9D6E-DC7BD79403CF PROCESSING_REQUIRED = TRUE {
SECTION FV_IMAGE = FVMAIN
@@ -235,7 +235,7 @@ READ_LOCK_STATUS = TRUE ############################################################################
-# Example of a DXE_DRIVER FFS file with a Checksum encapsulation section #
+# Example of a DXE_DRIVER FFS file with a Checksum encapsulation section #
############################################################################
#
#[Rule.Common.DXE_DRIVER]
@@ -260,14 +260,14 @@ READ_LOCK_STATUS = TRUE [Rule.Common.PEI_CORE]
FILE PEI_CORE = $(NAMED_GUID) {
TE TE $(INF_OUTPUT)/$(MODULE_NAME).efi
- UI STRING ="$(MODULE_NAME)" Optional
+ UI STRING ="$(MODULE_NAME)" Optional
}
[Rule.Common.PEIM]
FILE PEIM = $(NAMED_GUID) {
PEI_DEPEX PEI_DEPEX Optional $(INF_OUTPUT)/$(MODULE_NAME).depex
TE TE $(INF_OUTPUT)/$(MODULE_NAME).efi
- UI STRING="$(MODULE_NAME)" Optional
+ UI STRING="$(MODULE_NAME)" Optional
}
[Rule.Common.PEIM.TIANOCOMPRESSED]
@@ -308,7 +308,7 @@ READ_LOCK_STATUS = TRUE [Rule.Common.UEFI_APPLICATION]
FILE APPLICATION = $(NAMED_GUID) {
- UI STRING ="$(MODULE_NAME)" Optional
+ UI STRING ="$(MODULE_NAME)" Optional
PE32 PE32 $(INF_OUTPUT)/$(MODULE_NAME).efi
}
diff --git a/ArmPlatformPkg/ArmVExpressPkg/ArmVExpress-RTSM-AEMv8Ax4.dsc b/ArmPlatformPkg/ArmVExpressPkg/ArmVExpress-RTSM-AEMv8Ax4.dsc index ae3e9b9156..b2ffd37d73 100644 --- a/ArmPlatformPkg/ArmVExpressPkg/ArmVExpress-RTSM-AEMv8Ax4.dsc +++ b/ArmPlatformPkg/ArmVExpressPkg/ArmVExpress-RTSM-AEMv8Ax4.dsc @@ -116,7 +116,7 @@ ## Trustzone enable (to make the transition from EL3 to EL2 in ArmPlatformPkg/Sec)
gArmTokenSpaceGuid.PcdTrustzoneSupport|TRUE
-
+
#
# ARM PrimeCell
#
@@ -138,7 +138,7 @@ ## PL180 MMC/SD card controller
gArmPlatformTokenSpaceGuid.PcdPL180SysMciRegAddress|0x1C010048
gArmPlatformTokenSpaceGuid.PcdPL180MciBaseAddress|0x1C050000
-
+
#
# ARM General Interrupt Controller
#
@@ -180,7 +180,7 @@ # Use the implementation which set the Secure bits
ArmGicLib|ArmPkg/Drivers/ArmGic/ArmGicSecLib.inf
}
-
+
#
# PEI Phase modules
#
@@ -249,18 +249,18 @@ ArmPkg/Drivers/TimerDxe/TimerDxe.inf
ArmPlatformPkg/Drivers/LcdGraphicsOutputDxe/PL111LcdGraphicsOutputDxe.inf
ArmPlatformPkg/Drivers/SP805WatchdogDxe/SP805WatchdogDxe.inf
-
+
#
# Semi-hosting filesystem
#
ArmPkg/Filesystem/SemihostFs/SemihostFs.inf
-
+
#
# Multimedia Card Interface
#
EmbeddedPkg/Universal/MmcDxe/MmcDxe.inf
ArmPlatformPkg/Drivers/PL180MciDxe/PL180MciDxe.inf
-
+
#
# Platform Driver
#
diff --git a/ArmPlatformPkg/ArmVExpressPkg/ArmVExpress-RTSM-AEMv8Ax4.fdf b/ArmPlatformPkg/ArmVExpressPkg/ArmVExpress-RTSM-AEMv8Ax4.fdf index ed557b5c10..3546848a83 100644 --- a/ArmPlatformPkg/ArmVExpressPkg/ArmVExpress-RTSM-AEMv8Ax4.fdf +++ b/ArmPlatformPkg/ArmVExpressPkg/ArmVExpress-RTSM-AEMv8Ax4.fdf @@ -174,7 +174,7 @@ READ_LOCK_STATUS = TRUE # UEFI application (Shell Embedded Boot Loader)
#
INF ShellBinPkg/UefiShell/UefiShell.inf
-
+
#
# Bds
#
@@ -213,7 +213,7 @@ READ_LOCK_STATUS = TRUE INF MdeModulePkg/Universal/Variable/Pei/VariablePei.inf
INF MdeModulePkg/Core/DxeIplPeim/DxeIpl.inf
!endif
-
+
FILE FV_IMAGE = 9E21FD93-9C72-4c15-8C4B-E77F1DB2D792 {
SECTION GUIDED EE4E5898-3914-4259-9D6E-DC7BD79403CF PROCESSING_REQUIRED = TRUE {
SECTION FV_IMAGE = FVMAIN
diff --git a/ArmPlatformPkg/ArmVExpressPkg/ArmVExpress.dsc.inc b/ArmPlatformPkg/ArmVExpressPkg/ArmVExpress.dsc.inc index c61429e8d2..539b6b09ee 100644 --- a/ArmPlatformPkg/ArmVExpressPkg/ArmVExpress.dsc.inc +++ b/ArmPlatformPkg/ArmVExpressPkg/ArmVExpress.dsc.inc @@ -1,13 +1,13 @@ #
# Copyright (c) 2011-2014, ARM Limited. All rights reserved.
-#
-# This program and the accompanying materials
-# are licensed and made available under the terms and conditions of the BSD License
-# which accompanies this distribution. The full text of the license may be found at
-# http://opensource.org/licenses/bsd-license.php
#
-# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
-# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
+# This program and the accompanying materials
+# are licensed and made available under the terms and conditions of the BSD License
+# which accompanies this distribution. The full text of the license may be found at
+# http://opensource.org/licenses/bsd-license.php
+#
+# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
+# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
#
#
@@ -21,7 +21,7 @@ # UncachedMemoryAllocationLib|ArmPkg/Library/DebugUncachedMemoryAllocationLib/DebugUncachedMemoryAllocationLib.inf
!endif
DebugPrintErrorLevelLib|MdePkg/Library/BaseDebugPrintErrorLevelLib/BaseDebugPrintErrorLevelLib.inf
-
+
BaseLib|MdePkg/Library/BaseLib/BaseLib.inf
SynchronizationLib|MdePkg/Library/BaseSynchronizationLib/BaseSynchronizationLib.inf
PerformanceLib|MdePkg/Library/BasePerformanceLibNull/BasePerformanceLibNull.inf
@@ -41,7 +41,7 @@ UefiDriverEntryPoint|MdePkg/Library/UefiDriverEntryPoint/UefiDriverEntryPoint.inf
UefiApplicationEntryPoint|MdePkg/Library/UefiApplicationEntryPoint/UefiApplicationEntryPoint.inf
HiiLib|MdeModulePkg/Library/UefiHiiLib/UefiHiiLib.inf
- UefiHiiServicesLib|MdeModulePkg/Library/UefiHiiServicesLib/UefiHiiServicesLib.inf
+ UefiHiiServicesLib|MdeModulePkg/Library/UefiHiiServicesLib/UefiHiiServicesLib.inf
UefiRuntimeLib|MdePkg/Library/UefiRuntimeLib/UefiRuntimeLib.inf
@@ -49,7 +49,7 @@ # Assume everything is fixed at build
#
PcdLib|MdePkg/Library/BasePcdLibNull/BasePcdLibNull.inf
-
+
# 1/123 faster than Stm or Vstm version
#BaseMemoryLib|MdePkg/Library/BaseMemoryLib/BaseMemoryLib.inf
BaseMemoryLib|ArmPkg/Library/BaseMemoryLibStm/BaseMemoryLibStm.inf
@@ -87,14 +87,14 @@ # ARM SP804 Dual Timer Driver
TimerLib|ArmPlatformPkg/Library/SP804TimerLib/SP804TimerLib.inf
- # EBL Related Libraries
+ # EBL Related Libraries
EblCmdLib|ArmPlatformPkg/Library/EblCmdLib/EblCmdLib.inf
EfiFileLib|EmbeddedPkg/Library/EfiFileLib/EfiFileLib.inf
EblAddExternalCommandLib|EmbeddedPkg/Library/EblAddExternalCommandLib/EblAddExternalCommandLib.inf
EblNetworkLib|EmbeddedPkg/Library/EblNetworkLib/EblNetworkLib.inf
-
+
#
- # Uncomment (and comment out the next line) For RealView Debugger. The Standard IO window
+ # Uncomment (and comment out the next line) For RealView Debugger. The Standard IO window
# in the debugger will show load and unload commands for symbols. You can cut and paste this
# into the command window to load symbols. We should be able to use a script to do this, but
# the version of RVD I have does not support scripts accessing system memory.
@@ -102,11 +102,11 @@ #PeCoffExtraActionLib|ArmPkg/Library/RvdPeCoffExtraActionLib/RvdPeCoffExtraActionLib.inf
PeCoffExtraActionLib|ArmPkg/Library/DebugPeCoffExtraActionLib/DebugPeCoffExtraActionLib.inf
#PeCoffExtraActionLib|MdePkg/Library/BasePeCoffExtraActionLibNull/BasePeCoffExtraActionLibNull.inf
-
+
DebugAgentLib|MdeModulePkg/Library/DebugAgentLibNull/DebugAgentLibNull.inf
DebugAgentTimerLib|EmbeddedPkg/Library/DebugAgentTimerLibNull/DebugAgentTimerLibNull.inf
- SemihostLib|ArmPkg/Library/SemihostLib/SemihostLib.inf
+ SemihostLib|ArmPkg/Library/SemihostLib/SemihostLib.inf
# BDS Libraries
BdsLib|ArmPkg/Library/BdsLib/BdsLib.inf
@@ -115,10 +115,10 @@ [LibraryClasses.common.SEC]
ArmPlatformSecExtraActionLib|ArmPlatformPkg/Library/DebugSecExtraActionLib/DebugSecExtraActionLib.inf
ArmPlatformGlobalVariableLib|ArmPlatformPkg/Library/ArmPlatformGlobalVariableLib/Sec/SecArmPlatformGlobalVariableLib.inf
-
+
DebugAgentLib|ArmPkg/Library/DebugAgentSymbolsBaseLib/DebugAgentSymbolsBaseLib.inf
DefaultExceptionHandlerLib|ArmPkg/Library/DefaultExceptionHandlerLib/DefaultExceptionHandlerLibBase.inf
-
+
!ifdef $(EDK2_SKIP_PEICORE)
PrePiLib|EmbeddedPkg/Library/PrePiLib/PrePiLib.inf
ExtractGuidedSectionLib|EmbeddedPkg/Library/PrePiExtractGuidedSectionLib/PrePiExtractGuidedSectionLib.inf
@@ -145,10 +145,10 @@ PeCoffGetEntryPointLib|MdePkg/Library/BasePeCoffGetEntryPointLib/BasePeCoffGetEntryPointLib.inf
UefiDecompressLib|MdePkg/Library/BaseUefiDecompressLib/BaseUefiDecompressLib.inf
ExtractGuidedSectionLib|MdePkg/Library/PeiExtractGuidedSectionLib/PeiExtractGuidedSectionLib.inf
-
+
ArmPlatformGlobalVariableLib|ArmPlatformPkg/Library/ArmPlatformGlobalVariableLib/Pei/PeiArmPlatformGlobalVariableLib.inf
PeiServicesTablePointerLib|ArmPlatformPkg/Library/PeiServicesTablePointerLib/PeiServicesTablePointerLib.inf
-
+
[LibraryClasses.common.PEIM]
HobLib|MdePkg/Library/PeiHobLib/PeiHobLib.inf
PeiServicesLib|MdePkg/Library/PeiServicesLib/PeiServicesLib.inf
@@ -231,11 +231,11 @@ gEfiMdePkgTokenSpaceGuid.PcdDriverDiagnosticsDisable|TRUE
gEfiMdePkgTokenSpaceGuid.PcdComponentName2Disable|TRUE
gEfiMdePkgTokenSpaceGuid.PcdDriverDiagnostics2Disable|TRUE
-
+
#
# Control what commands are supported from the UI
# Turn these on and off to add features or save size
- #
+ #
gEmbeddedTokenSpaceGuid.PcdEmbeddedMacBoot|TRUE
gEmbeddedTokenSpaceGuid.PcdEmbeddedDirCmd|TRUE
gEmbeddedTokenSpaceGuid.PcdEmbeddedHobCmd|TRUE
@@ -245,17 +245,17 @@ gEmbeddedTokenSpaceGuid.PcdEmbeddedScriptCmd|FALSE
gEmbeddedTokenSpaceGuid.PcdCacheEnable|TRUE
-
+
# Use the Vector Table location in CpuDxe. We will not copy the Vector Table at PcdCpuVectorBaseAddress
gArmTokenSpaceGuid.PcdRelocateVectorTable|FALSE
-
+
gEmbeddedTokenSpaceGuid.PcdPrePiProduceMemoryTypeInformationHob|TRUE
-
+
gEfiMdeModulePkgTokenSpaceGuid.PcdTurnOffUsbLegacySupport|TRUE
[PcdsFixedAtBuild.common]
gArmPlatformTokenSpaceGuid.PcdFirmwareVendor|"ARM Versatile Express"
-
+
gEmbeddedTokenSpaceGuid.PcdEmbeddedPrompt|"VExpress"
gEfiMdePkgTokenSpaceGuid.PcdMaximumUnicodeStringLength|1000000
gEfiMdePkgTokenSpaceGuid.PcdMaximumAsciiStringLength|1000000
@@ -303,12 +303,12 @@ gEmbeddedTokenSpaceGuid.PcdEmbeddedAutomaticBootCommand|""
gEmbeddedTokenSpaceGuid.PcdEmbeddedDefaultTextColor|0x07
gEmbeddedTokenSpaceGuid.PcdEmbeddedMemVariableStoreSize|0x10000
-
+
#
# Optional feature to help prevent EFI memory map fragments
# Turned on and off via: PcdPrePiProduceMemoryTypeInformationHob
- # Values are in EFI Pages (4K). DXE Core will make sure that
- # at least this much of each type of memory can be allocated
+ # Values are in EFI Pages (4K). DXE Core will make sure that
+ # at least this much of each type of memory can be allocated
# from a single memory range. This way you only end up with
# maximum of two fragements for each type in the memory map
# (the memory used, and the free memory that was prereserved
@@ -347,12 +347,12 @@ #
# ARM OS Loader
#
- # Versatile Express machine type (ARM VERSATILE EXPRESS = 2272) required for ARM Linux:
+ # Versatile Express machine type (ARM VERSATILE EXPRESS = 2272) required for ARM Linux:
gArmTokenSpaceGuid.PcdArmMachineType|2272
gArmPlatformTokenSpaceGuid.PcdDefaultBootDescription|L"Linux from NorFlash"
gArmPlatformTokenSpaceGuid.PcdDefaultBootDevicePath|L"VenHw(E7223039-5836-41E1-B542-D7EC736C5E59)/MemoryMapped(0x0,0xED000000,0xED400000)"
gArmPlatformTokenSpaceGuid.PcdDefaultBootType|1
-
+
# Use the serial console (ConIn & ConOut) and the Graphic driver (ConOut)
gArmPlatformTokenSpaceGuid.PcdDefaultConOutPaths|L"VenHw(D3987D4B-971A-435F-8CAF-4967EB627241)/Uart(38400,8,N,1)/VenPcAnsi();VenHw(CE660500-824D-11E0-AC72-0002A5D5C51B)"
gArmPlatformTokenSpaceGuid.PcdDefaultConInPaths|L"VenHw(D3987D4B-971A-435F-8CAF-4967EB627241)/Uart(38400,8,N,1)/VenPcAnsi()"
diff --git a/ArmPlatformPkg/ArmVExpressPkg/ArmVExpressPkg.dec b/ArmPlatformPkg/ArmVExpressPkg/ArmVExpressPkg.dec index 2f4e351f5d..f54733a8a4 100644 --- a/ArmPlatformPkg/ArmVExpressPkg/ArmVExpressPkg.dec +++ b/ArmPlatformPkg/ArmVExpressPkg/ArmVExpressPkg.dec @@ -2,21 +2,21 @@ # Arm Versatile Express package.
#
# Copyright (c) 2012, ARM Limited. All rights reserved.
-#
-# This program and the accompanying materials
-# are licensed and made available under the terms and conditions of the BSD License
-# which accompanies this distribution. The full text of the license may be found at
-# http://opensource.org/licenses/bsd-license.php
#
-# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
-# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
+# This program and the accompanying materials
+# are licensed and made available under the terms and conditions of the BSD License
+# which accompanies this distribution. The full text of the license may be found at
+# http://opensource.org/licenses/bsd-license.php
+#
+# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
+# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
#
#**/
[Defines]
DEC_SPECIFICATION = 0x00010005
PACKAGE_NAME = ArmVExpressPkg
- PACKAGE_GUID = 9c0aaed4-74c5-4043-b417-a3223814ce76
+ PACKAGE_GUID = 9c0aaed4-74c5-4043-b417-a3223814ce76
PACKAGE_VERSION = 0.1
################################################################################
diff --git a/ArmPlatformPkg/ArmVExpressPkg/Library/ArmVExpressLibCTA15-A7/ArmVExpressLib.inf b/ArmPlatformPkg/ArmVExpressPkg/Library/ArmVExpressLibCTA15-A7/ArmVExpressLib.inf index a7f93b4f82..10ae6c7f60 100644 --- a/ArmPlatformPkg/ArmVExpressPkg/Library/ArmVExpressLibCTA15-A7/ArmVExpressLib.inf +++ b/ArmPlatformPkg/ArmVExpressPkg/Library/ArmVExpressLibCTA15-A7/ArmVExpressLib.inf @@ -1,14 +1,14 @@ #/* @file
#
# Copyright (c) 2011-2012, ARM Limited. All rights reserved.
-#
-# This program and the accompanying materials
-# are licensed and made available under the terms and conditions of the BSD License
-# which accompanies this distribution. The full text of the license may be found at
-# http://opensource.org/licenses/bsd-license.php
#
-# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
-# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
+# This program and the accompanying materials
+# are licensed and made available under the terms and conditions of the BSD License
+# which accompanies this distribution. The full text of the license may be found at
+# http://opensource.org/licenses/bsd-license.php
+#
+# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
+# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
#
#*/
diff --git a/ArmPlatformPkg/ArmVExpressPkg/Library/ArmVExpressLibCTA15-A7/CTA15-A7.c b/ArmPlatformPkg/ArmVExpressPkg/Library/ArmVExpressLibCTA15-A7/CTA15-A7.c index 32ce23dff7..8b3287b8ef 100644 --- a/ArmPlatformPkg/ArmVExpressPkg/Library/ArmVExpressLibCTA15-A7/CTA15-A7.c +++ b/ArmPlatformPkg/ArmVExpressPkg/Library/ArmVExpressLibCTA15-A7/CTA15-A7.c @@ -1,14 +1,14 @@ /** @file
*
* Copyright (c) 2012, ARM Limited. All rights reserved.
-*
-* This program and the accompanying materials
-* are licensed and made available under the terms and conditions of the BSD License
-* which accompanies this distribution. The full text of the license may be found at
-* http://opensource.org/licenses/bsd-license.php
*
-* THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
-* WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
+* This program and the accompanying materials
+* are licensed and made available under the terms and conditions of the BSD License
+* which accompanies this distribution. The full text of the license may be found at
+* http://opensource.org/licenses/bsd-license.php
+*
+* THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
+* WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
*
**/
diff --git a/ArmPlatformPkg/ArmVExpressPkg/Library/ArmVExpressLibCTA15-A7/CTA15-A7Helper.S b/ArmPlatformPkg/ArmVExpressPkg/Library/ArmVExpressLibCTA15-A7/CTA15-A7Helper.S index ac5378a622..e208a84ca2 100644 --- a/ArmPlatformPkg/ArmVExpressPkg/Library/ArmVExpressLibCTA15-A7/CTA15-A7Helper.S +++ b/ArmPlatformPkg/ArmVExpressPkg/Library/ArmVExpressLibCTA15-A7/CTA15-A7Helper.S @@ -16,7 +16,7 @@ #include <ArmPlatform.h>
-.text
+.text
.align 2
GCC_ASM_EXPORT(ArmPlatformPeiBootAction)
diff --git a/ArmPlatformPkg/ArmVExpressPkg/Library/ArmVExpressLibCTA15-A7/CTA15-A7Mem.c b/ArmPlatformPkg/ArmVExpressPkg/Library/ArmVExpressLibCTA15-A7/CTA15-A7Mem.c index e633c89375..4403cbacb8 100644 --- a/ArmPlatformPkg/ArmVExpressPkg/Library/ArmVExpressLibCTA15-A7/CTA15-A7Mem.c +++ b/ArmPlatformPkg/ArmVExpressPkg/Library/ArmVExpressLibCTA15-A7/CTA15-A7Mem.c @@ -1,14 +1,14 @@ /** @file
*
* Copyright (c) 2012, ARM Limited. All rights reserved.
-*
-* This program and the accompanying materials
-* are licensed and made available under the terms and conditions of the BSD License
-* which accompanies this distribution. The full text of the license may be found at
-* http://opensource.org/licenses/bsd-license.php
*
-* THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
-* WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
+* This program and the accompanying materials
+* are licensed and made available under the terms and conditions of the BSD License
+* which accompanies this distribution. The full text of the license may be found at
+* http://opensource.org/licenses/bsd-license.php
+*
+* THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
+* WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
*
**/
diff --git a/ArmPlatformPkg/ArmVExpressPkg/Library/ArmVExpressLibCTA9x4/ArmVExpressLib.inf b/ArmPlatformPkg/ArmVExpressPkg/Library/ArmVExpressLibCTA9x4/ArmVExpressLib.inf index febc6ddf90..d3c84de16d 100644 --- a/ArmPlatformPkg/ArmVExpressPkg/Library/ArmVExpressLibCTA9x4/ArmVExpressLib.inf +++ b/ArmPlatformPkg/ArmVExpressPkg/Library/ArmVExpressLibCTA9x4/ArmVExpressLib.inf @@ -1,13 +1,13 @@ #/* @file
# Copyright (c) 2011-2013, ARM Limited. All rights reserved.
-#
-# This program and the accompanying materials
-# are licensed and made available under the terms and conditions of the BSD License
-# which accompanies this distribution. The full text of the license may be found at
-# http://opensource.org/licenses/bsd-license.php
#
-# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
-# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
+# This program and the accompanying materials
+# are licensed and made available under the terms and conditions of the BSD License
+# which accompanies this distribution. The full text of the license may be found at
+# http://opensource.org/licenses/bsd-license.php
+#
+# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
+# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
#
#*/
diff --git a/ArmPlatformPkg/ArmVExpressPkg/Library/ArmVExpressLibCTA9x4/ArmVExpressLibSec.inf b/ArmPlatformPkg/ArmVExpressPkg/Library/ArmVExpressLibCTA9x4/ArmVExpressLibSec.inf index 418ee33690..20fc0b7d11 100644 --- a/ArmPlatformPkg/ArmVExpressPkg/Library/ArmVExpressLibCTA9x4/ArmVExpressLibSec.inf +++ b/ArmPlatformPkg/ArmVExpressPkg/Library/ArmVExpressLibCTA9x4/ArmVExpressLibSec.inf @@ -1,13 +1,13 @@ #/* @file
# Copyright (c) 2011-2012, ARM Limited. All rights reserved.
-#
-# This program and the accompanying materials
-# are licensed and made available under the terms and conditions of the BSD License
-# which accompanies this distribution. The full text of the license may be found at
-# http://opensource.org/licenses/bsd-license.php
#
-# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
-# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
+# This program and the accompanying materials
+# are licensed and made available under the terms and conditions of the BSD License
+# which accompanies this distribution. The full text of the license may be found at
+# http://opensource.org/licenses/bsd-license.php
+#
+# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
+# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
#
#*/
diff --git a/ArmPlatformPkg/ArmVExpressPkg/Library/ArmVExpressLibCTA9x4/CTA9x4.c b/ArmPlatformPkg/ArmVExpressPkg/Library/ArmVExpressLibCTA9x4/CTA9x4.c index 60cb09eccc..0af13893f7 100644 --- a/ArmPlatformPkg/ArmVExpressPkg/Library/ArmVExpressLibCTA9x4/CTA9x4.c +++ b/ArmPlatformPkg/ArmVExpressPkg/Library/ArmVExpressLibCTA9x4/CTA9x4.c @@ -1,14 +1,14 @@ /** @file
*
* Copyright (c) 2011-2013, ARM Limited. All rights reserved.
-*
-* This program and the accompanying materials
-* are licensed and made available under the terms and conditions of the BSD License
-* which accompanies this distribution. The full text of the license may be found at
-* http://opensource.org/licenses/bsd-license.php
*
-* THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
-* WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
+* This program and the accompanying materials
+* are licensed and made available under the terms and conditions of the BSD License
+* which accompanies this distribution. The full text of the license may be found at
+* http://opensource.org/licenses/bsd-license.php
+*
+* THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
+* WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
*
**/
diff --git a/ArmPlatformPkg/ArmVExpressPkg/Library/ArmVExpressLibCTA9x4/CTA9x4Helper.S b/ArmPlatformPkg/ArmVExpressPkg/Library/ArmVExpressLibCTA9x4/CTA9x4Helper.S index d419bcfeaf..c4aee741a6 100644 --- a/ArmPlatformPkg/ArmVExpressPkg/Library/ArmVExpressLibCTA9x4/CTA9x4Helper.S +++ b/ArmPlatformPkg/ArmVExpressPkg/Library/ArmVExpressLibCTA9x4/CTA9x4Helper.S @@ -1,13 +1,13 @@ #
# Copyright (c) 2011-2013, ARM Limited. All rights reserved.
-#
-# This program and the accompanying materials
-# are licensed and made available under the terms and conditions of the BSD License
-# which accompanies this distribution. The full text of the license may be found at
+#
+# This program and the accompanying materials
+# are licensed and made available under the terms and conditions of the BSD License
+# which accompanies this distribution. The full text of the license may be found at
# http://opensource.org/licenses/bsd-license.php
#
-# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
-# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
+# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
+# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
#
#
diff --git a/ArmPlatformPkg/ArmVExpressPkg/Library/ArmVExpressLibCTA9x4/CTA9x4Helper.asm b/ArmPlatformPkg/ArmVExpressPkg/Library/ArmVExpressLibCTA9x4/CTA9x4Helper.asm index e969db8744..86e1873e23 100644 --- a/ArmPlatformPkg/ArmVExpressPkg/Library/ArmVExpressLibCTA9x4/CTA9x4Helper.asm +++ b/ArmPlatformPkg/ArmVExpressPkg/Library/ArmVExpressLibCTA9x4/CTA9x4Helper.asm @@ -1,13 +1,13 @@ //
// Copyright (c) 2013, ARM Limited. All rights reserved.
-//
-// This program and the accompanying materials
-// are licensed and made available under the terms and conditions of the BSD License
-// which accompanies this distribution. The full text of the license may be found at
-// http://opensource.org/licenses/bsd-license.php
//
-// THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
-// WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
+// This program and the accompanying materials
+// are licensed and made available under the terms and conditions of the BSD License
+// which accompanies this distribution. The full text of the license may be found at
+// http://opensource.org/licenses/bsd-license.php
+//
+// THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
+// WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
//
//
diff --git a/ArmPlatformPkg/ArmVExpressPkg/Library/ArmVExpressLibCTA9x4/CTA9x4Mem.c b/ArmPlatformPkg/ArmVExpressPkg/Library/ArmVExpressLibCTA9x4/CTA9x4Mem.c index f647d2575a..7ea6e74173 100644 --- a/ArmPlatformPkg/ArmVExpressPkg/Library/ArmVExpressLibCTA9x4/CTA9x4Mem.c +++ b/ArmPlatformPkg/ArmVExpressPkg/Library/ArmVExpressLibCTA9x4/CTA9x4Mem.c @@ -1,14 +1,14 @@ /** @file
*
* Copyright (c) 2011, ARM Limited. All rights reserved.
-*
-* This program and the accompanying materials
-* are licensed and made available under the terms and conditions of the BSD License
-* which accompanies this distribution. The full text of the license may be found at
-* http://opensource.org/licenses/bsd-license.php
*
-* THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
-* WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
+* This program and the accompanying materials
+* are licensed and made available under the terms and conditions of the BSD License
+* which accompanies this distribution. The full text of the license may be found at
+* http://opensource.org/licenses/bsd-license.php
+*
+* THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
+* WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
*
**/
diff --git a/ArmPlatformPkg/ArmVExpressPkg/Library/ArmVExpressLibRTSM/Arm/RTSMHelper.S b/ArmPlatformPkg/ArmVExpressPkg/Library/ArmVExpressLibRTSM/Arm/RTSMHelper.S index 04651e7eaa..00a55e1db3 100644 --- a/ArmPlatformPkg/ArmVExpressPkg/Library/ArmVExpressLibRTSM/Arm/RTSMHelper.S +++ b/ArmPlatformPkg/ArmVExpressPkg/Library/ArmVExpressLibRTSM/Arm/RTSMHelper.S @@ -1,13 +1,13 @@ #
# Copyright (c) 2011-2013, ARM Limited. All rights reserved.
-#
-# This program and the accompanying materials
-# are licensed and made available under the terms and conditions of the BSD License
-# which accompanies this distribution. The full text of the license may be found at
+#
+# This program and the accompanying materials
+# are licensed and made available under the terms and conditions of the BSD License
+# which accompanies this distribution. The full text of the license may be found at
# http://opensource.org/licenses/bsd-license.php
#
-# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
-# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
+# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
+# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
#
#
@@ -113,4 +113,4 @@ ASM_PFX(ArmPlatformGetCorePosition): add r0, r1, r0, LSR #7
bx lr
-ASM_FUNCTION_REMOVE_IF_UNREFERENCED
+ASM_FUNCTION_REMOVE_IF_UNREFERENCED
diff --git a/ArmPlatformPkg/ArmVExpressPkg/Library/ArmVExpressLibRTSM/Arm/RTSMHelper.asm b/ArmPlatformPkg/ArmVExpressPkg/Library/ArmVExpressLibRTSM/Arm/RTSMHelper.asm index bcc56ca56d..d786323f7b 100644 --- a/ArmPlatformPkg/ArmVExpressPkg/Library/ArmVExpressLibRTSM/Arm/RTSMHelper.asm +++ b/ArmPlatformPkg/ArmVExpressPkg/Library/ArmVExpressLibRTSM/Arm/RTSMHelper.asm @@ -1,13 +1,13 @@ //
// Copyright (c) 2011-2013, ARM Limited. All rights reserved.
-//
-// This program and the accompanying materials
-// are licensed and made available under the terms and conditions of the BSD License
-// which accompanies this distribution. The full text of the license may be found at
-// http://opensource.org/licenses/bsd-license.php
//
-// THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
-// WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
+// This program and the accompanying materials
+// are licensed and made available under the terms and conditions of the BSD License
+// which accompanies this distribution. The full text of the license may be found at
+// http://opensource.org/licenses/bsd-license.php
+//
+// THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
+// WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
//
//
diff --git a/ArmPlatformPkg/ArmVExpressPkg/Library/ArmVExpressLibRTSM/ArmVExpressLib.inf b/ArmPlatformPkg/ArmVExpressPkg/Library/ArmVExpressLibRTSM/ArmVExpressLib.inf index 4e8c7aa788..5ee51a3817 100644 --- a/ArmPlatformPkg/ArmVExpressPkg/Library/ArmVExpressLibRTSM/ArmVExpressLib.inf +++ b/ArmPlatformPkg/ArmVExpressPkg/Library/ArmVExpressLibRTSM/ArmVExpressLib.inf @@ -1,13 +1,13 @@ #/* @file
# Copyright (c) 2011-2014, ARM Limited. All rights reserved.
-#
-# This program and the accompanying materials
-# are licensed and made available under the terms and conditions of the BSD License
-# which accompanies this distribution. The full text of the license may be found at
-# http://opensource.org/licenses/bsd-license.php
#
-# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
-# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
+# This program and the accompanying materials
+# are licensed and made available under the terms and conditions of the BSD License
+# which accompanies this distribution. The full text of the license may be found at
+# http://opensource.org/licenses/bsd-license.php
+#
+# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
+# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
#
#*/
@@ -55,5 +55,5 @@ gArmTokenSpaceGuid.PcdArmPrimaryCoreMask
gArmTokenSpaceGuid.PcdArmPrimaryCore
-
+
gArmPlatformTokenSpaceGuid.PcdCoreCount
diff --git a/ArmPlatformPkg/ArmVExpressPkg/Library/ArmVExpressLibRTSM/ArmVExpressLibSec.inf b/ArmPlatformPkg/ArmVExpressPkg/Library/ArmVExpressLibRTSM/ArmVExpressLibSec.inf index c27c2b000a..a535ffd792 100644 --- a/ArmPlatformPkg/ArmVExpressPkg/Library/ArmVExpressLibRTSM/ArmVExpressLibSec.inf +++ b/ArmPlatformPkg/ArmVExpressPkg/Library/ArmVExpressLibRTSM/ArmVExpressLibSec.inf @@ -1,13 +1,13 @@ #/* @file
# Copyright (c) 2011-2012, ARM Limited. All rights reserved.
-#
-# This program and the accompanying materials
-# are licensed and made available under the terms and conditions of the BSD License
-# which accompanies this distribution. The full text of the license may be found at
-# http://opensource.org/licenses/bsd-license.php
#
-# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
-# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
+# This program and the accompanying materials
+# are licensed and made available under the terms and conditions of the BSD License
+# which accompanies this distribution. The full text of the license may be found at
+# http://opensource.org/licenses/bsd-license.php
+#
+# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
+# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
#
#*/
diff --git a/ArmPlatformPkg/ArmVExpressPkg/Library/ArmVExpressLibRTSM/RTSMMem.c b/ArmPlatformPkg/ArmVExpressPkg/Library/ArmVExpressLibRTSM/RTSMMem.c index 77f1857aa0..6c5e494d50 100644 --- a/ArmPlatformPkg/ArmVExpressPkg/Library/ArmVExpressLibRTSM/RTSMMem.c +++ b/ArmPlatformPkg/ArmVExpressPkg/Library/ArmVExpressLibRTSM/RTSMMem.c @@ -1,14 +1,14 @@ /** @file
*
* Copyright (c) 2011-2014, ARM Limited. All rights reserved.
-*
-* This program and the accompanying materials
-* are licensed and made available under the terms and conditions of the BSD License
-* which accompanies this distribution. The full text of the license may be found at
-* http://opensource.org/licenses/bsd-license.php
*
-* THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
-* WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
+* This program and the accompanying materials
+* are licensed and made available under the terms and conditions of the BSD License
+* which accompanies this distribution. The full text of the license may be found at
+* http://opensource.org/licenses/bsd-license.php
+*
+* THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
+* WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
*
**/
diff --git a/ArmPlatformPkg/ArmVExpressPkg/Library/ArmVExpressSecLibCTA9x4/ArmVExpressSecLib.inf b/ArmPlatformPkg/ArmVExpressPkg/Library/ArmVExpressSecLibCTA9x4/ArmVExpressSecLib.inf index 969a75644d..b29168ebcf 100644 --- a/ArmPlatformPkg/ArmVExpressPkg/Library/ArmVExpressSecLibCTA9x4/ArmVExpressSecLib.inf +++ b/ArmPlatformPkg/ArmVExpressPkg/Library/ArmVExpressSecLibCTA9x4/ArmVExpressSecLib.inf @@ -1,13 +1,13 @@ #/* @file
# Copyright (c) 2011-2013, ARM Limited. All rights reserved.
-#
-# This program and the accompanying materials
-# are licensed and made available under the terms and conditions of the BSD License
-# which accompanies this distribution. The full text of the license may be found at
-# http://opensource.org/licenses/bsd-license.php
#
-# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
-# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
+# This program and the accompanying materials
+# are licensed and made available under the terms and conditions of the BSD License
+# which accompanies this distribution. The full text of the license may be found at
+# http://opensource.org/licenses/bsd-license.php
+#
+# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
+# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
#
#*/
diff --git a/ArmPlatformPkg/ArmVExpressPkg/Library/ArmVExpressSecLibCTA9x4/CTA9x4Sec.c b/ArmPlatformPkg/ArmVExpressPkg/Library/ArmVExpressSecLibCTA9x4/CTA9x4Sec.c index eff714cca9..6fa0774f59 100644 --- a/ArmPlatformPkg/ArmVExpressPkg/Library/ArmVExpressSecLibCTA9x4/CTA9x4Sec.c +++ b/ArmPlatformPkg/ArmVExpressPkg/Library/ArmVExpressSecLibCTA9x4/CTA9x4Sec.c @@ -1,14 +1,14 @@ /** @file
*
* Copyright (c) 2011-2013, ARM Limited. All rights reserved.
-*
-* This program and the accompanying materials
-* are licensed and made available under the terms and conditions of the BSD License
-* which accompanies this distribution. The full text of the license may be found at
-* http://opensource.org/licenses/bsd-license.php
*
-* THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
-* WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
+* This program and the accompanying materials
+* are licensed and made available under the terms and conditions of the BSD License
+* which accompanies this distribution. The full text of the license may be found at
+* http://opensource.org/licenses/bsd-license.php
+*
+* THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
+* WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
*
**/
diff --git a/ArmPlatformPkg/ArmVExpressPkg/Library/ArmVExpressSysConfigLib/ArmVExpressSysConfigLib.inf b/ArmPlatformPkg/ArmVExpressPkg/Library/ArmVExpressSysConfigLib/ArmVExpressSysConfigLib.inf index 8d4f52c52e..c1647756ef 100644 --- a/ArmPlatformPkg/ArmVExpressPkg/Library/ArmVExpressSysConfigLib/ArmVExpressSysConfigLib.inf +++ b/ArmPlatformPkg/ArmVExpressPkg/Library/ArmVExpressSysConfigLib/ArmVExpressSysConfigLib.inf @@ -1,17 +1,17 @@ #/** @file
-#
+#
# Component description file for ArmVExpressSysConfigLib module
-#
+#
# Copyright (c) 2011-2012, ARM Ltd. All rights reserved.<BR>
#
# This program and the accompanying materials
# are licensed and made available under the terms and conditions of the BSD License
# which accompanies this distribution. The full text of the license may be found at
# http://opensource.org/licenses/bsd-license.php
-#
+#
# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
-#
+#
#**/
[Defines]
@@ -21,7 +21,7 @@ MODULE_TYPE = BASE
VERSION_STRING = 1.0
LIBRARY_CLASS = ArmPlatformSysConfigLib
-
+
[Sources.common]
ArmVExpressSysConfig.c
diff --git a/ArmPlatformPkg/ArmVExpressPkg/Library/HdLcdArmVExpressLib/HdLcdArmVExpress.c b/ArmPlatformPkg/ArmVExpressPkg/Library/HdLcdArmVExpressLib/HdLcdArmVExpress.c index 04e73099de..a57846715e 100644 --- a/ArmPlatformPkg/ArmVExpressPkg/Library/HdLcdArmVExpressLib/HdLcdArmVExpress.c +++ b/ArmPlatformPkg/ArmVExpressPkg/Library/HdLcdArmVExpressLib/HdLcdArmVExpress.c @@ -1,7 +1,7 @@ /**
Copyright (c) 2012, ARM Ltd. All rights reserved.
-
+
This program and the accompanying materials
are licensed and made available under the terms and conditions of the BSD License
which accompanies this distribution. The full text of the license may be found at
diff --git a/ArmPlatformPkg/ArmVExpressPkg/Library/HdLcdArmVExpressLib/HdLcdArmVExpressLib.inf b/ArmPlatformPkg/ArmVExpressPkg/Library/HdLcdArmVExpressLib/HdLcdArmVExpressLib.inf index 6a1814e095..7807247379 100644 --- a/ArmPlatformPkg/ArmVExpressPkg/Library/HdLcdArmVExpressLib/HdLcdArmVExpressLib.inf +++ b/ArmPlatformPkg/ArmVExpressPkg/Library/HdLcdArmVExpressLib/HdLcdArmVExpressLib.inf @@ -1,17 +1,17 @@ #/** @file
-#
+#
# Component description file for HdLcdArmLib module
-#
+#
# Copyright (c) 2011-2012, ARM Ltd. All rights reserved.<BR>
#
# This program and the accompanying materials
# are licensed and made available under the terms and conditions of the BSD License
# which accompanies this distribution. The full text of the license may be found at
# http://opensource.org/licenses/bsd-license.php
-#
+#
# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
-#
+#
#**/
[Defines]
@@ -21,16 +21,16 @@ MODULE_TYPE = DXE_DRIVER
VERSION_STRING = 1.0
LIBRARY_CLASS = LcdPlatformLib
-
+
[Sources.common]
-
+
HdLcdArmVExpress.c
[Packages]
MdePkg/MdePkg.dec
ArmPlatformPkg/ArmPlatformPkg.dec
ArmPlatformPkg/ArmVExpressPkg/ArmVExpressPkg.dec
-
+
[LibraryClasses]
BaseLib
ArmPlatformSysConfigLib
@@ -41,4 +41,4 @@ HdLcdArmVExpress.c [Pcd]
gArmVExpressTokenSpaceGuid.PcdPL111LcdMaxMode
- gArmVExpressTokenSpaceGuid.PcdHdLcdVideoModeOscId
\ No newline at end of file + gArmVExpressTokenSpaceGuid.PcdHdLcdVideoModeOscId
diff --git a/ArmPlatformPkg/ArmVExpressPkg/Library/NorFlashArmVExpressLib/NorFlashArmVExpressLib.inf b/ArmPlatformPkg/ArmVExpressPkg/Library/NorFlashArmVExpressLib/NorFlashArmVExpressLib.inf index af227d5e65..0798cc30d8 100644 --- a/ArmPlatformPkg/ArmVExpressPkg/Library/NorFlashArmVExpressLib/NorFlashArmVExpressLib.inf +++ b/ArmPlatformPkg/ArmVExpressPkg/Library/NorFlashArmVExpressLib/NorFlashArmVExpressLib.inf @@ -1,14 +1,14 @@ #/** @file
-#
+#
# Copyright (c) 2011, ARM Ltd. All rights reserved.<BR>
# This program and the accompanying materials
# are licensed and made available under the terms and conditions of the BSD License
# which accompanies this distribution. The full text of the license may be found at
# http://opensource.org/licenses/bsd-license.php
-#
+#
# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
-#
+#
#**/
[Defines]
@@ -18,7 +18,7 @@ MODULE_TYPE = DXE_DRIVER
VERSION_STRING = 1.0
LIBRARY_CLASS = NorFlashPlatformLib
-
+
[Sources.common]
NorFlashArmVExpress.c
diff --git a/ArmPlatformPkg/ArmVExpressPkg/Library/PL111LcdArmVExpressLib/PL111LcdArmVExpressLib.inf b/ArmPlatformPkg/ArmVExpressPkg/Library/PL111LcdArmVExpressLib/PL111LcdArmVExpressLib.inf index 2440ea99cf..d1978e7110 100644 --- a/ArmPlatformPkg/ArmVExpressPkg/Library/PL111LcdArmVExpressLib/PL111LcdArmVExpressLib.inf +++ b/ArmPlatformPkg/ArmVExpressPkg/Library/PL111LcdArmVExpressLib/PL111LcdArmVExpressLib.inf @@ -1,17 +1,17 @@ #/** @file
-#
+#
# Component description file for ArmVeGraphicsDxe module
-#
+#
# Copyright (c) 2011-2012, ARM Ltd. All rights reserved.<BR>
#
# This program and the accompanying materials
# are licensed and made available under the terms and conditions of the BSD License
# which accompanies this distribution. The full text of the license may be found at
# http://opensource.org/licenses/bsd-license.php
-#
+#
# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
-#
+#
#**/
[Defines]
@@ -21,7 +21,7 @@ MODULE_TYPE = DXE_DRIVER
VERSION_STRING = 1.0
LIBRARY_CLASS = LcdPlatformLib
-
+
[Sources.common]
PL111LcdArmVExpress.c
diff --git a/ArmPlatformPkg/ArmVExpressPkg/Library/ResetSystemLib/ResetSystemLib.c b/ArmPlatformPkg/ArmVExpressPkg/Library/ResetSystemLib/ResetSystemLib.c index 98203ff081..bafb6f8093 100644 --- a/ArmPlatformPkg/ArmVExpressPkg/Library/ResetSystemLib/ResetSystemLib.c +++ b/ArmPlatformPkg/ArmVExpressPkg/Library/ResetSystemLib/ResetSystemLib.c @@ -73,7 +73,7 @@ LibResetSystem ( @param ImageHandle The firmware allocated handle for the EFI image.
@param SystemTable A pointer to the EFI System Table.
-
+
@retval EFI_SUCCESS The constructor always returns EFI_SUCCESS.
**/
diff --git a/ArmPlatformPkg/ArmVExpressPkg/Library/ResetSystemLib/ResetSystemLib.inf b/ArmPlatformPkg/ArmVExpressPkg/Library/ResetSystemLib/ResetSystemLib.inf index 8dbd1c869b..8c17ea8cdb 100644 --- a/ArmPlatformPkg/ArmVExpressPkg/Library/ResetSystemLib/ResetSystemLib.inf +++ b/ArmPlatformPkg/ArmVExpressPkg/Library/ResetSystemLib/ResetSystemLib.inf @@ -16,7 +16,7 @@ [Defines]
INF_VERSION = 0x00010005
BASE_NAME = ArmVeResetSystemLib
- FILE_GUID = 36885202-0854-4373-bfd2-95d229b44d44
+ FILE_GUID = 36885202-0854-4373-bfd2-95d229b44d44
MODULE_TYPE = BASE
VERSION_STRING = 1.0
LIBRARY_CLASS = EfiResetSystemLib
diff --git a/ArmPlatformPkg/Bds/BdsHelper.c b/ArmPlatformPkg/Bds/BdsHelper.c index d051f074ee..27180d9783 100644 --- a/ArmPlatformPkg/Bds/BdsHelper.c +++ b/ArmPlatformPkg/Bds/BdsHelper.c @@ -1,14 +1,14 @@ /** @file
*
* Copyright (c) 2011 - 2014, ARM Limited. All rights reserved.
-*
-* This program and the accompanying materials
-* are licensed and made available under the terms and conditions of the BSD License
-* which accompanies this distribution. The full text of the license may be found at
-* http://opensource.org/licenses/bsd-license.php
*
-* THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
-* WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
+* This program and the accompanying materials
+* are licensed and made available under the terms and conditions of the BSD License
+* which accompanies this distribution. The full text of the license may be found at
+* http://opensource.org/licenses/bsd-license.php
+*
+* THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
+* WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
*
**/
diff --git a/ArmPlatformPkg/Bds/BootOptionSupport.c b/ArmPlatformPkg/Bds/BootOptionSupport.c index d54361af04..86cfa45efa 100644 --- a/ArmPlatformPkg/Bds/BootOptionSupport.c +++ b/ArmPlatformPkg/Bds/BootOptionSupport.c @@ -429,7 +429,7 @@ BdsLoadOptionFileSystemUpdateDevicePath ( DevicePath = DuplicateDevicePath (OldDevicePath);
EndingDevicePath = (FILEPATH_DEVICE_PATH*)GetLastDevicePathNode (DevicePath);
-
+
Print(L"File path of the %s: ", FileName);
StrnCpy (BootFilePath, EndingDevicePath->PathName, BOOT_DEVICE_FILEPATH_MAX);
Status = EditHIInputStr (BootFilePath, BOOT_DEVICE_FILEPATH_MAX);
diff --git a/ArmPlatformPkg/Drivers/ArmTrustZone/ArmTrustZone.c b/ArmPlatformPkg/Drivers/ArmTrustZone/ArmTrustZone.c index 26d4004f69..070c0dcb5d 100644 --- a/ArmPlatformPkg/Drivers/ArmTrustZone/ArmTrustZone.c +++ b/ArmPlatformPkg/Drivers/ArmTrustZone/ArmTrustZone.c @@ -1,14 +1,14 @@ /** @file
*
* Copyright (c) 2011-2012, ARM Limited. All rights reserved.
-*
-* This program and the accompanying materials
-* are licensed and made available under the terms and conditions of the BSD License
-* which accompanies this distribution. The full text of the license may be found at
-* http://opensource.org/licenses/bsd-license.php
*
-* THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
-* WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
+* This program and the accompanying materials
+* are licensed and made available under the terms and conditions of the BSD License
+* which accompanies this distribution. The full text of the license may be found at
+* http://opensource.org/licenses/bsd-license.php
+*
+* THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
+* WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
*
**/
diff --git a/ArmPlatformPkg/Drivers/ArmTrustZone/ArmTrustZone.inf b/ArmPlatformPkg/Drivers/ArmTrustZone/ArmTrustZone.inf index 176224bf46..6f90589a5b 100644 --- a/ArmPlatformPkg/Drivers/ArmTrustZone/ArmTrustZone.inf +++ b/ArmPlatformPkg/Drivers/ArmTrustZone/ArmTrustZone.inf @@ -1,13 +1,13 @@ #/* @file
# Copyright (c) 2011-2012, ARM Limited. All rights reserved.
-#
-# This program and the accompanying materials
-# are licensed and made available under the terms and conditions of the BSD License
-# which accompanies this distribution. The full text of the license may be found at
-# http://opensource.org/licenses/bsd-license.php
#
-# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
-# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
+# This program and the accompanying materials
+# are licensed and made available under the terms and conditions of the BSD License
+# which accompanies this distribution. The full text of the license may be found at
+# http://opensource.org/licenses/bsd-license.php
+#
+# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
+# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
#
#*/
diff --git a/ArmPlatformPkg/Drivers/LcdGraphicsOutputDxe/HdLcdGraphicsOutputDxe.inf b/ArmPlatformPkg/Drivers/LcdGraphicsOutputDxe/HdLcdGraphicsOutputDxe.inf index 8de4752b72..462d1fa402 100644 --- a/ArmPlatformPkg/Drivers/LcdGraphicsOutputDxe/HdLcdGraphicsOutputDxe.inf +++ b/ArmPlatformPkg/Drivers/LcdGraphicsOutputDxe/HdLcdGraphicsOutputDxe.inf @@ -1,17 +1,17 @@ #/** @file
-#
+#
# Component description file for HDLCD module
-#
+#
# Copyright (c) 2011-2012, ARM Ltd. All rights reserved.<BR>
-#
+#
# This program and the accompanying materials
# are licensed and made available under the terms and conditions of the BSD License
# which accompanies this distribution. The full text of the license may be found at
# http://opensource.org/licenses/bsd-license.php
-#
+#
# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
-#
+#
#**/
[Defines]
@@ -51,7 +51,7 @@ gEfiGraphicsOutputProtocolGuid # Produced
gEfiEdidDiscoveredProtocolGuid # Produced
gEfiEdidActiveProtocolGuid # Produced
- gEfiEdidOverrideProtocolGuid # Produced
+ gEfiEdidOverrideProtocolGuid # Produced
[FixedPcd]
gArmPlatformTokenSpaceGuid.PcdArmHdLcdBase
diff --git a/ArmPlatformPkg/Drivers/LcdGraphicsOutputDxe/PL111LcdGraphicsOutputDxe.inf b/ArmPlatformPkg/Drivers/LcdGraphicsOutputDxe/PL111LcdGraphicsOutputDxe.inf index 27f00617e4..003cc2ffa9 100644 --- a/ArmPlatformPkg/Drivers/LcdGraphicsOutputDxe/PL111LcdGraphicsOutputDxe.inf +++ b/ArmPlatformPkg/Drivers/LcdGraphicsOutputDxe/PL111LcdGraphicsOutputDxe.inf @@ -1,16 +1,16 @@ #/** @file
-#
+#
# Component description file for PL111LcdGraphicsOutputDxe module
-#
+#
# Copyright (c) 2011-2012, ARM Ltd. All rights reserved.<BR>
# This program and the accompanying materials
# are licensed and made available under the terms and conditions of the BSD License
# which accompanies this distribution. The full text of the license may be found at
# http://opensource.org/licenses/bsd-license.php
-#
+#
# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
-#
+#
#**/
[Defines]
diff --git a/ArmPlatformPkg/Drivers/NorFlashDxe/NorFlashDxe.inf b/ArmPlatformPkg/Drivers/NorFlashDxe/NorFlashDxe.inf index 3003e1213d..a161c0399e 100644 --- a/ArmPlatformPkg/Drivers/NorFlashDxe/NorFlashDxe.inf +++ b/ArmPlatformPkg/Drivers/NorFlashDxe/NorFlashDxe.inf @@ -1,17 +1,17 @@ #/** @file
-#
+#
# Component description file for NorFlashDxe module
-#
+#
# Copyright (c) 2011 - 2014, ARM Ltd. All rights reserved.<BR>
-#
+#
# This program and the accompanying materials
# are licensed and made available under the terms and conditions of the BSD License
# which accompanies this distribution. The full text of the license may be found at
# http://opensource.org/licenses/bsd-license.php
-#
+#
# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
-#
+#
#**/
[Defines]
@@ -54,7 +54,7 @@ gEfiDevicePathProtocolGuid
gEfiFirmwareVolumeBlockProtocolGuid
gEfiDiskIoProtocolGuid
-
+
[Pcd.common]
gEfiMdeModulePkgTokenSpaceGuid.PcdFlashNvStorageVariableBase
gEfiMdeModulePkgTokenSpaceGuid.PcdFlashNvStorageVariableSize
@@ -62,11 +62,11 @@ gEfiMdeModulePkgTokenSpaceGuid.PcdFlashNvStorageFtwWorkingSize
gEfiMdeModulePkgTokenSpaceGuid.PcdFlashNvStorageFtwSpareBase
gEfiMdeModulePkgTokenSpaceGuid.PcdFlashNvStorageFtwSpareSize
-
+
gArmPlatformTokenSpaceGuid.PcdNorFlashCheckBlockLocked
[Depex]
#
# NorFlashDxe must be loaded before VariableRuntimeDxe in case empty flash needs populating with default values
- #
- BEFORE gVariableRuntimeDxeFileGuid
+ #
+ BEFORE gVariableRuntimeDxeFileGuid
diff --git a/ArmPlatformPkg/Drivers/NorFlashDxe/NorFlashFvbDxe.c b/ArmPlatformPkg/Drivers/NorFlashDxe/NorFlashFvbDxe.c index efe87e57fd..a844025a1f 100644 --- a/ArmPlatformPkg/Drivers/NorFlashDxe/NorFlashFvbDxe.c +++ b/ArmPlatformPkg/Drivers/NorFlashDxe/NorFlashFvbDxe.c @@ -728,7 +728,7 @@ NorFlashFvbInitialize ( Status = ValidateFvHeader (Instance);
}
- // Install the Default FVB header if required
+ // Install the Default FVB header if required
if (EFI_ERROR(Status)) {
// There is no valid header, so time to install one.
DEBUG((EFI_D_ERROR,"NorFlashFvbInitialize: ERROR - The FVB Header is not valid. Installing a correct one for this volume.\n"));
diff --git a/ArmPlatformPkg/Drivers/PL011Uart/PL011Uart.c b/ArmPlatformPkg/Drivers/PL011Uart/PL011Uart.c index 9361205b19..fd686799b2 100644 --- a/ArmPlatformPkg/Drivers/PL011Uart/PL011Uart.c +++ b/ArmPlatformPkg/Drivers/PL011Uart/PL011Uart.c @@ -313,7 +313,7 @@ PL011UartWrite ( while (Buffer < Final) {
// Wait until UART able to accept another char
while ((MmioRead32 (UartBase + UARTFR) & UART_TX_FULL_FLAG_MASK));
-
+
MmioWrite8 (UartBase + UARTDR, *Buffer++);
}
diff --git a/ArmPlatformPkg/Drivers/PL011Uart/PL011Uart.inf b/ArmPlatformPkg/Drivers/PL011Uart/PL011Uart.inf index 7f7709aecf..18df7c9fb9 100644 --- a/ArmPlatformPkg/Drivers/PL011Uart/PL011Uart.inf +++ b/ArmPlatformPkg/Drivers/PL011Uart/PL011Uart.inf @@ -1,23 +1,23 @@ #/** @file
-#
+#
# Component description file for PL011Uart module
-#
+#
# Copyright (c) 2011-2013, ARM Ltd. All rights reserved.<BR>
-#
+#
# This program and the accompanying materials
# are licensed and made available under the terms and conditions of the BSD License
# which accompanies this distribution. The full text of the license may be found at
# http://opensource.org/licenses/bsd-license.php
-#
+#
# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
-#
+#
#**/
[Defines]
INF_VERSION = 0x00010005
BASE_NAME = PL011Uart
- FILE_GUID = 4ec8b120-8307-11e0-bc91-0002a5d5c51b
+ FILE_GUID = 4ec8b120-8307-11e0-bc91-0002a5d5c51b
MODULE_TYPE = BASE
VERSION_STRING = 1.0
LIBRARY_CLASS = PL011UartLib
diff --git a/ArmPlatformPkg/Drivers/PL061GpioDxe/PL061GpioDxe.inf b/ArmPlatformPkg/Drivers/PL061GpioDxe/PL061GpioDxe.inf index 49284d0a07..9d9e4cd678 100644 --- a/ArmPlatformPkg/Drivers/PL061GpioDxe/PL061GpioDxe.inf +++ b/ArmPlatformPkg/Drivers/PL061GpioDxe/PL061GpioDxe.inf @@ -1,14 +1,14 @@ /** @file
*
* Copyright (c) 2011, ARM Limited. All rights reserved.
-*
-* This program and the accompanying materials
-* are licensed and made available under the terms and conditions of the BSD License
-* which accompanies this distribution. The full text of the license may be found at
-* http://opensource.org/licenses/bsd-license.php
*
-* THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
-* WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
+* This program and the accompanying materials
+* are licensed and made available under the terms and conditions of the BSD License
+* which accompanies this distribution. The full text of the license may be found at
+* http://opensource.org/licenses/bsd-license.php
+*
+* THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
+* WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
*
**/
@@ -44,7 +44,7 @@ gArmPlatformTokenSpaceGuid.PcdPL061GpioBase
[Protocols]
- gEmbeddedGpioProtocolGuid
+ gEmbeddedGpioProtocolGuid
[Depex]
TRUE
diff --git a/ArmPlatformPkg/Drivers/PL180MciDxe/PL180Mci.c b/ArmPlatformPkg/Drivers/PL180MciDxe/PL180Mci.c index f7a4d44311..411a61ed04 100644 --- a/ArmPlatformPkg/Drivers/PL180MciDxe/PL180Mci.c +++ b/ArmPlatformPkg/Drivers/PL180MciDxe/PL180Mci.c @@ -2,14 +2,14 @@ This file implement the MMC Host Protocol for the ARM PrimeCell PL180.
Copyright (c) 2011-2012, ARM Limited. All rights reserved.
-
- This program and the accompanying materials
- are licensed and made available under the terms and conditions of the BSD License
- which accompanies this distribution. The full text of the license may be found at
- http://opensource.org/licenses/bsd-license.php
- THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
- WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
+ This program and the accompanying materials
+ are licensed and made available under the terms and conditions of the BSD License
+ which accompanies this distribution. The full text of the license may be found at
+ http://opensource.org/licenses/bsd-license.php
+
+ THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
+ WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
**/
@@ -157,7 +157,7 @@ MciSendCommand ( if ((Status & MCI_STATUS_CMD_ERROR)) {
// Clear Status register error flags
MmioWrite32 (MCI_CLEAR_STATUS_REG, MCI_STATUS_CMD_ERROR);
-
+
if ((Status & MCI_STATUS_CMD_START_BIT_ERROR)) {
DEBUG ((EFI_D_ERROR, "MciSendCommand(CmdIndex:%d) Start bit Error! Response:0x%X Status:0x%x\n", (Cmd & 0x3F), MmioRead32 (MCI_RESPONSE0_REG), Status));
RetVal = EFI_NO_RESPONSE;
@@ -224,7 +224,7 @@ MciReadBlockData ( // Read data from the RX FIFO
Loop = 0;
Finish = MMCI0_BLOCKLEN / 4;
-
+
// Raise the TPL at the highest level to disable Interrupts.
Tpl = gBS->RaiseTPL (TPL_HIGH_LEVEL);
@@ -527,7 +527,7 @@ PL180MciDxeInitialize ( //Publish Component Name, BlockIO protocol interfaces
Status = gBS->InstallMultipleProtocolInterfaces (
- &Handle,
+ &Handle,
&gEfiMmcHostProtocolGuid, &gMciHost,
NULL
);
diff --git a/ArmPlatformPkg/Drivers/PL180MciDxe/PL180Mci.h b/ArmPlatformPkg/Drivers/PL180MciDxe/PL180Mci.h index 63c567d476..6dc155ee9a 100644 --- a/ArmPlatformPkg/Drivers/PL180MciDxe/PL180Mci.h +++ b/ArmPlatformPkg/Drivers/PL180MciDxe/PL180Mci.h @@ -2,14 +2,14 @@ Header for the MMC Host Protocol implementation for the ARM PrimeCell PL180.
Copyright (c) 2011-2012, ARM Limited. All rights reserved.
-
- This program and the accompanying materials
- are licensed and made available under the terms and conditions of the BSD License
- which accompanies this distribution. The full text of the license may be found at
- http://opensource.org/licenses/bsd-license.php
-
- THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
- WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
+
+ This program and the accompanying materials
+ are licensed and made available under the terms and conditions of the BSD License
+ which accompanies this distribution. The full text of the license may be found at
+ http://opensource.org/licenses/bsd-license.php
+
+ THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
+ WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
**/
diff --git a/ArmPlatformPkg/Drivers/PL180MciDxe/PL180MciDxe.inf b/ArmPlatformPkg/Drivers/PL180MciDxe/PL180MciDxe.inf index b6d72e77a4..418fbac78a 100755 --- a/ArmPlatformPkg/Drivers/PL180MciDxe/PL180MciDxe.inf +++ b/ArmPlatformPkg/Drivers/PL180MciDxe/PL180MciDxe.inf @@ -2,14 +2,14 @@ # INF file for the MMC Host Protocol implementation for the ARM PrimeCell PL180.
#
# Copyright (c) 2011, ARM Limited. All rights reserved.
-#
-# This program and the accompanying materials
-# are licensed and made available under the terms and conditions of the BSD License
-# which accompanies this distribution. The full text of the license may be found at
-# http://opensource.org/licenses/bsd-license.php
#
-# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
-# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
+# This program and the accompanying materials
+# are licensed and made available under the terms and conditions of the BSD License
+# which accompanies this distribution. The full text of the license may be found at
+# http://opensource.org/licenses/bsd-license.php
+#
+# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
+# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
#
#**/
@@ -43,10 +43,10 @@ gEfiCpuArchProtocolGuid
gEfiDevicePathProtocolGuid
gEfiMmcHostProtocolGuid
-
+
[Pcd]
gArmPlatformTokenSpaceGuid.PcdPL180SysMciRegAddress
gArmPlatformTokenSpaceGuid.PcdPL180MciBaseAddress
-
+
[Depex]
TRUE
diff --git a/ArmPlatformPkg/Drivers/PL301Axi/PL301Axi.c b/ArmPlatformPkg/Drivers/PL301Axi/PL301Axi.c index 7241f5cef2..8600721c58 100644 --- a/ArmPlatformPkg/Drivers/PL301Axi/PL301Axi.c +++ b/ArmPlatformPkg/Drivers/PL301Axi/PL301Axi.c @@ -1,14 +1,14 @@ /** @file
*
* Copyright (c) 2011, ARM Limited. All rights reserved.
-*
-* This program and the accompanying materials
-* are licensed and made available under the terms and conditions of the BSD License
-* which accompanies this distribution. The full text of the license may be found at
-* http://opensource.org/licenses/bsd-license.php
*
-* THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
-* WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
+* This program and the accompanying materials
+* are licensed and made available under the terms and conditions of the BSD License
+* which accompanies this distribution. The full text of the license may be found at
+* http://opensource.org/licenses/bsd-license.php
+*
+* THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
+* WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
*
**/
@@ -61,14 +61,14 @@ VOID PL301AxiInit(UINTN FAxiBase) { // Configure the Access Control Register (MI 0)
FAxiWriteReg(PL301_QOS_ACCESSCONTROL_MI_0, V2P_CA9_FAXI_MI0_ACCESSCNTRL_VAL);
- // MP0
+ // MP0
// Set priority for Read
FAxiWriteReg(PL301_AR_ARB_MI_0, 0x00000100);
FAxiWriteReg(PL301_AR_ARB_MI_0, 0x01000200);
FAxiWriteReg(PL301_AR_ARB_MI_0, 0x02000200);
FAxiWriteReg(PL301_AR_ARB_MI_0, 0x03000200);
FAxiWriteReg(PL301_AR_ARB_MI_0, 0x04000200);
-
+
// Set priority for Write
FAxiWriteReg(PL301_AW_ARB_MI_0, 0x00000100);
FAxiWriteReg(PL301_AW_ARB_MI_0, 0x01000200);
@@ -98,7 +98,7 @@ VOID PL301AxiInit(UINTN FAxiBase) { FAxiWriteReg(PL301_AR_ARB_MI_2, 0x02000100);
FAxiWriteReg(PL301_AR_ARB_MI_2, 0x03000100);
FAxiWriteReg(PL301_AR_ARB_MI_2, 0x04000100);
-
+
// Set priority for Write
FAxiWriteReg(PL301_AW_ARB_MI_2, 0x00000100);
FAxiWriteReg(PL301_AW_ARB_MI_2, 0x01000200);
diff --git a/ArmPlatformPkg/Drivers/PL301Axi/PL301Axi.inf b/ArmPlatformPkg/Drivers/PL301Axi/PL301Axi.inf index c0fa4d1ca9..108161fc16 100755 --- a/ArmPlatformPkg/Drivers/PL301Axi/PL301Axi.inf +++ b/ArmPlatformPkg/Drivers/PL301Axi/PL301Axi.inf @@ -1,13 +1,13 @@ #/* @file
# Copyright (c) 2011, ARM Limited. All rights reserved.
-#
-# This program and the accompanying materials
-# are licensed and made available under the terms and conditions of the BSD License
-# which accompanies this distribution. The full text of the license may be found at
-# http://opensource.org/licenses/bsd-license.php
#
-# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
-# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
+# This program and the accompanying materials
+# are licensed and made available under the terms and conditions of the BSD License
+# which accompanies this distribution. The full text of the license may be found at
+# http://opensource.org/licenses/bsd-license.php
+#
+# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
+# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
#
#*/
diff --git a/ArmPlatformPkg/Drivers/PL310L2Cache/PL310L2Cache.c b/ArmPlatformPkg/Drivers/PL310L2Cache/PL310L2Cache.c index b701978da5..1a6ab33720 100644 --- a/ArmPlatformPkg/Drivers/PL310L2Cache/PL310L2Cache.c +++ b/ArmPlatformPkg/Drivers/PL310L2Cache/PL310L2Cache.c @@ -1,14 +1,14 @@ /** @file
*
* Copyright (c) 2011, ARM Limited. All rights reserved.
-*
-* This program and the accompanying materials
-* are licensed and made available under the terms and conditions of the BSD License
-* which accompanies this distribution. The full text of the license may be found at
-* http://opensource.org/licenses/bsd-license.php
*
-* THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
-* WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
+* This program and the accompanying materials
+* are licensed and made available under the terms and conditions of the BSD License
+* which accompanies this distribution. The full text of the license may be found at
+* http://opensource.org/licenses/bsd-license.php
+*
+* THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
+* WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
*
**/
diff --git a/ArmPlatformPkg/Drivers/PL310L2Cache/PL310L2CacheSec.inf b/ArmPlatformPkg/Drivers/PL310L2Cache/PL310L2CacheSec.inf index 1a95aa85fe..78f952a1d0 100755 --- a/ArmPlatformPkg/Drivers/PL310L2Cache/PL310L2CacheSec.inf +++ b/ArmPlatformPkg/Drivers/PL310L2Cache/PL310L2CacheSec.inf @@ -1,13 +1,13 @@ #/* @file
# Copyright (c) 2011, ARM Limited. All rights reserved.
-#
-# This program and the accompanying materials
-# are licensed and made available under the terms and conditions of the BSD License
-# which accompanies this distribution. The full text of the license may be found at
-# http://opensource.org/licenses/bsd-license.php
#
-# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
-# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
+# This program and the accompanying materials
+# are licensed and made available under the terms and conditions of the BSD License
+# which accompanies this distribution. The full text of the license may be found at
+# http://opensource.org/licenses/bsd-license.php
+#
+# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
+# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
#
#*/
diff --git a/ArmPlatformPkg/Drivers/PL34xDmc/PL341Dmc.c b/ArmPlatformPkg/Drivers/PL34xDmc/PL341Dmc.c index 95f59eb661..08eba6ec69 100644 --- a/ArmPlatformPkg/Drivers/PL34xDmc/PL341Dmc.c +++ b/ArmPlatformPkg/Drivers/PL34xDmc/PL341Dmc.c @@ -1,14 +1,14 @@ /** @file
*
* Copyright (c) 2011, ARM Limited. All rights reserved.
-*
-* This program and the accompanying materials
-* are licensed and made available under the terms and conditions of the BSD License
-* which accompanies this distribution. The full text of the license may be found at
-* http://opensource.org/licenses/bsd-license.php
*
-* THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
-* WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
+* This program and the accompanying materials
+* are licensed and made available under the terms and conditions of the BSD License
+* which accompanies this distribution. The full text of the license may be found at
+* http://opensource.org/licenses/bsd-license.php
+*
+* THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
+* WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
*
**/
diff --git a/ArmPlatformPkg/Drivers/PL34xDmc/PL341Dmc.inf b/ArmPlatformPkg/Drivers/PL34xDmc/PL341Dmc.inf index c24cf3e062..0f3d862e14 100755 --- a/ArmPlatformPkg/Drivers/PL34xDmc/PL341Dmc.inf +++ b/ArmPlatformPkg/Drivers/PL34xDmc/PL341Dmc.inf @@ -1,13 +1,13 @@ #/* @file
# Copyright (c) 2011, ARM Limited. All rights reserved.
-#
-# This program and the accompanying materials
-# are licensed and made available under the terms and conditions of the BSD License
-# which accompanies this distribution. The full text of the license may be found at
-# http://opensource.org/licenses/bsd-license.php
#
-# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
-# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
+# This program and the accompanying materials
+# are licensed and made available under the terms and conditions of the BSD License
+# which accompanies this distribution. The full text of the license may be found at
+# http://opensource.org/licenses/bsd-license.php
+#
+# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
+# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
#
#*/
diff --git a/ArmPlatformPkg/Drivers/PL35xSmc/InitializeSMC.S b/ArmPlatformPkg/Drivers/PL35xSmc/InitializeSMC.S index 3630389f81..a26a4d4377 100755 --- a/ArmPlatformPkg/Drivers/PL35xSmc/InitializeSMC.S +++ b/ArmPlatformPkg/Drivers/PL35xSmc/InitializeSMC.S @@ -1,13 +1,13 @@ #
# Copyright (c) 2011-2012, ARM Limited. All rights reserved.
-#
-# This program and the accompanying materials
-# are licensed and made available under the terms and conditions of the BSD License
-# which accompanies this distribution. The full text of the license may be found at
-# http://opensource.org/licenses/bsd-license.php
#
-# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
-# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
+# This program and the accompanying materials
+# are licensed and made available under the terms and conditions of the BSD License
+# which accompanies this distribution. The full text of the license may be found at
+# http://opensource.org/licenses/bsd-license.php
+#
+# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
+# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
#
#
diff --git a/ArmPlatformPkg/Drivers/PL35xSmc/InitializeSMC.asm b/ArmPlatformPkg/Drivers/PL35xSmc/InitializeSMC.asm index fd6f6e6a13..661b0688c8 100755 --- a/ArmPlatformPkg/Drivers/PL35xSmc/InitializeSMC.asm +++ b/ArmPlatformPkg/Drivers/PL35xSmc/InitializeSMC.asm @@ -1,13 +1,13 @@ //
// Copyright (c) 2011-2012, ARM Limited. All rights reserved.
-//
-// This program and the accompanying materials
-// are licensed and made available under the terms and conditions of the BSD License
-// which accompanies this distribution. The full text of the license may be found at
-// http://opensource.org/licenses/bsd-license.php
//
-// THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
-// WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
+// This program and the accompanying materials
+// are licensed and made available under the terms and conditions of the BSD License
+// which accompanies this distribution. The full text of the license may be found at
+// http://opensource.org/licenses/bsd-license.php
+//
+// THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
+// WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
//
//
@@ -17,13 +17,13 @@ #include <AutoGen.h>
INCLUDE AsmMacroIoLib.inc
-
+
EXPORT PL35xSmcInitialize
EXPORT PL35xSmcSetRefresh
PRESERVE8
AREA ModuleInitializeSMC, CODE, READONLY
-
+
// IN r1 Smc Base Address
// IN r2 Smc Configuration Start Address
// IN r3 Smc Configuration End Address
diff --git a/ArmPlatformPkg/Drivers/PL35xSmc/PL35xSmc.inf b/ArmPlatformPkg/Drivers/PL35xSmc/PL35xSmc.inf index 3960d49756..2eee5ab505 100755 --- a/ArmPlatformPkg/Drivers/PL35xSmc/PL35xSmc.inf +++ b/ArmPlatformPkg/Drivers/PL35xSmc/PL35xSmc.inf @@ -1,13 +1,13 @@ #/* @file
# Copyright (c) 2011, ARM Limited. All rights reserved.
-#
-# This program and the accompanying materials
-# are licensed and made available under the terms and conditions of the BSD License
-# which accompanies this distribution. The full text of the license may be found at
-# http://opensource.org/licenses/bsd-license.php
#
-# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
-# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
+# This program and the accompanying materials
+# are licensed and made available under the terms and conditions of the BSD License
+# which accompanies this distribution. The full text of the license may be found at
+# http://opensource.org/licenses/bsd-license.php
+#
+# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
+# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
#
#*/
diff --git a/ArmPlatformPkg/Drivers/SP804TimerDxe/SP804Timer.c b/ArmPlatformPkg/Drivers/SP804TimerDxe/SP804Timer.c index 839d34d414..7ae25e9bb9 100644 --- a/ArmPlatformPkg/Drivers/SP804TimerDxe/SP804Timer.c +++ b/ArmPlatformPkg/Drivers/SP804TimerDxe/SP804Timer.c @@ -3,14 +3,14 @@ Copyright (c) 2008 - 2009, Apple Inc. All rights reserved.<BR>
Copyright (c) 2011 - 2012, ARM Ltd. All rights reserved.<BR>
-
- This program and the accompanying materials
- are licensed and made available under the terms and conditions of the BSD License
- which accompanies this distribution. The full text of the license may be found at
- http://opensource.org/licenses/bsd-license.php
- THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
- WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
+ This program and the accompanying materials
+ are licensed and made available under the terms and conditions of the BSD License
+ which accompanies this distribution. The full text of the license may be found at
+ http://opensource.org/licenses/bsd-license.php
+
+ THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
+ WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
**/
@@ -57,7 +57,7 @@ UINTN gVector; what source means.
@param SystemContext Pointer to system register context. Mostly used by debuggers and will
- update the system context after the return from the interrupt if
+ update the system context after the return from the interrupt if
modified. Don't change these values unless you know what you are doing
**/
@@ -65,15 +65,15 @@ VOID EFIAPI
TimerInterruptHandler (
IN HARDWARE_INTERRUPT_SOURCE Source,
- IN EFI_SYSTEM_CONTEXT SystemContext
+ IN EFI_SYSTEM_CONTEXT SystemContext
)
{
EFI_TPL OriginalTPL;
//
- // DXE core uses this callback for the EFI timer tick. The DXE core uses locks
+ // DXE core uses this callback for the EFI timer tick. The DXE core uses locks
// that raise to TPL_HIGH and then restore back to current level. Thus we need
- // to make sure TPL level is set to TPL_HIGH while we are handling the timer tick.
+ // to make sure TPL level is set to TPL_HIGH while we are handling the timer tick.
//
OriginalTPL = gBS->RaiseTPL (TPL_HIGH_LEVEL);
@@ -94,16 +94,16 @@ TimerInterruptHandler ( }
/**
- This function registers the handler NotifyFunction so it is called every time
- the timer interrupt fires. It also passes the amount of time since the last
- handler call to the NotifyFunction. If NotifyFunction is NULL, then the
- handler is unregistered. If the handler is registered, then EFI_SUCCESS is
- returned. If the CPU does not support registering a timer interrupt handler,
- then EFI_UNSUPPORTED is returned. If an attempt is made to register a handler
- when a handler is already registered, then EFI_ALREADY_STARTED is returned.
- If an attempt is made to unregister a handler when a handler is not registered,
- then EFI_INVALID_PARAMETER is returned. If an error occurs attempting to
- register the NotifyFunction with the timer interrupt, then EFI_DEVICE_ERROR
+ This function registers the handler NotifyFunction so it is called every time
+ the timer interrupt fires. It also passes the amount of time since the last
+ handler call to the NotifyFunction. If NotifyFunction is NULL, then the
+ handler is unregistered. If the handler is registered, then EFI_SUCCESS is
+ returned. If the CPU does not support registering a timer interrupt handler,
+ then EFI_UNSUPPORTED is returned. If an attempt is made to register a handler
+ when a handler is already registered, then EFI_ALREADY_STARTED is returned.
+ If an attempt is made to unregister a handler when a handler is not registered,
+ then EFI_INVALID_PARAMETER is returned. If an error occurs attempting to
+ register the NotifyFunction with the timer interrupt, then EFI_DEVICE_ERROR
is returned.
@param This The EFI_TIMER_ARCH_PROTOCOL instance.
@@ -169,17 +169,17 @@ ExitBootServicesEvent ( /**
- This function adjusts the period of timer interrupts to the value specified
- by TimerPeriod. If the timer period is updated, then the selected timer
- period is stored in EFI_TIMER.TimerPeriod, and EFI_SUCCESS is returned. If
- the timer hardware is not programmable, then EFI_UNSUPPORTED is returned.
- If an error occurs while attempting to update the timer period, then the
- timer hardware will be put back in its state prior to this call, and
- EFI_DEVICE_ERROR is returned. If TimerPeriod is 0, then the timer interrupt
- is disabled. This is not the same as disabling the CPU's interrupts.
- Instead, it must either turn off the timer hardware, or it must adjust the
- interrupt controller so that a CPU interrupt is not generated when the timer
- interrupt fires.
+ This function adjusts the period of timer interrupts to the value specified
+ by TimerPeriod. If the timer period is updated, then the selected timer
+ period is stored in EFI_TIMER.TimerPeriod, and EFI_SUCCESS is returned. If
+ the timer hardware is not programmable, then EFI_UNSUPPORTED is returned.
+ If an error occurs while attempting to update the timer period, then the
+ timer hardware will be put back in its state prior to this call, and
+ EFI_DEVICE_ERROR is returned. If TimerPeriod is 0, then the timer interrupt
+ is disabled. This is not the same as disabling the CPU's interrupts.
+ Instead, it must either turn off the timer hardware, or it must adjust the
+ interrupt controller so that a CPU interrupt is not generated when the timer
+ interrupt fires.
@param This The EFI_TIMER_ARCH_PROTOCOL instance.
@param TimerPeriod The rate to program the timer interrupt in 100 nS units. If
@@ -204,7 +204,7 @@ TimerDriverSetTimerPeriod ( {
EFI_STATUS Status;
UINT64 TimerTicks;
-
+
// always disable the timer
MmioAnd32 (SP804_TIMER_PERIODIC_BASE + SP804_TIMER_CONTROL_REG, ~SP804_TIMER_CTRL_ENABLE);
@@ -212,8 +212,8 @@ TimerDriverSetTimerPeriod ( // Leave timer disabled from above, and...
// Disable timer 0/1 interrupt for a TimerPeriod of 0
- Status = gInterrupt->DisableInterruptSource (gInterrupt, gVector);
- } else {
+ Status = gInterrupt->DisableInterruptSource (gInterrupt, gVector);
+ } else {
// Convert TimerPeriod into 1MHz clock counts (us units = 100ns units * 10)
TimerTicks = DivU64x32 (TimerPeriod, 10);
TimerTicks = MultU64x32 (TimerTicks, PcdGet32(PcdSP804TimerFrequencyInMHz));
@@ -230,7 +230,7 @@ TimerDriverSetTimerPeriod ( MmioOr32 (SP804_TIMER_PERIODIC_BASE + SP804_TIMER_CONTROL_REG, SP804_TIMER_CTRL_ENABLE);
// enable timer 0/1 interrupts
- Status = gInterrupt->EnableInterruptSource (gInterrupt, gVector);
+ Status = gInterrupt->EnableInterruptSource (gInterrupt, gVector);
}
// Save the new timer period
@@ -239,9 +239,9 @@ TimerDriverSetTimerPeriod ( }
/**
- This function retrieves the period of timer interrupts in 100 ns units,
- returns that value in TimerPeriod, and returns EFI_SUCCESS. If TimerPeriod
- is NULL, then EFI_INVALID_PARAMETER is returned. If a TimerPeriod of 0 is
+ This function retrieves the period of timer interrupts in 100 ns units,
+ returns that value in TimerPeriod, and returns EFI_SUCCESS. If TimerPeriod
+ is NULL, then EFI_INVALID_PARAMETER is returned. If a TimerPeriod of 0 is
returned, then the timer is currently disabled.
@param This The EFI_TIMER_ARCH_PROTOCOL instance.
@@ -269,12 +269,12 @@ TimerDriverGetTimerPeriod ( }
/**
- This function generates a soft timer interrupt. If the platform does not support soft
- timer interrupts, then EFI_UNSUPPORTED is returned. Otherwise, EFI_SUCCESS is returned.
- If a handler has been registered through the EFI_TIMER_ARCH_PROTOCOL.RegisterHandler()
- service, then a soft timer interrupt will be generated. If the timer interrupt is
- enabled when this service is called, then the registered handler will be invoked. The
- registered handler should not be able to distinguish a hardware-generated timer
+ This function generates a soft timer interrupt. If the platform does not support soft
+ timer interrupts, then EFI_UNSUPPORTED is returned. Otherwise, EFI_SUCCESS is returned.
+ If a handler has been registered through the EFI_TIMER_ARCH_PROTOCOL.RegisterHandler()
+ service, then a soft timer interrupt will be generated. If the timer interrupt is
+ enabled when this service is called, then the registered handler will be invoked. The
+ registered handler should not be able to distinguish a hardware-generated timer
interrupt from a software-generated timer interrupt.
@param This The EFI_TIMER_ARCH_PROTOCOL instance.
@@ -296,24 +296,24 @@ TimerDriverGenerateSoftInterrupt ( Interface structure for the Timer Architectural Protocol.
@par Protocol Description:
- This protocol provides the services to initialize a periodic timer
+ This protocol provides the services to initialize a periodic timer
interrupt, and to register a handler that is called each time the timer
interrupt fires. It may also provide a service to adjust the rate of the
- periodic timer interrupt. When a timer interrupt occurs, the handler is
- passed the amount of time that has passed since the previous timer
+ periodic timer interrupt. When a timer interrupt occurs, the handler is
+ passed the amount of time that has passed since the previous timer
interrupt.
@param RegisterHandler
- Registers a handler that will be called each time the
- timer interrupt fires. TimerPeriod defines the minimum
- time between timer interrupts, so TimerPeriod will also
- be the minimum time between calls to the registered
+ Registers a handler that will be called each time the
+ timer interrupt fires. TimerPeriod defines the minimum
+ time between timer interrupts, so TimerPeriod will also
+ be the minimum time between calls to the registered
handler.
@param SetTimerPeriod
- Sets the period of the timer interrupt in 100 nS units.
- This function is optional, and may return EFI_UNSUPPORTED.
- If this function is supported, then the timer period will
+ Sets the period of the timer interrupt in 100 nS units.
+ This function is optional, and may return EFI_UNSUPPORTED.
+ If this function is supported, then the timer period will
be rounded up to the nearest supported timer period.
@@ -321,8 +321,8 @@ TimerDriverGenerateSoftInterrupt ( Retrieves the period of the timer interrupt in 100 nS units.
@param GenerateSoftInterrupt
- Generates a soft timer interrupt that simulates the firing of
- the timer interrupt. This service can be used to invoke the registered handler if the timer interrupt has been masked for
+ Generates a soft timer interrupt that simulates the firing of
+ the timer interrupt. This service can be used to invoke the registered handler if the timer interrupt has been masked for
a period of time.
**/
diff --git a/ArmPlatformPkg/Drivers/SP804TimerDxe/SP804TimerDxe.inf b/ArmPlatformPkg/Drivers/SP804TimerDxe/SP804TimerDxe.inf index 8e87adcf07..386d9649ef 100644 --- a/ArmPlatformPkg/Drivers/SP804TimerDxe/SP804TimerDxe.inf +++ b/ArmPlatformPkg/Drivers/SP804TimerDxe/SP804TimerDxe.inf @@ -1,22 +1,22 @@ #/** @file
-#
+#
# Component description file for Timer module
-#
+#
# Copyright (c) 2009 - 2010, Apple Inc. All rights reserved.<BR>
# This program and the accompanying materials
# are licensed and made available under the terms and conditions of the BSD License
# which accompanies this distribution. The full text of the license may be found at
# http://opensource.org/licenses/bsd-license.php
-#
+#
# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
-#
+#
#**/
[Defines]
INF_VERSION = 0x00010005
BASE_NAME = ArmVeTimerDxe
- FILE_GUID = a73d663d-a491-4278-9a69-9521be3379f2
+ FILE_GUID = a73d663d-a491-4278-9a69-9521be3379f2
MODULE_TYPE = DXE_DRIVER
VERSION_STRING = 1.0
@@ -44,7 +44,7 @@ [Guids]
[Protocols]
- gEfiTimerArchProtocolGuid
+ gEfiTimerArchProtocolGuid
gHardwareInterruptProtocolGuid
[Pcd.common]
diff --git a/ArmPlatformPkg/Drivers/SP805WatchdogDxe/SP805Watchdog.c b/ArmPlatformPkg/Drivers/SP805WatchdogDxe/SP805Watchdog.c index 799ead9686..c78d2b9ff9 100644 --- a/ArmPlatformPkg/Drivers/SP805WatchdogDxe/SP805Watchdog.c +++ b/ArmPlatformPkg/Drivers/SP805WatchdogDxe/SP805Watchdog.c @@ -352,7 +352,7 @@ SP805Initialize ( // Prohibit any rogue access to SP805 registers
SP805Lock();
-
+
//
// Make sure the Watchdog Timer Architectural Protocol has not been installed in the system yet.
// This will avoid conflicts with the universal watchdog
diff --git a/ArmPlatformPkg/Drivers/SP805WatchdogDxe/SP805WatchdogDxe.inf b/ArmPlatformPkg/Drivers/SP805WatchdogDxe/SP805WatchdogDxe.inf index 5ec35188c9..37924f2e3c 100644 --- a/ArmPlatformPkg/Drivers/SP805WatchdogDxe/SP805WatchdogDxe.inf +++ b/ArmPlatformPkg/Drivers/SP805WatchdogDxe/SP805WatchdogDxe.inf @@ -1,21 +1,21 @@ /** @file
*
* Copyright (c) 2011-2012, ARM Limited. All rights reserved.
-*
-* This program and the accompanying materials
-* are licensed and made available under the terms and conditions of the BSD License
-* which accompanies this distribution. The full text of the license may be found at
-* http://opensource.org/licenses/bsd-license.php
*
-* THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
-* WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
+* This program and the accompanying materials
+* are licensed and made available under the terms and conditions of the BSD License
+* which accompanies this distribution. The full text of the license may be found at
+* http://opensource.org/licenses/bsd-license.php
+*
+* THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
+* WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
*
**/
[Defines]
INF_VERSION = 0x00010005
BASE_NAME = SP805WatchdogDxe
- FILE_GUID = ebd705fb-fa92-46a7-b32b-7f566d944614
+ FILE_GUID = ebd705fb-fa92-46a7-b32b-7f566d944614
MODULE_TYPE = DXE_DRIVER
VERSION_STRING = 1.0
@@ -46,7 +46,7 @@ gArmPlatformTokenSpaceGuid.PcdSP805WatchdogClockFrequencyInHz
[Protocols]
- gEfiWatchdogTimerArchProtocolGuid
+ gEfiWatchdogTimerArchProtocolGuid
[Depex]
TRUE
diff --git a/ArmPlatformPkg/Include/Drivers/ArmTrustzone.h b/ArmPlatformPkg/Include/Drivers/ArmTrustzone.h index da920bdfb5..78e98aad53 100644 --- a/ArmPlatformPkg/Include/Drivers/ArmTrustzone.h +++ b/ArmPlatformPkg/Include/Drivers/ArmTrustzone.h @@ -1,14 +1,14 @@ /** @file
*
* Copyright (c) 2011-2012, ARM Limited. All rights reserved.
-*
-* This program and the accompanying materials
-* are licensed and made available under the terms and conditions of the BSD License
-* which accompanies this distribution. The full text of the license may be found at
-* http://opensource.org/licenses/bsd-license.php
*
-* THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
-* WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
+* This program and the accompanying materials
+* are licensed and made available under the terms and conditions of the BSD License
+* which accompanies this distribution. The full text of the license may be found at
+* http://opensource.org/licenses/bsd-license.php
+*
+* THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
+* WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
*
**/
diff --git a/ArmPlatformPkg/Include/Drivers/PL011Uart.h b/ArmPlatformPkg/Include/Drivers/PL011Uart.h index 23e9a94347..a36347e529 100644 --- a/ArmPlatformPkg/Include/Drivers/PL011Uart.h +++ b/ArmPlatformPkg/Include/Drivers/PL011Uart.h @@ -1,14 +1,14 @@ /** @file
*
* Copyright (c) 2011-2012, ARM Limited. All rights reserved.
-*
-* This program and the accompanying materials
-* are licensed and made available under the terms and conditions of the BSD License
-* which accompanies this distribution. The full text of the license may be found at
-* http://opensource.org/licenses/bsd-license.php
*
-* THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
-* WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
+* This program and the accompanying materials
+* are licensed and made available under the terms and conditions of the BSD License
+* which accompanies this distribution. The full text of the license may be found at
+* http://opensource.org/licenses/bsd-license.php
+*
+* THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
+* WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
*
**/
diff --git a/ArmPlatformPkg/Include/Drivers/SP804Timer.h b/ArmPlatformPkg/Include/Drivers/SP804Timer.h index f9a89c5376..904b13c193 100644 --- a/ArmPlatformPkg/Include/Drivers/SP804Timer.h +++ b/ArmPlatformPkg/Include/Drivers/SP804Timer.h @@ -1,14 +1,14 @@ /** @file
*
* Copyright (c) 2011, ARM Limited. All rights reserved.
-*
-* This program and the accompanying materials
-* are licensed and made available under the terms and conditions of the BSD License
-* which accompanies this distribution. The full text of the license may be found at
-* http://opensource.org/licenses/bsd-license.php
*
-* THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
-* WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
+* This program and the accompanying materials
+* are licensed and made available under the terms and conditions of the BSD License
+* which accompanies this distribution. The full text of the license may be found at
+* http://opensource.org/licenses/bsd-license.php
+*
+* THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
+* WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
*
**/
diff --git a/ArmPlatformPkg/Include/Guid/ArmGlobalVariableHob.h b/ArmPlatformPkg/Include/Guid/ArmGlobalVariableHob.h index c175cee6df..844090b4e8 100644 --- a/ArmPlatformPkg/Include/Guid/ArmGlobalVariableHob.h +++ b/ArmPlatformPkg/Include/Guid/ArmGlobalVariableHob.h @@ -24,8 +24,8 @@ extern EFI_GUID gArmGlobalVariableGuid;
///
-/// Describes all memory ranges used during the HOB producer
-/// phase that exist outside the HOB list. This HOB type
+/// Describes all memory ranges used during the HOB producer
+/// phase that exist outside the HOB list. This HOB type
/// describes how memory is used, not the physical attributes of memory.
///
typedef struct {
@@ -42,9 +42,9 @@ typedef struct { ///
EFI_PHYSICAL_ADDRESS GlobalVariableBase;
- ///
+ ///
/// The length in bytes of memory allocated by this HOB.
- ///
+ ///
UINT32 GlobalVariableSize;
} ARM_HOB_GLOBAL_VARIABLE;
diff --git a/ArmPlatformPkg/Include/Library/ArmPlatformLib.h b/ArmPlatformPkg/Include/Library/ArmPlatformLib.h index ed631f3c42..77561a3d05 100644 --- a/ArmPlatformPkg/Include/Library/ArmPlatformLib.h +++ b/ArmPlatformPkg/Include/Library/ArmPlatformLib.h @@ -1,14 +1,14 @@ /** @file
*
* Copyright (c) 2011-2013, ARM Limited. All rights reserved.
-*
-* This program and the accompanying materials
-* are licensed and made available under the terms and conditions of the BSD License
-* which accompanies this distribution. The full text of the license may be found at
-* http://opensource.org/licenses/bsd-license.php
*
-* THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
-* WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
+* This program and the accompanying materials
+* are licensed and made available under the terms and conditions of the BSD License
+* which accompanies this distribution. The full text of the license may be found at
+* http://opensource.org/licenses/bsd-license.php
+*
+* THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
+* WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
*
**/
diff --git a/ArmPlatformPkg/Include/Library/ArmPlatformSecLib.h b/ArmPlatformPkg/Include/Library/ArmPlatformSecLib.h index ece8064903..cb3148e778 100644 --- a/ArmPlatformPkg/Include/Library/ArmPlatformSecLib.h +++ b/ArmPlatformPkg/Include/Library/ArmPlatformSecLib.h @@ -1,14 +1,14 @@ /** @file
*
* Copyright (c) 2011-2012, ARM Limited. All rights reserved.
-*
-* This program and the accompanying materials
-* are licensed and made available under the terms and conditions of the BSD License
-* which accompanies this distribution. The full text of the license may be found at
-* http://opensource.org/licenses/bsd-license.php
*
-* THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
-* WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
+* This program and the accompanying materials
+* are licensed and made available under the terms and conditions of the BSD License
+* which accompanies this distribution. The full text of the license may be found at
+* http://opensource.org/licenses/bsd-license.php
+*
+* THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
+* WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
*
**/
diff --git a/ArmPlatformPkg/Library/ArmPlatformGlobalVariableLib/Dxe/DxeArmPlatformGlobalVariableLib.inf b/ArmPlatformPkg/Library/ArmPlatformGlobalVariableLib/Dxe/DxeArmPlatformGlobalVariableLib.inf index a0835d25f9..e90d6a5811 100644 --- a/ArmPlatformPkg/Library/ArmPlatformGlobalVariableLib/Dxe/DxeArmPlatformGlobalVariableLib.inf +++ b/ArmPlatformPkg/Library/ArmPlatformGlobalVariableLib/Dxe/DxeArmPlatformGlobalVariableLib.inf @@ -1,27 +1,27 @@ #/** @file
# Timer library implementation
-#
-#
+#
+#
# Copyright (c) 2011-2012, ARM Ltd. All rights reserved.<BR>
#
# This program and the accompanying materials
# are licensed and made available under the terms and conditions of the BSD License
# which accompanies this distribution. The full text of the license may be found at
# http://opensource.org/licenses/bsd-license.php
-#
+#
# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
-#
+#
#**/
[Defines]
INF_VERSION = 0x00010005
BASE_NAME = DxeArmPlatformGlobalVariableLib
- FILE_GUID = 53fa3cc3-23b7-4ec2-9bfa-30257d7e1135
+ FILE_GUID = 53fa3cc3-23b7-4ec2-9bfa-30257d7e1135
MODULE_TYPE = BASE
VERSION_STRING = 1.0
LIBRARY_CLASS = ArmPlatformGlobalVariableLib
-
+
CONSTRUCTOR = ArmPlatformGlobalVariableConstructor
[Sources.common]
diff --git a/ArmPlatformPkg/Library/ArmPlatformGlobalVariableLib/Pei/PeiArmPlatformGlobalVariableLib.inf b/ArmPlatformPkg/Library/ArmPlatformGlobalVariableLib/Pei/PeiArmPlatformGlobalVariableLib.inf index 8eea9d3821..09995e1fa0 100644 --- a/ArmPlatformPkg/Library/ArmPlatformGlobalVariableLib/Pei/PeiArmPlatformGlobalVariableLib.inf +++ b/ArmPlatformPkg/Library/ArmPlatformGlobalVariableLib/Pei/PeiArmPlatformGlobalVariableLib.inf @@ -1,16 +1,16 @@ #/** @file
# ArmPlatformGlobalVariableLib library implementation
-#
+#
# Copyright (c) 2011-2012, ARM Ltd. All rights reserved.<BR>
-#
+#
# This program and the accompanying materials
# are licensed and made available under the terms and conditions of the BSD License
# which accompanies this distribution. The full text of the license may be found at
# http://opensource.org/licenses/bsd-license.php
-#
+#
# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
-#
+#
#**/
[Defines]
diff --git a/ArmPlatformPkg/Library/ArmPlatformGlobalVariableLib/PrePi/PrePiArmPlatformGlobalVariableLib.inf b/ArmPlatformPkg/Library/ArmPlatformGlobalVariableLib/PrePi/PrePiArmPlatformGlobalVariableLib.inf index 28ba984285..5d3a93fb72 100644 --- a/ArmPlatformPkg/Library/ArmPlatformGlobalVariableLib/PrePi/PrePiArmPlatformGlobalVariableLib.inf +++ b/ArmPlatformPkg/Library/ArmPlatformGlobalVariableLib/PrePi/PrePiArmPlatformGlobalVariableLib.inf @@ -1,21 +1,21 @@ #/** @file
-#
+#
# Copyright (c) 2011-2012, ARM Ltd. All rights reserved.<BR>
#
# This program and the accompanying materials
# are licensed and made available under the terms and conditions of the BSD License
# which accompanies this distribution. The full text of the license may be found at
# http://opensource.org/licenses/bsd-license.php
-#
+#
# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
-#
+#
#**/
[Defines]
INF_VERSION = 0x00010005
BASE_NAME = PrePiArmPlatformGlobalVariableLib
- FILE_GUID = 44d59470-e5e6-4811-af00-33bb573a804b
+ FILE_GUID = 44d59470-e5e6-4811-af00-33bb573a804b
MODULE_TYPE = BASE
VERSION_STRING = 1.0
LIBRARY_CLASS = ArmPlatformGlobalVariableLib
diff --git a/ArmPlatformPkg/Library/ArmPlatformGlobalVariableLib/Sec/SecArmPlatformGlobalVariableLib.c b/ArmPlatformPkg/Library/ArmPlatformGlobalVariableLib/Sec/SecArmPlatformGlobalVariableLib.c index 978ba33369..aa8d8927c1 100644 --- a/ArmPlatformPkg/Library/ArmPlatformGlobalVariableLib/Sec/SecArmPlatformGlobalVariableLib.c +++ b/ArmPlatformPkg/Library/ArmPlatformGlobalVariableLib/Sec/SecArmPlatformGlobalVariableLib.c @@ -32,7 +32,7 @@ ArmPlatformGetGlobalVariable ( ASSERT (VariableOffset < PcdGet32 (PcdSecGlobalVariableSize));
GlobalVariableBase = PcdGet32 (PcdCPUCoresSecStackBase) + PcdGet32 (PcdCPUCoreSecPrimaryStackSize) - PcdGet32 (PcdSecGlobalVariableSize);
-
+
if (VariableSize == 4) {
*(UINT32*)Variable = ReadUnaligned32 ((CONST UINT32*)(GlobalVariableBase + VariableOffset));
} else if (VariableSize == 8) {
diff --git a/ArmPlatformPkg/Library/ArmPlatformGlobalVariableLib/Sec/SecArmPlatformGlobalVariableLib.inf b/ArmPlatformPkg/Library/ArmPlatformGlobalVariableLib/Sec/SecArmPlatformGlobalVariableLib.inf index ced9ab0994..d64cbafb1e 100644 --- a/ArmPlatformPkg/Library/ArmPlatformGlobalVariableLib/Sec/SecArmPlatformGlobalVariableLib.inf +++ b/ArmPlatformPkg/Library/ArmPlatformGlobalVariableLib/Sec/SecArmPlatformGlobalVariableLib.inf @@ -1,15 +1,15 @@ #/** @file
-#
+#
# Copyright (c) 2011-2012, ARM Ltd. All rights reserved.<BR>
-#
+#
# This program and the accompanying materials
# are licensed and made available under the terms and conditions of the BSD License
# which accompanies this distribution. The full text of the license may be found at
# http://opensource.org/licenses/bsd-license.php
-#
+#
# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
-#
+#
#**/
[Defines]
diff --git a/ArmPlatformPkg/Library/ArmPlatformLibNull/Arm/ArmPlatformHelper.S b/ArmPlatformPkg/Library/ArmPlatformLibNull/Arm/ArmPlatformHelper.S index 1fc6b7af5c..0438d91f49 100644 --- a/ArmPlatformPkg/Library/ArmPlatformLibNull/Arm/ArmPlatformHelper.S +++ b/ArmPlatformPkg/Library/ArmPlatformLibNull/Arm/ArmPlatformHelper.S @@ -14,7 +14,7 @@ #include <AsmMacroIoLib.h>
#include <Library/ArmLib.h>
-.text
+.text
.align 2
GCC_ASM_EXPORT(ArmPlatformPeiBootAction)
diff --git a/ArmPlatformPkg/Library/ArmPlatformLibNull/Arm/ArmPlatformHelper.asm b/ArmPlatformPkg/Library/ArmPlatformLibNull/Arm/ArmPlatformHelper.asm index 5cdf6fa1a6..aafa9c60d2 100644 --- a/ArmPlatformPkg/Library/ArmPlatformLibNull/Arm/ArmPlatformHelper.asm +++ b/ArmPlatformPkg/Library/ArmPlatformLibNull/Arm/ArmPlatformHelper.asm @@ -23,7 +23,7 @@ IMPORT _gPcd_FixedAtBuild_PcdArmPrimaryCore
IMPORT _gPcd_FixedAtBuild_PcdArmPrimaryCoreMask
-
+
PRESERVE8
AREA ArmPlatformNullHelper, CODE, READONLY
diff --git a/ArmPlatformPkg/Library/ArmPlatformLibNull/ArmPlatformLibNull.c b/ArmPlatformPkg/Library/ArmPlatformLibNull/ArmPlatformLibNull.c index b45c11b4e1..0cc1e4a03c 100644 --- a/ArmPlatformPkg/Library/ArmPlatformLibNull/ArmPlatformLibNull.c +++ b/ArmPlatformPkg/Library/ArmPlatformLibNull/ArmPlatformLibNull.c @@ -1,14 +1,14 @@ /** @file
*
* Copyright (c) 2011-2012, ARM Limited. All rights reserved.
-*
-* This program and the accompanying materials
-* are licensed and made available under the terms and conditions of the BSD License
-* which accompanies this distribution. The full text of the license may be found at
-* http://opensource.org/licenses/bsd-license.php
*
-* THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
-* WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
+* This program and the accompanying materials
+* are licensed and made available under the terms and conditions of the BSD License
+* which accompanies this distribution. The full text of the license may be found at
+* http://opensource.org/licenses/bsd-license.php
+*
+* THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
+* WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
*
**/
diff --git a/ArmPlatformPkg/Library/ArmPlatformLibNull/ArmPlatformLibNull.inf b/ArmPlatformPkg/Library/ArmPlatformLibNull/ArmPlatformLibNull.inf index 43fc04711b..4517ad5102 100644 --- a/ArmPlatformPkg/Library/ArmPlatformLibNull/ArmPlatformLibNull.inf +++ b/ArmPlatformPkg/Library/ArmPlatformLibNull/ArmPlatformLibNull.inf @@ -1,13 +1,13 @@ #/* @file
# Copyright (c) 2011-2012, ARM Limited. All rights reserved.
-#
-# This program and the accompanying materials
-# are licensed and made available under the terms and conditions of the BSD License
-# which accompanies this distribution. The full text of the license may be found at
-# http://opensource.org/licenses/bsd-license.php
#
-# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
-# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
+# This program and the accompanying materials
+# are licensed and made available under the terms and conditions of the BSD License
+# which accompanies this distribution. The full text of the license may be found at
+# http://opensource.org/licenses/bsd-license.php
+#
+# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
+# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
#
#*/
diff --git a/ArmPlatformPkg/Library/ArmPlatformLibNull/ArmPlatformLibNullMem.c b/ArmPlatformPkg/Library/ArmPlatformLibNull/ArmPlatformLibNullMem.c index aafb797683..45a64c622a 100644 --- a/ArmPlatformPkg/Library/ArmPlatformLibNull/ArmPlatformLibNullMem.c +++ b/ArmPlatformPkg/Library/ArmPlatformLibNull/ArmPlatformLibNullMem.c @@ -1,14 +1,14 @@ /** @file
*
* Copyright (c) 2011, ARM Limited. All rights reserved.
-*
-* This program and the accompanying materials
-* are licensed and made available under the terms and conditions of the BSD License
-* which accompanies this distribution. The full text of the license may be found at
-* http://opensource.org/licenses/bsd-license.php
*
-* THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
-* WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
+* This program and the accompanying materials
+* are licensed and made available under the terms and conditions of the BSD License
+* which accompanies this distribution. The full text of the license may be found at
+* http://opensource.org/licenses/bsd-license.php
+*
+* THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
+* WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
*
**/
diff --git a/ArmPlatformPkg/Library/ArmPlatformLibNull/ArmPlatformLibNullSec.inf b/ArmPlatformPkg/Library/ArmPlatformLibNull/ArmPlatformLibNullSec.inf index 38266bff33..3cd5fd889e 100644 --- a/ArmPlatformPkg/Library/ArmPlatformLibNull/ArmPlatformLibNullSec.inf +++ b/ArmPlatformPkg/Library/ArmPlatformLibNull/ArmPlatformLibNullSec.inf @@ -1,13 +1,13 @@ #/* @file
# Copyright (c) 2011-2012, ARM Limited. All rights reserved.
-#
-# This program and the accompanying materials
-# are licensed and made available under the terms and conditions of the BSD License
-# which accompanies this distribution. The full text of the license may be found at
-# http://opensource.org/licenses/bsd-license.php
#
-# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
-# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
+# This program and the accompanying materials
+# are licensed and made available under the terms and conditions of the BSD License
+# which accompanies this distribution. The full text of the license may be found at
+# http://opensource.org/licenses/bsd-license.php
+#
+# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
+# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
#
#*/
diff --git a/ArmPlatformPkg/Library/ArmPlatformSecLibNull/ArmPlatformLibNullSec.c b/ArmPlatformPkg/Library/ArmPlatformSecLibNull/ArmPlatformLibNullSec.c index 41f4f74085..fc04977b5c 100644 --- a/ArmPlatformPkg/Library/ArmPlatformSecLibNull/ArmPlatformLibNullSec.c +++ b/ArmPlatformPkg/Library/ArmPlatformSecLibNull/ArmPlatformLibNullSec.c @@ -1,14 +1,14 @@ /** @file
*
* Copyright (c) 2011-2012, ARM Limited. All rights reserved.
-*
-* This program and the accompanying materials
-* are licensed and made available under the terms and conditions of the BSD License
-* which accompanies this distribution. The full text of the license may be found at
-* http://opensource.org/licenses/bsd-license.php
*
-* THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
-* WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
+* This program and the accompanying materials
+* are licensed and made available under the terms and conditions of the BSD License
+* which accompanies this distribution. The full text of the license may be found at
+* http://opensource.org/licenses/bsd-license.php
+*
+* THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
+* WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
*
**/
diff --git a/ArmPlatformPkg/Library/ArmPlatformSecLibNull/ArmPlatformLibNullSec.inf b/ArmPlatformPkg/Library/ArmPlatformSecLibNull/ArmPlatformLibNullSec.inf index bcc2d66c62..27960e989f 100644 --- a/ArmPlatformPkg/Library/ArmPlatformSecLibNull/ArmPlatformLibNullSec.inf +++ b/ArmPlatformPkg/Library/ArmPlatformSecLibNull/ArmPlatformLibNullSec.inf @@ -1,13 +1,13 @@ #/* @file
# Copyright (c) 2011-2012, ARM Limited. All rights reserved.
-#
-# This program and the accompanying materials
-# are licensed and made available under the terms and conditions of the BSD License
-# which accompanies this distribution. The full text of the license may be found at
-# http://opensource.org/licenses/bsd-license.php
#
-# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
-# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
+# This program and the accompanying materials
+# are licensed and made available under the terms and conditions of the BSD License
+# which accompanies this distribution. The full text of the license may be found at
+# http://opensource.org/licenses/bsd-license.php
+#
+# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
+# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
#
#*/
diff --git a/ArmPlatformPkg/Library/ArmPlatformStackLib/ArmPlatformStackLib.inf b/ArmPlatformPkg/Library/ArmPlatformStackLib/ArmPlatformStackLib.inf index d0197474f6..16a2917873 100644 --- a/ArmPlatformPkg/Library/ArmPlatformStackLib/ArmPlatformStackLib.inf +++ b/ArmPlatformPkg/Library/ArmPlatformStackLib/ArmPlatformStackLib.inf @@ -1,14 +1,14 @@ #/* @file
#
# Copyright (c) 2012, ARM Limited. All rights reserved.
-#
-# This program and the accompanying materials
-# are licensed and made available under the terms and conditions of the BSD License
-# which accompanies this distribution. The full text of the license may be found at
-# http://opensource.org/licenses/bsd-license.php
#
-# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
-# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
+# This program and the accompanying materials
+# are licensed and made available under the terms and conditions of the BSD License
+# which accompanies this distribution. The full text of the license may be found at
+# http://opensource.org/licenses/bsd-license.php
+#
+# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
+# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
#
#*/
diff --git a/ArmPlatformPkg/Library/ArmTrustedMonitorLibNull/ArmTrustedMonitorLibNull.inf b/ArmPlatformPkg/Library/ArmTrustedMonitorLibNull/ArmTrustedMonitorLibNull.inf index da867e1fe9..505d2ec0c0 100644 --- a/ArmPlatformPkg/Library/ArmTrustedMonitorLibNull/ArmTrustedMonitorLibNull.inf +++ b/ArmPlatformPkg/Library/ArmTrustedMonitorLibNull/ArmTrustedMonitorLibNull.inf @@ -1,13 +1,13 @@ #/* @file
# Copyright (c) 2011-2012, ARM Limited. All rights reserved.
-#
-# This program and the accompanying materials
-# are licensed and made available under the terms and conditions of the BSD License
-# which accompanies this distribution. The full text of the license may be found at
-# http://opensource.org/licenses/bsd-license.php
#
-# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
-# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
+# This program and the accompanying materials
+# are licensed and made available under the terms and conditions of the BSD License
+# which accompanies this distribution. The full text of the license may be found at
+# http://opensource.org/licenses/bsd-license.php
+#
+# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
+# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
#
#*/
@@ -37,4 +37,4 @@ BaseLib
DebugLib
PcdLib
-
+
diff --git a/ArmPlatformPkg/Library/DebugSecExtraActionLib/DebugSecExtraActionLib.inf b/ArmPlatformPkg/Library/DebugSecExtraActionLib/DebugSecExtraActionLib.inf index 5a2d28876a..b058f367a5 100755 --- a/ArmPlatformPkg/Library/DebugSecExtraActionLib/DebugSecExtraActionLib.inf +++ b/ArmPlatformPkg/Library/DebugSecExtraActionLib/DebugSecExtraActionLib.inf @@ -1,13 +1,13 @@ #/* @file
# Copyright (c) 2011-2012, ARM Limited. All rights reserved.
-#
-# This program and the accompanying materials
-# are licensed and made available under the terms and conditions of the BSD License
-# which accompanies this distribution. The full text of the license may be found at
-# http://opensource.org/licenses/bsd-license.php
#
-# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
-# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
+# This program and the accompanying materials
+# are licensed and made available under the terms and conditions of the BSD License
+# which accompanies this distribution. The full text of the license may be found at
+# http://opensource.org/licenses/bsd-license.php
+#
+# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
+# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
#
#*/
diff --git a/ArmPlatformPkg/Library/EblCmdLib/Arm/EblCmdMmu.c b/ArmPlatformPkg/Library/EblCmdLib/Arm/EblCmdMmu.c index 138216e9b7..bc074de117 100644 --- a/ArmPlatformPkg/Library/EblCmdLib/Arm/EblCmdMmu.c +++ b/ArmPlatformPkg/Library/EblCmdLib/Arm/EblCmdMmu.c @@ -1,14 +1,14 @@ /** @file
*
* Copyright (c) 2011-2012, ARM Limited. All rights reserved.
-*
-* This program and the accompanying materials
-* are licensed and made available under the terms and conditions of the BSD License
-* which accompanies this distribution. The full text of the license may be found at
-* http://opensource.org/licenses/bsd-license.php
*
-* THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
-* WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
+* This program and the accompanying materials
+* are licensed and made available under the terms and conditions of the BSD License
+* which accompanies this distribution. The full text of the license may be found at
+* http://opensource.org/licenses/bsd-license.php
+*
+* THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
+* WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
*
**/
diff --git a/ArmPlatformPkg/Library/EblCmdLib/EblCmdLib.c b/ArmPlatformPkg/Library/EblCmdLib/EblCmdLib.c index 9319050b06..899991062f 100644 --- a/ArmPlatformPkg/Library/EblCmdLib/EblCmdLib.c +++ b/ArmPlatformPkg/Library/EblCmdLib/EblCmdLib.c @@ -1,14 +1,14 @@ /** @file
*
* Copyright (c) 2011-2013, ARM Limited. All rights reserved.
-*
-* This program and the accompanying materials
-* are licensed and made available under the terms and conditions of the BSD License
-* which accompanies this distribution. The full text of the license may be found at
-* http://opensource.org/licenses/bsd-license.php
*
-* THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
-* WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
+* This program and the accompanying materials
+* are licensed and made available under the terms and conditions of the BSD License
+* which accompanies this distribution. The full text of the license may be found at
+* http://opensource.org/licenses/bsd-license.php
+*
+* THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
+* WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
*
**/
@@ -42,7 +42,7 @@ EblDumpMmu ( IN UINTN Argc,
IN CHAR8 **Argv
);
-
+
EFI_STATUS
EblDumpFdt (
IN UINTN Argc,
@@ -53,11 +53,11 @@ EblDumpFdt ( Simple arm disassembler via a library
Argv[0] - symboltable
- Argv[1] - Optional qoted format string
+ Argv[1] - Optional qoted format string
Argv[2] - Optional flag
@param Argc Number of command arguments in Argv
- @param Argv Array of strings that represent the parsed command line.
+ @param Argv Array of strings that represent the parsed command line.
Argv[0] is the command name
@return EFI_SUCCESS
@@ -78,7 +78,7 @@ EblSymbolTable ( UINT32 PeCoffSizeOfHeaders;
UINT32 ImageBase;
BOOLEAN Elf;
-
+
// Need to add lots of error checking on the passed in string
// Default string is for RealView debugger
#if (__ARMCC_VERSION < 500000)
@@ -87,12 +87,12 @@ EblSymbolTable ( Format = (Argc > 1) ? Argv[1] : "add-symbol-file %a 0x%x";
#endif
Elf = (Argc > 2) ? FALSE : TRUE;
-
+
Status = EfiGetSystemConfigurationTable (&gEfiDebugImageInfoTableGuid, (VOID **)&DebugImageTableHeader);
if (EFI_ERROR (Status)) {
return Status;
}
-
+
DebugTable = DebugImageTableHeader->EfiDebugImageInfoTable;
if (DebugTable == NULL) {
return EFI_SUCCESS;
@@ -108,13 +108,13 @@ EblSymbolTable ( if (Elf) {
// ELF and Mach-O images don't include the header so the linked address does not include header
ImageBase += PeCoffSizeOfHeaders;
- }
+ }
AsciiPrint (Format, Pdb, ImageBase);
AsciiPrint ("\n");
} else {
}
}
- }
+ }
}
return EFI_SUCCESS;
@@ -129,7 +129,7 @@ EblSymbolTable ( ARgv[2] - Number of instructions to disassembly (optional)
@param Argc Number of command arguments in Argv
- @param Argv Array of strings that represent the parsed command line.
+ @param Argv Array of strings that represent the parsed command line.
Argv[0] is the command name
@return EFI_SUCCESS
@@ -146,22 +146,22 @@ EblDisassembler ( UINT32 Count;
CHAR8 Buffer[80];
UINT32 ItBlock;
-
+
if (Argc < 2) {
return EFI_INVALID_PARAMETER;
}
-
+
Address = AsciiStrHexToUintn (Argv[1]);
Count = (Argc > 2) ? (UINT32)AsciiStrHexToUintn (Argv[2]) : 20;
- Ptr = (UINT8 *)(UINTN)Address;
+ Ptr = (UINT8 *)(UINTN)Address;
ItBlock = 0;
do {
CurrentAddress = Ptr;
DisassembleInstruction (&Ptr, TRUE, TRUE, &ItBlock, Buffer, sizeof (Buffer));
AsciiPrint ("0x%08x: %a\n", CurrentAddress, Buffer);
} while (Count-- > 0);
-
+
return EFI_SUCCESS;
}
@@ -211,7 +211,7 @@ STATIC CHAR8 *mTokenList[] = { ARgv[2] - Number of instructions to disassembly (optional)
@param Argc Number of command arguments in Argv
- @param Argv Array of strings that represent the parsed command line.
+ @param Argv Array of strings that represent the parsed command line.
Argv[0] is the command name
@return EFI_SUCCESS
@@ -270,7 +270,7 @@ EblPerformance ( AsciiPrint ("%6a %6ld ms\n", Token, Milliseconds);
break;
}
- }
+ }
}
} while (Key != 0);
diff --git a/ArmPlatformPkg/Library/EblCmdLib/EblCmdLib.inf b/ArmPlatformPkg/Library/EblCmdLib/EblCmdLib.inf index 4de0d9d9de..5506c77ebe 100644 --- a/ArmPlatformPkg/Library/EblCmdLib/EblCmdLib.inf +++ b/ArmPlatformPkg/Library/EblCmdLib/EblCmdLib.inf @@ -1,14 +1,14 @@ #/** @file
-#
+#
# Copyright (c) 2011-2012, ARM Ltd. All rights reserved.<BR>
# This program and the accompanying materials
# are licensed and made available under the terms and conditions of the BSD License
# which accompanies this distribution. The full text of the license may be found at
# http://opensource.org/licenses/bsd-license.php
-#
+#
# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
-#
+#
#**/
@@ -18,7 +18,7 @@ FILE_GUID = 6085e1ca-0d2d-4ba4-9872-c59b36ffd6ad
MODULE_TYPE = UEFI_DRIVER
VERSION_STRING = 1.0
- LIBRARY_CLASS = EblCmdLib|DXE_DRIVER UEFI_APPLICATION UEFI_DRIVER
+ LIBRARY_CLASS = EblCmdLib|DXE_DRIVER UEFI_APPLICATION UEFI_DRIVER
#
@@ -53,12 +53,12 @@ TimerLib
BdsLib
FdtLib
-
+
[Protocols]
gEfiDebugSupportProtocolGuid
gEfiLoadedImageProtocolGuid
gEfiDevicePathToTextProtocolGuid
-
+
[Guids]
gEfiDebugImageInfoTableGuid
diff --git a/ArmPlatformPkg/Library/L2X0CacheLibNull/L2X0Cache.c b/ArmPlatformPkg/Library/L2X0CacheLibNull/L2X0Cache.c index ec0a0dd464..3f7fd305c4 100644 --- a/ArmPlatformPkg/Library/L2X0CacheLibNull/L2X0Cache.c +++ b/ArmPlatformPkg/Library/L2X0CacheLibNull/L2X0Cache.c @@ -1,14 +1,14 @@ /** @file
*
* Copyright (c) 2011, ARM Limited. All rights reserved.
-*
-* This program and the accompanying materials
-* are licensed and made available under the terms and conditions of the BSD License
-* which accompanies this distribution. The full text of the license may be found at
-* http://opensource.org/licenses/bsd-license.php
*
-* THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
-* WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
+* This program and the accompanying materials
+* are licensed and made available under the terms and conditions of the BSD License
+* which accompanies this distribution. The full text of the license may be found at
+* http://opensource.org/licenses/bsd-license.php
+*
+* THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
+* WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
*
**/
diff --git a/ArmPlatformPkg/Library/L2X0CacheLibNull/L2X0CacheLibNull.inf b/ArmPlatformPkg/Library/L2X0CacheLibNull/L2X0CacheLibNull.inf index f0ebe17c41..1bced4d87f 100755 --- a/ArmPlatformPkg/Library/L2X0CacheLibNull/L2X0CacheLibNull.inf +++ b/ArmPlatformPkg/Library/L2X0CacheLibNull/L2X0CacheLibNull.inf @@ -1,13 +1,13 @@ #/* @file
# Copyright (c) 2011, ARM Limited. All rights reserved.
-#
-# This program and the accompanying materials
-# are licensed and made available under the terms and conditions of the BSD License
-# which accompanies this distribution. The full text of the license may be found at
-# http://opensource.org/licenses/bsd-license.php
#
-# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
-# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
+# This program and the accompanying materials
+# are licensed and made available under the terms and conditions of the BSD License
+# which accompanies this distribution. The full text of the license may be found at
+# http://opensource.org/licenses/bsd-license.php
+#
+# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
+# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
#
#*/
diff --git a/ArmPlatformPkg/Library/PL011SerialPortLib/PL011SerialPortExtLib.c b/ArmPlatformPkg/Library/PL011SerialPortLib/PL011SerialPortExtLib.c index 57f3fa0eea..723a1b1624 100644 --- a/ArmPlatformPkg/Library/PL011SerialPortLib/PL011SerialPortExtLib.c +++ b/ArmPlatformPkg/Library/PL011SerialPortLib/PL011SerialPortExtLib.c @@ -2,7 +2,7 @@ Serial I/O Port library functions with no library constructor/destructor
Copyright (c) 2012-2013, ARM Ltd. All rights reserved.<BR>
-
+
This program and the accompanying materials
are licensed and made available under the terms and conditions of the BSD License
which accompanies this distribution. The full text of the license may be found at
diff --git a/ArmPlatformPkg/Library/PL011SerialPortLib/PL011SerialPortExtLib.inf b/ArmPlatformPkg/Library/PL011SerialPortLib/PL011SerialPortExtLib.inf index 89c8c9c119..723cc97d1b 100644 --- a/ArmPlatformPkg/Library/PL011SerialPortLib/PL011SerialPortExtLib.inf +++ b/ArmPlatformPkg/Library/PL011SerialPortLib/PL011SerialPortExtLib.inf @@ -1,17 +1,17 @@ #/** @file
-#
+#
# Component description file for PL011SerialPortLib module
-#
+#
# Copyright (c) 2011-2012, ARM Ltd. All rights reserved.<BR>
-#
+#
# This program and the accompanying materials
# are licensed and made available under the terms and conditions of the BSD License
# which accompanies this distribution. The full text of the license may be found at
# http://opensource.org/licenses/bsd-license.php
-#
+#
# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
-#
+#
#**/
[Defines]
diff --git a/ArmPlatformPkg/Library/PL011SerialPortLib/PL011SerialPortLib.c b/ArmPlatformPkg/Library/PL011SerialPortLib/PL011SerialPortLib.c index 4f628086ac..d4f7fc96f6 100644 --- a/ArmPlatformPkg/Library/PL011SerialPortLib/PL011SerialPortLib.c +++ b/ArmPlatformPkg/Library/PL011SerialPortLib/PL011SerialPortLib.c @@ -3,7 +3,7 @@ Copyright (c) 2008 - 2010, Apple Inc. All rights reserved.<BR>
Copyright (c) 2012 - 2013, ARM Ltd. All rights reserved.<BR>
-
+
This program and the accompanying materials
are licensed and made available under the terms and conditions of the BSD License
which accompanies this distribution. The full text of the license may be found at
diff --git a/ArmPlatformPkg/Library/PL011SerialPortLib/PL011SerialPortLib.inf b/ArmPlatformPkg/Library/PL011SerialPortLib/PL011SerialPortLib.inf index 13168dfc4c..3a950d0788 100644 --- a/ArmPlatformPkg/Library/PL011SerialPortLib/PL011SerialPortLib.inf +++ b/ArmPlatformPkg/Library/PL011SerialPortLib/PL011SerialPortLib.inf @@ -1,23 +1,23 @@ #/** @file
-#
+#
# Component description file for PL011SerialPortLib module
-#
+#
# Copyright (c) 2011-2012, ARM Ltd. All rights reserved.<BR>
-#
+#
# This program and the accompanying materials
# are licensed and made available under the terms and conditions of the BSD License
# which accompanies this distribution. The full text of the license may be found at
# http://opensource.org/licenses/bsd-license.php
-#
+#
# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
-#
+#
#**/
[Defines]
INF_VERSION = 0x00010005
BASE_NAME = PL011SerialPortLib
- FILE_GUID = 8ecefc8f-a2c4-4091-b80f-20f7aeb0567f
+ FILE_GUID = 8ecefc8f-a2c4-4091-b80f-20f7aeb0567f
MODULE_TYPE = BASE
VERSION_STRING = 1.0
LIBRARY_CLASS = SerialPortLib
diff --git a/ArmPlatformPkg/Library/PeiServicesTablePointerLib/PeiServicesTablePointer.c b/ArmPlatformPkg/Library/PeiServicesTablePointerLib/PeiServicesTablePointer.c index 3606963075..5c241fa59e 100644 --- a/ArmPlatformPkg/Library/PeiServicesTablePointerLib/PeiServicesTablePointer.c +++ b/ArmPlatformPkg/Library/PeiServicesTablePointerLib/PeiServicesTablePointer.c @@ -1,6 +1,6 @@ /** @file
PEI Services Table Pointer Library.
-
+
This library is used for PEIM which does executed from flash device directly but
executed in memory.
@@ -22,13 +22,13 @@ #include <Library/PcdLib.h>
/**
- Caches a pointer PEI Services Table.
-
- Caches the pointer to the PEI Services Table specified by PeiServicesTablePointer
+ Caches a pointer PEI Services Table.
+
+ Caches the pointer to the PEI Services Table specified by PeiServicesTablePointer
in a platform specific manner.
-
+
If PeiServicesTablePointer is NULL, then ASSERT().
-
+
@param PeiServicesTablePointer The address of PeiServices pointer.
**/
VOID
@@ -45,10 +45,10 @@ SetPeiServicesTablePointer ( /**
Retrieves the cached value of the PEI Services Table pointer.
- Returns the cached value of the PEI Services Table pointer in a CPU specific manner
- as specified in the CPU binding section of the Platform Initialization Pre-EFI
+ Returns the cached value of the PEI Services Table pointer in a CPU specific manner
+ as specified in the CPU binding section of the Platform Initialization Pre-EFI
Initialization Core Interface Specification.
-
+
If the cached PEI Services Table pointer is NULL, then ASSERT().
@return The pointer to PeiServices.
@@ -68,16 +68,16 @@ GetPeiServicesTablePointer ( }
/**
- Perform CPU specific actions required to migrate the PEI Services Table
+ Perform CPU specific actions required to migrate the PEI Services Table
pointer from temporary RAM to permanent RAM.
- For IA32 CPUs, the PEI Services Table pointer is stored in the 4 bytes
+ For IA32 CPUs, the PEI Services Table pointer is stored in the 4 bytes
immediately preceding the Interrupt Descriptor Table (IDT) in memory.
- For X64 CPUs, the PEI Services Table pointer is stored in the 8 bytes
+ For X64 CPUs, the PEI Services Table pointer is stored in the 8 bytes
immediately preceding the Interrupt Descriptor Table (IDT) in memory.
For Itanium and ARM CPUs, a the PEI Services Table Pointer is stored in
- a dedicated CPU register. This means that there is no memory storage
- associated with storing the PEI Services Table pointer, so no additional
+ a dedicated CPU register. This means that there is no memory storage
+ associated with storing the PEI Services Table pointer, so no additional
migration actions are required for Itanium or ARM CPUs.
**/
diff --git a/ArmPlatformPkg/Library/PeiServicesTablePointerLib/PeiServicesTablePointerLib.inf b/ArmPlatformPkg/Library/PeiServicesTablePointerLib/PeiServicesTablePointerLib.inf index 1e8b5e131e..307cec8443 100644 --- a/ArmPlatformPkg/Library/PeiServicesTablePointerLib/PeiServicesTablePointerLib.inf +++ b/ArmPlatformPkg/Library/PeiServicesTablePointerLib/PeiServicesTablePointerLib.inf @@ -38,7 +38,7 @@ [LibraryClasses]
ArmPlatformGlobalVariableLib
-
+
[Pcd]
gArmPlatformTokenSpaceGuid.PcdPeiServicePtrGlobalOffset
diff --git a/ArmPlatformPkg/Library/PrePiHobListPointerLib/PrePiHobListPointer.c b/ArmPlatformPkg/Library/PrePiHobListPointerLib/PrePiHobListPointer.c index 8ec0808b32..8932e10049 100755 --- a/ArmPlatformPkg/Library/PrePiHobListPointerLib/PrePiHobListPointer.c +++ b/ArmPlatformPkg/Library/PrePiHobListPointerLib/PrePiHobListPointer.c @@ -1,14 +1,14 @@ /** @file
*
* Copyright (c) 2011, ARM Limited. All rights reserved.
-*
-* This program and the accompanying materials
-* are licensed and made available under the terms and conditions of the BSD License
-* which accompanies this distribution. The full text of the license may be found at
-* http://opensource.org/licenses/bsd-license.php
*
-* THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
-* WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
+* This program and the accompanying materials
+* are licensed and made available under the terms and conditions of the BSD License
+* which accompanies this distribution. The full text of the license may be found at
+* http://opensource.org/licenses/bsd-license.php
+*
+* THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
+* WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
*
**/
@@ -45,7 +45,7 @@ PrePeiGetHobList ( Updates the pointer to the HOB list.
@param HobList Hob list pointer to store
-
+
**/
EFI_STATUS
EFIAPI
diff --git a/ArmPlatformPkg/Library/PrePiHobListPointerLib/PrePiHobListPointerLib.inf b/ArmPlatformPkg/Library/PrePiHobListPointerLib/PrePiHobListPointerLib.inf index dece6ff070..16b201e8f6 100755 --- a/ArmPlatformPkg/Library/PrePiHobListPointerLib/PrePiHobListPointerLib.inf +++ b/ArmPlatformPkg/Library/PrePiHobListPointerLib/PrePiHobListPointerLib.inf @@ -1,14 +1,14 @@ #/** @file
#
# Copyright (c) 2011, ARM Limited. All rights reserved.
-#
-# This program and the accompanying materials
-# are licensed and made available under the terms and conditions of the BSD License
-# which accompanies this distribution. The full text of the license may be found at
-# http://opensource.org/licenses/bsd-license.php
#
-# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
-# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
+# This program and the accompanying materials
+# are licensed and made available under the terms and conditions of the BSD License
+# which accompanies this distribution. The full text of the license may be found at
+# http://opensource.org/licenses/bsd-license.php
+#
+# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
+# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
#
#**/
@@ -30,6 +30,6 @@ [LibraryClasses]
ArmPlatformGlobalVariableLib
-
+
[FixedPcd.common]
gArmPlatformTokenSpaceGuid.PcdHobListPtrGlobalOffset
diff --git a/ArmPlatformPkg/Library/SP804TimerLib/SP804TimerLib.c b/ArmPlatformPkg/Library/SP804TimerLib/SP804TimerLib.c index 2d9b7ccb3e..16798e9ba9 100644 --- a/ArmPlatformPkg/Library/SP804TimerLib/SP804TimerLib.c +++ b/ArmPlatformPkg/Library/SP804TimerLib/SP804TimerLib.c @@ -203,7 +203,7 @@ EFIAPI GetPerformanceCounter (
VOID
)
-{
+{
// Free running 64-bit/32-bit counter is needed here.
// Don't think we need this to boot, just to do performance profile
UINT64 Value;
@@ -246,11 +246,11 @@ GetPerformanceCounterProperties ( // Timer starts with the reload value
*StartValue = 0xFFFFFFFF;
}
-
+
if (EndValue != NULL) {
// Timer counts down to 0x0
*EndValue = (UINT64)0ULL;
}
-
+
return PcdGet64 (PcdEmbeddedPerformanceCounterFrequencyInHz);
}
diff --git a/ArmPlatformPkg/Library/SP804TimerLib/SP804TimerLib.inf b/ArmPlatformPkg/Library/SP804TimerLib/SP804TimerLib.inf index d9bce48b93..fb5cc18926 100644 --- a/ArmPlatformPkg/Library/SP804TimerLib/SP804TimerLib.inf +++ b/ArmPlatformPkg/Library/SP804TimerLib/SP804TimerLib.inf @@ -1,26 +1,26 @@ #/** @file
# Timer library implementation
-#
-#
+#
+#
# Copyright (c) 2011, ARM Ltd. All rights reserved.<BR>
# This program and the accompanying materials
# are licensed and made available under the terms and conditions of the BSD License
# which accompanies this distribution. The full text of the license may be found at
# http://opensource.org/licenses/bsd-license.php
-#
+#
# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
-#
+#
#**/
[Defines]
INF_VERSION = 0x00010005
BASE_NAME = SP804TimerLib
- FILE_GUID = 09cefa99-0d07-487f-a651-fb44f094b1c7
+ FILE_GUID = 09cefa99-0d07-487f-a651-fb44f094b1c7
MODULE_TYPE = BASE
VERSION_STRING = 1.0
LIBRARY_CLASS = TimerLib
-
+
CONSTRUCTOR = TimerConstructor
[Sources.common]
diff --git a/ArmPlatformPkg/MemoryInitPei/MemoryInitPeiLib.inf b/ArmPlatformPkg/MemoryInitPei/MemoryInitPeiLib.inf index fb77e4db5d..4b21caa027 100755 --- a/ArmPlatformPkg/MemoryInitPei/MemoryInitPeiLib.inf +++ b/ArmPlatformPkg/MemoryInitPei/MemoryInitPeiLib.inf @@ -1,14 +1,14 @@ #/** @file
-#
+#
# Copyright (c) 2011, ARM Ltd. All rights reserved.<BR>
# This program and the accompanying materials
# are licensed and made available under the terms and conditions of the BSD License
# which accompanies this distribution. The full text of the license may be found at
# http://opensource.org/licenses/bsd-license.php
-#
+#
# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
-#
+#
#**/
[Defines]
@@ -29,7 +29,7 @@ EmbeddedPkg/EmbeddedPkg.dec
ArmPkg/ArmPkg.dec
ArmPlatformPkg/ArmPlatformPkg.dec
-
+
[LibraryClasses]
DebugLib
HobLib
@@ -51,7 +51,7 @@ gArmTokenSpaceGuid.PcdSystemMemoryBase
gArmTokenSpaceGuid.PcdSystemMemorySize
gArmPlatformTokenSpaceGuid.PcdSystemMemoryUefiRegionSize
-
+
gEmbeddedTokenSpaceGuid.PcdMemoryTypeEfiACPIReclaimMemory
gEmbeddedTokenSpaceGuid.PcdMemoryTypeEfiACPIMemoryNVS
gEmbeddedTokenSpaceGuid.PcdMemoryTypeEfiReservedMemoryType
@@ -61,6 +61,6 @@ gEmbeddedTokenSpaceGuid.PcdMemoryTypeEfiBootServicesData
gEmbeddedTokenSpaceGuid.PcdMemoryTypeEfiLoaderCode
gEmbeddedTokenSpaceGuid.PcdMemoryTypeEfiLoaderData
-
+
[depex]
TRUE
diff --git a/ArmPlatformPkg/MemoryInitPei/MemoryInitPeim.c b/ArmPlatformPkg/MemoryInitPei/MemoryInitPeim.c index c6a6fe64ba..4821fdc2fa 100755 --- a/ArmPlatformPkg/MemoryInitPei/MemoryInitPeim.c +++ b/ArmPlatformPkg/MemoryInitPei/MemoryInitPeim.c @@ -1,14 +1,14 @@ /** @file
*
* Copyright (c) 2011, ARM Limited. All rights reserved.
-*
-* This program and the accompanying materials
-* are licensed and made available under the terms and conditions of the BSD License
-* which accompanies this distribution. The full text of the license may be found at
-* http://opensource.org/licenses/bsd-license.php
*
-* THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
-* WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
+* This program and the accompanying materials
+* are licensed and made available under the terms and conditions of the BSD License
+* which accompanies this distribution. The full text of the license may be found at
+* http://opensource.org/licenses/bsd-license.php
+*
+* THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
+* WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
*
**/
@@ -63,7 +63,7 @@ BuildMemoryTypeInformationHob ( Info[7].NumberOfPages = PcdGet32 (PcdMemoryTypeEfiLoaderCode);
Info[8].Type = EfiLoaderData;
Info[8].NumberOfPages = PcdGet32 (PcdMemoryTypeEfiLoaderData);
-
+
// Terminator for the list
Info[9].Type = EfiMaxMemoryType;
Info[9].NumberOfPages = 0;
@@ -75,13 +75,13 @@ BuildMemoryTypeInformationHob ( Routine Description:
-
+
Arguments:
FileHandle - Handle of the file being invoked.
PeiServices - Describes the list of possible PEI Services.
-
+
Returns:
Status - EFI_SUCCESS if the boot mode could be set
diff --git a/ArmPlatformPkg/MemoryInitPei/MemoryInitPeim.inf b/ArmPlatformPkg/MemoryInitPei/MemoryInitPeim.inf index ee44004d84..504026e90f 100755 --- a/ArmPlatformPkg/MemoryInitPei/MemoryInitPeim.inf +++ b/ArmPlatformPkg/MemoryInitPei/MemoryInitPeim.inf @@ -1,14 +1,14 @@ #/** @file
-#
+#
# Copyright (c) 2011, ARM Ltd. All rights reserved.<BR>
# This program and the accompanying materials
# are licensed and made available under the terms and conditions of the BSD License
# which accompanies this distribution. The full text of the license may be found at
# http://opensource.org/licenses/bsd-license.php
-#
+#
# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
-#
+#
#**/
[Defines]
@@ -36,7 +36,7 @@ EmbeddedPkg/EmbeddedPkg.dec
ArmPkg/ArmPkg.dec
ArmPlatformPkg/ArmPlatformPkg.dec
-
+
[LibraryClasses]
PeimEntryPoint
DebugLib
@@ -58,7 +58,7 @@ gArmTokenSpaceGuid.PcdSystemMemoryBase
gArmTokenSpaceGuid.PcdSystemMemorySize
gArmPlatformTokenSpaceGuid.PcdSystemMemoryUefiRegionSize
-
+
gEmbeddedTokenSpaceGuid.PcdMemoryTypeEfiACPIReclaimMemory
gEmbeddedTokenSpaceGuid.PcdMemoryTypeEfiACPIMemoryNVS
gEmbeddedTokenSpaceGuid.PcdMemoryTypeEfiReservedMemoryType
@@ -68,6 +68,6 @@ gEmbeddedTokenSpaceGuid.PcdMemoryTypeEfiBootServicesData
gEmbeddedTokenSpaceGuid.PcdMemoryTypeEfiLoaderCode
gEmbeddedTokenSpaceGuid.PcdMemoryTypeEfiLoaderData
-
+
[Depex]
TRUE
diff --git a/ArmPlatformPkg/PlatformPei/PlatformPeiLib.inf b/ArmPlatformPkg/PlatformPei/PlatformPeiLib.inf index 5cddeccb68..314789d0a9 100755 --- a/ArmPlatformPkg/PlatformPei/PlatformPeiLib.inf +++ b/ArmPlatformPkg/PlatformPei/PlatformPeiLib.inf @@ -1,14 +1,14 @@ #/** @file
#
# Copyright (c) 2011-2012, ARM Limited. All rights reserved.
-#
-# This program and the accompanying materials
-# are licensed and made available under the terms and conditions of the BSD License
-# which accompanies this distribution. The full text of the license may be found at
-# http://opensource.org/licenses/bsd-license.php
#
-# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
-# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
+# This program and the accompanying materials
+# are licensed and made available under the terms and conditions of the BSD License
+# which accompanies this distribution. The full text of the license may be found at
+# http://opensource.org/licenses/bsd-license.php
+#
+# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
+# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
#
#**/
@@ -42,12 +42,12 @@ [FixedPcd]
gArmTokenSpaceGuid.PcdFdBaseAddress
gArmTokenSpaceGuid.PcdFdSize
-
+
gArmTokenSpaceGuid.PcdFvBaseAddress
gArmTokenSpaceGuid.PcdFvSize
-
+
gEmbeddedTokenSpaceGuid.PcdPrePiCpuMemorySize
gEmbeddedTokenSpaceGuid.PcdPrePiCpuIoSize
-
+
[depex]
TRUE
diff --git a/ArmPlatformPkg/PlatformPei/PlatformPeim.c b/ArmPlatformPkg/PlatformPei/PlatformPeim.c index 8392ecf6c2..ca33ae5313 100755 --- a/ArmPlatformPkg/PlatformPei/PlatformPeim.c +++ b/ArmPlatformPkg/PlatformPei/PlatformPeim.c @@ -1,14 +1,14 @@ /** @file
*
* Copyright (c) 2011, ARM Limited. All rights reserved.
-*
-* This program and the accompanying materials
-* are licensed and made available under the terms and conditions of the BSD License
-* which accompanies this distribution. The full text of the license may be found at
-* http://opensource.org/licenses/bsd-license.php
*
-* THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
-* WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
+* This program and the accompanying materials
+* are licensed and made available under the terms and conditions of the BSD License
+* which accompanies this distribution. The full text of the license may be found at
+* http://opensource.org/licenses/bsd-license.php
+*
+* THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
+* WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
*
**/
@@ -40,7 +40,7 @@ InitializePlatformPeim ( IN EFI_PEI_FILE_HANDLE FileHandle,
IN CONST EFI_PEI_SERVICES **PeiServices
);
-
+
EFI_STATUS
EFIAPI
PlatformPeim (
@@ -84,13 +84,13 @@ BuildGlobalVariableHob ( Routine Description:
-
+
Arguments:
FileHandle - Handle of the file being invoked.
PeiServices - Describes the list of possible PEI Services.
-
+
Returns:
Status - EFI_SUCCESS if the boot mode could be set
@@ -111,7 +111,7 @@ InitializePlatformPeim ( DEBUG ((EFI_D_ERROR, "Platform PEIM Loaded\n"));
PlatformPeim ();
-
+
Status = PeiServicesLocatePpi (&gArmGlobalVariablePpiGuid, 0, NULL, (VOID**)&ArmGlobalVariablePpi);
if (!EFI_ERROR(Status)) {
Status = ArmGlobalVariablePpi->GetGlobalVariableMemory (&GlobalVariableBase);
diff --git a/ArmPlatformPkg/PlatformPei/PlatformPeim.inf b/ArmPlatformPkg/PlatformPei/PlatformPeim.inf index 5fcebf0551..8ed44e7e39 100755 --- a/ArmPlatformPkg/PlatformPei/PlatformPeim.inf +++ b/ArmPlatformPkg/PlatformPei/PlatformPeim.inf @@ -1,14 +1,14 @@ #/** @file
#
# Copyright (c) 2011-2012, ARM Limited. All rights reserved.
-#
-# This program and the accompanying materials
-# are licensed and made available under the terms and conditions of the BSD License
-# which accompanies this distribution. The full text of the license may be found at
-# http://opensource.org/licenses/bsd-license.php
#
-# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
-# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
+# This program and the accompanying materials
+# are licensed and made available under the terms and conditions of the BSD License
+# which accompanies this distribution. The full text of the license may be found at
+# http://opensource.org/licenses/bsd-license.php
+#
+# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
+# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
#
#**/
@@ -55,15 +55,15 @@ [FixedPcd]
gArmTokenSpaceGuid.PcdFdBaseAddress
gArmTokenSpaceGuid.PcdFdSize
-
+
gArmTokenSpaceGuid.PcdFvBaseAddress
gArmTokenSpaceGuid.PcdFvSize
-
+
gEmbeddedTokenSpaceGuid.PcdPrePiCpuMemorySize
gEmbeddedTokenSpaceGuid.PcdPrePiCpuIoSize
-
+
gArmPlatformTokenSpaceGuid.PcdPeiGlobalVariableSize
-
+
[Depex]
TRUE
-
+
diff --git a/ArmPlatformPkg/PrePeiCore/Arm/ArchPrePeiCore.c b/ArmPlatformPkg/PrePeiCore/Arm/ArchPrePeiCore.c index b0594ae2cd..6a250391b4 100644 --- a/ArmPlatformPkg/PrePeiCore/Arm/ArchPrePeiCore.c +++ b/ArmPlatformPkg/PrePeiCore/Arm/ArchPrePeiCore.c @@ -2,14 +2,14 @@ * Main file supporting the transition to PEI Core in Normal World for Versatile Express
*
* Copyright (c) 2012, ARM Limited. All rights reserved.
-*
-* This program and the accompanying materials
-* are licensed and made available under the terms and conditions of the BSD License
-* which accompanies this distribution. The full text of the license may be found at
-* http://opensource.org/licenses/bsd-license.php
*
-* THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
-* WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
+* This program and the accompanying materials
+* are licensed and made available under the terms and conditions of the BSD License
+* which accompanies this distribution. The full text of the license may be found at
+* http://opensource.org/licenses/bsd-license.php
+*
+* THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
+* WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
*
**/
diff --git a/ArmPlatformPkg/PrePeiCore/Arm/Exception.S b/ArmPlatformPkg/PrePeiCore/Arm/Exception.S index abce21d0a5..afd284a2c7 100644 --- a/ArmPlatformPkg/PrePeiCore/Arm/Exception.S +++ b/ArmPlatformPkg/PrePeiCore/Arm/Exception.S @@ -1,13 +1,13 @@ //
// Copyright (c) 2011, ARM Limited. All rights reserved.
-//
-# This program and the accompanying materials
-# are licensed and made available under the terms and conditions of the BSD License
-# which accompanies this distribution. The full text of the license may be found at
+//
+# This program and the accompanying materials
+# are licensed and made available under the terms and conditions of the BSD License
+# which accompanies this distribution. The full text of the license may be found at
# http://opensource.org/licenses/bsd-license.php
#
-# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
-# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
+# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
+# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
#
#
@@ -28,8 +28,8 @@ GCC_ASM_EXPORT(PeiVectorTable) //============================================================
//Default Exception Handlers
//============================================================
-
-
+
+
ASM_PFX(PeiVectorTable):
b _DefaultResetHandler
b _DefaultUndefined
diff --git a/ArmPlatformPkg/PrePeiCore/Arm/Exception.asm b/ArmPlatformPkg/PrePeiCore/Arm/Exception.asm index 55bd4af1dd..de438f913a 100644 --- a/ArmPlatformPkg/PrePeiCore/Arm/Exception.asm +++ b/ArmPlatformPkg/PrePeiCore/Arm/Exception.asm @@ -1,13 +1,13 @@ //
// Copyright (c) 2011, ARM Limited. All rights reserved.
-//
-// This program and the accompanying materials
-// are licensed and made available under the terms and conditions of the BSD License
-// which accompanies this distribution. The full text of the license may be found at
-// http://opensource.org/licenses/bsd-license.php
//
-// THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
-// WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
+// This program and the accompanying materials
+// are licensed and made available under the terms and conditions of the BSD License
+// which accompanies this distribution. The full text of the license may be found at
+// http://opensource.org/licenses/bsd-license.php
+//
+// THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
+// WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
//
//
@@ -17,15 +17,15 @@ IMPORT PeiCommonExceptionEntry
EXPORT PeiVectorTable
-
+
PRESERVE8
AREA PrePeiCoreException, CODE, READONLY, CODEALIGN, ALIGN=5
//============================================================
//Default Exception Handlers
//============================================================
-
-
+
+
PeiVectorTable
b _DefaultResetHandler
b _DefaultUndefined
@@ -75,7 +75,7 @@ _DefaultReserved cps #0x13 ; Switch to SVC for common stack
mov r0, #5
blx PeiCommonExceptionEntry
-
+
_DefaultIrq
sub r1, LR, #4
cps #0x13 ; Switch to SVC for common stack
diff --git a/ArmPlatformPkg/PrePeiCore/Arm/PrePeiCoreEntryPoint.S b/ArmPlatformPkg/PrePeiCore/Arm/PrePeiCoreEntryPoint.S index af4350b0cb..a6f19aff0f 100644 --- a/ArmPlatformPkg/PrePeiCore/Arm/PrePeiCoreEntryPoint.S +++ b/ArmPlatformPkg/PrePeiCore/Arm/PrePeiCoreEntryPoint.S @@ -1,13 +1,13 @@ //
// Copyright (c) 2011-2013, ARM Limited. All rights reserved.
-//
-// This program and the accompanying materials
-// are licensed and made available under the terms and conditions of the BSD License
-// which accompanies this distribution. The full text of the license may be found at
-// http://opensource.org/licenses/bsd-license.php
//
-// THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
-// WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
+// This program and the accompanying materials
+// are licensed and made available under the terms and conditions of the BSD License
+// which accompanies this distribution. The full text of the license may be found at
+// http://opensource.org/licenses/bsd-license.php
+//
+// THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
+// WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
//
//
@@ -74,7 +74,7 @@ _PrepareArguments: // Move sec startup address into a data register
// Ensure we're jumping to FV version of the code (not boot remapped alias)
ldr r3, StartupAddr
-
+
// Jump to PrePeiCore C code
// r0 = mp_id
// r1 = pei_core_address
diff --git a/ArmPlatformPkg/PrePeiCore/Arm/PrePeiCoreEntryPoint.asm b/ArmPlatformPkg/PrePeiCore/Arm/PrePeiCoreEntryPoint.asm index be1a767696..9ac7500f19 100644 --- a/ArmPlatformPkg/PrePeiCore/Arm/PrePeiCoreEntryPoint.asm +++ b/ArmPlatformPkg/PrePeiCore/Arm/PrePeiCoreEntryPoint.asm @@ -1,13 +1,13 @@ //
// Copyright (c) 2011-2013, ARM Limited. All rights reserved.
-//
-// This program and the accompanying materials
-// are licensed and made available under the terms and conditions of the BSD License
-// which accompanies this distribution. The full text of the license may be found at
-// http://opensource.org/licenses/bsd-license.php
//
-// THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
-// WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
+// This program and the accompanying materials
+// are licensed and made available under the terms and conditions of the BSD License
+// which accompanies this distribution. The full text of the license may be found at
+// http://opensource.org/licenses/bsd-license.php
+//
+// THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
+// WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
//
//
@@ -17,17 +17,17 @@ #include <AutoGen.h>
INCLUDE AsmMacroIoLib.inc
-
+
IMPORT CEntryPoint
IMPORT ArmPlatformGetCorePosition
IMPORT ArmPlatformIsPrimaryCore
IMPORT ArmReadMpidr
IMPORT ArmPlatformPeiBootAction
EXPORT _ModuleEntryPoint
-
+
PRESERVE8
AREA PrePeiCoreEntryPoint, CODE, READONLY
-
+
StartupAddr DCD CEntryPoint
_ModuleEntryPoint
@@ -38,7 +38,7 @@ _ModuleEntryPoint bl ArmReadMpidr
// Keep a copy of the MpId register value
mov r5, r0
-
+
// Is it the Primary Core ?
bl ArmPlatformIsPrimaryCore
@@ -76,7 +76,7 @@ _PrepareArguments // Move sec startup address into a data register
// Ensure we're jumping to FV version of the code (not boot remapped alias)
ldr r3, StartupAddr
-
+
// Jump to PrePeiCore C code
// r0 = mp_id
// r1 = pei_core_address
diff --git a/ArmPlatformPkg/PrePeiCore/Arm/SwitchStack.S b/ArmPlatformPkg/PrePeiCore/Arm/SwitchStack.S index 2543f58414..509dc205d9 100644 --- a/ArmPlatformPkg/PrePeiCore/Arm/SwitchStack.S +++ b/ArmPlatformPkg/PrePeiCore/Arm/SwitchStack.S @@ -1,4 +1,4 @@ -#------------------------------------------------------------------------------
+#------------------------------------------------------------------------------
#
# Copyright (c) 2006 - 2009, Intel Corporation. All rights reserved.<BR>
# Portions copyright (c) 2008 - 2009, Apple Inc. All rights reserved.<BR>
@@ -11,14 +11,14 @@ # WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
#
#------------------------------------------------------------------------------
-
+
.text
.align 3
GCC_ASM_EXPORT(SecSwitchStack)
-
+
#/**
# This allows the caller to switch the stack and return
#
@@ -33,11 +33,11 @@ GCC_ASM_EXPORT(SecSwitchStack) # VOID *StackDelta
# )#
#
-ASM_PFX(SecSwitchStack):
+ASM_PFX(SecSwitchStack):
mov R1, R13
add R1, R0, R1
mov R13, R1
bx LR
-
-
-
+
+
+
diff --git a/ArmPlatformPkg/PrePeiCore/Arm/SwitchStack.asm b/ArmPlatformPkg/PrePeiCore/Arm/SwitchStack.asm index 10da81d6ac..cb1308feab 100644 --- a/ArmPlatformPkg/PrePeiCore/Arm/SwitchStack.asm +++ b/ArmPlatformPkg/PrePeiCore/Arm/SwitchStack.asm @@ -1,4 +1,4 @@ -;------------------------------------------------------------------------------
+;------------------------------------------------------------------------------
;
; Copyright (c) 2006 - 2009, Intel Corporation. All rights reserved.<BR>
; Portions copyright (c) 2008 - 2009, Apple Inc. All rights reserved.<BR>
@@ -11,11 +11,11 @@ ; WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
;
;------------------------------------------------------------------------------
-
+
EXPORT SecSwitchStack
-
+
AREA Switch_Stack, CODE, READONLY
-
+
;/**
; This allows the caller to switch the stack and return
;
@@ -30,7 +30,7 @@ ; VOID *StackDelta
; );
;
-SecSwitchStack
+SecSwitchStack
MOV R1, SP
ADD R1, R0, R1
MOV SP, R1
diff --git a/ArmPlatformPkg/PrePeiCore/PrePeiCore.c b/ArmPlatformPkg/PrePeiCore/PrePeiCore.c index f33f376cf1..93d7e1c4c0 100644 --- a/ArmPlatformPkg/PrePeiCore/PrePeiCore.c +++ b/ArmPlatformPkg/PrePeiCore/PrePeiCore.c @@ -141,7 +141,7 @@ PrePeiCoreTemporaryRamSupport ( // Migrate the temporary memory heap to permanent memory heap.
//
CopyMem (NewHeap, OldHeap, CopySize >> 1);
-
+
SecSwitchStack ((UINTN)NewStack - (UINTN)OldStack);
return EFI_SUCCESS;
diff --git a/ArmPlatformPkg/PrePeiCore/PrePeiCoreMPCore.inf b/ArmPlatformPkg/PrePeiCore/PrePeiCoreMPCore.inf index 3b441d4439..96a542deb6 100644 --- a/ArmPlatformPkg/PrePeiCore/PrePeiCoreMPCore.inf +++ b/ArmPlatformPkg/PrePeiCore/PrePeiCoreMPCore.inf @@ -1,16 +1,16 @@ #/** @file
# Pre PeiCore - Hand-off to PEI Core in Normal World
-#
+#
# Copyright (c) 2011-2012, ARM Limited. All rights reserved.
-#
-# This program and the accompanying materials
-# are licensed and made available under the terms and conditions of the BSD License
-# which accompanies this distribution. The full text of the license may be found at
-# http://opensource.org/licenses/bsd-license.php
#
-# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
-# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
-#
+# This program and the accompanying materials
+# are licensed and made available under the terms and conditions of the BSD License
+# which accompanies this distribution. The full text of the license may be found at
+# http://opensource.org/licenses/bsd-license.php
+#
+# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
+# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
+#
#**/
[Defines]
@@ -74,9 +74,9 @@ gArmPlatformTokenSpaceGuid.PcdCPUCoresStackBase
gArmPlatformTokenSpaceGuid.PcdCPUCorePrimaryStackSize
gArmPlatformTokenSpaceGuid.PcdCPUCoreSecondaryStackSize
-
+
gArmPlatformTokenSpaceGuid.PcdPeiGlobalVariableSize
-
+
gArmTokenSpaceGuid.PcdGicDistributorBase
gArmTokenSpaceGuid.PcdGicInterruptInterfaceBase
gArmTokenSpaceGuid.PcdGicSgiIntId
diff --git a/ArmPlatformPkg/PrePeiCore/PrePeiCoreUniCore.inf b/ArmPlatformPkg/PrePeiCore/PrePeiCoreUniCore.inf index f50d21fa6e..ecef43231d 100644 --- a/ArmPlatformPkg/PrePeiCore/PrePeiCoreUniCore.inf +++ b/ArmPlatformPkg/PrePeiCore/PrePeiCoreUniCore.inf @@ -1,16 +1,16 @@ #/** @file
# Pre PeiCore - Hand-off to PEI Core in Normal World
-#
+#
# Copyright (c) 2011, ARM Limited. All rights reserved.
-#
-# This program and the accompanying materials
-# are licensed and made available under the terms and conditions of the BSD License
-# which accompanies this distribution. The full text of the license may be found at
-# http://opensource.org/licenses/bsd-license.php
#
-# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
-# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
-#
+# This program and the accompanying materials
+# are licensed and made available under the terms and conditions of the BSD License
+# which accompanies this distribution. The full text of the license may be found at
+# http://opensource.org/licenses/bsd-license.php
+#
+# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
+# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
+#
#**/
[Defines]
@@ -70,8 +70,8 @@ gArmPlatformTokenSpaceGuid.PcdCPUCoresStackBase
gArmPlatformTokenSpaceGuid.PcdCPUCorePrimaryStackSize
gArmPlatformTokenSpaceGuid.PcdCPUCoreSecondaryStackSize
-
+
gArmPlatformTokenSpaceGuid.PcdPeiGlobalVariableSize
-
+
gArmTokenSpaceGuid.PcdGicDistributorBase
gArmTokenSpaceGuid.PcdGicInterruptInterfaceBase
diff --git a/ArmPlatformPkg/PrePi/Arm/ModuleEntryPoint.asm b/ArmPlatformPkg/PrePi/Arm/ModuleEntryPoint.asm index 028a9a1b22..4e2bb16c99 100644 --- a/ArmPlatformPkg/PrePi/Arm/ModuleEntryPoint.asm +++ b/ArmPlatformPkg/PrePi/Arm/ModuleEntryPoint.asm @@ -19,18 +19,18 @@ #include <Chipset/ArmV7.h>
INCLUDE AsmMacroIoLib.inc
-
+
IMPORT CEntryPoint
IMPORT ArmPlatformIsPrimaryCore
IMPORT ArmReadMpidr
IMPORT ArmPlatformPeiBootAction
IMPORT ArmPlatformStackSet
-
+
EXPORT _ModuleEntryPoint
PRESERVE8
AREA PrePiCoreEntryPoint, CODE, READONLY
-
+
StartupAddr DCD CEntryPoint
_ModuleEntryPoint
diff --git a/ArmPlatformPkg/PrePi/LzmaDecompress.h b/ArmPlatformPkg/PrePi/LzmaDecompress.h index e4483b6823..a79ff343d2 100644 --- a/ArmPlatformPkg/PrePi/LzmaDecompress.h +++ b/ArmPlatformPkg/PrePi/LzmaDecompress.h @@ -19,16 +19,16 @@ Examines a GUIDed section and returns the size of the decoded buffer and the
size of an scratch buffer required to actually decode the data in a GUIDed section.
- Examines a GUIDed section specified by InputSection.
+ Examines a GUIDed section specified by InputSection.
If GUID for InputSection does not match the GUID that this handler supports,
- then RETURN_UNSUPPORTED is returned.
+ then RETURN_UNSUPPORTED is returned.
If the required information can not be retrieved from InputSection,
then RETURN_INVALID_PARAMETER is returned.
If the GUID of InputSection does match the GUID that this handler supports,
then the size required to hold the decoded buffer is returned in OututBufferSize,
the size of an optional scratch buffer is returned in ScratchSize, and the Attributes field
from EFI_GUID_DEFINED_SECTION header of InputSection is returned in SectionAttribute.
-
+
If InputSection is NULL, then ASSERT().
If OutputBufferSize is NULL, then ASSERT().
If ScratchBufferSize is NULL, then ASSERT().
@@ -59,16 +59,16 @@ LzmaGuidedSectionGetInfo ( /**
Decompress a LZAM compressed GUIDed section into a caller allocated output buffer.
-
- Decodes the GUIDed section specified by InputSection.
- If GUID for InputSection does not match the GUID that this handler supports, then RETURN_UNSUPPORTED is returned.
+
+ Decodes the GUIDed section specified by InputSection.
+ If GUID for InputSection does not match the GUID that this handler supports, then RETURN_UNSUPPORTED is returned.
If the data in InputSection can not be decoded, then RETURN_INVALID_PARAMETER is returned.
If the GUID of InputSection does match the GUID that this handler supports, then InputSection
is decoded into the buffer specified by OutputBuffer and the authentication status of this
decode operation is returned in AuthenticationStatus. If the decoded buffer is identical to the
data in InputSection, then OutputBuffer is set to point at the data in InputSection. Otherwise,
the decoded data will be placed in caller allocated buffer specified by OutputBuffer.
-
+
If InputSection is NULL, then ASSERT().
If OutputBuffer is NULL, then ASSERT().
If ScratchBuffer is NULL and this decode operation requires a scratch buffer, then ASSERT().
@@ -76,10 +76,10 @@ LzmaGuidedSectionGetInfo ( @param[in] InputSection A pointer to a GUIDed section of an FFS formatted file.
- @param[out] OutputBuffer A pointer to a buffer that contains the result of a decode operation.
+ @param[out] OutputBuffer A pointer to a buffer that contains the result of a decode operation.
@param[out] ScratchBuffer A caller allocated buffer that may be required by this function
- as a scratch buffer to perform the decode operation.
- @param[out] AuthenticationStatus
+ as a scratch buffer to perform the decode operation.
+ @param[out] AuthenticationStatus
A pointer to the authentication status of the decoded output buffer.
See the definition of authentication status in the EFI_PEI_GUIDED_SECTION_EXTRACTION_PPI
section of the PI Specification. EFI_AUTH_STATUS_PLATFORM_OVERRIDE must
@@ -98,6 +98,6 @@ LzmaGuidedSectionExtraction ( OUT VOID *ScratchBuffer, OPTIONAL
OUT UINT32 *AuthenticationStatus
);
-
+
#endif // __LZMADECOMPRESS_H__
diff --git a/ArmPlatformPkg/PrePi/PeiMPCore.inf b/ArmPlatformPkg/PrePi/PeiMPCore.inf index 38ba50c138..e7d3d6bb60 100755 --- a/ArmPlatformPkg/PrePi/PeiMPCore.inf +++ b/ArmPlatformPkg/PrePi/PeiMPCore.inf @@ -1,15 +1,15 @@ #/** @file
-#
+#
# Copyright (c) 2011-2014, ARM Ltd. All rights reserved.<BR>
-#
+#
# This program and the accompanying materials
# are licensed and made available under the terms and conditions of the BSD License
# which accompanies this distribution. The full text of the license may be found at
# http://opensource.org/licenses/bsd-license.php
-#
+#
# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
-#
+#
#**/
[Defines]
@@ -31,7 +31,7 @@ [Sources.AArch64]
AArch64/ArchPrePi.c
AArch64/ModuleEntryPoint.S
-
+
[Packages]
MdePkg/MdePkg.dec
MdeModulePkg/MdeModulePkg.dec
@@ -69,13 +69,13 @@ gArmGlobalVariableGuid
gArmMpCoreInfoGuid
-[FeaturePcd]
+[FeaturePcd]
gEmbeddedTokenSpaceGuid.PcdPrePiProduceMemoryTypeInformationHob
gArmPlatformTokenSpaceGuid.PcdSendSgiToBringUpSecondaryCores
[FixedPcd]
gEfiMdeModulePkgTokenSpaceGuid.PcdFirmwareVersionString
-
+
gArmTokenSpaceGuid.PcdVFPEnabled
gArmTokenSpaceGuid.PcdFdBaseAddress
@@ -96,7 +96,7 @@ gArmTokenSpaceGuid.PcdSystemMemoryBase
gArmTokenSpaceGuid.PcdSystemMemorySize
gArmPlatformTokenSpaceGuid.PcdSystemMemoryUefiRegionSize
-
+
gArmPlatformTokenSpaceGuid.PcdCoreCount
gArmTokenSpaceGuid.PcdArmPrimaryCore
diff --git a/ArmPlatformPkg/PrePi/PeiUniCore.inf b/ArmPlatformPkg/PrePi/PeiUniCore.inf index ec3b898768..1c0737bded 100755 --- a/ArmPlatformPkg/PrePi/PeiUniCore.inf +++ b/ArmPlatformPkg/PrePi/PeiUniCore.inf @@ -1,15 +1,15 @@ #/** @file
-#
+#
# Copyright (c) 2011-2014, ARM Ltd. All rights reserved.<BR>
-#
+#
# This program and the accompanying materials
# are licensed and made available under the terms and conditions of the BSD License
# which accompanies this distribution. The full text of the license may be found at
# http://opensource.org/licenses/bsd-license.php
-#
+#
# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
-#
+#
#**/
[Defines]
@@ -31,7 +31,7 @@ [Sources.AArch64]
AArch64/ArchPrePi.c
AArch64/ModuleEntryPoint.S
-
+
[Packages]
MdePkg/MdePkg.dec
MdeModulePkg/MdeModulePkg.dec
@@ -68,13 +68,13 @@ gArmGlobalVariableGuid
gArmMpCoreInfoGuid
-[FeaturePcd]
+[FeaturePcd]
gEmbeddedTokenSpaceGuid.PcdPrePiProduceMemoryTypeInformationHob
gArmPlatformTokenSpaceGuid.PcdSendSgiToBringUpSecondaryCores
[FixedPcd]
gEfiMdeModulePkgTokenSpaceGuid.PcdFirmwareVersionString
-
+
gArmTokenSpaceGuid.PcdVFPEnabled
gArmTokenSpaceGuid.PcdFdBaseAddress
@@ -91,7 +91,7 @@ gArmTokenSpaceGuid.PcdSystemMemoryBase
gArmTokenSpaceGuid.PcdSystemMemorySize
gArmPlatformTokenSpaceGuid.PcdSystemMemoryUefiRegionSize
-
+
gArmPlatformTokenSpaceGuid.PcdCoreCount
gEmbeddedTokenSpaceGuid.PcdPrePiCpuMemorySize
diff --git a/ArmPlatformPkg/PrePi/PrePi.c b/ArmPlatformPkg/PrePi/PrePi.c index 84b01b3fbe..9a5e067ef5 100755 --- a/ArmPlatformPkg/PrePi/PrePi.c +++ b/ArmPlatformPkg/PrePi/PrePi.c @@ -107,7 +107,7 @@ PrePiMain ( UINTN StacksSize;
// If ensure the FD is either part of the System Memory or totally outside of the System Memory (XIP)
- ASSERT (IS_XIP() ||
+ ASSERT (IS_XIP() ||
((FixedPcdGet32 (PcdFdBaseAddress) >= FixedPcdGet64 (PcdSystemMemoryBase)) &&
((UINT32)(FixedPcdGet32 (PcdFdBaseAddress) + FixedPcdGet32 (PcdFdSize)) <= (UINT32)(FixedPcdGet64 (PcdSystemMemoryBase) + FixedPcdGet64 (PcdSystemMemorySize)))));
@@ -123,7 +123,7 @@ PrePiMain ( // Initialize the Debug Agent for Source Level Debugging
InitializeDebugAgent (DEBUG_AGENT_INIT_POSTMEM_SEC, NULL, NULL);
SaveAndSetDebugTimerInterrupt (TRUE);
-
+
// Declare the PI/UEFI memory region
HobList = HobConstructor (
(VOID*)UefiMemoryBase,
@@ -208,7 +208,7 @@ CEntryPoint ( )
{
UINT64 StartTimeStamp;
-
+
ASSERT(!ArmIsMpCore() || (PcdGet32 (PcdCoreCount) > 1));
// Initialize the platform specific controllers
@@ -245,7 +245,7 @@ CEntryPoint ( ArmCallWFE ();
}
}
-
+
// If not primary Jump to Secondary Main
if (ArmPlatformIsPrimaryCore (MpId)) {
// Goto primary Main.
diff --git a/ArmPlatformPkg/Scripts/Ds5/build_report.py b/ArmPlatformPkg/Scripts/Ds5/build_report.py index e59230090f..effaf1db48 100644 --- a/ArmPlatformPkg/Scripts/Ds5/build_report.py +++ b/ArmPlatformPkg/Scripts/Ds5/build_report.py @@ -1,26 +1,26 @@ #
# Copyright (c) 2011-2012, ARM Limited. All rights reserved.
-#
-# This program and the accompanying materials
-# are licensed and made available under the terms and conditions of the BSD License
-# which accompanies this distribution. The full text of the license may be found at
-# http://opensource.org/licenses/bsd-license.php
#
-# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
-# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
+# This program and the accompanying materials
+# are licensed and made available under the terms and conditions of the BSD License
+# which accompanies this distribution. The full text of the license may be found at
+# http://opensource.org/licenses/bsd-license.php
+#
+# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
+# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
#
import re
class BuildReport:
PCDs = {}
-
+
def parse_platform_summary(self, file):
pass
-
+
def parse_pcd_report(self, report_file):
pcd_reg = re.compile(" (\*P|\*F|\*M| ) (\w+)(\ +)\: (.*) \((\w+)\) = (.*)\n")
-
+
for line in report_file.xreadlines():
stripped_line = line.strip()
if re.match("\<=+\>", stripped_line):
@@ -32,19 +32,19 @@ class BuildReport: m = pcd_reg.match(line)
if m:
self.PCDs[guid][m.group(2)] = (m.group(6).strip(),m.group(5))
-
+
def parse_firmware_device(self, file):
pass
-
+
def parse_module_summary(self, file):
#print "Module Summary"
pass
-
+
CONST_SECTION_HEADERS = [('Platform Summary', parse_platform_summary),
('Platform Configuration Database Report',parse_pcd_report),
('Firmware Device (FD)',parse_firmware_device),
('Module Summary',parse_module_summary)]
-
+
def __init__(self, filename = 'report.log'):
report_file = open(filename, 'r')
for line in report_file.xreadlines():
diff --git a/ArmPlatformPkg/Scripts/Ds5/cmd_load_symbols.py b/ArmPlatformPkg/Scripts/Ds5/cmd_load_symbols.py index 994a475cb9..280b6b4de0 100644 --- a/ArmPlatformPkg/Scripts/Ds5/cmd_load_symbols.py +++ b/ArmPlatformPkg/Scripts/Ds5/cmd_load_symbols.py @@ -1,13 +1,13 @@ #
# Copyright (c) 2011-2013, ARM Limited. All rights reserved.
-#
-# This program and the accompanying materials
-# are licensed and made available under the terms and conditions of the BSD License
-# which accompanies this distribution. The full text of the license may be found at
-# http://opensource.org/licenses/bsd-license.php
#
-# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
-# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
+# This program and the accompanying materials
+# are licensed and made available under the terms and conditions of the BSD License
+# which accompanies this distribution. The full text of the license may be found at
+# http://opensource.org/licenses/bsd-license.php
+#
+# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
+# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
#
from arm_ds.debugger_v1 import Debugger
@@ -38,7 +38,7 @@ if (opts is None) or (not opts): else:
region_reg = re.compile("\((.*),(.*)\)")
base_reg = re.compile("(.*)")
-
+
for o,a in opts:
region_type = None
regex = None
@@ -63,7 +63,7 @@ else: regex = region_reg
else:
assert False, "Unhandled option (%s)" % o
-
+
if region_type:
m = regex.match(a)
if m:
@@ -76,7 +76,7 @@ else: raise Exception('cmd_load_symbols', "Expect a base address")
else:
raise Exception('cmd_load_symbols', "Expect a region format as (base,size)")
-
+
# Debugger object for accessing the debugger
debugger = Debugger()
@@ -89,7 +89,7 @@ ec = debugger.getExecutionContext(0) try:
armplatform_debugger = edk2_debugger.ArmPlatformDebugger(ec, report_file, regions, verbose)
-
+
if load_all:
armplatform_debugger.load_all_symbols()
else:
diff --git a/ArmPlatformPkg/Scripts/Ds5/edk2_debugger.py b/ArmPlatformPkg/Scripts/Ds5/edk2_debugger.py index b6108d6a19..cb420af898 100644 --- a/ArmPlatformPkg/Scripts/Ds5/edk2_debugger.py +++ b/ArmPlatformPkg/Scripts/Ds5/edk2_debugger.py @@ -1,13 +1,13 @@ #
# Copyright (c) 2011-2013, ARM Limited. All rights reserved.
-#
-# This program and the accompanying materials
-# are licensed and made available under the terms and conditions of the BSD License
-# which accompanies this distribution. The full text of the license may be found at
-# http://opensource.org/licenses/bsd-license.php
#
-# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
-# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
+# This program and the accompanying materials
+# are licensed and made available under the terms and conditions of the BSD License
+# which accompanies this distribution. The full text of the license may be found at
+# http://opensource.org/licenses/bsd-license.php
+#
+# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
+# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
#
import os
@@ -29,11 +29,11 @@ def dump_fv(ec, fv_base, fv_size): fv = firmware_volume.FirmwareVolume(ec,
int(build.PCDs['gArmTokenSpaceGuid']['PcdFvBaseAddress'][0],16),
int(build.PCDs['gArmTokenSpaceGuid']['PcdFvSize'][0],16))
-
+
ffs = fv.get_next_ffs()
- while ffs != None:
+ while ffs != None:
print "# %s" % ffs
-
+
section = ffs.get_next_section()
while section != None:
print "\t%s" % section
@@ -42,21 +42,21 @@ def dump_fv(ec, fv_base, fv_size): except Exception:
pass
section = ffs.get_next_section(section)
-
+
ffs = fv.get_next_ffs(ffs)
def dump_system_table(ec, mem_base, mem_size):
st = system_table.SystemTable(ec, mem_base, mem_size)
-
+
debug_info_table_base = st.get_configuration_table(system_table.DebugInfoTable.CONST_DEBUG_INFO_TABLE_GUID)
-
+
debug_info_table = system_table.DebugInfoTable(ec, debug_info_table_base)
debug_info_table.dump()
def load_symbol_from_file(ec, filename, address, verbose = False):
if verbose:
print "Add symbols of %s at 0x%x" % (filename, address)
-
+
try:
ec.getImageService().addSymbols(filename, address)
except:
@@ -81,28 +81,28 @@ class ArmPlatform: self.sysmembase = sysmembase
self.sysmemsize = sysmemsize
self.fvs = fvs
-
+
class ArmPlatformDebugger:
system_table = None
firmware_volumes = {}
-
+
REGION_TYPE_SYSMEM = 1
REGION_TYPE_ROM = 2
REGION_TYPE_FV = 3
-
+
def __init__(self, ec, report_log, regions, verbose = False):
self.ec = ec
self.verbose = verbose
fvs = []
sysmem_base = None
sysmem_size = None
-
+
if report_log and os.path.isfile(report_log):
try:
self.build = build_report.BuildReport(report_log)
except IOError:
raise IOError(2, 'Report \'%s\' is not valid' % report_log)
-
+
# Generate list of supported Firmware Volumes
if self.build.PCDs['gArmTokenSpaceGuid'].has_key('PcdFvSize') and int(self.build.PCDs['gArmTokenSpaceGuid']['PcdFvSize'][0],16) != 0:
fvs.append((int(self.build.PCDs['gArmTokenSpaceGuid']['PcdFvBaseAddress'][0],16),int(self.build.PCDs['gArmTokenSpaceGuid']['PcdFvSize'][0],16)))
@@ -110,7 +110,7 @@ class ArmPlatformDebugger: fvs.append((int(self.build.PCDs['gArmTokenSpaceGuid']['PcdSecureFvBaseAddress'][0],16),int(self.build.PCDs['gArmTokenSpaceGuid']['PcdSecureFvSize'][0],16)))
if self.build.PCDs['gArmTokenSpaceGuid'].has_key('PcdHypFvSize') and int(self.build.PCDs['gArmTokenSpaceGuid']['PcdHypFvSize'][0],16) != 0:
fvs.append((int(self.build.PCDs['gArmTokenSpaceGuid']['PcdHypFvBaseAddress'][0],16),int(self.build.PCDs['gArmTokenSpaceGuid']['PcdHypFvSize'][0],16)))
-
+
sysmem_base = int(self.build.PCDs['gArmTokenSpaceGuid']['PcdSystemMemoryBase'][0],16)
sysmem_size = int(self.build.PCDs['gArmTokenSpaceGuid']['PcdSystemMemorySize'][0],16)
else:
@@ -127,9 +127,9 @@ class ArmPlatformDebugger: fvs.append((base,0))
else:
print "Region type '%d' Not Supported" % region[0]
-
+
self.platform = ArmPlatform(sysmem_base, sysmem_size, fvs)
-
+
def in_sysmem(self, addr):
return (self.platform.sysmembase is not None) and (self.platform.sysmembase <= addr) and (addr < self.platform.sysmembase + self.platform.sysmemsize)
@@ -146,21 +146,21 @@ class ArmPlatformDebugger: pc = int(self.ec.getRegisterService().getValue('PC')) & 0xFFFFFFFF
if self.in_fv(pc):
debug_infos = []
-
+
(fv_base, fv_size) = self.get_fv_at(pc)
-
+
if self.firmware_volumes.has_key(fv_base) == False:
self.firmware_volumes[fv_base] = firmware_volume.FirmwareVolume(self.ec, fv_base, fv_size)
-
+
stack_frame = self.ec.getTopLevelStackFrame()
info = self.firmware_volumes[fv_base].load_symbols_at(int(stack_frame.getRegisterService().getValue('PC')) & 0xFFFFFFFF, self.verbose)
debug_infos.append(info)
while stack_frame.next() is not None:
stack_frame = stack_frame.next()
-
+
# Stack frame attached to 'PC'
pc = int(stack_frame.getRegisterService().getValue('PC')) & 0xFFFFFFFF
-
+
# Check if the symbols for this stack frame have already been loaded
found = False
for debug_info in debug_infos:
@@ -169,28 +169,28 @@ class ArmPlatformDebugger: if found == False:
info = self.firmware_volumes[fv_base].load_symbols_at(pc)
debug_infos.append(info)
-
+
#self.firmware_volumes[fv_base].load_symbols_at(pc)
elif self.in_sysmem(pc):
debug_infos = []
-
+
if self.system_table is None:
# Find the System Table
self.system_table = system_table.SystemTable(self.ec, self.platform.sysmembase, self.platform.sysmemsize)
-
+
# Find the Debug Info Table
debug_info_table_base = self.system_table.get_configuration_table(system_table.DebugInfoTable.CONST_DEBUG_INFO_TABLE_GUID)
self.debug_info_table = system_table.DebugInfoTable(self.ec, debug_info_table_base)
-
+
stack_frame = self.ec.getTopLevelStackFrame()
info = self.debug_info_table.load_symbols_at(int(stack_frame.getRegisterService().getValue('PC')) & 0xFFFFFFFF, self.verbose)
debug_infos.append(info)
while stack_frame.next() is not None:
stack_frame = stack_frame.next()
-
+
# Stack frame attached to 'PC'
pc = int(stack_frame.getRegisterService().getValue('PC')) & 0xFFFFFFFF
-
+
# Check if the symbols for this stack frame have already been loaded
found = False
for debug_info in debug_infos:
@@ -202,16 +202,16 @@ class ArmPlatformDebugger: debug_infos.append(info)
except:
pass
-
+
#self.debug_info_table.load_symbols_at(pc)
else:
raise Exception('ArmPlatformDebugger', "Not supported region")
-
+
def load_all_symbols(self):
# Load all the XIP symbols attached to the Firmware Volume
for (fv_base, fv_size) in self.platform.fvs:
if self.firmware_volumes.has_key(fv_base) == False:
- self.firmware_volumes[fv_base] = firmware_volume.FirmwareVolume(self.ec, fv_base, fv_size)
+ self.firmware_volumes[fv_base] = firmware_volume.FirmwareVolume(self.ec, fv_base, fv_size)
self.firmware_volumes[fv_base].load_all_symbols(self.verbose)
try:
@@ -219,12 +219,12 @@ class ArmPlatformDebugger: if self.system_table is None:
# Find the System Table
self.system_table = system_table.SystemTable(self.ec, self.platform.sysmembase, self.platform.sysmemsize)
-
-
+
+
# Find the Debug Info Table
debug_info_table_base = self.system_table.get_configuration_table(system_table.DebugInfoTable.CONST_DEBUG_INFO_TABLE_GUID)
self.debug_info_table = system_table.DebugInfoTable(self.ec, debug_info_table_base)
-
+
self.debug_info_table.load_all_symbols(self.verbose)
except:
# Debugger exception could be excepted if DRAM has not been initialized or if we have not started to run from DRAM yet
diff --git a/ArmPlatformPkg/Scripts/Ds5/firmware_volume.py b/ArmPlatformPkg/Scripts/Ds5/firmware_volume.py index cd6f34acaf..8e3a8adc9b 100644 --- a/ArmPlatformPkg/Scripts/Ds5/firmware_volume.py +++ b/ArmPlatformPkg/Scripts/Ds5/firmware_volume.py @@ -1,13 +1,13 @@ #
# Copyright (c) 2011-2013, ARM Limited. All rights reserved.
-#
-# This program and the accompanying materials
-# are licensed and made available under the terms and conditions of the BSD License
-# which accompanies this distribution. The full text of the license may be found at
-# http://opensource.org/licenses/bsd-license.php
#
-# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
-# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
+# This program and the accompanying materials
+# are licensed and made available under the terms and conditions of the BSD License
+# which accompanies this distribution. The full text of the license may be found at
+# http://opensource.org/licenses/bsd-license.php
+#
+# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
+# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
#
from arm_ds.debugger_v1 import DebugException
@@ -16,29 +16,29 @@ import struct import string
import edk2_debugger
-
+
class EfiFileSection(object):
EFI_SECTION_PE32 = 0x10
EFI_SECTION_PIC = 0x11
EFI_SECTION_TE = 0x12
-
+
EFI_IMAGE_DEBUG_TYPE_CODEVIEW = 0x2
-
+
SIZEOF_EFI_FFS_FILE_HEADER = 0x28
def __init__(self, ec, base):
self.base = base
self.ec = ec
-
+
def __str__(self):
return "FileSection(type:0x%X, size:0x%x)" % (self.get_type(), self.get_size())
-
+
def get_base(self):
return self.base
-
+
def get_type(self):
return struct.unpack("B", self.ec.getMemoryService().read(self.base + 0x3, 1, 8))[0]
-
+
def get_size(self):
return (struct.unpack("<I", self.ec.getMemoryService().read(self.base, 4, 32))[0] & 0x00ffffff)
@@ -55,23 +55,23 @@ class EfiFileSection(object): class EfiSectionTE:
SIZEOF_EFI_TE_IMAGE_HEADER = 0x28
EFI_TE_IMAGE_SIGNATURE = ('V','Z')
-
+
def __init__(self, ec, base_te):
self.ec = ec
self.base_te = int(base_te)
te_sig = struct.unpack("cc", self.ec.getMemoryService().read(self.base_te, 2, 32))
if te_sig != EfiSectionTE.EFI_TE_IMAGE_SIGNATURE:
raise Exception("EfiFileSectionTE","TE Signature incorrect")
-
+
def get_debug_filepath(self):
stripped_size = struct.unpack("<H", self.ec.getMemoryService().read(self.base_te + 0x6, 2, 32))[0]
stripped_size -= EfiSectionTE.SIZEOF_EFI_TE_IMAGE_HEADER
-
+
debug_dir_entry_rva = self.ec.getMemoryService().readMemory32(self.base_te + 0x20)
if debug_dir_entry_rva == 0:
raise Exception("EfiFileSectionTE","No debug directory for image")
debug_dir_entry_rva -= stripped_size
-
+
debug_type = self.ec.getMemoryService().readMemory32(self.base_te + debug_dir_entry_rva + 0xC)
if (debug_type != 0xdf) and (debug_type != EfiFileSection.EFI_IMAGE_DEBUG_TYPE_CODEVIEW):
raise Exception("EfiFileSectionTE","Debug type is not dwarf")
@@ -82,20 +82,20 @@ class EfiSectionTE: dwarf_sig = struct.unpack("cccc", self.ec.getMemoryService().read(self.base_te + debug_rva, 4, 32))
if (dwarf_sig != 0x66727764) and (dwarf_sig != FirmwareFile.CONST_NB10_SIGNATURE):
raise Exception("EfiFileSectionTE","Dwarf debug signature not found")
-
+
if dwarf_sig == 0x66727764:
filename = self.base_te + debug_rva + 0xc
else:
filename = self.base_te + debug_rva + 0x10
filename = struct.unpack("200s", self.ec.getMemoryService().read(filename, 200, 32))[0]
return filename[0:string.find(filename,'\0')]
-
+
def get_debug_elfbase(self):
stripped_size = struct.unpack("<H", self.ec.getMemoryService().read(self.base_te + 0x6, 2, 32))[0]
stripped_size -= EfiSectionTE.SIZEOF_EFI_TE_IMAGE_HEADER
-
+
base_of_code = self.ec.getMemoryService().readMemory32(self.base_te + 0xC)
-
+
return self.base_te + base_of_code - stripped_size
class EfiSectionPE32:
@@ -115,28 +115,28 @@ class EfiSectionPE32: debug_type = self.ec.getMemoryService().readMemory32(self.base_pe32 + debug_dir_entry_rva + 0xC)
if (debug_type != 0xdf) and (debug_type != EfiFileSection.EFI_IMAGE_DEBUG_TYPE_CODEVIEW):
raise Exception("EfiFileSectionPE32","Debug type is not dwarf")
-
-
+
+
debug_rva = self.ec.getMemoryService().readMemory32(self.base_pe32 + debug_dir_entry_rva + 0x14)
-
+
dwarf_sig = struct.unpack("cccc", self.ec.getMemoryService().read(str(self.base_pe32 + debug_rva), 4, 32))
if (dwarf_sig != 0x66727764) and (dwarf_sig != FirmwareFile.CONST_NB10_SIGNATURE):
raise Exception("EfiFileSectionPE32","Dwarf debug signature not found")
-
+
if dwarf_sig == 0x66727764:
filename = self.base_pe32 + debug_rva + 0xc
else:
filename = self.base_pe32 + debug_rva + 0x10
filename = struct.unpack("200s", self.ec.getMemoryService().read(str(filename), 200, 32))[0]
return filename[0:string.find(filename,'\0')]
-
+
def get_debug_elfbase(self):
# Offset from dos hdr to PE file hdr
pe_file_header = self.base_pe32 + self.ec.getMemoryService().readMemory32(self.base_pe32 + 0x3C)
-
+
base_of_code = self.base_pe32 + self.ec.getMemoryService().readMemory32(pe_file_header + 0x28)
base_of_data = self.base_pe32 + self.ec.getMemoryService().readMemory32(pe_file_header + 0x2C)
-
+
if (base_of_code < base_of_data) and (base_of_code != 0):
return base_of_code
else:
@@ -160,33 +160,33 @@ class EfiSectionPE64: debug_type = self.ec.getMemoryService().readMemory32(self.base_pe64 + debug_dir_entry_rva + 0xC)
if (debug_type != 0xdf) and (debug_type != EfiFileSection.EFI_IMAGE_DEBUG_TYPE_CODEVIEW):
raise Exception("EfiFileSectionPE64","Debug type is not dwarf")
-
-
+
+
debug_rva = self.ec.getMemoryService().readMemory32(self.base_pe64 + debug_dir_entry_rva + 0x14)
-
+
dwarf_sig = struct.unpack("cccc", self.ec.getMemoryService().read(str(self.base_pe64 + debug_rva), 4, 32))
if (dwarf_sig != 0x66727764) and (dwarf_sig != FirmwareFile.CONST_NB10_SIGNATURE):
raise Exception("EfiFileSectionPE64","Dwarf debug signature not found")
-
+
if dwarf_sig == 0x66727764:
filename = self.base_pe64 + debug_rva + 0xc
else:
filename = self.base_pe64 + debug_rva + 0x10
filename = struct.unpack("200s", self.ec.getMemoryService().read(str(filename), 200, 32))[0]
return filename[0:string.find(filename,'\0')]
-
+
def get_debug_elfbase(self):
# Offset from dos hdr to PE file hdr
pe_file_header = self.base_pe64 + self.ec.getMemoryService().readMemory32(self.base_pe64 + 0x3C)
-
+
base_of_code = self.base_pe64 + self.ec.getMemoryService().readMemory32(pe_file_header + 0x28)
base_of_data = self.base_pe64 + self.ec.getMemoryService().readMemory32(pe_file_header + 0x2C)
-
+
if (base_of_code < base_of_data) and (base_of_code != 0):
return base_of_code
else:
return base_of_data
-
+
class FirmwareFile:
EFI_FV_FILETYPE_RAW = 0x01
EFI_FV_FILETYPE_FREEFORM = 0x02
@@ -199,42 +199,42 @@ class FirmwareFile: EFI_FV_FILETYPE_APPLICATION = 0x09
EFI_FV_FILETYPE_FIRMWARE_VOLUME_IMAGE = 0x0B
EFI_FV_FILETYPE_FFS_MIN = 0xF0
-
+
CONST_NB10_SIGNATURE = ('N','B','1','0')
-
+
def __init__(self, fv, base, ec):
self.fv = fv
self.base = base
self.ec = ec
-
+
def __str__(self):
return "FFS(state:0x%x, type:0x%X, size:0x%x)" % (self.get_state(), self.get_type(), self.get_size())
-
+
def get_base(self):
return self.base
-
+
def get_size(self):
size = (self.ec.getMemoryService().readMemory32(self.base + 0x14) & 0x00ffffff)
# Occupied size is the size considering the alignment
return size + ((0x8 - (size & 0x7)) & 0x7)
-
+
def get_type(self):
return self.ec.getMemoryService().readMemory8(self.base + 0x12)
-
+
def get_state(self):
state = self.ec.getMemoryService().readMemory8(self.base + 0x17)
-
+
polarity = self.fv.get_polarity()
if polarity:
state = ~state
-
+
highest_bit = 0x80;
while (highest_bit != 0) and ((highest_bit & state) == 0):
highest_bit >>= 1
-
+
return highest_bit
-
+
def get_next_section(self, section=None):
if section == None:
if self.get_type() != FirmwareFile.EFI_FV_FILETYPE_FFS_MIN:
@@ -243,7 +243,7 @@ class FirmwareFile: return None
else:
section_base = int(section.get_base() + section.get_size())
-
+
# Align to next 4 byte boundary
if (section_base & 0x3) != 0:
section_base = section_base + 0x4 - (section_base & 0x3)
@@ -252,38 +252,38 @@ class FirmwareFile: return EfiFileSection(self.ec, section_base)
else:
return None
-
+
class FirmwareVolume:
CONST_FV_SIGNATURE = ('_','F','V','H')
EFI_FVB2_ERASE_POLARITY = 0x800
-
+
DebugInfos = []
-
+
def __init__(self, ec, fv_base, fv_size):
self.ec = ec
self.fv_base = fv_base
self.fv_size = fv_size
-
+
try:
signature = struct.unpack("cccc", self.ec.getMemoryService().read(fv_base + 0x28, 4, 32))
except DebugException:
raise Exception("FirmwareVolume", "Not possible to access the defined firmware volume at [0x%X,0x%X]. Could be the used build report does not correspond to your current debugging context." % (int(fv_base),int(fv_base+fv_size)))
if signature != FirmwareVolume.CONST_FV_SIGNATURE:
raise Exception("FirmwareVolume", "This is not a valid firmware volume")
-
+
def get_size(self):
return self.ec.getMemoryService().readMemory32(self.fv_base + 0x20)
-
+
def get_attributes(self):
return self.ec.getMemoryService().readMemory32(self.fv_base + 0x2C)
-
+
def get_polarity(self):
attributes = self.get_attributes()
if attributes & FirmwareVolume.EFI_FVB2_ERASE_POLARITY:
return 1
else:
return 0
-
+
def get_next_ffs(self, ffs=None):
if ffs == None:
# Get the offset of the first FFS file from the FV header
@@ -291,21 +291,21 @@ class FirmwareVolume: else:
# Goto the next FFS file
ffs_base = int(ffs.get_base() + ffs.get_size())
-
+
# Align to next 8 byte boundary
if (ffs_base & 0x7) != 0:
ffs_base = ffs_base + 0x8 - (ffs_base & 0x7)
-
+
if ffs_base < self.fv_base + self.get_size():
return FirmwareFile(self, ffs_base, self.ec)
else:
return None
-
- def get_debug_info(self):
+
+ def get_debug_info(self):
self.DebugInfos = []
-
+
ffs = self.get_next_ffs()
- while ffs != None:
+ while ffs != None:
section = ffs.get_next_section()
while section != None:
type = section.get_type()
@@ -317,7 +317,7 @@ class FirmwareVolume: def load_symbols_at(self, addr, verbose = False):
if self.DebugInfos == []:
self.get_debug_info()
-
+
for debug_info in self.DebugInfos:
if (addr >= debug_info[0]) and (addr < debug_info[0] + debug_info[1]):
if debug_info[2] == EfiFileSection.EFI_SECTION_TE:
@@ -326,7 +326,7 @@ class FirmwareVolume: section = EfiSectionPE32(self.ec, debug_info[0] + 0x4)
else:
raise Exception('FirmwareVolume','Section Type not supported')
-
+
try:
edk2_debugger.load_symbol_from_file(self.ec, section.get_debug_filepath(), section.get_debug_elfbase(), verbose)
except Exception, (ErrorClass, ErrorMessage):
@@ -338,7 +338,7 @@ class FirmwareVolume: def load_all_symbols(self, verbose = False):
if self.DebugInfos == []:
self.get_debug_info()
-
+
for debug_info in self.DebugInfos:
if debug_info[2] == EfiFileSection.EFI_SECTION_TE:
section = EfiSectionTE(self.ec, debug_info[0] + 0x4)
@@ -346,7 +346,7 @@ class FirmwareVolume: section = EfiSectionPE32(self.ec, debug_info[0] + 0x4)
else:
continue
-
+
try:
edk2_debugger.load_symbol_from_file(self.ec, section.get_debug_filepath(), section.get_debug_elfbase(), verbose)
except Exception, (ErrorClass, ErrorMessage):
diff --git a/ArmPlatformPkg/Scripts/Ds5/system_table.py b/ArmPlatformPkg/Scripts/Ds5/system_table.py index dbb827e96d..0a14f80830 100644 --- a/ArmPlatformPkg/Scripts/Ds5/system_table.py +++ b/ArmPlatformPkg/Scripts/Ds5/system_table.py @@ -1,13 +1,13 @@ #
# Copyright (c) 2011-2013, ARM Limited. All rights reserved.
-#
-# This program and the accompanying materials
-# are licensed and made available under the terms and conditions of the BSD License
-# which accompanies this distribution. The full text of the license may be found at
-# http://opensource.org/licenses/bsd-license.php
#
-# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
-# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
+# This program and the accompanying materials
+# are licensed and made available under the terms and conditions of the BSD License
+# which accompanies this distribution. The full text of the license may be found at
+# http://opensource.org/licenses/bsd-license.php
+#
+# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
+# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
#
from arm_ds.debugger_v1 import DebugException
@@ -19,13 +19,13 @@ import firmware_volume class DebugInfoTable:
CONST_DEBUG_INFO_TABLE_GUID = ( 0x49152E77L, 0x47641ADAL, 0xFE7AA2B7L, 0x8B5ED9FEL)
-
+
DebugInfos = []
-
+
def __init__(self, ec, debug_info_table_header_offset):
self.ec = ec
self.base = debug_info_table_header_offset
-
+
def get_debug_info(self):
# Get the information from EFI_DEBUG_IMAGE_INFO_TABLE_HEADER
count = self.ec.getMemoryService().readMemory32(self.base + 0x4)
@@ -33,9 +33,9 @@ class DebugInfoTable: debug_info_table_base = self.ec.getMemoryService().readMemory64(self.base + 0x8)
else:
debug_info_table_base = self.ec.getMemoryService().readMemory32(self.base + 0x8)
-
+
self.DebugInfos = []
-
+
for i in range(0, count):
# Get the address of the structure EFI_DEBUG_IMAGE_INFO
if edk2_debugger.is_aarch64(self.ec):
@@ -59,14 +59,14 @@ class DebugInfoTable: image_base = self.ec.getMemoryService().readMemory32(loaded_image_protocol + 0x20)
image_size = self.ec.getMemoryService().readMemory32(loaded_image_protocol + 0x28)
-
+
self.DebugInfos.append((image_base,image_size))
-
+
# Return (base, size)
def load_symbols_at(self, addr, verbose = False):
if self.DebugInfos == []:
self.get_debug_info()
-
+
found = False
for debug_info in self.DebugInfos:
if (addr >= debug_info[0]) and (addr < debug_info[0] + debug_info[1]):
@@ -74,7 +74,7 @@ class DebugInfoTable: section = firmware_volume.EfiSectionPE64(self.ec, debug_info[0])
else:
section = firmware_volume.EfiSectionPE32(self.ec, debug_info[0])
-
+
try:
edk2_debugger.load_symbol_from_file(self.ec, section.get_debug_filepath(), section.get_debug_elfbase(), verbose)
except Exception, (ErrorClass, ErrorMessage):
@@ -90,13 +90,13 @@ class DebugInfoTable: def load_all_symbols(self, verbose = False):
if self.DebugInfos == []:
self.get_debug_info()
-
+
for debug_info in self.DebugInfos:
if edk2_debugger.is_aarch64(self.ec):
section = firmware_volume.EfiSectionPE64(self.ec, debug_info[0])
else:
section = firmware_volume.EfiSectionPE32(self.ec, debug_info[0])
-
+
try:
edk2_debugger.load_symbol_from_file(self.ec, section.get_debug_filepath(), section.get_debug_elfbase(), verbose)
except Exception, (ErrorClass, ErrorMessage):
@@ -112,24 +112,24 @@ class DebugInfoTable: else:
section = firmware_volume.EfiSectionPE32(self.ec, base_pe32)
print section.get_debug_filepath()
-
+
class SystemTable:
CONST_ST_SIGNATURE = ('I','B','I',' ','S','Y','S','T')
-
+
def __init__(self, ec, membase, memsize):
self.membase = membase
self.memsize = memsize
self.ec = ec
-
+
found = False
-
+
# Start from the top of the memory
offset = self.membase + self.memsize
# Align to highest 4MB boundary
offset = offset & ~0x3FFFFF
# We should not have a System Table at the top of the System Memory
offset = offset - 0x400000
-
+
# Start at top and look on 4MB boundaries for system table ptr structure
while offset > self.membase:
try:
@@ -144,10 +144,10 @@ class SystemTable: self.system_table_base = self.ec.getMemoryService().readMemory32(offset + 0x8)
break
offset = offset - 0x400000
-
+
if not found:
raise Exception('SystemTable','System Table not found in System Memory [0x%x;0x%X]' % (membase,membase+memsize))
-
+
def get_configuration_table(self, conf_table_guid):
if edk2_debugger.is_aarch64(self.ec):
# Number of configuration Table entry
@@ -161,7 +161,7 @@ class SystemTable: # Get location of the Configuration Table entries
conf_table_offset = self.ec.getMemoryService().readMemory32(self.system_table_base + 0x44)
-
+
for i in range(0, conf_table_entry_count):
if edk2_debugger.is_aarch64(self.ec):
offset = conf_table_offset + (i * 0x18)
@@ -173,5 +173,5 @@ class SystemTable: return self.ec.getMemoryService().readMemory64(offset + 0x10)
else:
return self.ec.getMemoryService().readMemory32(offset + 0x10)
-
+
raise Exception('SystemTable','Configuration Table not found')
diff --git a/ArmPlatformPkg/Sec/Arm/Helper.S b/ArmPlatformPkg/Sec/Arm/Helper.S index ae4bc44540..2e2801fe85 100644 --- a/ArmPlatformPkg/Sec/Arm/Helper.S +++ b/ArmPlatformPkg/Sec/Arm/Helper.S @@ -1,18 +1,18 @@ #========================================================================================
# Copyright (c) 2011-2014, ARM Limited. All rights reserved.
-#
-# This program and the accompanying materials
-# are licensed and made available under the terms and conditions of the BSD License
-# which accompanies this distribution. The full text of the license may be found at
+#
+# This program and the accompanying materials
+# are licensed and made available under the terms and conditions of the BSD License
+# which accompanies this distribution. The full text of the license may be found at
# http://opensource.org/licenses/bsd-license.php
#
-# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
-# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
+# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
+# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
#
#=======================================================================================
#start of the code section
-.text
+.text
.align 3
GCC_ASM_EXPORT(return_from_exception)
@@ -36,7 +36,7 @@ ASM_PFX(enter_monitor_mode): mov sp, r3 @ Set the stack of the Monitor Mode
mov lr, r0 @ Use the pass entrypoint as lr
-
+
msr spsr_cxsf, r4 @ Use saved mode for the MOVS jump to the kernel
mov r4, r0 @ Swap EntryPoint and MpId registers
@@ -80,5 +80,5 @@ ASM_PFX(set_non_secure_mode): isb
pop { r1 }
bx lr @ return (hopefully thumb-safe!)
-
+
ASM_FUNCTION_REMOVE_IF_UNREFERENCED
diff --git a/ArmPlatformPkg/Sec/Arm/Helper.asm b/ArmPlatformPkg/Sec/Arm/Helper.asm index b31cc31a97..febcdb18a1 100644 --- a/ArmPlatformPkg/Sec/Arm/Helper.asm +++ b/ArmPlatformPkg/Sec/Arm/Helper.asm @@ -1,13 +1,13 @@ //
// Copyright (c) 2011-2012, ARM Limited. All rights reserved.
-//
-// This program and the accompanying materials
-// are licensed and made available under the terms and conditions of the BSD License
-// which accompanies this distribution. The full text of the license may be found at
-// http://opensource.org/licenses/bsd-license.php
//
-// THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
-// WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
+// This program and the accompanying materials
+// are licensed and made available under the terms and conditions of the BSD License
+// which accompanies this distribution. The full text of the license may be found at
+// http://opensource.org/licenses/bsd-license.php
+//
+// THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
+// WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
//
//
@@ -15,7 +15,7 @@ EXPORT enter_monitor_mode
EXPORT copy_cpsr_into_spsr
EXPORT set_non_secure_mode
-
+
AREA Helper, CODE, READONLY
// r0: Monitor World EntryPoint
@@ -34,7 +34,7 @@ enter_monitor_mode FUNCTION mov sp, r3 // Set the stack of the Monitor Mode
mov lr, r0 // Use the pass entrypoint as lr
-
+
msr spsr_cxsf, r4 // Use saved mode for the MOVS jump to the kernel
mov r4, r0 // Swap EntryPoint and MpId registers
@@ -75,5 +75,5 @@ set_non_secure_mode dead
B dead
-
+
END
diff --git a/ArmPlatformPkg/Sec/Arm/SecEntryPoint.S b/ArmPlatformPkg/Sec/Arm/SecEntryPoint.S index 5096251a74..158a08f5e3 100644 --- a/ArmPlatformPkg/Sec/Arm/SecEntryPoint.S +++ b/ArmPlatformPkg/Sec/Arm/SecEntryPoint.S @@ -1,13 +1,13 @@ //
// Copyright (c) 2011-2013, ARM Limited. All rights reserved.
-//
-// This program and the accompanying materials
-// are licensed and made available under the terms and conditions of the BSD License
-// which accompanies this distribution. The full text of the license may be found at
-// http://opensource.org/licenses/bsd-license.php
//
-// THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
-// WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
+// This program and the accompanying materials
+// are licensed and made available under the terms and conditions of the BSD License
+// which accompanies this distribution. The full text of the license may be found at
+// http://opensource.org/licenses/bsd-license.php
+//
+// THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
+// WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
//
//
@@ -49,13 +49,13 @@ _IdentifyCpu: bl ASM_PFX(ArmReadMpidr)
// Keep a copy of the MpId register value
mov r9, r0
-
+
// Is it the Primary Core ?
bl ASM_PFX(ArmPlatformIsPrimaryCore)
cmp r0, #1
// Only the primary core initialize the memory (SMC)
beq _InitMem
-
+
_WaitInitMem:
// If we are not doing a cold boot in this case we should assume the Initial Memory to be already initialized
// Otherwise we have to wait the Primary Core to finish the initialization
@@ -66,7 +66,7 @@ _WaitInitMem: bl ASM_PFX(ArmCallWFE)
// Now the Init Mem is initialized, we setup the secondary core stacks
b _SetupSecondaryCoreStack
-
+
_InitMem:
// If we are not doing a cold boot in this case we should assume the Initial Memory to be already initialized
cmp r10, #ARM_SEC_COLD_BOOT
@@ -74,7 +74,7 @@ _InitMem: // Initialize Init Boot Memory
bl ASM_PFX(ArmPlatformSecBootMemoryInit)
-
+
_SetupPrimaryCoreStack:
// Get the top of the primary stacks (and the base of the secondary stacks)
LoadConstantToReg (FixedPcdGet32(PcdCPUCoresSecStackBase), r1)
@@ -110,13 +110,13 @@ _PrepareArguments: // Move sec startup address into a data register
// Ensure we're jumping to FV version of the code (not boot remapped alias)
ldr r3, StartupAddr
-
+
// Jump to SEC C code
// r0 = mp_id
// r1 = Boot Mode
mov r0, r9
mov r1, r10
blx r3
-
+
_NeverReturn:
b _NeverReturn
diff --git a/ArmPlatformPkg/Sec/Arm/SecEntryPoint.asm b/ArmPlatformPkg/Sec/Arm/SecEntryPoint.asm index 14f7e9c663..a97041d021 100644 --- a/ArmPlatformPkg/Sec/Arm/SecEntryPoint.asm +++ b/ArmPlatformPkg/Sec/Arm/SecEntryPoint.asm @@ -1,13 +1,13 @@ //
// Copyright (c) 2011-2013, ARM Limited. All rights reserved.
-//
-// This program and the accompanying materials
-// are licensed and made available under the terms and conditions of the BSD License
-// which accompanies this distribution. The full text of the license may be found at
-// http://opensource.org/licenses/bsd-license.php
//
-// THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
-// WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
+// This program and the accompanying materials
+// are licensed and made available under the terms and conditions of the BSD License
+// which accompanies this distribution. The full text of the license may be found at
+// http://opensource.org/licenses/bsd-license.php
+//
+// THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
+// WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
//
//
@@ -16,7 +16,7 @@ #include "SecInternal.h"
INCLUDE AsmMacroIoLib.inc
-
+
IMPORT CEntryPoint
IMPORT ArmPlatformIsPrimaryCore
IMPORT ArmPlatformGetCorePosition
@@ -30,7 +30,7 @@ PRESERVE8
AREA SecEntryPoint, CODE, READONLY
-
+
StartupAddr DCD CEntryPoint
_ModuleEntryPoint FUNCTION
@@ -46,18 +46,18 @@ _ModuleEntryPoint FUNCTION // Jump to Platform Specific Boot Action function
blx ArmPlatformSecBootAction
-_IdentifyCpu
+_IdentifyCpu
// Identify CPU ID
bl ArmReadMpidr
// Keep a copy of the MpId register value
mov r9, r0
-
+
// Is it the Primary Core ?
bl ArmPlatformIsPrimaryCore
cmp r0, #1
// Only the primary core initialize the memory (SMC)
beq _InitMem
-
+
_WaitInitMem
// If we are not doing a cold boot in this case we should assume the Initial Memory to be already initialized
// Otherwise we have to wait the Primary Core to finish the initialization
@@ -68,7 +68,7 @@ _WaitInitMem bl ArmCallWFE
// Now the Init Mem is initialized, we setup the secondary core stacks
b _SetupSecondaryCoreStack
-
+
_InitMem
// If we are not doing a cold boot in this case we should assume the Initial Memory to be already initialized
cmp r10, #ARM_SEC_COLD_BOOT
@@ -76,7 +76,7 @@ _InitMem // Initialize Init Boot Memory
bl ArmPlatformSecBootMemoryInit
-
+
_SetupPrimaryCoreStack
// Get the top of the primary stacks (and the base of the secondary stacks)
LoadConstantToReg (FixedPcdGet32(PcdCPUCoresSecStackBase), r1)
@@ -112,7 +112,7 @@ _PrepareArguments // Move sec startup address into a data register
// Ensure we're jumping to FV version of the code (not boot remapped alias)
ldr r3, StartupAddr
-
+
// Jump to SEC C code
// r0 = mp_id
// r1 = Boot Mode
@@ -120,7 +120,7 @@ _PrepareArguments mov r1, r10
blx r3
ENDFUNC
-
+
_NeverReturn
b _NeverReturn
END
diff --git a/ArmPlatformPkg/Sec/Sec.inf b/ArmPlatformPkg/Sec/Sec.inf index 4ccf72ae0f..27e64c78ee 100644 --- a/ArmPlatformPkg/Sec/Sec.inf +++ b/ArmPlatformPkg/Sec/Sec.inf @@ -1,16 +1,16 @@ #/** @file
# SEC - Reset vector code that jumps to C and starts the PEI phase
-#
+#
# Copyright (c) 2011-2013, ARM Limited. All rights reserved.
-#
-# This program and the accompanying materials
-# are licensed and made available under the terms and conditions of the BSD License
-# which accompanies this distribution. The full text of the license may be found at
-# http://opensource.org/licenses/bsd-license.php
#
-# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
-# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
-#
+# This program and the accompanying materials
+# are licensed and made available under the terms and conditions of the BSD License
+# which accompanies this distribution. The full text of the license may be found at
+# http://opensource.org/licenses/bsd-license.php
+#
+# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
+# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
+#
#**/
[Defines]
@@ -29,7 +29,7 @@ Arm/Helper.S | GCC
Arm/SecEntryPoint.S | GCC
Arm/SecEntryPoint.asm | RVCT
-
+
[Sources.AARCH64]
AArch64/Arch.c
AArch64/Helper.S
@@ -54,19 +54,19 @@ ArmGicLib
PrintLib
SerialPortLib
-
+
[FixedPcd.common]
gEfiMdeModulePkgTokenSpaceGuid.PcdFirmwareVersionString
gArmTokenSpaceGuid.PcdTrustzoneSupport
gArmTokenSpaceGuid.PcdVFPEnabled
-
+
gArmTokenSpaceGuid.PcdArmScr
gArmTokenSpaceGuid.PcdArmNonSecModeTransition
-
+
gArmTokenSpaceGuid.PcdSecureFvBaseAddress
gArmTokenSpaceGuid.PcdSecureFvSize
-
+
gArmTokenSpaceGuid.PcdFvBaseAddress
gArmPlatformTokenSpaceGuid.PcdCPUCoresSecStackBase
@@ -74,11 +74,11 @@ gArmPlatformTokenSpaceGuid.PcdCPUCoreSecSecondaryStackSize
gArmPlatformTokenSpaceGuid.PcdCPUCoresSecMonStackBase
gArmPlatformTokenSpaceGuid.PcdCPUCoreSecMonStackSize
-
+
gArmTokenSpaceGuid.PcdGicDistributorBase
gArmTokenSpaceGuid.PcdGicInterruptInterfaceBase
-
- gArmPlatformTokenSpaceGuid.PcdSecGlobalVariableSize
+
+ gArmPlatformTokenSpaceGuid.PcdSecGlobalVariableSize
[FixedPcd.ARM]
gArmTokenSpaceGuid.PcdArmNsacr
diff --git a/BeagleBoardPkg/Bds/Bds.inf b/BeagleBoardPkg/Bds/Bds.inf index 093559c7cb..2b20a09549 100644 --- a/BeagleBoardPkg/Bds/Bds.inf +++ b/BeagleBoardPkg/Bds/Bds.inf @@ -1,18 +1,18 @@ #/** @file
-#
+#
# Component description file for Bds module
-#
+#
# Copyright (c) 2009, Apple Inc. All rights reserved.<BR>
#
# This program and the accompanying materials
# are licensed and made available under the terms and conditions of the BSD License
# which accompanies this distribution. The full text of the license may be found at
# http://opensource.org/licenses/bsd-license.php
-#
+#
# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
-#
+#
#**/
[Defines]
@@ -49,13 +49,13 @@ UefiDriverEntryPoint
[Guids]
-
+
[Protocols]
- gEfiBdsArchProtocolGuid
- gEfiSimpleTextInProtocolGuid
- gEfiSimpleTextOutProtocolGuid
- gEfiSerialIoProtocolGuid
+ gEfiBdsArchProtocolGuid
+ gEfiSimpleTextInProtocolGuid
+ gEfiSimpleTextOutProtocolGuid
+ gEfiSerialIoProtocolGuid
gEfiDevicePathProtocolGuid
gEfiSimpleFileSystemProtocolGuid
gEfiUsbIoProtocolGuid
diff --git a/BeagleBoardPkg/Bds/BdsEntry.c b/BeagleBoardPkg/Bds/BdsEntry.c index f65c9eb8b9..f2f1ae3983 100644 --- a/BeagleBoardPkg/Bds/BdsEntry.c +++ b/BeagleBoardPkg/Bds/BdsEntry.c @@ -1,13 +1,13 @@ /** @file
- The entry of the embedded BDS. This BDS does not follow the Boot Manager requirements
- of the UEFI specification as it is designed to implement an embedded systmes
+ The entry of the embedded BDS. This BDS does not follow the Boot Manager requirements
+ of the UEFI specification as it is designed to implement an embedded systmes
propriatary boot scheme.
- This template assume a DXE driver produces a SerialIo protocol not using the EFI
+ This template assume a DXE driver produces a SerialIo protocol not using the EFI
driver module and it will attempt to connect a console on top of this.
Copyright (c) 2008 - 2009, Apple Inc. All rights reserved.<BR>
-
+
This program and the accompanying materials
are licensed and made available under the terms and conditions of the BSD License
which accompanies this distribution. The full text of the license may be found at
@@ -28,22 +28,22 @@ EFI_BDS_ARCH_PROTOCOL gBdsProtocol = { };
-
-
+
+
/**
- This function uses policy data from the platform to determine what operating
- system or system utility should be loaded and invoked. This function call
- also optionally make the use of user input to determine the operating system
- or system utility to be loaded and invoked. When the DXE Core has dispatched
- all the drivers on the dispatch queue, this function is called. This
- function will attempt to connect the boot devices required to load and invoke
- the selected operating system or system utility. During this process,
- additional firmware volumes may be discovered that may contain addition DXE
- drivers that can be dispatched by the DXE Core. If a boot device cannot be
- fully connected, this function calls the DXE Service Dispatch() to allow the
- DXE drivers from any newly discovered firmware volumes to be dispatched.
- Then the boot device connection can be attempted again. If the same boot
- device connection operation fails twice in a row, then that boot device has
+ This function uses policy data from the platform to determine what operating
+ system or system utility should be loaded and invoked. This function call
+ also optionally make the use of user input to determine the operating system
+ or system utility to be loaded and invoked. When the DXE Core has dispatched
+ all the drivers on the dispatch queue, this function is called. This
+ function will attempt to connect the boot devices required to load and invoke
+ the selected operating system or system utility. During this process,
+ additional firmware volumes may be discovered that may contain addition DXE
+ drivers that can be dispatched by the DXE Core. If a boot device cannot be
+ fully connected, this function calls the DXE Service Dispatch() to allow the
+ DXE drivers from any newly discovered firmware volumes to be dispatched.
+ Then the boot device connection can be attempted again. If the same boot
+ device connection operation fails twice in a row, then that boot device has
failed, and should be skipped. This function should never return.
@param This The EFI_BDS_ARCH_PROTOCOL instance.
@@ -71,7 +71,7 @@ BdsEntry ( UINTN Index;
EFI_DEVICE_PATH_PROTOCOL *LoadImageDevicePath;
EFI_DEVICE_PATH_PROTOCOL *FileSystemDevicePath;
-
+
PERF_END (NULL, "DXE", NULL, 0);
PERF_START (NULL, "BDS", NULL, 0);
@@ -82,12 +82,12 @@ BdsEntry ( Size = 0x100;
gST->FirmwareVendor = AllocateRuntimePool (Size);
ASSERT (gST->FirmwareVendor != NULL);
-
+
UnicodeSPrint (gST->FirmwareVendor, Size, L"BeagleBoard EFI %a %a", __DATE__, __TIME__);
//
// Now we need to setup the EFI System Table with information about the console devices.
- // This code is normally in the console spliter driver on platforms that support multiple
+ // This code is normally in the console spliter driver on platforms that support multiple
// consoles at the same time
//
Status = gBS->LocateHandleBuffer (ByProtocol, &gEfiSimpleTextOutProtocolGuid, NULL, &NoHandles, &Buffer);
@@ -97,15 +97,15 @@ BdsEntry ( gST->StandardErrorHandle = Buffer[0];
Status = gBS->HandleProtocol (Buffer[0], &gEfiSimpleTextOutProtocolGuid, (VOID **)&gST->ConOut);
ASSERT_EFI_ERROR (Status);
-
+
gST->StdErr = gST->ConOut;
-
+
gST->ConOut->OutputString (gST->ConOut, L"BDS: Console Started!!!!\n\r");
FreePool (Buffer);
-
+
gConsolePresent = TRUE;
- }
-
+ }
+
Status = gBS->LocateHandleBuffer (ByProtocol, &gEfiSimpleTextInProtocolGuid, NULL, &NoHandles, &Buffer);
if (!EFI_ERROR (Status)) {
@@ -113,12 +113,12 @@ BdsEntry ( gST->ConsoleInHandle = Buffer[0];
Status = gBS->HandleProtocol (Buffer[0], &gEfiSimpleTextInProtocolGuid, (VOID **)&gST->ConIn);
ASSERT_EFI_ERROR (Status);
-
+
FreePool (Buffer);
}
//
- // We now have EFI Consoles up and running. Print () will work now. DEBUG () and ASSERT () worked
+ // We now have EFI Consoles up and running. Print () will work now. DEBUG () and ASSERT () worked
// prior to this point as they were configured to use a more primative output scheme.
//
@@ -138,7 +138,7 @@ BdsEntry ( if (EFI_ERROR (Status)) {
break;
}
-
+
if (HandleCount == OldHandleCount) {
break;
}
@@ -186,9 +186,9 @@ BdsEntry ( }
}
}
-
+
//
- // Normal UEFI behavior is to process Globally Defined Variables as defined in Chapter 3
+ // Normal UEFI behavior is to process Globally Defined Variables as defined in Chapter 3
// (Boot Manager) of the UEFI specification. For this embedded system we don't do this.
//
@@ -208,7 +208,7 @@ BdsEntry ( }
//
- // EFI does not define the behaviour if all boot attemps fail and the last one returns.
+ // EFI does not define the behaviour if all boot attemps fail and the last one returns.
// So we make a policy choice to reset the system since this BDS does not have a UI.
//
gRT->ResetSystem (EfiResetShutdown, Status, 0, NULL);
diff --git a/BeagleBoardPkg/Bds/BdsEntry.h b/BeagleBoardPkg/Bds/BdsEntry.h index 149acbefc5..646f7b276d 100644 --- a/BeagleBoardPkg/Bds/BdsEntry.h +++ b/BeagleBoardPkg/Bds/BdsEntry.h @@ -45,7 +45,7 @@ EFI_STATUS
LoadPeCoffSectionFromFv (
- IN EFI_HANDLE FvHandle,
+ IN EFI_HANDLE FvHandle,
IN EFI_GUID *NameGuid
);
diff --git a/BeagleBoardPkg/Bds/FirmwareVolume.c b/BeagleBoardPkg/Bds/FirmwareVolume.c index 142095fa66..31e1c5100e 100644 --- a/BeagleBoardPkg/Bds/FirmwareVolume.c +++ b/BeagleBoardPkg/Bds/FirmwareVolume.c @@ -1,14 +1,14 @@ /** @file
- The entry of the embedded BDS. This BDS does not follow the Boot Manager requirements
- of the UEFI specification as it is designed to implement an embedded systmes
+ The entry of the embedded BDS. This BDS does not follow the Boot Manager requirements
+ of the UEFI specification as it is designed to implement an embedded systmes
propriatary boot scheme.
- This template assume a DXE driver produces a SerialIo protocol not using the EFI
+ This template assume a DXE driver produces a SerialIo protocol not using the EFI
driver module and it will attempt to connect a console on top of this.
-
+
Copyright (c) 2009, Apple Inc. All rights reserved.<BR>
-
+
This program and the accompanying materials
are licensed and made available under the terms and conditions of the BSD License
which accompanies this distribution. The full text of the license may be found at
@@ -42,14 +42,14 @@ FindApplicationMatchingUiSection ( UINTN UiStringLen;
CHAR16 *UiSection;
UINT32 Authentication;
-
-
+
+
UiStringLen = 0;
if (UiString != NULL) {
DEBUG ((DEBUG_ERROR, "UiString %s\n", UiString));
UiStringLen = StrLen (UiString);
}
-
+
Status = gBS->LocateHandleBuffer (ByProtocol, &gEfiFirmwareVolume2ProtocolGuid, NULL, &NoHandles, &Buffer);
if (!EFI_ERROR (Status)) {
for (Index = 0; Index < NoHandles; Index++) {
@@ -58,9 +58,9 @@ FindApplicationMatchingUiSection ( Key = AllocatePool (Fv->KeySize);
ASSERT (Key != NULL);
ZeroMem (Key, Fv->KeySize);
-
+
FileType = EFI_FV_FILETYPE_APPLICATION;
-
+
do {
NextStatus = Fv->GetNextFile (Fv, Key, &FileType, NameGuid, &Attributes, &Size);
if (!EFI_ERROR (NextStatus)) {
@@ -72,12 +72,12 @@ FindApplicationMatchingUiSection ( FreePool (Key);
return Status;
}
-
+
UiSection = NULL;
Status = Fv->ReadSection (
- Fv,
- NameGuid,
- EFI_SECTION_USER_INTERFACE,
+ Fv,
+ NameGuid,
+ EFI_SECTION_USER_INTERFACE,
0,
(VOID **)&UiSection,
&Size,
@@ -86,7 +86,7 @@ FindApplicationMatchingUiSection ( if (!EFI_ERROR (Status)) {
if (StrnCmp (UiString, UiSection, UiStringLen) == 0) {
//
- // We found a UiString match.
+ // We found a UiString match.
//
*FvHandle = Buffer[Index];
FreePool (Key);
@@ -97,11 +97,11 @@ FindApplicationMatchingUiSection ( }
}
} while (!EFI_ERROR (NextStatus));
-
+
FreePool (Key);
}
}
-
+
FreePool (Buffer);
}
@@ -114,14 +114,14 @@ FvFileDevicePath ( IN EFI_HANDLE FvHandle,
IN EFI_GUID *NameGuid
)
-{
+{
EFI_DEVICE_PATH_PROTOCOL *DevicePath;
MEDIA_FW_VOL_FILEPATH_DEVICE_PATH NewNode;
DevicePath = DevicePathFromHandle (FvHandle);
EfiInitializeFwVolDevicepathNode (&NewNode, NameGuid);
-
+
return AppendDevicePathNode (DevicePath, (EFI_DEVICE_PATH_PROTOCOL *)&NewNode);
}
@@ -129,7 +129,7 @@ FvFileDevicePath ( EFI_STATUS
LoadPeCoffSectionFromFv (
- IN EFI_HANDLE FvHandle,
+ IN EFI_HANDLE FvHandle,
IN EFI_GUID *NameGuid
)
{
@@ -138,13 +138,13 @@ LoadPeCoffSectionFromFv ( EFI_HANDLE ImageHandle;
DevicePath = FvFileDevicePath (FvHandle, NameGuid);
-
+
Status = gBS->LoadImage (TRUE, gImageHandle, DevicePath, NULL, 0, &ImageHandle);
if (!EFI_ERROR (Status)) {
PERF_END (NULL, "BDS", NULL, 0);
Status = gBS->StartImage (ImageHandle, NULL, NULL);
}
-
+
return Status;
}
-
+
diff --git a/BeagleBoardPkg/BeagleBoardPkg.dsc b/BeagleBoardPkg/BeagleBoardPkg.dsc index caf6182c4b..fbab13fc74 100644 --- a/BeagleBoardPkg/BeagleBoardPkg.dsc +++ b/BeagleBoardPkg/BeagleBoardPkg.dsc @@ -36,7 +36,7 @@ ArmCpuLib|ArmPkg/Drivers/ArmCpuLib/ArmCortexA8Lib/ArmCortexA8Lib.inf
ArmPlatformStackLib|ArmPlatformPkg/Library/ArmPlatformStackLib/ArmPlatformStackLib.inf
ArmSmcLib|ArmPkg/Library/ArmSmcLib/ArmSmcLib.inf
-
+
HiiLib|MdeModulePkg/Library/UefiHiiLib/UefiHiiLib.inf
UefiHiiServicesLib|MdeModulePkg/Library/UefiHiiServicesLib/UefiHiiServicesLib.inf
@@ -51,23 +51,23 @@ DebugPrintErrorLevelLib|MdePkg/Library/BaseDebugPrintErrorLevelLib/BaseDebugPrintErrorLevelLib.inf
MemoryAllocationLib|MdePkg/Library/UefiMemoryAllocationLib/UefiMemoryAllocationLib.inf
-
+
BaseLib|MdePkg/Library/BaseLib/BaseLib.inf
BaseMemoryLib|ArmPkg/Library/BaseMemoryLibStm/BaseMemoryLibStm.inf
EfiResetSystemLib|BeagleBoardPkg/Library/ResetSystemLib/ResetSystemLib.inf
-
+
PciLib|MdePkg/Library/BasePciLibCf8/BasePciLibCf8.inf
PerformanceLib|MdePkg/Library/BasePerformanceLibNull/BasePerformanceLibNull.inf
PrintLib|MdePkg/Library/BasePrintLib/BasePrintLib.inf
-
+
EfiFileLib|EmbeddedPkg/Library/EfiFileLib/EfiFileLib.inf
-
-
+
+
PeCoffGetEntryPointLib|MdePkg/Library/BasePeCoffGetEntryPointLib/BasePeCoffGetEntryPointLib.inf
-
+
#
- # Uncomment (and comment out the next line) For RealView Debugger. The Standard IO window
+ # Uncomment (and comment out the next line) For RealView Debugger. The Standard IO window
# in the debugger will show load and unload commands for symbols. You can cut and paste this
# into the command window to load symbols. We should be able to use a script to do this, but
# the version of RVD I have does not support scipts accessing system memory.
@@ -76,20 +76,20 @@ PeCoffExtraActionLib|ArmPkg/Library/DebugPeCoffExtraActionLib/DebugPeCoffExtraActionLib.inf
# PeCoffExtraActionLib|MdePkg/Library/BasePeCoffExtraActionLibNull/BasePeCoffExtraActionLibNull.inf
-
+
CacheMaintenanceLib|ArmPkg/Library/ArmCacheMaintenanceLib/ArmCacheMaintenanceLib.inf
DefaultExceptionHandlerLib|ArmPkg/Library/DefaultExceptionHandlerLib/DefaultExceptionHandlerLib.inf
CpuExceptionHandlerLib|MdeModulePkg/Library/CpuExceptionHandlerLibNull/CpuExceptionHandlerLibNull.inf
PrePiLib|EmbeddedPkg/Library/PrePiLib/PrePiLib.inf
-
+
SerialPortLib|Omap35xxPkg/Library/SerialPortLib/SerialPortLib.inf
- SerialPortExtLib|EmbeddedPkg/Library/TemplateSerialPortExtLib/TemplateSerialPortExtLib.inf
+ SerialPortExtLib|EmbeddedPkg/Library/TemplateSerialPortExtLib/TemplateSerialPortExtLib.inf
SemihostLib|ArmPkg/Library/SemihostLib/SemihostLib.inf
-
+
RealTimeClockLib|Omap35xxPkg/Library/RealTimeClockLib/RealTimeClockLib.inf
IoLib|MdePkg/Library/BaseIoLibIntrinsic/BaseIoLibIntrinsic.inf
-
+
MemoryAllocationLib|MdePkg/Library/UefiMemoryAllocationLib/UefiMemoryAllocationLib.inf
UefiLib|MdePkg/Library/UefiLib/UefiLib.inf
HobLib|MdePkg/Library/DxeHobLib/DxeHobLib.inf
@@ -107,12 +107,12 @@ PcdLib|MdePkg/Library/BasePcdLibNull/BasePcdLibNull.inf
UefiRuntimeLib|MdePkg/Library/UefiRuntimeLib/UefiRuntimeLib.inf
-
+
UefiUsbLib|MdePkg/Library/UefiUsbLib/UefiUsbLib.inf
CpuLib|MdePkg/Library/BaseCpuLib/BaseCpuLib.inf
- TimerLib|Omap35xxPkg/Library/Omap35xxTimerLib/Omap35xxTimerLib.inf
+ TimerLib|Omap35xxPkg/Library/Omap35xxTimerLib/Omap35xxTimerLib.inf
OmapLib|Omap35xxPkg/Library/OmapLib/OmapLib.inf
OmapDmaLib|Omap35xxPkg/Library/OmapDmaLib/OmapDmaLib.inf
DebugAgentTimerLib|Omap35xxPkg/Library/DebugAgentTimerLib/DebugAgentTimerLib.inf
@@ -129,7 +129,7 @@ [LibraryClasses.common.SEC]
ArmLib|ArmPkg/Library/ArmLib/ArmV7/ArmV7LibPrePi.inf
ArmPlatformGlobalVariableLib|ArmPlatformPkg/Library/ArmPlatformGlobalVariableLib/PrePi/PrePiArmPlatformGlobalVariableLib.inf
-
+
PcdLib|MdePkg/Library/BasePcdLibNull/BasePcdLibNull.inf
ReportStatusCodeLib|IntelFrameworkModulePkg/Library/PeiDxeDebugLibReportStatusCode/PeiDxeDebugLibReportStatusCode.inf
UefiDecompressLib|MdePkg/Library/BaseUefiDecompressLib/BaseUefiDecompressLib.inf
@@ -137,18 +137,18 @@ LzmaDecompressLib|IntelFrameworkModulePkg/Library/LzmaCustomDecompressLib/LzmaCustomDecompressLib.inf
PeCoffLib|MdePkg/Library/BasePeCoffLib/BasePeCoffLib.inf
-
+
HobLib|EmbeddedPkg/Library/PrePiHobLib/PrePiHobLib.inf
PrePiHobListPointerLib|ArmPlatformPkg/Library/PrePiHobListPointerLib/PrePiHobListPointerLib.inf
MemoryAllocationLib|EmbeddedPkg/Library/PrePiMemoryAllocationLib/PrePiMemoryAllocationLib.inf
PerformanceLib|MdeModulePkg/Library/PeiPerformanceLib/PeiPerformanceLib.inf
PlatformPeiLib|ArmPlatformPkg/PlatformPei/PlatformPeiLib.inf
MemoryInitPeiLib|ArmPlatformPkg/MemoryInitPei/MemoryInitPeiLib.inf
-
+
# 1/123 faster than Stm or Vstm version
BaseMemoryLib|MdePkg/Library/BaseMemoryLib/BaseMemoryLib.inf
- # Uncomment to turn on GDB stub in SEC.
+ # Uncomment to turn on GDB stub in SEC.
#DebugAgentLib|EmbeddedPkg/Library/GdbDebugAgent/GdbDebugAgent.inf
[LibraryClasses.common.PEI_CORE]
@@ -167,7 +167,7 @@ PeCoffLib|EmbeddedPkg/Library/DxeHobPeCoffLib/DxeHobPeCoffLib.inf
PerformanceLib|MdeModulePkg/Library/DxeCorePerformanceLib/DxeCorePerformanceLib.inf
-
+
[LibraryClasses.common.DXE_DRIVER]
ReportStatusCodeLib|IntelFrameworkModulePkg/Library/DxeReportStatusCodeLibFramework/DxeReportStatusCodeLib.inf
@@ -225,11 +225,11 @@ gEfiMdePkgTokenSpaceGuid.PcdDriverDiagnosticsDisable|TRUE
gEfiMdePkgTokenSpaceGuid.PcdComponentName2Disable|TRUE
gEfiMdePkgTokenSpaceGuid.PcdDriverDiagnostics2Disable|TRUE
-
+
#
# Control what commands are supported from the UI
# Turn these on and off to add features or save size
- #
+ #
gEmbeddedTokenSpaceGuid.PcdEmbeddedMacBoot|TRUE
gEmbeddedTokenSpaceGuid.PcdEmbeddedDirCmd|TRUE
gEmbeddedTokenSpaceGuid.PcdEmbeddedHobCmd|TRUE
@@ -239,10 +239,10 @@ gEmbeddedTokenSpaceGuid.PcdEmbeddedScriptCmd|FALSE
gEmbeddedTokenSpaceGuid.PcdCacheEnable|TRUE
-
+
# Use the Vector Table location in CpuDxe. We will not copy the Vector Table at PcdCpuVectorBaseAddress
gArmTokenSpaceGuid.PcdRelocateVectorTable|FALSE
-
+
gEmbeddedTokenSpaceGuid.PcdPrePiProduceMemoryTypeInformationHob|TRUE
gArmTokenSpaceGuid.PcdCpuDxeProduceDebugSupport|FALSE
@@ -254,7 +254,7 @@ [PcdsFixedAtBuild.common]
gArmPlatformTokenSpaceGuid.PcdFirmwareVendor|"Beagle Board"
-
+
gEmbeddedTokenSpaceGuid.PcdEmbeddedPrompt|"BeagleEdk2"
gEfiMdePkgTokenSpaceGuid.PcdMaximumUnicodeStringLength|1000000
gEfiMdePkgTokenSpaceGuid.PcdMaximumAsciiStringLength|1000000
@@ -300,12 +300,12 @@ gEmbeddedTokenSpaceGuid.PcdEmbeddedAutomaticBootCommand|""
gEmbeddedTokenSpaceGuid.PcdEmbeddedDefaultTextColor|0x07
gEmbeddedTokenSpaceGuid.PcdEmbeddedMemVariableStoreSize|0x10000
-
+
#
# Optional feature to help prevent EFI memory map fragments
# Turned on and off via: PcdPrePiProduceMemoryTypeInformationHob
-# Values are in EFI Pages (4K). DXE Core will make sure that
-# at least this much of each type of memory can be allocated
+# Values are in EFI Pages (4K). DXE Core will make sure that
+# at least this much of each type of memory can be allocated
# from a single memory range. This way you only end up with
# maximum of two fragements for each type in the memory map
# (the memory used, and the free memory that was prereserved
@@ -326,23 +326,23 @@ # Beagle board Specific PCDs
#
gArmTokenSpaceGuid.PcdVFPEnabled|1
-
+
gArmTokenSpaceGuid.PcdSystemMemoryBase|0x80000000
gArmTokenSpaceGuid.PcdSystemMemorySize|0x08000000
# Size of the region used by UEFI in permanent memory (Reserved 16MB)
gArmPlatformTokenSpaceGuid.PcdSystemMemoryUefiRegionSize|0x01000000
-
+
# Size of the region reserved for fixed address allocations (Reserved 32MB)
gArmTokenSpaceGuid.PcdArmLinuxKernelMaxOffset|0x02000000
gArmTokenSpaceGuid.PcdCpuVectorBaseAddress|0x80008000
gArmTokenSpaceGuid.PcdCpuResetAddress|0x80008000
-
+
gEmbeddedTokenSpaceGuid.PcdTimerPeriod|100000
gEmbeddedTokenSpaceGuid.PcdEmbeddedPerformanceCounterPeriodInNanoseconds|77
gEmbeddedTokenSpaceGuid.PcdEmbeddedPerformanceCounterFrequencyInHz|13000000
-
+
#
# ARM Pcds
#
@@ -361,8 +361,8 @@ #
# ARM OS Loader
#
- # BeagleBoard machine type (OMAP3_BEAGLE = 1546) required for ARM Linux:
- gArmTokenSpaceGuid.PcdArmMachineType|1546
+ # BeagleBoard machine type (OMAP3_BEAGLE = 1546) required for ARM Linux:
+ gArmTokenSpaceGuid.PcdArmMachineType|1546
################################################################################
#
@@ -375,7 +375,7 @@ # SEC
#
ArmPlatformPkg/PrePi/PeiUniCore.inf
-
+
#
# DXE
#
@@ -384,30 +384,30 @@ PcdLib|MdePkg/Library/BasePcdLibNull/BasePcdLibNull.inf
NULL|MdeModulePkg/Library/DxeCrc32GuidedSectionExtractLib/DxeCrc32GuidedSectionExtractLib.inf
# NULL|IntelFrameworkModulePkg/Library/LzmaCustomDecompressLib/LzmaCustomDecompressLib.inf
- NULL|EmbeddedPkg/Library/LzmaHobCustomDecompressLib/LzmaHobCustomDecompressLib.inf
+ NULL|EmbeddedPkg/Library/LzmaHobCustomDecompressLib/LzmaHobCustomDecompressLib.inf
}
ArmPkg/Drivers/CpuDxe/CpuDxe.inf
-
+
MdeModulePkg/Core/RuntimeDxe/RuntimeDxe.inf
MdeModulePkg/Universal/SecurityStubDxe/SecurityStubDxe.inf
MdeModulePkg/Universal/WatchdogTimerDxe/WatchdogTimer.inf
MdeModulePkg/Universal/CapsuleRuntimeDxe/CapsuleRuntimeDxe.inf
MdeModulePkg/Universal/Variable/EmuRuntimeDxe/EmuVariableRuntimeDxe.inf
EmbeddedPkg/EmbeddedMonotonicCounter/EmbeddedMonotonicCounter.inf
-
+
MdeModulePkg/Universal/Console/ConPlatformDxe/ConPlatformDxe.inf
MdeModulePkg/Universal/Console/ConSplitterDxe/ConSplitterDxe.inf
- MdeModulePkg/Universal/Console/GraphicsConsoleDxe/GraphicsConsoleDxe.inf
+ MdeModulePkg/Universal/Console/GraphicsConsoleDxe/GraphicsConsoleDxe.inf
EmbeddedPkg/SerialDxe/SerialDxe.inf
- MdeModulePkg/Universal/Console/TerminalDxe/TerminalDxe.inf
+ MdeModulePkg/Universal/Console/TerminalDxe/TerminalDxe.inf
#
-# This version uses semi-hosting console
+# This version uses semi-hosting console
# EmbeddedPkg/SimpleTextInOutSerial/SimpleTextInOutSerial.inf {
# <LibraryClasses>
# SerialPortLib|ArmPkg/Library/SemiHostingSerialPortLib/SemiHostingSerialPortLib.inf
# }
-
+
EmbeddedPkg/ResetRuntimeDxe/ResetRuntimeDxe.inf
EmbeddedPkg/RealTimeClockRuntimeDxe/RealTimeClockRuntimeDxe.inf
EmbeddedPkg/MetronomeDxe/MetronomeDxe.inf
@@ -416,7 +416,7 @@ # Semi-hosting filesystem
#
ArmPkg/Filesystem/SemihostFs/SemihostFs.inf
-
+
#
# FAT filesystem + GPT/MBR partitioning
#
@@ -447,34 +447,34 @@ #
EmbeddedPkg/Universal/MmcDxe/MmcDxe.inf
Omap35xxPkg/MmcHostDxe/MmcHostDxe.inf
-
+
#
# I2C
#
Omap35xxPkg/SmbusDxe/Smbus.inf
-
+
#
# SoC Drivers
#
Omap35xxPkg/Gpio/Gpio.inf
Omap35xxPkg/InterruptDxe/InterruptDxe.inf
- Omap35xxPkg/TimerDxe/TimerDxe.inf
+ Omap35xxPkg/TimerDxe/TimerDxe.inf
Omap35xxPkg/LcdGraphicsOutputDxe/LcdGraphicsOutputDxe.inf
#
# Power IC
#
Omap35xxPkg/TPS65950Dxe/TPS65950.inf
-
+
#
# Bds
#
MdeModulePkg/Universal/DevicePathDxe/DevicePathDxe.inf
MdeModulePkg/Universal/HiiDatabaseDxe/HiiDatabaseDxe.inf
- ArmPlatformPkg/Bds/Bds.inf
+ ArmPlatformPkg/Bds/Bds.inf
#
# Example Application
- #
+ #
MdeModulePkg/Application/HelloWorld/HelloWorld.inf
diff --git a/BeagleBoardPkg/BeagleBoardPkg.fdf b/BeagleBoardPkg/BeagleBoardPkg.fdf index 5b3573d9d7..a2a5fe725e 100644 --- a/BeagleBoardPkg/BeagleBoardPkg.fdf +++ b/BeagleBoardPkg/BeagleBoardPkg.fdf @@ -83,37 +83,37 @@ READ_STATUS = TRUE READ_LOCK_CAP = TRUE
READ_LOCK_STATUS = TRUE
- INF MdeModulePkg/Core/Dxe/DxeMain.inf
+ INF MdeModulePkg/Core/Dxe/DxeMain.inf
#
- # PI DXE Drivers producing Architectural Protocols (EFI Services)
+ # PI DXE Drivers producing Architectural Protocols (EFI Services)
#
INF ArmPkg/Drivers/CpuDxe/CpuDxe.inf
-
+
INF MdeModulePkg/Core/RuntimeDxe/RuntimeDxe.inf
INF MdeModulePkg/Universal/SecurityStubDxe/SecurityStubDxe.inf
INF MdeModulePkg/Universal/WatchdogTimerDxe/WatchdogTimer.inf
INF MdeModulePkg/Universal/CapsuleRuntimeDxe/CapsuleRuntimeDxe.inf
INF MdeModulePkg/Universal/Variable/EmuRuntimeDxe/EmuVariableRuntimeDxe.inf
INF EmbeddedPkg/EmbeddedMonotonicCounter/EmbeddedMonotonicCounter.inf
-
+
INF MdeModulePkg/Universal/Console/ConPlatformDxe/ConPlatformDxe.inf
INF MdeModulePkg/Universal/Console/ConSplitterDxe/ConSplitterDxe.inf
- INF MdeModulePkg/Universal/Console/GraphicsConsoleDxe/GraphicsConsoleDxe.inf
+ INF MdeModulePkg/Universal/Console/GraphicsConsoleDxe/GraphicsConsoleDxe.inf
INF EmbeddedPkg/SerialDxe/SerialDxe.inf
- INF MdeModulePkg/Universal/Console/TerminalDxe/TerminalDxe.inf
+ INF MdeModulePkg/Universal/Console/TerminalDxe/TerminalDxe.inf
INF EmbeddedPkg/ResetRuntimeDxe/ResetRuntimeDxe.inf
INF EmbeddedPkg/RealTimeClockRuntimeDxe/RealTimeClockRuntimeDxe.inf
INF EmbeddedPkg/MetronomeDxe/MetronomeDxe.inf
-
+
!if $(TARGET) == RELEASE
#
# Semi-hosting filesystem
#
INF ArmPkg/Filesystem/SemihostFs/SemihostFs.inf
!endif
-
+
#
# Nand Flash
#
@@ -124,18 +124,18 @@ READ_LOCK_STATUS = TRUE #
INF EmbeddedPkg/Universal/MmcDxe/MmcDxe.inf
INF Omap35xxPkg/MmcHostDxe/MmcHostDxe.inf
-
+
#
# I2C
#
INF Omap35xxPkg/SmbusDxe/Smbus.inf
-
+
#
# SoC Drivers
#
INF Omap35xxPkg/Gpio/Gpio.inf
INF Omap35xxPkg/InterruptDxe/InterruptDxe.inf
- INF Omap35xxPkg/TimerDxe/TimerDxe.inf
+ INF Omap35xxPkg/TimerDxe/TimerDxe.inf
INF Omap35xxPkg/LcdGraphicsOutputDxe/LcdGraphicsOutputDxe.inf
#
@@ -162,9 +162,9 @@ READ_LOCK_STATUS = TRUE INF MdeModulePkg/Bus/Usb/UsbMassStorageDxe/UsbMassStorageDxe.inf
#
- # UEFI application (Shell Embedded Boot Loader)
- #
- INF ShellBinPkg/UefiShell/UefiShell.inf
+ # UEFI application (Shell Embedded Boot Loader)
+ #
+ INF ShellBinPkg/UefiShell/UefiShell.inf
#
# Bds
@@ -212,7 +212,7 @@ READ_LOCK_STATUS = TRUE ############################################################################
-# Example of a DXE_DRIVER FFS file with a Checksum encapsulation section #
+# Example of a DXE_DRIVER FFS file with a Checksum encapsulation section #
############################################################################
#
#[Rule.Common.DXE_DRIVER]
@@ -237,14 +237,14 @@ READ_LOCK_STATUS = TRUE [Rule.Common.PEI_CORE]
FILE PEI_CORE = $(NAMED_GUID) {
TE TE $(INF_OUTPUT)/$(MODULE_NAME).efi
- UI STRING ="$(MODULE_NAME)" Optional
+ UI STRING ="$(MODULE_NAME)" Optional
}
[Rule.Common.PEIM]
FILE PEIM = $(NAMED_GUID) {
PEI_DEPEX PEI_DEPEX Optional $(INF_OUTPUT)/$(MODULE_NAME).depex
PE32 PE32 $(INF_OUTPUT)/$(MODULE_NAME).efi
- UI STRING="$(MODULE_NAME)" Optional
+ UI STRING="$(MODULE_NAME)" Optional
}
[Rule.Common.PEIM.TIANOCOMPRESSED]
@@ -286,7 +286,7 @@ READ_LOCK_STATUS = TRUE [Rule.Common.UEFI_APPLICATION]
FILE APPLICATION = $(NAMED_GUID) {
- UI STRING ="$(MODULE_NAME)" Optional
+ UI STRING ="$(MODULE_NAME)" Optional
PE32 PE32 $(INF_OUTPUT)/$(MODULE_NAME).efi
}
diff --git a/BeagleBoardPkg/Debugger_scripts/rvi_boot_from_ram.inc b/BeagleBoardPkg/Debugger_scripts/rvi_boot_from_ram.inc index c691af69d7..a4e96747f8 100644 --- a/BeagleBoardPkg/Debugger_scripts/rvi_boot_from_ram.inc +++ b/BeagleBoardPkg/Debugger_scripts/rvi_boot_from_ram.inc @@ -1,6 +1,6 @@ //
// Copyright (c) 2008 - 2009, Apple Inc. All rights reserved.<BR>
-//
+//
// This program and the accompanying materials
// are licensed and made available under the terms and conditions of the BSD License
// which accompanies this distribution. The full text of the license may be found at
diff --git a/BeagleBoardPkg/Debugger_scripts/rvi_hw_setup.inc b/BeagleBoardPkg/Debugger_scripts/rvi_hw_setup.inc index f7c211f15a..dbce4dfdbd 100644 --- a/BeagleBoardPkg/Debugger_scripts/rvi_hw_setup.inc +++ b/BeagleBoardPkg/Debugger_scripts/rvi_hw_setup.inc @@ -1,6 +1,6 @@ //
// Copyright (c) 2008 - 2009, Apple Inc. All rights reserved.<BR>
-//
+//
// This program and the accompanying materials
// are licensed and made available under the terms and conditions of the BSD License
// which accompanies this distribution. The full text of the license may be found at
diff --git a/BeagleBoardPkg/Debugger_scripts/rvi_load_symbols.inc b/BeagleBoardPkg/Debugger_scripts/rvi_load_symbols.inc index e093ccbcb2..33e3eacac4 100644 --- a/BeagleBoardPkg/Debugger_scripts/rvi_load_symbols.inc +++ b/BeagleBoardPkg/Debugger_scripts/rvi_load_symbols.inc @@ -1,6 +1,6 @@ //
// Copyright (c) 2008 - 2009, Apple Inc. All rights reserved.<BR>
-//
+//
// This program and the accompanying materials
// are licensed and made available under the terms and conditions of the BSD License
// which accompanies this distribution. The full text of the license may be found at
diff --git a/BeagleBoardPkg/Debugger_scripts/rvi_symbols_macros.inc b/BeagleBoardPkg/Debugger_scripts/rvi_symbols_macros.inc index 97d465eaf2..0fc2c64b1a 100755 --- a/BeagleBoardPkg/Debugger_scripts/rvi_symbols_macros.inc +++ b/BeagleBoardPkg/Debugger_scripts/rvi_symbols_macros.inc @@ -1,6 +1,6 @@ //
// Copyright (c) 2008 - 2009, Apple Inc. All rights reserved.<BR>
-//
+//
// This program and the accompanying materials
// are licensed and made available under the terms and conditions of the BSD License
// which accompanies this distribution. The full text of the license may be found at
@@ -23,20 +23,20 @@ define /R unsigned char * find_system_table(mem_start, mem_size) unsigned long mem_size;
{
unsigned char *mem_ptr;
-
+
mem_ptr = mem_start + mem_size;
-
+
do
{
mem_ptr -= 0x400000; // 4 MB
-
+
if (strncmp(mem_ptr, "IBI SYST", 8) == 0)
{
return *(unsigned long *)(mem_ptr + 8); // EfiSystemTableBase
- }
-
+ }
+
} while (mem_ptr > mem_start);
-
+
return 0;
}
.
@@ -48,7 +48,7 @@ define /R unsigned char * find_debug_info_table_header(system_table) unsigned char *configuration_table;
unsigned long index;
unsigned char debug_table_guid[16];
-
+
// Fill in the debug table's guid
debug_table_guid[ 0] = 0x77;
debug_table_guid[ 1] = 0x2E;
@@ -66,20 +66,20 @@ define /R unsigned char * find_debug_info_table_header(system_table) debug_table_guid[13] = 0xD9;
debug_table_guid[14] = 0x5E;
debug_table_guid[15] = 0x8B;
-
+
configuration_table_entries = *(unsigned long *)(system_table + 64);
configuration_table = *(unsigned long *)(system_table + 68);
-
+
for (index = 0; index < configuration_table_entries; index++)
{
if (compare_guid(configuration_table, debug_table_guid) == 0)
{
return *(unsigned long *)(configuration_table + 16);
}
-
+
configuration_table += 20;
}
-
+
return 0;
}
.
@@ -94,7 +94,7 @@ define /R int valid_pe_header(header) {
return 1;
}
-
+
return 0;
}
.
@@ -103,9 +103,9 @@ define /R unsigned long pe_headersize(header) unsigned char *header;
{
unsigned long *size;
-
+
size = header + 0x00AC;
-
+
return *size;
}
.
@@ -115,15 +115,15 @@ define /R unsigned char *pe_filename(header) {
unsigned long *debugOffset;
unsigned char *stringOffset;
-
+
if (valid_pe_header(header))
{
debugOffset = header + 0x0128;
stringOffset = header + *debugOffset + 0x002C;
-
+
return stringOffset;
}
-
+
return 0;
}
.
@@ -141,7 +141,7 @@ define /R int char_is_valid(c) define /R write_symbols_file(filename, mem_start, mem_size)
unsigned char *filename;
unsigned char *mem_start;
- unsigned long mem_size;
+ unsigned long mem_size;
{
unsigned char *system_table;
unsigned char *debug_info_table_header;
@@ -154,40 +154,40 @@ define /R write_symbols_file(filename, mem_start, mem_size) unsigned char *debug_filename;
unsigned long header_size;
int status;
-
+
system_table = find_system_table(mem_start, mem_size);
if (system_table == 0)
{
return;
}
-
+
status = fopen(88, filename, "w");
-
+
debug_info_table_header = find_debug_info_table_header(system_table);
-
+
debug_info_table = *(unsigned long *)(debug_info_table_header + 8);
debug_info_table_size = *(unsigned long *)(debug_info_table_header + 4);
-
+
for (index = 0; index < (debug_info_table_size * 4); index += 4)
{
- debug_image_info = *(unsigned long *)(debug_info_table + index);
-
+ debug_image_info = *(unsigned long *)(debug_info_table + index);
+
if (debug_image_info == 0)
{
break;
}
-
+
loaded_image_protocol = *(unsigned long *)(debug_image_info + 4);
-
+
image_base = *(unsigned long *)(loaded_image_protocol + 32);
-
+
debug_filename = pe_filename(image_base);
header_size = pe_headersize(image_base);
-
+
$fprintf 88, "%s 0x%08x\n", debug_filename, image_base + header_size$;
}
-
-
+
+
fclose(88);
}
.
diff --git a/BeagleBoardPkg/Debugger_scripts/rvi_unload_symbols.inc b/BeagleBoardPkg/Debugger_scripts/rvi_unload_symbols.inc index f85f442c9c..b00a1322d4 100755 --- a/BeagleBoardPkg/Debugger_scripts/rvi_unload_symbols.inc +++ b/BeagleBoardPkg/Debugger_scripts/rvi_unload_symbols.inc @@ -1,6 +1,6 @@ //
// Copyright (c) 2008 - 2009, Apple Inc. All rights reserved.<BR>
-//
+//
// This program and the accompanying materials
// are licensed and made available under the terms and conditions of the BSD License
// which accompanies this distribution. The full text of the license may be found at
diff --git a/BeagleBoardPkg/Include/BeagleBoard.h b/BeagleBoardPkg/Include/BeagleBoard.h index cdd7242331..cae398a984 100755 --- a/BeagleBoardPkg/Include/BeagleBoard.h +++ b/BeagleBoardPkg/Include/BeagleBoard.h @@ -2,14 +2,14 @@ * Header defining the BeagleBoard constants (Base addresses, sizes, flags)
*
* Copyright (c) 2011, ARM Limited. All rights reserved.
-*
-* This program and the accompanying materials
-* are licensed and made available under the terms and conditions of the BSD License
-* which accompanies this distribution. The full text of the license may be found at
-* http://opensource.org/licenses/bsd-license.php
*
-* THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
-* WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
+* This program and the accompanying materials
+* are licensed and made available under the terms and conditions of the BSD License
+* which accompanies this distribution. The full text of the license may be found at
+* http://opensource.org/licenses/bsd-license.php
+*
+* THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
+* WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
*
**/
@@ -176,4 +176,4 @@ typedef enum { REVISION_AB,
} BEAGLEBOARD_REVISION;
-#endif
+#endif
diff --git a/BeagleBoardPkg/Library/BeagleBoardLib/BeagleBoard.c b/BeagleBoardPkg/Library/BeagleBoardLib/BeagleBoard.c index 4e58f36042..dbbe68a7a0 100755 --- a/BeagleBoardPkg/Library/BeagleBoardLib/BeagleBoard.c +++ b/BeagleBoardPkg/Library/BeagleBoardLib/BeagleBoard.c @@ -1,14 +1,14 @@ /** @file
*
* Copyright (c) 2011-2012, ARM Limited. All rights reserved.
-*
-* This program and the accompanying materials
-* are licensed and made available under the terms and conditions of the BSD License
-* which accompanies this distribution. The full text of the license may be found at
-* http://opensource.org/licenses/bsd-license.php
*
-* THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
-* WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
+* This program and the accompanying materials
+* are licensed and made available under the terms and conditions of the BSD License
+* which accompanies this distribution. The full text of the license may be found at
+* http://opensource.org/licenses/bsd-license.php
+*
+* THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
+* WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
*
**/
@@ -47,10 +47,10 @@ BeagleBoardGetRevision ( OldPinDir = MmioRead32 (GPIO6_BASE + GPIO_OE);
MmioWrite32(GPIO6_BASE + GPIO_OE, (OldPinDir | BIT11 | BIT12 | BIT13));
Revision = MmioRead32 (GPIO6_BASE + GPIO_DATAIN);
-
+
// Restore I/O settings
MmioWrite32 (GPIO6_BASE + GPIO_OE, OldPinDir);
-
+
return (BEAGLEBOARD_REVISION)((Revision >> 11) & 0x7);
}
diff --git a/BeagleBoardPkg/Library/BeagleBoardLib/BeagleBoardHelper.S b/BeagleBoardPkg/Library/BeagleBoardLib/BeagleBoardHelper.S index 0d50cbd45a..8e02088efc 100644 --- a/BeagleBoardPkg/Library/BeagleBoardLib/BeagleBoardHelper.S +++ b/BeagleBoardPkg/Library/BeagleBoardLib/BeagleBoardHelper.S @@ -1,13 +1,13 @@ #
# Copyright (c) 2012-2013, ARM Limited. All rights reserved.
-#
-# This program and the accompanying materials
-# are licensed and made available under the terms and conditions of the BSD License
-# which accompanies this distribution. The full text of the license may be found at
+#
+# This program and the accompanying materials
+# are licensed and made available under the terms and conditions of the BSD License
+# which accompanies this distribution. The full text of the license may be found at
# http://opensource.org/licenses/bsd-license.php
#
-# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
-# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
+# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
+# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
#
#
@@ -44,4 +44,4 @@ ASM_PFX(ArmPlatformGetPrimaryCoreMpId): // always the MPIDR of the calling CPU.
b ASM_PFX(ArmReadMpidr)
-ASM_FUNCTION_REMOVE_IF_UNREFERENCED
+ASM_FUNCTION_REMOVE_IF_UNREFERENCED
diff --git a/BeagleBoardPkg/Library/BeagleBoardLib/BeagleBoardHelper.asm b/BeagleBoardPkg/Library/BeagleBoardLib/BeagleBoardHelper.asm index b850d9858e..39a2a536ad 100644 --- a/BeagleBoardPkg/Library/BeagleBoardLib/BeagleBoardHelper.asm +++ b/BeagleBoardPkg/Library/BeagleBoardLib/BeagleBoardHelper.asm @@ -1,13 +1,13 @@ //
// Copyright (c) 2012-2013, ARM Limited. All rights reserved.
-//
-// This program and the accompanying materials
-// are licensed and made available under the terms and conditions of the BSD License
-// which accompanies this distribution. The full text of the license may be found at
-// http://opensource.org/licenses/bsd-license.php
//
-// THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
-// WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
+// This program and the accompanying materials
+// are licensed and made available under the terms and conditions of the BSD License
+// which accompanies this distribution. The full text of the license may be found at
+// http://opensource.org/licenses/bsd-license.php
+//
+// THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
+// WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
//
//
diff --git a/BeagleBoardPkg/Library/BeagleBoardLib/BeagleBoardLib.inf b/BeagleBoardPkg/Library/BeagleBoardLib/BeagleBoardLib.inf index f3242729b7..b1139a477d 100755 --- a/BeagleBoardPkg/Library/BeagleBoardLib/BeagleBoardLib.inf +++ b/BeagleBoardPkg/Library/BeagleBoardLib/BeagleBoardLib.inf @@ -1,13 +1,13 @@ #/* @file
# Copyright (c) 2011-2013, ARM Limited. All rights reserved.
-#
-# This program and the accompanying materials
-# are licensed and made available under the terms and conditions of the BSD License
-# which accompanies this distribution. The full text of the license may be found at
-# http://opensource.org/licenses/bsd-license.php
#
-# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
-# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
+# This program and the accompanying materials
+# are licensed and made available under the terms and conditions of the BSD License
+# which accompanies this distribution. The full text of the license may be found at
+# http://opensource.org/licenses/bsd-license.php
+#
+# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
+# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
#
#*/
diff --git a/BeagleBoardPkg/Library/BeagleBoardLib/BeagleBoardMem.c b/BeagleBoardPkg/Library/BeagleBoardLib/BeagleBoardMem.c index 210e850c8d..b77b069930 100755 --- a/BeagleBoardPkg/Library/BeagleBoardLib/BeagleBoardMem.c +++ b/BeagleBoardPkg/Library/BeagleBoardLib/BeagleBoardMem.c @@ -1,14 +1,14 @@ /** @file
*
* Copyright (c) 2011, ARM Limited. All rights reserved.
-*
-* This program and the accompanying materials
-* are licensed and made available under the terms and conditions of the BSD License
-* which accompanies this distribution. The full text of the license may be found at
-* http://opensource.org/licenses/bsd-license.php
*
-* THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
-* WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
+* This program and the accompanying materials
+* are licensed and made available under the terms and conditions of the BSD License
+* which accompanies this distribution. The full text of the license may be found at
+* http://opensource.org/licenses/bsd-license.php
+*
+* THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
+* WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
*
**/
diff --git a/BeagleBoardPkg/Library/BeagleBoardLib/Clock.c b/BeagleBoardPkg/Library/BeagleBoardLib/Clock.c index 1985a6bfb4..6ca48e0c9f 100755 --- a/BeagleBoardPkg/Library/BeagleBoardLib/Clock.c +++ b/BeagleBoardPkg/Library/BeagleBoardLib/Clock.c @@ -1,7 +1,7 @@ /** @file
Copyright (c) 2008 - 2009, Apple Inc. All rights reserved.<BR>
-
+
This program and the accompanying materials
are licensed and made available under the terms and conditions of the BSD License
which accompanies this distribution. The full text of the license may be found at
diff --git a/BeagleBoardPkg/Library/BeagleBoardLib/PadConfiguration.c b/BeagleBoardPkg/Library/BeagleBoardLib/PadConfiguration.c index 45438023d2..e6f7cc55ff 100755 --- a/BeagleBoardPkg/Library/BeagleBoardLib/PadConfiguration.c +++ b/BeagleBoardPkg/Library/BeagleBoardLib/PadConfiguration.c @@ -1,7 +1,7 @@ /** @file
Copyright (c) 2008 - 2009, Apple Inc. All rights reserved.<BR>
-
+
This program and the accompanying materials
are licensed and made available under the terms and conditions of the BSD License
which accompanies this distribution. The full text of the license may be found at
diff --git a/BeagleBoardPkg/Library/EblCmdLib/EblCmdLib.c b/BeagleBoardPkg/Library/EblCmdLib/EblCmdLib.c index 4f1a327cea..46204a4386 100644 --- a/BeagleBoardPkg/Library/EblCmdLib/EblCmdLib.c +++ b/BeagleBoardPkg/Library/EblCmdLib/EblCmdLib.c @@ -2,7 +2,7 @@ Add custom commands for BeagleBoard development.
Copyright (c) 2008 - 2010, Apple Inc. All rights reserved.<BR>
-
+
This program and the accompanying materials
are licensed and made available under the terms and conditions of the BSD License
which accompanies this distribution. The full text of the license may be found at
@@ -39,11 +39,11 @@ Simple arm disassembler via a library
Argv[0] - symboltable
- Argv[1] - Optional quoted format string
+ Argv[1] - Optional quoted format string
Argv[2] - Optional flag
@param Argc Number of command arguments in Argv
- @param Argv Array of strings that represent the parsed command line.
+ @param Argv Array of strings that represent the parsed command line.
Argv[0] is the command name
@return EFI_SUCCESS
@@ -64,7 +64,7 @@ EblSymbolTable ( UINT32 PeCoffSizeOfHeaders;
UINT32 ImageBase;
BOOLEAN Elf;
-
+
// Need to add lots of error checking on the passed in string
// Default string is for RealView debugger or gdb depending on toolchain used.
if (Argc > 1) {
@@ -74,17 +74,17 @@ EblSymbolTable ( // Assume gdb
Format = "add-symbol-file %a 0x%x";
#else
- // Default to RVCT
+ // Default to RVCT
Format = "load /a /ni /np %a &0x%x";
#endif
}
Elf = (Argc > 2) ? FALSE : TRUE;
-
+
Status = EfiGetSystemConfigurationTable (&gEfiDebugImageInfoTableGuid, (VOID **)&DebugImageTableHeader);
if (EFI_ERROR (Status)) {
return Status;
}
-
+
DebugTable = DebugImageTableHeader->EfiDebugImageInfoTable;
if (DebugTable == NULL) {
return EFI_SUCCESS;
@@ -100,13 +100,13 @@ EblSymbolTable ( if (Elf) {
// ELF and Mach-O images don't include the header so the linked address does not include header
ImageBase += PeCoffSizeOfHeaders;
- }
+ }
AsciiPrint (Format, Pdb, ImageBase);
AsciiPrint ("\n");
} else {
}
}
- }
+ }
}
return EFI_SUCCESS;
@@ -121,7 +121,7 @@ EblSymbolTable ( ARgv[2] - Number of instructions to disassembly (optional)
@param Argc Number of command arguments in Argv
- @param Argv Array of strings that represent the parsed command line.
+ @param Argv Array of strings that represent the parsed command line.
Argv[0] is the command name
@return EFI_SUCCESS
@@ -138,22 +138,22 @@ EblDisassembler ( UINT32 Count;
CHAR8 Buffer[80];
UINT32 ItBlock;
-
+
if (Argc < 2) {
return EFI_INVALID_PARAMETER;
}
-
+
Address = AsciiStrHexToUintn (Argv[1]);
Count = (Argc > 2) ? (UINT32)AsciiStrHexToUintn (Argv[2]) : 20;
- Ptr = (UINT8 *)(UINTN)Address;
+ Ptr = (UINT8 *)(UINTN)Address;
ItBlock = 0;
do {
CurrentAddress = Ptr;
DisassembleInstruction (&Ptr, TRUE, TRUE, &ItBlock, Buffer, sizeof (Buffer));
AsciiPrint ("0x%08x: %a\n", CurrentAddress, Buffer);
} while (Count-- > 0);
-
+
return EFI_SUCCESS;
}
@@ -203,7 +203,7 @@ CHAR8 *mTokenList[] = { ARgv[2] - Number of instructions to disassembly (optional)
@param Argc Number of command arguments in Argv
- @param Argv Array of strings that represent the parsed command line.
+ @param Argv Array of strings that represent the parsed command line.
Argv[0] is the command name
@return EFI_SUCCESS
@@ -256,7 +256,7 @@ EblPerformance ( AsciiPrint ("%6a %6ld ms\n", Token, Milliseconds);
break;
}
- }
+ }
}
} while (Key != 0);
diff --git a/BeagleBoardPkg/Library/EblCmdLib/EblCmdLib.inf b/BeagleBoardPkg/Library/EblCmdLib/EblCmdLib.inf index 329df78bbe..a79448c0e9 100644 --- a/BeagleBoardPkg/Library/EblCmdLib/EblCmdLib.inf +++ b/BeagleBoardPkg/Library/EblCmdLib/EblCmdLib.inf @@ -20,7 +20,7 @@ FILE_GUID = ea62bdc3-1063-425f-8851-98cb47f213a8
MODULE_TYPE = UEFI_DRIVER
VERSION_STRING = 1.0
- LIBRARY_CLASS = EblCmdLib|DXE_DRIVER UEFI_APPLICATION UEFI_DRIVER
+ LIBRARY_CLASS = EblCmdLib|DXE_DRIVER UEFI_APPLICATION UEFI_DRIVER
#
@@ -44,10 +44,10 @@ ArmDisassemblerLib
PerformanceLib
TimerLib
-
+
[Protocols]
gEfiDebugSupportProtocolGuid
gEfiLoadedImageProtocolGuid
-
+
[Guids]
gEfiDebugImageInfoTableGuid
diff --git a/BeagleBoardPkg/Library/GdbSerialLib/GdbSerialLib.c b/BeagleBoardPkg/Library/GdbSerialLib/GdbSerialLib.c index 7634ee174c..82a2957dc9 100644 --- a/BeagleBoardPkg/Library/GdbSerialLib/GdbSerialLib.c +++ b/BeagleBoardPkg/Library/GdbSerialLib/GdbSerialLib.c @@ -2,7 +2,7 @@ Basic serial IO abstaction for GDB
Copyright (c) 2008 - 2009, Apple Inc. All rights reserved.<BR>
-
+
This program and the accompanying materials
are licensed and made available under the terms and conditions of the BSD License
which accompanies this distribution. The full text of the license may be found at
@@ -34,10 +34,10 @@ GdbSerialLibConstructor ( RETURN_STATUS
EFIAPI
GdbSerialInit (
- IN UINT64 BaudRate,
- IN UINT8 Parity,
- IN UINT8 DataBits,
- IN UINT8 StopBits
+ IN UINT64 BaudRate,
+ IN UINT8 Parity,
+ IN UINT8 DataBits,
+ IN UINT8 StopBits
)
{
return RETURN_SUCCESS;
@@ -47,7 +47,7 @@ BOOLEAN EFIAPI
GdbIsCharAvailable (
VOID
- )
+ )
{
UINT32 LSR = UartBase(PcdGet32(PcdOmap35xxConsoleUart)) + UART_LSR_REG;
@@ -67,7 +67,7 @@ GdbGetChar ( UINT32 LSR = UartBase(PcdGet32(PcdOmap35xxConsoleUart)) + UART_LSR_REG;
UINT32 RBR = UartBase(PcdGet32(PcdOmap35xxConsoleUart)) + UART_RBR_REG;
CHAR8 Char;
-
+
while ((MmioRead8(LSR) & UART_LSR_RX_FIFO_E_MASK) == UART_LSR_RX_FIFO_E_EMPTY);
Char = MmioRead8(RBR);
@@ -82,7 +82,7 @@ GdbPutChar ( {
UINT32 LSR = UartBase(PcdGet32(PcdOmap35xxConsoleUart)) + UART_LSR_REG;
UINT32 THR = UartBase(PcdGet32(PcdOmap35xxConsoleUart)) + UART_THR_REG;
-
+
while ((MmioRead8(LSR) & UART_LSR_TX_FIFO_E_MASK) == UART_LSR_TX_FIFO_E_NOT_EMPTY);
MmioWrite8(THR, Char);
}
diff --git a/BeagleBoardPkg/Library/GdbSerialLib/GdbSerialLib.inf b/BeagleBoardPkg/Library/GdbSerialLib/GdbSerialLib.inf index df96e8b756..a06acf14fb 100644 --- a/BeagleBoardPkg/Library/GdbSerialLib/GdbSerialLib.inf +++ b/BeagleBoardPkg/Library/GdbSerialLib/GdbSerialLib.inf @@ -1,14 +1,14 @@ #/** @file
-#
+#
# Copyright (c) 2008 - 2010, Apple Inc. All rights reserved.<BR>
# This program and the accompanying materials
# are licensed and made available under the terms and conditions of the BSD License
# which accompanies this distribution. The full text of the license may be found at
# http://opensource.org/licenses/bsd-license.php
-#
+#
# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
-#
+#
#**/
[Defines]
@@ -34,7 +34,7 @@ [LibraryClasses]
DebugLib
IoLib
- OmapLib
+ OmapLib
[FixedPcd]
gOmap35xxTokenSpaceGuid.PcdOmap35xxConsoleUart
diff --git a/BeagleBoardPkg/Library/ResetSystemLib/ResetSystemLib.c b/BeagleBoardPkg/Library/ResetSystemLib/ResetSystemLib.c index 706a19b273..7b0949e043 100644 --- a/BeagleBoardPkg/Library/ResetSystemLib/ResetSystemLib.c +++ b/BeagleBoardPkg/Library/ResetSystemLib/ResetSystemLib.c @@ -1,8 +1,8 @@ /** @file
Do a generic Cold Reset for OMAP3550 and BeagleBoard specific Warm reset
-
+
Copyright (c) 2008 - 2010, Apple Inc. All rights reserved.<BR>
-
+
This program and the accompanying materials
are licensed and made available under the terms and conditions of the BSD License
which accompanies this distribution. The full text of the license may be found at
@@ -54,7 +54,7 @@ ShutdownEfi ( Pages = EFI_SIZE_TO_PAGES (MemoryMapSize) + 1;
MemoryMap = AllocatePages (Pages);
-
+
//
// Get System MemoryMap
//
@@ -141,7 +141,7 @@ LibResetSystem ( ASSERT (FALSE);
return EFI_DEVICE_ERROR;
}
-
+
/**
@@ -149,7 +149,7 @@ LibResetSystem ( @param ImageHandle The firmware allocated handle for the EFI image.
@param SystemTable A pointer to the EFI System Table.
-
+
@retval EFI_SUCCESS The constructor always returns EFI_SUCCESS.
**/
diff --git a/BeagleBoardPkg/Library/ResetSystemLib/ResetSystemLib.inf b/BeagleBoardPkg/Library/ResetSystemLib/ResetSystemLib.inf index e198812554..64638cb62c 100644 --- a/BeagleBoardPkg/Library/ResetSystemLib/ResetSystemLib.inf +++ b/BeagleBoardPkg/Library/ResetSystemLib/ResetSystemLib.inf @@ -34,7 +34,7 @@ [Pcd.common]
gArmTokenSpaceGuid.PcdCpuResetAddress
gEmbeddedTokenSpaceGuid.PcdEmbeddedFdBaseAddress
-
+
[LibraryClasses]
DebugLib
ArmLib
diff --git a/BeagleBoardPkg/Sec/Arm/ModuleEntryPoint.S b/BeagleBoardPkg/Sec/Arm/ModuleEntryPoint.S index 94291fc52c..b656c1e040 100644 --- a/BeagleBoardPkg/Sec/Arm/ModuleEntryPoint.S +++ b/BeagleBoardPkg/Sec/Arm/ModuleEntryPoint.S @@ -1,4 +1,4 @@ -#------------------------------------------------------------------------------
+#------------------------------------------------------------------------------
#
# Copyright (c) 2008 - 2009, Apple Inc. All rights reserved.<BR>
#
@@ -27,7 +27,7 @@ ASM_PFX(_ModuleEntryPoint): mrc p15, 0, r0, c1, c0, 1 // read Auxiliary Control Register
bic r0, r0, #0x00000002 // disable L2 cache
mcr p15, 0, r0, c1, c0, 1 // store Auxiliary Control Register
-
+
//Enable Strict alignment checking & Instruction cache
mrc p15, 0, r0, c1, c0, 0
bic r0, r0, #0x00002300 /* clear bits 13, 9:8 (--V- --RS) */
@@ -42,8 +42,8 @@ ASM_PFX(_ModuleEntryPoint): mcr p15, 0, r0, c1, c0, 2
mov r0, #0x40000000 // Set EN bit in FPEXC
mcr p10,#0x7,r0,c8,c0,#0 // msr FPEXC,r0 in ARM assembly
-
-
+
+
// Set CPU vectors to start of DRAM
LoadConstantToReg (FixedPcdGet32(PcdCpuVectorBaseAddress) ,r0) // Get vector base
mcr p15, 0, r0, c12, c0, 0
@@ -57,14 +57,14 @@ FillVectors: adds r2, r2, #4
cmp r2, #32
bne FillVectors
-
+
/* before we call C code, lets setup the stack pointer in internal RAM */
stack_pointer_setup:
//
- // Set stack based on PCD values. Need to do it this way to make C code work
- // when it runs from FLASH.
- //
+ // Set stack based on PCD values. Need to do it this way to make C code work
+ // when it runs from FLASH.
+ //
LoadConstantToReg (FixedPcdGet32(PcdPrePiStackBase) ,r2) /* stack base arg2 */
LoadConstantToReg (FixedPcdGet32(PcdPrePiStackSize) ,r3) /* stack size arg3 */
add r4, r2, r3
@@ -82,4 +82,4 @@ stack_pointer_setup: ShouldNeverGetHere:
/* _CEntryPoint should never return */
b ShouldNeverGetHere
-
+
diff --git a/BeagleBoardPkg/Sec/Arm/ModuleEntryPoint.asm b/BeagleBoardPkg/Sec/Arm/ModuleEntryPoint.asm index d31a29b7c9..63174d4b84 100644 --- a/BeagleBoardPkg/Sec/Arm/ModuleEntryPoint.asm +++ b/BeagleBoardPkg/Sec/Arm/ModuleEntryPoint.asm @@ -1,4 +1,4 @@ -//------------------------------------------------------------------------------
+//------------------------------------------------------------------------------
//
// Copyright (c) 2008 - 2009, Apple Inc. All rights reserved.<BR>
//
@@ -16,21 +16,21 @@ #include <Library/PcdLib.h>
#include <AutoGen.h>
INCLUDE AsmMacroIoLib.inc
-
+
IMPORT CEntryPoint
EXPORT _ModuleEntryPoint
-
+
PRESERVE8
AREA ModuleEntryPoint, CODE, READONLY
-
+
_ModuleEntryPoint
-
+
//Disable L2 cache
mrc p15, 0, r0, c1, c0, 1 // read Auxiliary Control Register
bic r0, r0, #0x00000002 // disable L2 cache
mcr p15, 0, r0, c1, c0, 1 // store Auxiliary Control Register
-
+
//Enable Strict alignment checking & Instruction cache
mrc p15, 0, r0, c1, c0, 0
bic r0, r0, #0x00002300 /* clear bits 13, 9:8 (--V- --RS) */
@@ -38,14 +38,14 @@ _ModuleEntryPoint orr r0, r0, #0x00000002 /* set bit 1 (A) Align */
orr r0, r0, #0x00001000 /* set bit 12 (I) enable I-Cache */
mcr p15, 0, r0, c1, c0, 0
-
+
// Enable NEON register in case folks want to use them for optimizations (CopyMem)
mrc p15, 0, r0, c1, c0, 2
orr r0, r0, #0x00f00000 // Enable VPF access (V* instructions)
mcr p15, 0, r0, c1, c0, 2
mov r0, #0x40000000 // Set EN bit in FPEXC
msr FPEXC,r0
-
+
// Set CPU vectors to start of DRAM
LoadConstantToReg (FixedPcdGet32(PcdCpuVectorBaseAddress) ,r0) // Get vector base
mcr p15, 0, r0, c12, c0, 0
@@ -59,16 +59,16 @@ FillVectors adds r2, r2, #4
cmp r2, #32
bne FillVectors
-
+
/* before we call C code, lets setup the stack pointer in internal RAM */
stack_pointer_setup
//
- // Set stack based on PCD values. Need to do it this way to make C code work
- // when it runs from FLASH.
- //
- LoadConstantToReg (FixedPcdGet32(PcdPrePiStackBase) ,r2) // stack base arg2
- LoadConstantToReg (FixedPcdGet32(PcdPrePiStackSize) ,r3) // stack size arg3
+ // Set stack based on PCD values. Need to do it this way to make C code work
+ // when it runs from FLASH.
+ //
+ LoadConstantToReg (FixedPcdGet32(PcdPrePiStackBase) ,r2) // stack base arg2
+ LoadConstantToReg (FixedPcdGet32(PcdPrePiStackSize) ,r3) // stack size arg3
add r4, r2, r3
//Enter SVC mode and set up SVC stack pointer
@@ -77,13 +77,13 @@ stack_pointer_setup mov r13,r4
// Call C entry point
- LoadConstantToReg (FixedPcdGet32(PcdMemorySize) ,r1) // memory size arg1
+ LoadConstantToReg (FixedPcdGet32(PcdMemorySize) ,r1) // memory size arg1
LoadConstantToReg (FixedPcdGet32(PcdMemoryBase) ,r0) // memory start arg0
- blx CEntryPoint // Assume C code is thumb
+ blx CEntryPoint // Assume C code is thumb
ShouldNeverGetHere
/* _CEntryPoint should never return */
b ShouldNeverGetHere
-
+
END
diff --git a/BeagleBoardPkg/Sec/Cache.c b/BeagleBoardPkg/Sec/Cache.c index 193004a8e8..7399eef5be 100644 --- a/BeagleBoardPkg/Sec/Cache.c +++ b/BeagleBoardPkg/Sec/Cache.c @@ -1,7 +1,7 @@ /** @file
Copyright (c) 2008 - 2009, Apple Inc. All rights reserved.<BR>
-
+
This program and the accompanying materials
are licensed and made available under the terms and conditions of the BSD License
which accompanies this distribution. The full text of the license may be found at
@@ -60,7 +60,7 @@ InitCache ( MemoryTable[1].VirtualBase = SOC_REGISTERS_L3_PHYSICAL_BASE;
MemoryTable[1].Length = SOC_REGISTERS_L3_PHYSICAL_LENGTH;
MemoryTable[1].Attributes = SOC_REGISTERS_L3_ATTRIBUTES;
-
+
// SOC Registers. L4 interconnects
MemoryTable[2].PhysicalBase = SOC_REGISTERS_L4_PHYSICAL_BASE;
MemoryTable[2].VirtualBase = SOC_REGISTERS_L4_PHYSICAL_BASE;
@@ -72,8 +72,8 @@ InitCache ( MemoryTable[3].VirtualBase = 0;
MemoryTable[3].Length = 0;
MemoryTable[3].Attributes = (ARM_MEMORY_REGION_ATTRIBUTES)0;
-
+
ArmConfigureMmu (MemoryTable, &TranslationTableBase, &TranslationTableSize);
-
+
BuildMemoryAllocationHob((EFI_PHYSICAL_ADDRESS)(UINTN)TranslationTableBase, TranslationTableSize, EfiBootServicesData);
}
diff --git a/BeagleBoardPkg/Sec/Clock.c b/BeagleBoardPkg/Sec/Clock.c index 8de24f851c..24fdc71c42 100644 --- a/BeagleBoardPkg/Sec/Clock.c +++ b/BeagleBoardPkg/Sec/Clock.c @@ -1,7 +1,7 @@ /** @file
Copyright (c) 2008 - 2009, Apple Inc. All rights reserved.<BR>
-
+
This program and the accompanying materials
are licensed and made available under the terms and conditions of the BSD License
which accompanies this distribution. The full text of the license may be found at
diff --git a/BeagleBoardPkg/Sec/LzmaDecompress.h b/BeagleBoardPkg/Sec/LzmaDecompress.h index e4483b6823..a79ff343d2 100644 --- a/BeagleBoardPkg/Sec/LzmaDecompress.h +++ b/BeagleBoardPkg/Sec/LzmaDecompress.h @@ -19,16 +19,16 @@ Examines a GUIDed section and returns the size of the decoded buffer and the
size of an scratch buffer required to actually decode the data in a GUIDed section.
- Examines a GUIDed section specified by InputSection.
+ Examines a GUIDed section specified by InputSection.
If GUID for InputSection does not match the GUID that this handler supports,
- then RETURN_UNSUPPORTED is returned.
+ then RETURN_UNSUPPORTED is returned.
If the required information can not be retrieved from InputSection,
then RETURN_INVALID_PARAMETER is returned.
If the GUID of InputSection does match the GUID that this handler supports,
then the size required to hold the decoded buffer is returned in OututBufferSize,
the size of an optional scratch buffer is returned in ScratchSize, and the Attributes field
from EFI_GUID_DEFINED_SECTION header of InputSection is returned in SectionAttribute.
-
+
If InputSection is NULL, then ASSERT().
If OutputBufferSize is NULL, then ASSERT().
If ScratchBufferSize is NULL, then ASSERT().
@@ -59,16 +59,16 @@ LzmaGuidedSectionGetInfo ( /**
Decompress a LZAM compressed GUIDed section into a caller allocated output buffer.
-
- Decodes the GUIDed section specified by InputSection.
- If GUID for InputSection does not match the GUID that this handler supports, then RETURN_UNSUPPORTED is returned.
+
+ Decodes the GUIDed section specified by InputSection.
+ If GUID for InputSection does not match the GUID that this handler supports, then RETURN_UNSUPPORTED is returned.
If the data in InputSection can not be decoded, then RETURN_INVALID_PARAMETER is returned.
If the GUID of InputSection does match the GUID that this handler supports, then InputSection
is decoded into the buffer specified by OutputBuffer and the authentication status of this
decode operation is returned in AuthenticationStatus. If the decoded buffer is identical to the
data in InputSection, then OutputBuffer is set to point at the data in InputSection. Otherwise,
the decoded data will be placed in caller allocated buffer specified by OutputBuffer.
-
+
If InputSection is NULL, then ASSERT().
If OutputBuffer is NULL, then ASSERT().
If ScratchBuffer is NULL and this decode operation requires a scratch buffer, then ASSERT().
@@ -76,10 +76,10 @@ LzmaGuidedSectionGetInfo ( @param[in] InputSection A pointer to a GUIDed section of an FFS formatted file.
- @param[out] OutputBuffer A pointer to a buffer that contains the result of a decode operation.
+ @param[out] OutputBuffer A pointer to a buffer that contains the result of a decode operation.
@param[out] ScratchBuffer A caller allocated buffer that may be required by this function
- as a scratch buffer to perform the decode operation.
- @param[out] AuthenticationStatus
+ as a scratch buffer to perform the decode operation.
+ @param[out] AuthenticationStatus
A pointer to the authentication status of the decoded output buffer.
See the definition of authentication status in the EFI_PEI_GUIDED_SECTION_EXTRACTION_PPI
section of the PI Specification. EFI_AUTH_STATUS_PLATFORM_OVERRIDE must
@@ -98,6 +98,6 @@ LzmaGuidedSectionExtraction ( OUT VOID *ScratchBuffer, OPTIONAL
OUT UINT32 *AuthenticationStatus
);
-
+
#endif // __LZMADECOMPRESS_H__
diff --git a/BeagleBoardPkg/Sec/PadConfiguration.c b/BeagleBoardPkg/Sec/PadConfiguration.c index ddd9296120..2dace3bf38 100644 --- a/BeagleBoardPkg/Sec/PadConfiguration.c +++ b/BeagleBoardPkg/Sec/PadConfiguration.c @@ -1,7 +1,7 @@ /** @file
Copyright (c) 2008 - 2009, Apple Inc. All rights reserved.<BR>
-
+
This program and the accompanying materials
are licensed and made available under the terms and conditions of the BSD License
which accompanies this distribution. The full text of the license may be found at
diff --git a/BeagleBoardPkg/Sec/Sec.c b/BeagleBoardPkg/Sec/Sec.c index eea9455e3f..0708396d97 100644 --- a/BeagleBoardPkg/Sec/Sec.c +++ b/BeagleBoardPkg/Sec/Sec.c @@ -2,7 +2,7 @@ C Entry point for the SEC. First C code after the reset vector.
Copyright (c) 2008 - 2009, Apple Inc. All rights reserved.<BR>
-
+
This program and the accompanying materials
are licensed and made available under the terms and conditions of the BSD License
which accompanies this distribution. The full text of the license may be found at
@@ -93,9 +93,9 @@ UartInit ( MmioWrite32 (UartBaseAddress + UART_MCR_REG, UART_MCR_RTS_FORCE_ACTIVE | UART_MCR_DTR_FORCE_ACTIVE);
// Clear & enable fifos
- MmioWrite32 (UartBaseAddress + UART_FCR_REG, UART_FCR_TX_FIFO_CLEAR | UART_FCR_RX_FIFO_CLEAR | UART_FCR_FIFO_ENABLE);
+ MmioWrite32 (UartBaseAddress + UART_FCR_REG, UART_FCR_TX_FIFO_CLEAR | UART_FCR_RX_FIFO_CLEAR | UART_FCR_FIFO_ENABLE);
- // Restore MODE_SELECT
+ // Restore MODE_SELECT
MmioWrite32 (UartBaseAddress + UART_MDR1_REG, UART_MDR1_MODE_SELECT_UART_16X);
}
@@ -153,7 +153,7 @@ CEntryPoint ( // Start talking
UartInit ();
-
+
InitializeDebugAgent (DEBUG_AGENT_INIT_PREMEM_SEC, NULL, NULL);
SaveAndSetDebugTimerInterrupt (TRUE);
@@ -179,7 +179,7 @@ CEntryPoint ( // Load the DXE Core and transfer control to it
LoadDxeCoreFromFv (NULL, 0);
-
+
// DXE Core should always load and never return
ASSERT (FALSE);
}
diff --git a/BeagleBoardPkg/Sec/Sec.inf b/BeagleBoardPkg/Sec/Sec.inf index 7fc4ec12d4..eb6d93c000 100644 --- a/BeagleBoardPkg/Sec/Sec.inf +++ b/BeagleBoardPkg/Sec/Sec.inf @@ -1,16 +1,16 @@ #/** @file
# SEC - Reset vector code that jumps to C and loads DXE core
-#
+#
# Copyright (c) 2008, Apple Inc. All rights reserved.<BR>
# This program and the accompanying materials
# are licensed and made available under the terms and conditions of the BSD License
# which accompanies this distribution. The full text of the license may be found at
# http://opensource.org/licenses/bsd-license.php
-#
+#
# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
-#
+#
#**/
[Defines]
@@ -30,7 +30,7 @@ Cache.c
PadConfiguration.c
Clock.c
-
+
[Packages]
MdePkg/MdePkg.dec
MdeModulePkg/MdeModulePkg.dec
@@ -52,7 +52,7 @@ MemoryAllocationLib
PrePiHobListPointerLib
-[FeaturePcd]
+[FeaturePcd]
gEmbeddedTokenSpaceGuid.PcdCacheEnable
[FixedPcd]
@@ -65,9 +65,9 @@ gEmbeddedTokenSpaceGuid.PcdPrePiStackBase
gEmbeddedTokenSpaceGuid.PcdMemoryBase
gEmbeddedTokenSpaceGuid.PcdMemorySize
-
+
gOmap35xxTokenSpaceGuid.PcdOmap35xxConsoleUart
gOmap35xxTokenSpaceGuid.PcdOmap35xxFreeTimer
-
+
gArmTokenSpaceGuid.PcdCpuVectorBaseAddress
diff --git a/BeagleBoardPkg/Tools/generate_image.c b/BeagleBoardPkg/Tools/generate_image.c index 9426ca3337..7fc3faba10 100644 --- a/BeagleBoardPkg/Tools/generate_image.c +++ b/BeagleBoardPkg/Tools/generate_image.c @@ -2,13 +2,13 @@ The data structures in this code come from:
OMAP35x Applications Processor Technical Reference Manual chapter 25
OMAP34xx Multimedia Device Technical Reference Manual chapter 26.4.8.
-
- You should use the OMAP35x manual when possible. Some things, like SectionKey,
+
+ You should use the OMAP35x manual when possible. Some things, like SectionKey,
are not defined in the OMAP35x manual and you have to use the OMAP34xx manual
- to find the data.
+ to find the data.
Copyright (c) 2008 - 2010, Apple Inc. All rights reserved.<BR>
-
+
This program and the accompanying materials
are licensed and made available under the terms and conditions of the BSD License
which accompanies this distribution. The full text of the license may be found at
@@ -44,22 +44,22 @@ typedef struct { unsigned char Version;
unsigned short Reserved;
unsigned int Flags;
- unsigned int PRM_CLKSRC_CTRL;
- unsigned int PRM_CLKSEL;
+ unsigned int PRM_CLKSRC_CTRL;
+ unsigned int PRM_CLKSEL;
unsigned int CM_CLKSEL1_EMU;
unsigned int CM_CLKSEL_CORE;
unsigned int CM_CLKSEL_WKUP;
unsigned int CM_CLKEN_PLL_DPLL3;
- unsigned int CM_AUTOIDLE_PLL_DPLL3;
- unsigned int CM_CLKSEL1_PLL;
+ unsigned int CM_AUTOIDLE_PLL_DPLL3;
+ unsigned int CM_CLKSEL1_PLL;
unsigned int CM_CLKEN_PLL_DPLL4;
unsigned int CM_AUTOIDLE_PLL_DPLL4;
unsigned int CM_CLKSEL2_PLL;
- unsigned int CM_CLKSEL3_PLL;
- unsigned int CM_CLKEN_PLL_MPU;
- unsigned int CM_AUTOIDLE_PLL_MPU;
- unsigned int CM_CLKSEL1_PLL_MPU;
- unsigned int CM_CLKSEL2_PLL_MPU;
+ unsigned int CM_CLKSEL3_PLL;
+ unsigned int CM_CLKEN_PLL_MPU;
+ unsigned int CM_AUTOIDLE_PLL_MPU;
+ unsigned int CM_CLKSEL1_PLL_MPU;
+ unsigned int CM_CLKSEL2_PLL_MPU;
unsigned int CM_CLKSTCTRL_MPU;
} CHSETTINGS_DATA;
@@ -131,7 +131,7 @@ PopulateCHSETTINGSData ( )
{
unsigned int Value;
-
+
CHSETTINGSData->SectionKey = 0xC0C0C0C1;
CHSETTINGSData->Valid = 0x1;
CHSETTINGSData->Version = 0x1;
@@ -191,10 +191,10 @@ PopulateCHRAMData ( )
{
unsigned int Value;
-
+
CHRAMData->SectionKey = 0xC0C0C0C2;
CHRAMData->Valid = 0x1;
-
+
fscanf(DataFile, "SDRC_SYSCONFIG_LSB=0x%04x\n", &Value);
CHRAMData->SDRC_SYSCONFIG_LSB = Value;
fscanf(DataFile, "SDRC_CS_CFG_LSB=0x%04x\n", &Value);
@@ -247,8 +247,8 @@ PopulateCHRAMData ( CHRAMData->Flags = 0x0003;
}
-static
-void
+static
+void
PrepareConfigurationHeader (
void
)
@@ -258,14 +258,14 @@ PrepareConfigurationHeader ( CHRAM_DATA CHRAMData;
unsigned int ConfigurationHdrOffset = 0;
FILE *DataFile;
-
+
// Open data file
DataFile = fopen(gDataFile, "rb");
if (DataFile == NULL) {
fprintf(stderr, "Can't open data file %s.\n", gDataFile);
exit(1);
}
-
+
//Initialize configuration header.
memset(gConfigurationHeader, 0x00, sizeof(gConfigurationHeader));
@@ -295,19 +295,19 @@ PrepareConfigurationHeader ( memset(&CHRAMData, 0x00, sizeof(CHRAM_DATA));
PopulateCHRAMData(DataFile, &CHRAMData);
memcpy(gConfigurationHeader + Toc.Start, &CHRAMData, Toc.Size);
-
+
//Adjust ConfigurationHdrOffset to point to next TOC
ConfigurationHdrOffset += sizeof(TOC_DATA);
//Closing TOC item
memset(gConfigurationHeader + ConfigurationHdrOffset, 0xFF, CLOSING_TOC_ITEM_SIZE);
ConfigurationHdrOffset += CLOSING_TOC_ITEM_SIZE;
-
+
// Close data file
fclose(DataFile);
}
-static
+static
void
ConstructImage (
void
@@ -324,19 +324,19 @@ ConstructImage ( if (InputFile == NULL) {
fprintf(stderr, "Can't open input file.\n");
exit(0);
- }
+ }
// Get the size of the input image.
fstat(fileno(InputFile), &FileStat);
InputImageFileSize = FileStat.st_size;
-
+
OutputFile = fopen(gOutputImageFile, "wb");
if (OutputFile == NULL) {
fprintf(stderr, "Can't open output file %s.\n", gOutputImageFile);
exit(0);
}
- // Write Configuration header
+ // Write Configuration header
fwrite(gConfigurationHeader, 1, sizeof(gConfigurationHeader), OutputFile);
// Write image header (Input image size, execution address)
@@ -354,16 +354,16 @@ ConstructImage ( }
-int
+int
main (
- int argc,
+ int argc,
char** argv
)
{
char Ch;
unsigned char *ptr;
int i;
- int TwoArg;
+ int TwoArg;
if (argc == 1) {
PrintUsage ();
@@ -378,7 +378,7 @@ main ( case 'E': /* Image execution address */
gImageExecutionAddress = strtoul (TwoArg ? argv[i+1] : &argv[i][2], (char **)&ptr, 16);
break;
-
+
case 'I': /* Input image file */
gInputImageFile = TwoArg ? argv[i+1] : &argv[i][2];
break;
@@ -386,7 +386,7 @@ main ( case 'O': /* Output image file */
gOutputImageFile = TwoArg ? argv[i+1] : &argv[i][2];
break;
-
+
case 'D': /* Data file */
gDataFile = TwoArg ? argv[i+1] : &argv[i][2];
break;
@@ -397,7 +397,7 @@ main ( }
}
-
+
//Prepare configuration header
PrepareConfigurationHeader ();
diff --git a/BeagleBoardPkg/Tools/replace.c b/BeagleBoardPkg/Tools/replace.c index e35c394dc2..00f4249592 100644 --- a/BeagleBoardPkg/Tools/replace.c +++ b/BeagleBoardPkg/Tools/replace.c @@ -1,9 +1,9 @@ //
-// Quick hack to work around not having sed, or any other reasonable
+// Quick hack to work around not having sed, or any other reasonable
// way to edit a file from a script on Windows......
//
// Copyright (c) 2010, Apple Inc. All rights reserved.<BR>
-//
+//
// This program and the accompanying materials
// are licensed and made available under the terms and conditions of the BSD License
// which accompanies this distribution. The full text of the license may be found at
@@ -40,7 +40,7 @@ Usage (char *Name) // argv[1] - Old File
// argv[2] - New File
// argv[3+n] - Match String
-// argv[4+n] - Replace string
+// argv[4+n] - Replace string
int
main (int argc, char **argv)
{
@@ -106,9 +106,9 @@ main (int argc, char **argv) // into a buffer that is as big as the maximum search key size.
// Then we can search the keys for a match. If no match
// copy the old file character to the new file. If it is a match
- // then copy the replacement string into the output file.
- // This code assumes the file system is smart and caches the
- // file in a buffer. So all the reads don't really hit the disk.
+ // then copy the replacement string into the output file.
+ // This code assumes the file system is smart and caches the
+ // file in a buffer. So all the reads don't really hit the disk.
InFilePos = 0;
while (InFilePos < (InFileSize - MinLenKey)) {
fseek (In, InFilePos, SEEK_SET);
@@ -126,7 +126,7 @@ main (int argc, char **argv) if (!Found) {
fputc (Key[0], Out);
}
-
+
InFilePos++;
}
@@ -136,7 +136,7 @@ main (int argc, char **argv) while ((c = fgetc (In)) != EOF) {
fputc (c, Out);
}
-
+
fclose (In);
fclose (Out);
free (Key);
diff --git a/EmbeddedPkg/Ebl/CmdTemplate.c b/EmbeddedPkg/Ebl/CmdTemplate.c index e19d63a8b0..2c291fcaea 100644 --- a/EmbeddedPkg/Ebl/CmdTemplate.c +++ b/EmbeddedPkg/Ebl/CmdTemplate.c @@ -25,7 +25,7 @@ Argv[0] - "%CommandName%"
@param Argc Number of command arguments in Argv
- @param Argv Array of strings that represent the parsed command line.
+ @param Argv Array of strings that represent the parsed command line.
Argv[0] is the command name
@return EFI_SUCCESS
diff --git a/EmbeddedPkg/Ebl/Command.c b/EmbeddedPkg/Ebl/Command.c index 78ddcd1936..7c00bcae85 100644 --- a/EmbeddedPkg/Ebl/Command.c +++ b/EmbeddedPkg/Ebl/Command.c @@ -32,7 +32,7 @@ EBL_COMMAND_TABLE *mCmdTable[EBL_MAX_COMMAND_COUNT]; @param chr one Ascii character
- @return The uppercase value of Ascii character
+ @return The uppercase value of Ascii character
**/
STATIC
@@ -55,11 +55,11 @@ AsciiToUpper ( FirstString is identical to SecondString, then 0 is returned. Otherwise, the
value returned is the first mismatched Unicode character in SecondString
subtracted from the first mismatched Unicode character in FirstString.
-
- @param FirstString Pointer to a Null-terminated ASCII string.
+
+ @param FirstString Pointer to a Null-terminated ASCII string.
@param SecondString Pointer to a Null-terminated ASCII string.
@param Length Max length to compare.
-
+
@retval 0 FirstString is identical to SecondString using case insensitive
comparisons.
@retval !=0 FirstString is not identical to SecondString using case
@@ -85,15 +85,15 @@ AsciiStrniCmp ( SecondString++;
Length--;
}
-
+
return AsciiToUpper (*FirstString) - AsciiToUpper (*SecondString);
}
/**
- Add a command to the mCmdTable. If there is no free space in the command
- table ASSERT. The mCmdTable is maintained in alphabetical order and the
+ Add a command to the mCmdTable. If there is no free space in the command
+ table ASSERT. The mCmdTable is maintained in alphabetical order and the
new entry is inserted into its sorted position.
@param Entry Command Entry to add to the CmdTable
@@ -124,7 +124,7 @@ EblAddCommand ( if (AsciiStriCmp (mCmdTable[Count - 1]->Name, Entry->Name) <= 0) {
break;
}
-
+
mCmdTable[Count] = mCmdTable[Count - 1];
}
mCmdTable[Count] = (EBL_COMMAND_TABLE *)Entry;
@@ -135,7 +135,7 @@ EblAddCommand ( /**
- Add an set of commands to the command table. Most commonly used on static
+ Add an set of commands to the command table. Most commonly used on static
array of commands.
@param EntryArray Pointer to array of command entries
@@ -167,7 +167,7 @@ EBL_ADD_COMMAND_PROTOCOL gEblAddCommand = { /**
- Return the best matching command for the passed in command name. The match
+ Return the best matching command for the passed in command name. The match
does not have to be exact, it just needs to be unique. This enables commands
to be shortened to the smallest set of starting characters that is unique.
@@ -193,9 +193,9 @@ EblGetCommand ( if (Str != NULL) {
// If the command includes a trailing . command extension skip it for the match.
// Example: hexdump.4
- Length = (UINTN)(Str - CommandName);
+ Length = (UINTN)(Str - CommandName);
}
-
+
for (Index = 0, BestMatchCount = 0, Match = NULL; Index < mCmdTableNextFreeIndex; Index++) {
if (AsciiStriCmp (mCmdTable[Index]->Name, CommandName) == 0) {
// match a command exactly
@@ -226,30 +226,30 @@ CountNewLines ( )
{
UINTN Count;
-
+
if (Str == NULL) {
return 0;
}
-
+
for (Count = 0; *Str != '\0'; Str++) {
if (Str[Count] == '\n') {
Count++;
}
}
-
+
return Count;
}
/**
- List out help information on all the commands or print extended information
+ List out help information on all the commands or print extended information
about a specific passed in command.
Argv[0] - "help"
Argv[1] - Command to display help about
@param Argc Number of command arguments in Argv
- @param Argv Array of strings that represent the parsed command line.
+ @param Argv Array of strings that represent the parsed command line.
Argv[0] is the command name
@return EFI_SUCCESS
@@ -281,7 +281,7 @@ EblHelpCmd ( }
}
} else if (Argv[1] != NULL) {
- // Print specific help
+ // Print specific help
for (Index = 0, CurrentRow = 0; Index < mCmdTableNextFreeIndex; Index++) {
if (AsciiStriCmp (Argv[1], mCmdTable[Index]->Name) == 0) {
Ptr = (mCmdTable[Index]->Help == NULL) ? mCmdTable[Index]->HelpSummary : mCmdTable[Index]->Help;
@@ -306,7 +306,7 @@ EblHelpCmd ( Argv[0] - "exit"
@param Argc Number of command arguments in Argv
- @param Argv Array of strings that represent the parsed command line.
+ @param Argv Array of strings that represent the parsed command line.
Argv[0] is the command name
@return EFI_ABORTED
@@ -326,14 +326,14 @@ EblExitCmd ( UINT32 DescriptorVersion;
UINTN Pages;
- if (Argc > 1) {
+ if (Argc > 1) {
if (AsciiStriCmp (Argv[1], "efi") != 0) {
return EFI_ABORTED;
}
} else if (Argc == 1) {
return EFI_ABORTED;
}
-
+
MemoryMap = NULL;
MemoryMapSize = 0;
do {
@@ -348,7 +348,7 @@ EblExitCmd ( Pages = EFI_SIZE_TO_PAGES (MemoryMapSize) + 1;
MemoryMap = AllocatePages (Pages);
-
+
//
// Get System MemoryMap
//
@@ -375,9 +375,9 @@ EblExitCmd ( // At this point it is very dangerous to do things EFI as most of EFI is now gone.
// This command is useful if you are working with a debugger as it will shutdown
// DMA and other things that could break a soft resets.
- //
+ //
CpuDeadLoop ();
-
+
// Should never get here, but makes the compiler happy
return EFI_ABORTED;
}
@@ -385,8 +385,8 @@ EblExitCmd ( /**
Update the screen by decrementing the timeout value.
- This AsciiPrint has to match the AsciiPrint in
- EblPauseCmd.
+ This AsciiPrint has to match the AsciiPrint in
+ EblPauseCmd.
@param ElaspedTime Current timeout value remaining
@@ -410,7 +410,7 @@ EblPauseCallback ( Argv[1] - timeout value is decimal seconds
@param Argc Number of command arguments in Argv
- @param Argv Array of strings that represent the parsed command line.
+ @param Argv Array of strings that represent the parsed command line.
Argv[0] is the command name
@return EFI_SUCCESS Timeout expired with no input
@@ -445,7 +445,7 @@ EblPauseCmd ( Argv[0] - "break"
@param Argc Number of command arguments in Argv
- @param Argv Array of strings that represent the parsed command line.
+ @param Argv Array of strings that represent the parsed command line.
Argv[0] is the command name
@return EFI_SUCCESS
@@ -471,7 +471,7 @@ EblBreakPointCmd ( Argv[1] - warm or shutdown reset type
@param Argc Number of command arguments in Argv
- @param Argv Array of strings that represent the parsed command line.
+ @param Argv Array of strings that represent the parsed command line.
Argv[0] is the command name
@return EFI_SUCCESS
@@ -496,7 +496,7 @@ EblResetCmd ( case 's':
ResetType = EfiResetShutdown;
}
- }
+ }
gRT->ResetSystem (ResetType, EFI_SUCCESS, 0, NULL);
return EFI_SUCCESS;
@@ -511,7 +511,7 @@ EblResetCmd ( Argv[1] - on or off
@param Argc Number of command arguments in Argv
- @param Argv Array of strings that represent the parsed command line.
+ @param Argv Array of strings that represent the parsed command line.
Argv[0] is the command name
@return EFI_SUCCESS
@@ -524,7 +524,7 @@ EblPageCmd ( )
{
if (Argc <= 1) {
- // toggle setting
+ // toggle setting
gPageBreak = (gPageBreak) ? FALSE : TRUE;
} else {
// use argv to set the value
@@ -581,7 +581,7 @@ GetBytes ( }
if (Bytes >= 2) {
Result = (Result << 8) + *Address++;
- }
+ }
if (Bytes >= 3) {
Result = (Result << 8) + *Address++;
}
@@ -611,7 +611,7 @@ OutputData ( AsciiPrint ("%08x: ", Offset);
for (Line = 0; (Line < 0x10) && (Address < EndAddress);) {
Bytes = EndAddress - Address;
-
+
switch (Width) {
case 4:
if (Bytes >= 4) {
@@ -667,7 +667,7 @@ OutputData ( Blanks[Spaces] = '\0';
AsciiPrint(Blanks);
-
+
Blanks[Spaces] = ' ';
}
@@ -682,15 +682,15 @@ OutputData ( if (Length % Width != 0) {
AsciiPrint ("%08x\n", Offset);
}
-
+
return EFI_SUCCESS;
}
/**
See if command contains .# where # is a number. Return # as the Width
- or 1 as the default Width for commands.
-
+ or 1 as the default Width for commands.
+
Example hexdump.4 returns a width of 4.
@param Argv Argv[0] is the command name
@@ -706,7 +706,7 @@ WidthFromCommandName ( {
CHAR8 *Str;
UINTN Width;
-
+
//Hexdump.2 HexDump.4 mean use a different width
Str = AsciiStrStr (Argv, ".");
if (Str != NULL) {
@@ -728,13 +728,13 @@ WidthFromCommandName ( Toggle page break global. This turns on and off prompting to Quit or hit any
key to continue when a command is about to scroll the screen with its output
- Argv[0] - "hexdump"[.#] # is optional 1,2, or 4 for width
- Argv[1] - Device or File to dump.
+ Argv[0] - "hexdump"[.#] # is optional 1,2, or 4 for width
+ Argv[1] - Device or File to dump.
Argv[2] - Optional offset to start dumping
Argv[3] - Optional number of bytes to dump
@param Argc Number of command arguments in Argv
- @param Argv Array of strings that represent the parsed command line.
+ @param Argv Array of strings that represent the parsed command line.
Argv[0] is the command name
@return EFI_SUCCESS
@@ -757,7 +757,7 @@ EblHexdumpCmd ( if ((Argc < 2) || (Argc > 4)) {
return EFI_INVALID_PARAMETER;
}
-
+
Width = WidthFromCommandName (Argv[0], 1);
if ((Width != 1) && (Width != 2) && (Width != 4)) {
return EFI_INVALID_PARAMETER;
@@ -778,13 +778,13 @@ EblHexdumpCmd ( // Make sure size includes the part of the file we have skipped
Size += Offset;
}
- }
+ }
Status = EfiSeek (File, Offset, EfiSeekStart);
if (EFI_ERROR (Status)) {
goto Exit;
}
-
+
for (; Offset + HEXDUMP_CHUNK <= Size; Offset += Chunk) {
Chunk = HEXDUMP_CHUNK;
Status = EfiRead (File, Location, &Chunk);
@@ -801,7 +801,7 @@ EblHexdumpCmd ( goto Exit;
}
}
-
+
// Any left over?
if (Offset < Size) {
Chunk = Size - Offset;
@@ -894,7 +894,7 @@ EblInitializeCmdTable ( {
EblAddCommands (mCmdTemplate, sizeof (mCmdTemplate)/sizeof (EBL_COMMAND_TABLE));
-
+
gBS->InstallProtocolInterface (
&gExternalCmdHandle,
&gEfiEblAddCommandProtocolGuid,
diff --git a/EmbeddedPkg/Ebl/Dir.c b/EmbeddedPkg/Ebl/Dir.c index 5e28ecf61a..c45f67b95b 100644 --- a/EmbeddedPkg/Ebl/Dir.c +++ b/EmbeddedPkg/Ebl/Dir.c @@ -40,22 +40,22 @@ GLOBAL_REMOVE_IF_UNREFERENCED CHAR8 *gFvFileType[] = { /**
Perform a dir on a device. The device must support Simple File System Protocol
- or the FV protocol.
+ or the FV protocol.
Argv[0] - "dir"
- Argv[1] - Device Name:path. Path is optional
+ Argv[1] - Device Name:path. Path is optional
Argv[2] - Optional filename to match on. A leading * means match substring
Argv[3] - Optional FV file type
dir fs1:\efi ; perform a dir on fs1: device in the efi directory
- dir fs1:\efi *.efi; perform a dir on fs1: device in the efi directory but
+ dir fs1:\efi *.efi; perform a dir on fs1: device in the efi directory but
only print out files that contain the string *.efi
- dir fv1:\ ; perform a dir on fv1: device in the efi directory
+ dir fv1:\ ; perform a dir on fv1: device in the efi directory
NOTE: fv devices do not contain subdirs
dir fv1:\ * PEIM ; will match all files of type PEIM
@param Argc Number of command arguments in Argv
- @param Argv Array of strings that represent the parsed command line.
+ @param Argv Array of strings that represent the parsed command line.
Argv[0] is the command name
@return EFI_SUCCESS
@@ -71,7 +71,7 @@ EblDirCmd ( EFI_OPEN_FILE *File;
EFI_FILE_INFO *DirInfo;
UINTN ReadSize;
- UINTN CurrentRow;
+ UINTN CurrentRow;
CHAR16 *MatchSubString;
EFI_STATUS GetNextFileStatus;
UINTN Key;
@@ -151,11 +151,11 @@ EblDirCmd ( do {
Type = SearchType;
GetNextFileStatus = Fv->GetNextFile (
- Fv,
+ Fv,
&Key,
- &Type,
- &NameGuid,
- &Attributes,
+ &Type,
+ &NameGuid,
+ &Attributes,
&Size
);
if (!EFI_ERROR (GetNextFileStatus)) {
@@ -165,7 +165,7 @@ EblDirCmd ( Size = 0;
Status = Fv->ReadFile (
Fv,
- &NameGuid,
+ &NameGuid,
Section,
&Size,
&Type,
@@ -173,10 +173,10 @@ EblDirCmd ( &AuthenticationStatus
);
if (!((Status == EFI_BUFFER_TOO_SMALL) || !EFI_ERROR (Status))) {
- // EFI_SUCCESS or EFI_BUFFER_TOO_SMALL mean size is valid
+ // EFI_SUCCESS or EFI_BUFFER_TOO_SMALL mean size is valid
Size = 0;
}
-
+
TypeStr = (Type <= EFI_FV_FILETYPE_FIRMWARE_VOLUME_IMAGE) ? gFvFileType[Type] : "UNKNOWN";
// read the UI seciton to do a name match.
@@ -208,12 +208,12 @@ EblDirCmd ( }
}
} while (!EFI_ERROR (GetNextFileStatus));
-
+
if (SearchType == EFI_FV_FILETYPE_ALL) {
AsciiPrint ("%,20d bytes in files %,d bytes free\n", TotalSize, File->FvSize - File->FvHeaderSize - TotalSize);
}
-
-
+
+
} else if ((File->Type == EfiOpenFileSystem) || (File->Type == EfiOpenBlockIo)) {
// Simple File System DIR
@@ -233,7 +233,7 @@ EblDirCmd ( if (UnicodeFileName[0] == '*') {
MatchSubString = &UnicodeFileName[1];
}
- }
+ }
File->FsFileHandle->SetPosition (File->FsFileHandle, 0);
for (CurrentRow = 0;;) {
@@ -247,7 +247,7 @@ EblDirCmd ( if (DirInfo == NULL) {
goto Done;
}
-
+
// Read the data
Status = File->FsFileHandle->Read (File->FsFileHandle, &ReadSize, DirInfo);
if ((EFI_ERROR (Status)) || (ReadSize == 0)) {
@@ -256,7 +256,7 @@ EblDirCmd ( } else {
break;
}
-
+
if (MatchSubString != NULL) {
if (StrStr (&DirInfo->FileName[0], MatchSubString) == NULL) {
// does not match *name argument, so skip
@@ -278,7 +278,7 @@ EblDirCmd ( if (EblAnyKeyToContinueQtoQuit (&CurrentRow, FALSE)) {
break;
}
-
+
FreePool (DirInfo);
}
@@ -297,10 +297,10 @@ Done: Change the Current Working Directory
Argv[0] - "cd"
- Argv[1] - Device Name:path. Path is optional
+ Argv[1] - Device Name:path. Path is optional
@param Argc Number of command arguments in Argv
- @param Argv Array of strings that represent the parsed command line.
+ @param Argv Array of strings that represent the parsed command line.
Argv[0] is the command name
@return EFI_SUCCESS
@@ -314,8 +314,8 @@ EblCdCmd ( {
if (Argc <= 1) {
return EFI_SUCCESS;
- }
-
+ }
+
return EfiSetCwd (Argv[1]);
}
@@ -345,7 +345,7 @@ VOID EblInitializeDirCmd (
VOID
)
-{
+{
if (FeaturePcdGet (PcdEmbeddedDirCmd)) {
EblAddCommands (mCmdDirTemplate, sizeof (mCmdDirTemplate)/sizeof (EBL_COMMAND_TABLE));
}
diff --git a/EmbeddedPkg/Ebl/Ebl.h b/EmbeddedPkg/Ebl/Ebl.h index 44c44fb0fc..c2242df9e0 100644 --- a/EmbeddedPkg/Ebl/Ebl.h +++ b/EmbeddedPkg/Ebl/Ebl.h @@ -18,13 +18,13 @@ #define __EBL_H__
#include <PiDxe.h>
-#include <Protocol/BlockIo.h>
-#include <Protocol/SimpleFileSystem.h>
-#include <Protocol/FirmwareVolume2.h>
-#include <Protocol/LoadFile.h>
-#include <Protocol/FirmwareVolumeBlock.h>
-#include <Protocol/PxeBaseCode.h>
-#include <Protocol/LoadedImage.h>
+#include <Protocol/BlockIo.h>
+#include <Protocol/SimpleFileSystem.h>
+#include <Protocol/FirmwareVolume2.h>
+#include <Protocol/LoadFile.h>
+#include <Protocol/FirmwareVolumeBlock.h>
+#include <Protocol/PxeBaseCode.h>
+#include <Protocol/LoadedImage.h>
#include <Protocol/EblAddCommand.h>
#include <Protocol/PciIo.h>
#include <Protocol/DevicePath.h>
@@ -38,7 +38,7 @@ #include <Library/DevicePathLib.h>
#include <Library/PrintLib.h>
#include <Library/BaseMemoryLib.h>
-#include <Library/UefiLib.h>
+#include <Library/UefiLib.h>
#include <Library/UefiBootServicesTableLib.h>
#include <Library/UefiRuntimeServicesTableLib.h>
#include <Library/DebugLib.h>
@@ -190,7 +190,7 @@ OutputData ( IN UINTN Width,
IN UINTN Offset
);
-
+
UINTN
WidthFromCommandName (
IN CHAR8 *Argv,
diff --git a/EmbeddedPkg/Ebl/Ebl.inf b/EmbeddedPkg/Ebl/Ebl.inf index 7c302337a5..91a82d9f8c 100644 --- a/EmbeddedPkg/Ebl/Ebl.inf +++ b/EmbeddedPkg/Ebl/Ebl.inf @@ -44,43 +44,43 @@ Ebl.h
Network.c
Variable.c
-
+
[Packages]
MdePkg/MdePkg.dec
MdeModulePkg/MdeModulePkg.dec
IntelFrameworkPkg/IntelFrameworkPkg.dec
IntelFrameworkModulePkg/IntelFrameworkModulePkg.dec
EmbeddedPkg/EmbeddedPkg.dec
-
+
[LibraryClasses]
- DebugLib
- UefiLib
- UefiApplicationEntryPoint
- UefiBootServicesTableLib
- UefiRuntimeServicesTableLib
- BaseMemoryLib
- MemoryAllocationLib
- DevicePathLib
- IoLib
- PrintLib
- PcdLib
- EfiFileLib
+ DebugLib
+ UefiLib
+ UefiApplicationEntryPoint
+ UefiBootServicesTableLib
+ UefiRuntimeServicesTableLib
+ BaseMemoryLib
+ MemoryAllocationLib
+ DevicePathLib
+ IoLib
+ PrintLib
+ PcdLib
+ EfiFileLib
HobLib
- BaseLib
+ BaseLib
EblCmdLib
EblNetworkLib
[LibraryClasses.ARM]
SemihostLib
-
-[Protocols.common]
- gEfiFirmwareVolume2ProtocolGuid
- gEfiFirmwareVolumeBlockProtocolGuid
- gEfiBlockIoProtocolGuid
+
+[Protocols.common]
+ gEfiFirmwareVolume2ProtocolGuid
+ gEfiFirmwareVolumeBlockProtocolGuid
+ gEfiBlockIoProtocolGuid
gEfiSimpleFileSystemProtocolGuid
- gEfiLoadFileProtocolGuid
- gEfiLoadedImageProtocolGuid
- gEfiPxeBaseCodeProtocolGuid
+ gEfiLoadFileProtocolGuid
+ gEfiLoadedImageProtocolGuid
+ gEfiPxeBaseCodeProtocolGuid
gEfiEblAddCommandProtocolGuid
gEfiDiskIoProtocolGuid
gEfiPciIoProtocolGuid
diff --git a/EmbeddedPkg/Ebl/EfiDevice.c b/EmbeddedPkg/Ebl/EfiDevice.c index c623bd8b7e..7d2060936d 100644 --- a/EmbeddedPkg/Ebl/EfiDevice.c +++ b/EmbeddedPkg/Ebl/EfiDevice.c @@ -157,23 +157,23 @@ EblPrintLoadFileInfo ( if (File->DevicePath != NULL) {
// Try to print out the MAC address
- for (DevicePathNode = File->DevicePath;
- !IsDevicePathEnd (DevicePathNode);
+ for (DevicePathNode = File->DevicePath;
+ !IsDevicePathEnd (DevicePathNode);
DevicePathNode = NextDevicePathNode (DevicePathNode)) {
-
+
if ((DevicePathType (DevicePathNode) == MESSAGING_DEVICE_PATH) && (DevicePathSubType (DevicePathNode) == MSG_MAC_ADDR_DP)) {
MacAddr = (MAC_ADDR_DEVICE_PATH *)DevicePathNode;
-
+
HwAddressSize = sizeof (EFI_MAC_ADDRESS);
if (MacAddr->IfType == 0x01 || MacAddr->IfType == 0x00) {
HwAddressSize = 6;
}
-
+
AsciiPrint ("MAC ");
for (Index = 0; Index < HwAddressSize; Index++) {
AsciiPrint ("%02x", MacAddr->MacAddress.Addr[Index] & 0xff);
}
- }
+ }
}
}
@@ -185,7 +185,7 @@ EblPrintLoadFileInfo ( /**
- Dump information about devices in the system.
+ Dump information about devices in the system.
fv: PI Firmware Volume
fs: EFI Simple File System
@@ -195,7 +195,7 @@ EblPrintLoadFileInfo ( Argv[0] - "device"
@param Argc Number of command arguments in Argv
- @param Argv Array of strings that represent the parsed command line.
+ @param Argv Array of strings that represent the parsed command line.
Argv[0] is the command name
@return EFI_SUCCESS
@@ -249,7 +249,7 @@ EblDeviceCmd ( }
}
}
-
+
Max = EfiGetDeviceCounts (EfiOpenLoadFile);
if (Max != 0) {
AsciiPrint ("LoadFile Devices: (usually network)\n");
@@ -266,7 +266,7 @@ EblDeviceCmd ( /**
- Start an EFI image (PE32+ with EFI defined entry point).
+ Start an EFI image (PE32+ with EFI defined entry point).
Argv[0] - "start"
Argv[1] - device name and path
@@ -278,7 +278,7 @@ EblDeviceCmd ( start LoadFile0: ; load an FV via a PXE boot
@param Argc Number of command arguments in Argv
- @param Argv Array of strings that represent the parsed command line.
+ @param Argv Array of strings that represent the parsed command line.
Argv[0] is the command name
@return EFI_SUCCESS
@@ -308,7 +308,7 @@ EblStartCmd ( File = EfiOpen (Argv[1], EFI_FILE_MODE_READ, 0);
if (File == NULL) {
- return EFI_INVALID_PARAMETER;
+ return EFI_INVALID_PARAMETER;
}
DevicePath = File->DevicePath;
@@ -328,7 +328,7 @@ EblStartCmd ( FreePool (Buffer);
}
-
+
EfiClose (File);
if (!EFI_ERROR (Status)) {
@@ -337,7 +337,7 @@ EblStartCmd ( // We don't pass Argv[0] to the EFI Application (it's name) just the args
Status = gBS->HandleProtocol (ImageHandle, &gEfiLoadedImageProtocolGuid, (VOID **)&ImageInfo);
ASSERT_EFI_ERROR (Status);
-
+
ImageInfo->LoadOptionsSize = (UINT32)AsciiStrSize (Argv[2]);
ImageInfo->LoadOptions = AllocatePool (ImageInfo->LoadOptionsSize);
AsciiStrCpy (ImageInfo->LoadOptions, Argv[2]);
@@ -354,7 +354,7 @@ EblStartCmd ( /**
Load a Firmware Volume (FV) into memory from a device. This causes drivers in
the FV to be dispatched if the dependencies of the drivers are met.
-
+
Argv[0] - "loadfv"
Argv[1] - device name and path
@@ -363,7 +363,7 @@ EblStartCmd ( loadfv LoadFile0: ; load an FV via a PXE boot
@param Argc Number of command arguments in Argv
- @param Argv Array of strings that represent the parsed command line.
+ @param Argv Array of strings that represent the parsed command line.
Argv[0] is the command name
@return EFI_SUCCESS
@@ -388,7 +388,7 @@ EblLoadFvCmd ( File = EfiOpen (Argv[1], EFI_FILE_MODE_READ, 0);
if (File == NULL) {
- return EFI_INVALID_PARAMETER;
+ return EFI_INVALID_PARAMETER;
}
if (File->Type == EfiOpenMemoryBuffer) {
@@ -401,25 +401,25 @@ EblLoadFvCmd ( if (EFI_ERROR (Status)) {
return Status;
}
-
+
Status = gDS->ProcessFirmwareVolume (FvStart, FvSize, &FvHandle);
if (EFI_ERROR (Status)) {
FreePool (FvStart);
- }
+ }
}
return Status;
}
/**
- Perform an EFI connect to connect devices that follow the EFI driver model.
+ Perform an EFI connect to connect devices that follow the EFI driver model.
If it is a PI system also call the dispatcher in case a new FV was made
available by one of the connect EFI drivers (this is not a common case).
-
+
Argv[0] - "connect"
@param Argc Number of command arguments in Argv
- @param Argv Array of strings that represent the parsed command line.
+ @param Argv Array of strings that represent the parsed command line.
Argv[0] is the command name
@return EFI_SUCCESS
@@ -451,11 +451,11 @@ EblConnectCmd ( if (EFI_ERROR (Status)) {
return Status;
}
-
+
for (Index = 0; Index < HandleCount; Index++) {
gBS->DisconnectController (HandleBuffer[Index], NULL, NULL);
}
-
+
//
// Given we disconnect our console we should go and do a connect now
//
@@ -537,11 +537,11 @@ CHAR8 *gMemMapType[] = { /**
Dump out the EFI memory map
-
+
Argv[0] - "memmap"
@param Argc Number of command arguments in Argv
- @param Argv Array of strings that represent the parsed command line.
+ @param Argv Array of strings that represent the parsed command line.
Argv[0] is the command name
@return EFI_SUCCESS
@@ -569,7 +569,7 @@ EblMemMapCmd ( ZeroMem (PageCount, sizeof (PageCount));
AsciiPrint ("EFI Memory Map\n");
-
+
// First call is to figure out how big the buffer needs to be
MemMapSize = 0;
MemMap = NULL;
@@ -593,7 +593,7 @@ EblMemMapCmd ( MemMap = NEXT_MEMORY_DESCRIPTOR (MemMap, DescriptorSize);
}
}
-
+
for (Index = 0, TotalMemory = 0; Index < EfiMaxMemoryType; Index++) {
if (PageCount[Index] != 0) {
AsciiPrint ("\n %a %,7ld Pages (%,14ld)", gMemMapType[Index], PageCount[Index], LShiftU64 (PageCount[Index], 12));
@@ -630,27 +630,27 @@ EblMemMapCmd ( /**
Load a file into memory and optionally jump to it. A load address can be
specified or automatically allocated. A quoted command line can optionally
- be passed into the image.
+ be passed into the image.
Argv[0] - "go"
Argv[1] - Device Name:path for the file to load
Argv[2] - Address to load to or '*' if the load address will be allocated
Argv[3] - Optional Entry point to the image. Image will be called if present
- Argv[4] - "" string that will be passed as Argc & Argv to EntryPoint. Needs
+ Argv[4] - "" string that will be passed as Argc & Argv to EntryPoint. Needs
to include the command name
- go fv1:\EblCmdX 0x10000 0x10010 "EblCmdX Arg2 Arg3 Arg4"; - load EblCmdX
- from FV1 to location 0x10000 and call the entry point at 0x10010 passing
+ go fv1:\EblCmdX 0x10000 0x10010 "EblCmdX Arg2 Arg3 Arg4"; - load EblCmdX
+ from FV1 to location 0x10000 and call the entry point at 0x10010 passing
in "EblCmdX Arg2 Arg3 Arg4" as the arguments.
- go fv0:\EblCmdX * 0x10 "EblCmdX Arg2 Arg3 Arg4"; - load EblCmdX from FS0
+ go fv0:\EblCmdX * 0x10 "EblCmdX Arg2 Arg3 Arg4"; - load EblCmdX from FS0
to location allocated by this command and call the entry point at offset 0x10
passing in "EblCmdX Arg2 Arg3 Arg4" as the arguments.
go fv1:\EblCmdX 0x10000; Load EblCmdX to address 0x10000 and return
@param Argc Number of command arguments in Argv
- @param Argv Array of strings that represent the parsed command line.
+ @param Argv Array of strings that represent the parsed command line.
Argv[0] is the command name
@return EFI_SUCCESS
@@ -669,7 +669,7 @@ EblGoCmd ( EBL_COMMMAND EntryPoint;
UINTN EntryPointArgc;
CHAR8 *EntryPointArgv[MAX_ARGS];
-
+
if (Argc <= 2) {
// device name and laod address are required
@@ -686,7 +686,7 @@ EblGoCmd ( if (Argv[2][0] == '*') {
// * Means allocate the buffer
Status = EfiReadAllocatePool (File, &Address, &Size);
-
+
// EntryPoint is relative to the start of the image
EntryPoint = (EBL_COMMMAND)((UINTN)EntryPoint + (UINTN)Address);
@@ -709,7 +709,7 @@ EblGoCmd ( EntryPointArgc = 1;
EntryPointArgv[0] = File->FileName;
}
-
+
Status = EntryPoint (EntryPointArgc, EntryPointArgv);
}
}
@@ -741,7 +741,7 @@ EblFileCopyCmd ( if (Argc < 3) {
return EFI_INVALID_PARAMETER;
}
-
+
DestFileName = Argv[2];
FileNameLen = AsciiStrLen (DestFileName);
@@ -788,7 +788,7 @@ EblFileCopyCmd ( AsciiPrint("Source file open error.\n");
return EFI_NOT_FOUND;
}
-
+
Destination = EfiOpen(DestFileName, EFI_FILE_MODE_READ | EFI_FILE_MODE_WRITE | EFI_FILE_MODE_CREATE, 0);
if (Destination == NULL) {
AsciiPrint("Destination file open error.\n");
@@ -799,12 +799,12 @@ EblFileCopyCmd ( if (Buffer == NULL) {
goto Exit;
}
-
+
Size = EfiTell(Source, NULL);
for (Offset = 0; Offset + FILE_COPY_CHUNK <= Size; Offset += Chunk) {
Chunk = FILE_COPY_CHUNK;
-
+
Status = EfiRead(Source, Buffer, &Chunk);
if (EFI_ERROR(Status)) {
AsciiPrint("Read file error %r\n", Status);
@@ -815,13 +815,13 @@ EblFileCopyCmd ( if (EFI_ERROR(Status)) {
AsciiPrint("Write file error %r\n", Status);
goto Exit;
- }
+ }
}
-
+
// Any left over?
if (Offset < Size) {
Chunk = Size - Offset;
-
+
Status = EfiRead(Source, Buffer, &Chunk);
if (EFI_ERROR(Status)) {
AsciiPrint("Read file error %r\n", Status);
@@ -832,7 +832,7 @@ EblFileCopyCmd ( if (EFI_ERROR(Status)) {
AsciiPrint("Write file error %r\n", Status);
goto Exit;
- }
+ }
}
@@ -854,11 +854,11 @@ Exit: FreePool (DestFileName);
}
}
-
+
if (Buffer != NULL) {
FreePool(Buffer);
}
-
+
return Status;
}
@@ -877,17 +877,17 @@ EblFileDiffCmd ( UINTN Size2;
UINTN Offset;
UINTN Chunk = FILE_COPY_CHUNK;
-
+
if (Argc != 3) {
return EFI_INVALID_PARAMETER;
}
-
+
File1 = EfiOpen(Argv[1], EFI_FILE_MODE_READ, 0);
if (File1 == NULL) {
AsciiPrint("File 1 open error.\n");
return EFI_NOT_FOUND;
}
-
+
File2 = EfiOpen(Argv[2], EFI_FILE_MODE_READ, 0);
if (File2 == NULL) {
AsciiPrint("File 2 open error.\n");
@@ -906,15 +906,15 @@ EblFileDiffCmd ( if (Buffer1 == NULL) {
goto Exit;
}
-
+
Buffer2 = AllocatePool(FILE_COPY_CHUNK);
if (Buffer2 == NULL) {
goto Exit;
- }
+ }
for (Offset = 0; Offset + FILE_COPY_CHUNK <= Size1; Offset += Chunk) {
Chunk = FILE_COPY_CHUNK;
-
+
Status = EfiRead(File1, Buffer1, &Chunk);
if (EFI_ERROR(Status)) {
AsciiPrint("File 1 read error\n");
@@ -926,17 +926,17 @@ EblFileDiffCmd ( AsciiPrint("File 2 read error\n");
goto Exit;
}
-
+
if (CompareMem(Buffer1, Buffer2, Chunk) != 0) {
AsciiPrint("Files differ.\n");
goto Exit;
};
}
-
+
// Any left over?
if (Offset < Size1) {
Chunk = Size1 - Offset;
-
+
Status = EfiRead(File1, Buffer1, &Chunk);
if (EFI_ERROR(Status)) {
AsciiPrint("File 1 read error\n");
@@ -947,9 +947,9 @@ EblFileDiffCmd ( if (EFI_ERROR(Status)) {
AsciiPrint("File 2 read error\n");
goto Exit;
- }
+ }
}
-
+
if (CompareMem(Buffer1, Buffer2, Chunk) != 0) {
AsciiPrint("Files differ.\n");
} else {
@@ -963,22 +963,22 @@ Exit: AsciiPrint("File 1 close error %r\n", Status);
}
}
-
+
if (File2 != NULL) {
Status = EfiClose(File2);
if (EFI_ERROR(Status)) {
AsciiPrint("File 2 close error %r\n", Status);
}
}
-
+
if (Buffer1 != NULL) {
FreePool(Buffer1);
}
-
+
if (Buffer2 != NULL) {
FreePool(Buffer2);
}
-
+
return Status;
}
@@ -998,25 +998,25 @@ GLOBAL_REMOVE_IF_UNREFERENCED const EBL_COMMAND_TABLE mCmdDeviceTemplate[] = },
{
"go",
- " dev:path loadaddress entrypoint args; load to given address and jump in",
+ " dev:path loadaddress entrypoint args; load to given address and jump in",
NULL,
EblGoCmd
},
{
"loadfv",
- " devname; Load PI FV from device",
+ " devname; Load PI FV from device",
NULL,
EblLoadFvCmd
},
{
"start",
- " path; EFI Boot Device:filepath. fs1:\\EFI\\BOOT.EFI",
+ " path; EFI Boot Device:filepath. fs1:\\EFI\\BOOT.EFI",
NULL,
EblStartCmd
},
{
"memmap",
- "; dump EFI memory map",
+ "; dump EFI memory map",
NULL,
EblMemMapCmd
},
diff --git a/EmbeddedPkg/Ebl/Hob.c b/EmbeddedPkg/Ebl/Hob.c index b8c1c52752..8b7a52e139 100644 --- a/EmbeddedPkg/Ebl/Hob.c +++ b/EmbeddedPkg/Ebl/Hob.c @@ -87,7 +87,7 @@ **/
#include "Ebl.h"
-// BugBug: Autogen does not allow this to be included currently
+// BugBug: Autogen does not allow this to be included currently
//#include <EdkModulePkg/Include/EdkDxe.h>
GLOBAL_REMOVE_IF_UNREFERENCED char *mHobResourceType[] = {
@@ -109,7 +109,7 @@ GLOBAL_REMOVE_IF_UNREFERENCED char *mHobResourceType[] = { Argv[0] - "hob"
@param Argc Number of command arguments in Argv
- @param Argv Array of strings that represent the parsed command line.
+ @param Argv Array of strings that represent the parsed command line.
Argv[0] is the command name
@return EFI_SUCCESS
@@ -129,9 +129,9 @@ EblHobCmd ( CurrentRow = 0;
for (Hob.Raw = GetHobList (); !END_OF_HOB_LIST(Hob); Hob.Raw = GET_NEXT_HOB(Hob)) {
if (Hob.Header->HobType == EFI_HOB_TYPE_HANDOFF) {
- AsciiPrint ("PHIT HOB Ver %x Boot Mode %02x Top %lx Bottom %lx\n",
- Hob.HandoffInformationTable->Version,
- Hob.HandoffInformationTable->BootMode,
+ AsciiPrint ("PHIT HOB Ver %x Boot Mode %02x Top %lx Bottom %lx\n",
+ Hob.HandoffInformationTable->Version,
+ Hob.HandoffInformationTable->BootMode,
Hob.HandoffInformationTable->EfiMemoryTop,
Hob.HandoffInformationTable->EfiMemoryBottom
);
@@ -140,7 +140,7 @@ EblHobCmd ( return EFI_SUCCESS;
}
- AsciiPrint (" Free Top %lx Free Bottom %lx End Of HOB %lx\n",
+ AsciiPrint (" Free Top %lx Free Bottom %lx End Of HOB %lx\n",
Hob.HandoffInformationTable->EfiFreeMemoryTop,
Hob.HandoffInformationTable->EfiFreeMemoryBottom,
Hob.HandoffInformationTable->EfiEndOfHobList
@@ -149,9 +149,9 @@ EblHobCmd ( } else if (Hob.Header->HobType == EFI_HOB_TYPE_MEMORY_ALLOCATION) {
// mod(%) on array index is just to prevent buffer overrun
AsciiPrint ("Mem Alloc HOB %a %g %08lx:%lx\n",
- (Hob.MemoryAllocation->AllocDescriptor.MemoryType < EfiMaxMemoryType) ? gMemMapType[Hob.MemoryAllocation->AllocDescriptor.MemoryType] : "ILLEGAL TYPE",
- &Hob.MemoryAllocation->AllocDescriptor.Name,
- Hob.MemoryAllocation->AllocDescriptor.MemoryBaseAddress,
+ (Hob.MemoryAllocation->AllocDescriptor.MemoryType < EfiMaxMemoryType) ? gMemMapType[Hob.MemoryAllocation->AllocDescriptor.MemoryType] : "ILLEGAL TYPE",
+ &Hob.MemoryAllocation->AllocDescriptor.Name,
+ Hob.MemoryAllocation->AllocDescriptor.MemoryBaseAddress,
Hob.MemoryAllocation->AllocDescriptor.MemoryLength
);
if (CompareGuid (&gEfiHobMemoryAllocModuleGuid, &Hob.MemoryAllocation->AllocDescriptor.Name)) {
@@ -163,9 +163,9 @@ EblHobCmd ( } else if (Hob.Header->HobType == EFI_HOB_TYPE_RESOURCE_DESCRIPTOR) {
AsciiPrint ("Resource HOB %a %g %08lx:%lx\n Attributes: %08x\n",
(Hob.ResourceDescriptor->ResourceType < EFI_RESOURCE_MAX_MEMORY_TYPE) ? mHobResourceType[Hob.ResourceDescriptor->ResourceType] : mHobResourceType[EFI_RESOURCE_MAX_MEMORY_TYPE],
- &Hob.ResourceDescriptor->Owner,
- Hob.ResourceDescriptor->PhysicalStart,
- Hob.ResourceDescriptor->ResourceLength,
+ &Hob.ResourceDescriptor->Owner,
+ Hob.ResourceDescriptor->PhysicalStart,
+ Hob.ResourceDescriptor->ResourceLength,
Hob.ResourceDescriptor->ResourceAttribute
);
if (EblAnyKeyToContinueQtoQuit (&CurrentRow, FALSE)) {
@@ -179,16 +179,16 @@ EblHobCmd ( if (EblAnyKeyToContinueQtoQuit (&CurrentRow, FALSE)) {
return EFI_SUCCESS;
}
- AsciiPrint (" %a 0x%08x\n",
- (EfiMemoryTypeInformation->Type < EfiMaxMemoryType) ? gMemMapType[EfiMemoryTypeInformation->Type] : "END ",
+ AsciiPrint (" %a 0x%08x\n",
+ (EfiMemoryTypeInformation->Type < EfiMaxMemoryType) ? gMemMapType[EfiMemoryTypeInformation->Type] : "END ",
EfiMemoryTypeInformation->NumberOfPages
);
}
}
} else if (Hob.Header->HobType == EFI_HOB_TYPE_FV) {
- AsciiPrint ("FV HOB %08lx:%08lx\n", Hob.FirmwareVolume->BaseAddress, Hob.FirmwareVolume->Length);
+ AsciiPrint ("FV HOB %08lx:%08lx\n", Hob.FirmwareVolume->BaseAddress, Hob.FirmwareVolume->Length);
} else if (Hob.Header->HobType == EFI_HOB_TYPE_CPU) {
- AsciiPrint ("CPU HOB: Mem %x IO %x\n", Hob.Cpu->SizeOfMemorySpace, Hob.Cpu->SizeOfIoSpace);
+ AsciiPrint ("CPU HOB: Mem %x IO %x\n", Hob.Cpu->SizeOfMemorySpace, Hob.Cpu->SizeOfIoSpace);
} else if (Hob.Header->HobType == EFI_HOB_TYPE_MEMORY_POOL) {
AsciiPrint ("Mem Pool HOB:\n");
/* Not in PI
@@ -199,7 +199,7 @@ EblHobCmd ( if (EblAnyKeyToContinueQtoQuit (&CurrentRow, FALSE)) {
break;
- }
+ }
}
return EFI_SUCCESS;
diff --git a/EmbeddedPkg/Ebl/HwDebug.c b/EmbeddedPkg/Ebl/HwDebug.c index c87d1c4d1a..226b24500a 100644 --- a/EmbeddedPkg/Ebl/HwDebug.c +++ b/EmbeddedPkg/Ebl/HwDebug.c @@ -14,7 +14,7 @@ Module Name: HwDebug.c
- Commands useful for debugging hardware.
+ Commands useful for debugging hardware.
**/
@@ -33,7 +33,7 @@ md 0x123445678 ; Dump 0x20 1 byte quantities starting at 0x123445678
@param Argc Number of command arguments in Argv
- @param Argv Array of strings that represent the parsed command line.
+ @param Argv Array of strings that represent the parsed command line.
Argv[0] is the command name
@return EFI_SUCCESS
@@ -63,7 +63,7 @@ EblMdCmd ( OutputData (Address, Length, Width, (UINTN)Address);
Address += Length;
-
+
return EFI_SUCCESS;
}
@@ -82,7 +82,7 @@ EblMdCmd ( mf 0x123445678 ; Start at 0x123445678 and write 00 (4 byte) to the next 1 byte
@param Argc Number of command arguments in Argv
- @param Argv Array of strings that represent the parsed command line.
+ @param Argv Array of strings that represent the parsed command line.
Argv[0] is the command name
@return EFI_SUCCESS
@@ -119,7 +119,7 @@ EblMfillCmd ( MmioWrite8 (Address, (UINT8)Data);
}
}
-
+
return EFI_SUCCESS;
}
@@ -162,7 +162,7 @@ CHAR8 *gPciSerialClassCodes[] = { Argv[3] - func
@param Argc Number of command arguments in Argv
- @param Argv Array of strings that represent the parsed command line.
+ @param Argv Array of strings that represent the parsed command line.
Argv[0] is the command name
@return EFI_SUCCESS
@@ -195,13 +195,13 @@ EblPciCmd ( CHAR8 *Str;
UINTN ThisBus;
-
+
BusArg = (Argc > 1) ? AsciiStrDecimalToUintn (Argv[1]) : 0;
DevArg = (Argc > 2) ? AsciiStrDecimalToUintn (Argv[2]) : 0;
FuncArg = (Argc > 3) ? AsciiStrDecimalToUintn (Argv[3]) : 0;
Header = &PciHeader;
-
+
Status = gBS->LocateHandleBuffer (ByProtocol, &gEfiPciIoProtocolGuid, NULL, &HandleCount, &HandleBuffer);
if (EFI_ERROR (Status)) {
AsciiPrint ("No PCI devices found in the system\n");
@@ -224,7 +224,7 @@ EblPciCmd ( Status = Pci->Pci.Read (Pci, EfiPciIoWidthUint32, 0, sizeof (PciHeader)/sizeof (UINT32), &PciHeader);
if (!EFI_ERROR (Status)) {
Hdr = &PciHeader.Bridge.Hdr;
-
+
if (Hdr->ClassCode[2] < sizeof (gPciDevClass)/sizeof (VOID *)) {
Str = gPciDevClass[Hdr->ClassCode[2]];
if (Hdr->ClassCode[2] == PCI_CLASS_SERIAL) {
@@ -239,7 +239,7 @@ EblPciCmd ( AsciiPrint (" 0x%04x 0x%04x %a 0x%02x", Hdr->VendorId, Hdr->DeviceId, Str, Hdr->ClassCode[1]);
}
if (Seg != 0) {
- // Only print Segment if it is non zero. If you only have one PCI segment it is
+ // Only print Segment if it is non zero. If you only have one PCI segment it is
// redundent to print it out
AsciiPrint (" Seg:%d", Seg);
}
@@ -254,20 +254,20 @@ EblPciCmd ( if (!EFI_ERROR (Status)) {
Pci->GetLocation (Pci, &Seg, &Bus, &Dev, &Func);
if ((Bus == BusArg) && (Dev == DevArg) && (Func == FuncArg)) {
- // Only print Segment if it is non zero. If you only have one PCI segment it is
+ // Only print Segment if it is non zero. If you only have one PCI segment it is
// redundant to print it out
if (Seg != 0) {
AsciiPrint ("Seg:%d ", Seg);
}
AsciiPrint ("Bus:%d Dev:%d Func:%d ", Bus, Dev, Func);
-
+
Status = Pci->Pci.Read (Pci, EfiPciIoWidthUint32, 0, sizeof (PciHeader)/sizeof (UINT32), Header);
if (!EFI_ERROR (Status)) {
Hdr = &PciHeader.Bridge.Hdr;
if (IS_PCI_BRIDGE (&PciHeader.Bridge)) {
Bridge = &PciHeader.Bridge.Bridge;
AsciiPrint (
- "PCI Bridge. Bus Primary %d Secondary %d Subordinate %d\n",
+ "PCI Bridge. Bus Primary %d Secondary %d Subordinate %d\n",
Bridge->PrimaryBus, Bridge->SecondaryBus, Bridge->SubordinateBus
);
AsciiPrint (" Bar 0: 0x%08x Bar 1: 0x%08x\n", Bridge->Bar[0], Bridge->Bar[1]);
@@ -283,14 +283,14 @@ EblPciCmd ( }
}
}
-
+
AsciiPrint ("\n");
break;
}
}
}
}
-
+
FreePool (HandleBuffer);
return EFI_SUCCESS;
}
diff --git a/EmbeddedPkg/Ebl/HwIoDebug.c b/EmbeddedPkg/Ebl/HwIoDebug.c index 13f4d643f7..c9144fe43e 100644 --- a/EmbeddedPkg/Ebl/HwIoDebug.c +++ b/EmbeddedPkg/Ebl/HwIoDebug.c @@ -31,7 +31,7 @@ ior 0x3f8 ;Do a 8-bit IO Read from 0x3f8
@param Argc Number of command arguments in Argv
- @param Argv Array of strings that represent the parsed command line.
+ @param Argv Array of strings that represent the parsed command line.
Argv[0] is the command name
@return EFI_SUCCESS
@@ -81,7 +81,7 @@ EblIoReadCmd ( iow 0x3f8 af ;Do an 8-bit IO write of af to 0x3f8
@param Argc Number of command arguments in Argv
- @param Argv Array of strings that represent the parsed command line.
+ @param Argv Array of strings that represent the parsed command line.
Argv[0] is the command name
@return EFI_SUCCESS
@@ -104,7 +104,7 @@ EblIoWriteCmd ( Port = AsciiStrHexToUintn (Argv[1]);
Data = AsciiStrHexToUintn (Argv[2]);
Width = WidthFromCommandName (Argv[0], 1);
-
+
if (Width == 1) {
IoWrite8 (Port, (UINT8)Data);
} else if (Width == 2) {
diff --git a/EmbeddedPkg/Ebl/Main.c b/EmbeddedPkg/Ebl/Main.c index f1665627aa..dc17d26c71 100644 --- a/EmbeddedPkg/Ebl/Main.c +++ b/EmbeddedPkg/Ebl/Main.c @@ -31,13 +31,13 @@ UINTN gScreenRows; // Global to turn on/off breaking commands with prompts before they scroll the screen
BOOLEAN gPageBreak = TRUE;
-VOID
+VOID
RingBufferIncrement (
IN INTN *Value
)
{
*Value = *Value + 1;
-
+
if (*Value >= MAX_CMD_HISTORY) {
*Value = 0;
}
@@ -49,14 +49,14 @@ RingBufferDecrement ( )
{
*Value = *Value - 1;
-
+
if (*Value < 0) {
*Value = MAX_CMD_HISTORY - 1;
}
}
/**
- Save this command in the circular history buffer. Older commands are
+ Save this command in the circular history buffer. Older commands are
overwritten with newer commands.
@param Cmd Command line to archive the history of.
@@ -71,7 +71,7 @@ SetCmdHistory ( {
// Don't bother adding empty commands to the list
if (AsciiStrLen(Cmd) != 0) {
-
+
// First entry
if (mCmdHistoryStart == -1) {
mCmdHistoryStart = 0;
@@ -79,19 +79,19 @@ SetCmdHistory ( } else {
// Record the new command at the next index
RingBufferIncrement(&mCmdHistoryStart);
-
+
// If the next index runs into the end index, shuffle end back by one
if (mCmdHistoryStart == mCmdHistoryEnd) {
RingBufferIncrement(&mCmdHistoryEnd);
}
}
-
+
// Copy the new command line into the ring buffer
AsciiStrnCpy(&mCmdHistory[mCmdHistoryStart][0], Cmd, MAX_CMD_LINE);
}
-
+
// Reset the command history for the next up arrow press
- mCmdHistoryCurrent = mCmdHistoryStart;
+ mCmdHistoryCurrent = mCmdHistoryStart;
}
@@ -110,41 +110,41 @@ GetCmdHistory ( )
{
CHAR8 *HistoricalCommand = NULL;
-
+
// No history yet?
if (mCmdHistoryCurrent == -1) {
HistoricalCommand = mCmdBlank;
goto Exit;
}
-
+
if (Direction == SCAN_UP) {
HistoricalCommand = &mCmdHistory[mCmdHistoryCurrent][0];
-
+
// if we just echoed the last command, hang out there, don't wrap around
if (mCmdHistoryCurrent == mCmdHistoryEnd) {
goto Exit;
}
-
+
// otherwise, back up by one
RingBufferDecrement(&mCmdHistoryCurrent);
-
+
} else if (Direction == SCAN_DOWN) {
-
+
// if we last echoed the start command, put a blank prompt out
if (mCmdHistoryCurrent == mCmdHistoryStart) {
HistoricalCommand = mCmdBlank;
goto Exit;
}
-
+
// otherwise increment the current pointer and return that command
RingBufferIncrement(&mCmdHistoryCurrent);
RingBufferIncrement(&mCmdHistoryCurrent);
-
+
HistoricalCommand = &mCmdHistory[mCmdHistoryCurrent][0];
RingBufferDecrement(&mCmdHistoryCurrent);
}
-Exit:
+Exit:
return HistoricalCommand;
}
@@ -202,7 +202,7 @@ ParseArguments ( } else if (*Char != ' ') {
Argv[Arg++] = Char;
LookingForArg = FALSE;
- }
+ }
} else {
// Looking for the terminator of an Argv[] entry
if (!InQuote && (*Char == ' ')) {
@@ -214,7 +214,7 @@ ParseArguments ( *Char = '\0';
InQuote = FALSE;
}
- }
+ }
}
*Argc = Arg;
@@ -236,7 +236,7 @@ ParseArguments ( @param Key EFI Key information returned
@param TimeoutInSec Number of seconds to wait to timeout
- @param CallBack Callback called every second during the timeout wait
+ @param CallBack Callback called every second during the timeout wait
@return EFI_SUCCESS Key was returned
@return EFI_TIMEOUT If the TimoutInSec expired
@@ -275,15 +275,15 @@ EblGetCharKey ( if (WaitCount == 2) {
gBS->CloseEvent (WaitList[1]);
}
- return EFI_SUCCESS;
+ return EFI_SUCCESS;
}
break;
case 1:
- // Periodic 1 sec timer signaled
+ // Periodic 1 sec timer signaled
TimeoutInSec--;
if (CallBack != NULL) {
- // Call the users callback function if registered
+ // Call the users callback function if registered
CallBack (TimeoutInSec);
}
if (TimeoutInSec == 0) {
@@ -294,7 +294,7 @@ EblGetCharKey ( default:
ASSERT (FALSE);
}
- }
+ }
}
@@ -305,7 +305,7 @@ EblGetCharKey ( If the use hits Q to quit return TRUE else for any other key return FALSE.
PrefixNewline is used to figure out if a newline is needed before the prompt
string. This depends on the last print done before calling this function.
- CurrentRow is updated by one on a call or set back to zero if a prompt is
+ CurrentRow is updated by one on a call or set back to zero if a prompt is
needed.
@param CurrentRow Used to figure out if its the end of the page and updated
@@ -349,7 +349,7 @@ EblAnyKeyToContinueQtoQuit ( /**
- Set the text color of the EFI Console. If a zero is passed in reset to
+ Set the text color of the EFI Console. If a zero is passed in reset to
default text/background color.
@param Attribute For text and background color
@@ -372,12 +372,12 @@ EblSetTextColor ( /**
Collect the keyboard input for a cmd line. Carriage Return, New Line, or ESC
terminates the command line. You can edit the command line via left arrow,
- delete and backspace and they all back up and erase the command line.
+ delete and backspace and they all back up and erase the command line.
No edit of command line is possible without deletion at this time!
- The up arrow and down arrow fill Cmd with information from the history
+ The up arrow and down arrow fill Cmd with information from the history
buffer.
- @param Cmd Command line to return
+ @param Cmd Command line to return
@param CmdMaxSize Maximum size of Cmd
@return The Status of EblGetCharKey()
@@ -462,9 +462,9 @@ EblPrintStartupBanner ( /**
Send null requests to all removable media block IO devices so the a media add/remove/change
- can be detected in real before we execute a command.
+ can be detected in real before we execute a command.
- This is mainly due to the fact that the FAT driver does not do this today so you can get stale
+ This is mainly due to the fact that the FAT driver does not do this today so you can get stale
dir commands after an SD Card has been removed.
**/
VOID
@@ -521,7 +521,7 @@ EblPrompt ( commands returns an error.
@param CmdLine Command Line to process.
- @param MaxCmdLineSize MaxSize of the Command line
+ @param MaxCmdLineSize MaxSize of the Command line
@return EFI status of the Command
@@ -559,17 +559,17 @@ ProcessCmdLine ( }
} else {
AsciiPrint ("The command '%a' is not supported.\n", Argv[0]);
- }
- }
+ }
+ }
}
return Status;
}
-
+
/**
- Embedded Boot Loader (EBL) - A simple EFI command line application for embedded
+ Embedded Boot Loader (EBL) - A simple EFI command line application for embedded
devices. PcdEmbeddedAutomaticBootCommand is a complied in command line that
gets executed automatically. The ; separator allows multiple commands
for each command line.
@@ -585,7 +585,7 @@ EFIAPI EdkBootLoaderEntry (
IN EFI_HANDLE ImageHandle,
IN EFI_SYSTEM_TABLE *SystemTable
- )
+ )
{
EFI_STATUS Status;
CHAR8 CmdLine[MAX_CMD_LINE];
@@ -605,7 +605,7 @@ EdkBootLoaderEntry ( EblInitializeExternalCmd ();
EblInitializeNetworkCmd();
EblInitializeVariableCmds ();
-
+
if (gST->ConOut == NULL) {
DEBUG((EFI_D_ERROR,"Error: No Console Output\n"));
return EFI_NOT_READY;
@@ -628,29 +628,29 @@ EdkBootLoaderEntry ( gST->ConOut->QueryMode (gST->ConOut, gST->ConOut->Mode->Mode, &gScreenColumns, &gScreenRows);
EblPrintStartupBanner ();
-
+
// Parse command line and handle commands separated by ;
// The loop prints the prompt gets user input and saves history
-
+
// Look for a variable with a default command line, otherwise use the Pcd
ZeroMem(&VendorGuid, sizeof(EFI_GUID));
Status = gRT->GetVariable(CommandLineVariableName, &VendorGuid, NULL, &CommandLineVariableSize, CommandLineVariable);
if (Status == EFI_BUFFER_TOO_SMALL) {
CommandLineVariable = AllocatePool(CommandLineVariableSize);
-
+
Status = gRT->GetVariable(CommandLineVariableName, &VendorGuid, NULL, &CommandLineVariableSize, CommandLineVariable);
if (!EFI_ERROR(Status)) {
UnicodeStrToAsciiStr(CommandLineVariable, CmdLine);
}
-
+
FreePool(CommandLineVariable);
}
-
+
if (EFI_ERROR(Status)) {
AsciiStrCpy (CmdLine, (CHAR8 *)PcdGetPtr (PcdEmbeddedAutomaticBootCommand));
}
-
+
for (;;) {
Status = ProcessCmdLine (CmdLine, MAX_CMD_LINE);
if (Status == EFI_ABORTED) {
diff --git a/EmbeddedPkg/Ebl/Network.c b/EmbeddedPkg/Ebl/Network.c index 7d3d553bb3..d02c9988e1 100644 --- a/EmbeddedPkg/Ebl/Network.c +++ b/EmbeddedPkg/Ebl/Network.c @@ -28,7 +28,7 @@ ParseIp ( Address->v4.Addr[2] = (UINT8)AsciiStrDecimalToUintn (String);
String = AsciiStrStr(String, ".") + 1;
Address->v4.Addr[3] = (UINT8)AsciiStrDecimalToUintn (String);
-
+
return EFI_SUCCESS;
}
@@ -41,28 +41,28 @@ EblIpCmd ( EFI_STATUS Status = EFI_INVALID_PARAMETER;
EFI_MAC_ADDRESS Mac;
EFI_IP_ADDRESS Ip;
-
- if (Argc == 1) {
+
+ if (Argc == 1) {
// Get current IP/MAC
-
+
// Get current MAC address
Status = EblGetCurrentMacAddress (&Mac);
if (EFI_ERROR (Status)) {
goto Exit;
}
-
+
AsciiPrint ("MAC Address: %02x:%02x:%02x:%02x:%02x:%02x\n", Mac.Addr[0], Mac.Addr[1], Mac.Addr[2], Mac.Addr[3], Mac.Addr[4], Mac.Addr[5]);
-
+
// Get current IP address
Status = EblGetCurrentIpAddress (&Ip);
if (EFI_ERROR(Status)) {
AsciiPrint("IP Address is not configured.\n");
Status = EFI_SUCCESS;
goto Exit;
- }
+ }
AsciiPrint("IP Address: %d.%d.%d.%d\n", Ip.v4.Addr[0], Ip.v4.Addr[1],Ip.v4.Addr[2], Ip.v4.Addr[3]);
-
+
} else if ((Argv[1][0] == 'r') && (Argc == 2)) {
// Get new address via dhcp
Status = EblPerformDHCP (TRUE);
@@ -72,10 +72,10 @@ EblIpCmd ( if (EFI_ERROR (Status)) {
goto Exit;
}
-
+
Status = EblSetStationIp (&Ip, NULL);
}
-
+
Exit:
return Status;
}
diff --git a/EmbeddedPkg/Ebl/Script.c b/EmbeddedPkg/Ebl/Script.c index 7c2d58b0a4..a739e37dd9 100644 --- a/EmbeddedPkg/Ebl/Script.c +++ b/EmbeddedPkg/Ebl/Script.c @@ -21,13 +21,13 @@ /**
Execute the passed in file like a series of commands. The ; can be used on
- a single line to indicate multiple commands per line. The Ascii text file
- can contain any number of lines. The following line termination forms are
+ a single line to indicate multiple commands per line. The Ascii text file
+ can contain any number of lines. The following line termination forms are
supported:
LF : Unix, Mac OS X*, BeOS
CR+LF: MS-DOS*, Microsoft Windows*
CR : Commodore, Apple II, and really Mac OS
- LF+CR: for simplicity and completeness
+ LF+CR: for simplicity and completeness
Argv[0] - "script"
Argv[1] - Device Name:path for the file to load
@@ -35,7 +35,7 @@ script fv1:\script.txt
@param Argc Number of command arguments in Argv
- @param Argv Array of strings that represent the parsed command line.
+ @param Argv Array of strings that represent the parsed command line.
Argv[0] is the command name
@return EFI_SUCCESS
@@ -54,8 +54,8 @@ EblScriptCmd ( CHAR8 *Ptr;
CHAR8 *ScanPtr;
UINTN CmdLineSize;
-
-
+
+
if (Argc < 2) {
// file name required
@@ -85,15 +85,15 @@ EblScriptCmd ( CmdLineSize++;
break;
}
-
+
}
Status = ProcessCmdLine (Ptr, CmdLineSize);
}
-
+
FreePool (Address);
}
-
+
EfiClose (File);
return Status;
}
@@ -103,7 +103,7 @@ EblScriptCmd ( GLOBAL_REMOVE_IF_UNREFERENCED const EBL_COMMAND_TABLE mScriptTemplate[] = {
{
"script",
- " device:path; load an ascii file and execute it like commands",
+ " device:path; load an ascii file and execute it like commands",
NULL,
EblScriptCmd
}
diff --git a/EmbeddedPkg/Ebl/Variable.c b/EmbeddedPkg/Ebl/Variable.c index 5c00122cdb..f7627a8def 100644 --- a/EmbeddedPkg/Ebl/Variable.c +++ b/EmbeddedPkg/Ebl/Variable.c @@ -1,14 +1,14 @@ /** @file
*
* Copyright (c) 2011, ARM Limited. All rights reserved.
-*
-* This program and the accompanying materials
-* are licensed and made available under the terms and conditions of the BSD License
-* which accompanies this distribution. The full text of the license may be found at
-* http://opensource.org/licenses/bsd-license.php
*
-* THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
-* WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
+* This program and the accompanying materials
+* are licensed and made available under the terms and conditions of the BSD License
+* which accompanies this distribution. The full text of the license may be found at
+* http://opensource.org/licenses/bsd-license.php
+*
+* THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
+* WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
*
**/
@@ -113,7 +113,7 @@ EblSetCmd ( AsciiPrint("Variable name is missing.\n");
return Status;
}
-
+
// Check if it is a valid variable setting
AsciiValue = AsciiStrStr (AsciiVariableSetting,"=");
if (AsciiValue == NULL) {
diff --git a/EmbeddedPkg/EblExternCmd/EntryPointGlue.c b/EmbeddedPkg/EblExternCmd/EntryPointGlue.c index 87757dfd47..d0e549bdc1 100644 --- a/EmbeddedPkg/EblExternCmd/EntryPointGlue.c +++ b/EmbeddedPkg/EblExternCmd/EntryPointGlue.c @@ -1,5 +1,5 @@ /** @file
- Glue code that contains the EFI entry point and converts it to an EBL
+ Glue code that contains the EFI entry point and converts it to an EBL
ASCII Argc, Argv sytle entry point
@@ -88,7 +88,7 @@ ParseArguments ( } else if (*Char != ' ') {
Argv[Arg++] = Char;
LookingForArg = FALSE;
- }
+ }
} else {
// Looking for the terminator of an Argv[] entry
if ((InQuote && (*Char == '"')) || (!InQuote && (*Char == ' '))) {
@@ -112,12 +112,12 @@ ParseArguments ( return;
}
-
+
/**
- Embedded Boot Loader (EBL) - A simple EFI command line application for embedded
+ Embedded Boot Loader (EBL) - A simple EFI command line application for embedded
devices. PcdEmbeddedAutomaticBootCommand is a complied in command line that
gets executed automatically. The ; separator allows multiple commands
for each command line.
@@ -133,7 +133,7 @@ EFIAPI EdkExternCmdEntry (
IN EFI_HANDLE ImageHandle,
IN EFI_SYSTEM_TABLE *SystemTable
- )
+ )
{
EFI_STATUS Status;
EFI_LOADED_IMAGE_PROTOCOL *ImageInfo;
@@ -144,10 +144,10 @@ EdkExternCmdEntry ( if (EFI_ERROR (Status)) {
Argc = 0;
} else {
- // Looks like valid commands were passed in.
+ // Looks like valid commands were passed in.
ParseArguments (ImageInfo->LoadOptions, ImageInfo->LoadOptionsSize, &Argc, Argv);
}
-
+
return EblMain (Argc, Argv);
}
diff --git a/EmbeddedPkg/EblExternCmd/Main.c b/EmbeddedPkg/EblExternCmd/Main.c index 9e75c909cc..dbfe336899 100644 --- a/EmbeddedPkg/EblExternCmd/Main.c +++ b/EmbeddedPkg/EblExternCmd/Main.c @@ -1,10 +1,10 @@ /** @file
- Example of an external EBL command. It's loaded via EBL start command.
+ Example of an external EBL command. It's loaded via EBL start command.
Argc and Argv are passed in via "" of the EBL command line.
Start fs0:\EdkExternCmd.efi "Argv[0] Argv[1] 2"
- will launch this command with
+ will launch this command with
Argv[0] = "Argv[0]"
Argv[1] = "Argv[2]"
Argv[2] = "3"
@@ -29,7 +29,7 @@ Entry point with Argc, Argv. Put your code here.
@param Argc Number of command arguments in Argv
- @param Argv Array of strings that represent the parsed command line.
+ @param Argv Array of strings that represent the parsed command line.
Argv[0] is the command name
@return EFI_SUCCESS
@@ -47,7 +47,7 @@ EblMain ( for (Index = 0; Index < Argc; Index++) {
AsciiPrint ("Argv[%d] = %a\n", Index, Argv[Index]);
}
-
+
return EFI_SUCCESS;
}
diff --git a/EmbeddedPkg/EmbeddedMonotonicCounter/EmbeddedMonotonicCounter.c b/EmbeddedPkg/EmbeddedMonotonicCounter/EmbeddedMonotonicCounter.c index 7348fa60e6..1dec02e65a 100644 --- a/EmbeddedPkg/EmbeddedMonotonicCounter/EmbeddedMonotonicCounter.c +++ b/EmbeddedPkg/EmbeddedMonotonicCounter/EmbeddedMonotonicCounter.c @@ -1,7 +1,7 @@ /** @file
Copyright (c) 2008 - 2009, Apple Inc. All rights reserved.<BR>
-
+
This program and the accompanying materials
are licensed and made available under the terms and conditions of the BSD License
which accompanies this distribution. The full text of the license may be found at
@@ -32,7 +32,7 @@ GetNextMonotonicCount ( if (Count == NULL) {
return EFI_INVALID_PARAMETER;
}
-
+
*Count = gCurrentMonotonicCount++;
return EFI_SUCCESS;
}
@@ -46,9 +46,9 @@ GetNextHighMonotonicCount ( if (HighCount == NULL) {
return EFI_INVALID_PARAMETER;
}
-
+
gCurrentMonotonicCount += 0x0000000100000000ULL;
-
+
*HighCount = (UINT32)RShiftU64 (gCurrentMonotonicCount, 32) & 0xFFFFFFFF;
return EFI_SUCCESS;
diff --git a/EmbeddedPkg/EmbeddedMonotonicCounter/EmbeddedMonotonicCounter.inf b/EmbeddedPkg/EmbeddedMonotonicCounter/EmbeddedMonotonicCounter.inf index 6b262dbc45..9f28522252 100644 --- a/EmbeddedPkg/EmbeddedMonotonicCounter/EmbeddedMonotonicCounter.inf +++ b/EmbeddedPkg/EmbeddedMonotonicCounter/EmbeddedMonotonicCounter.inf @@ -1,14 +1,14 @@ #/** @file
-#
+#
# Copyright (c) 2008 - 2010, Apple Inc. All rights reserved.<BR>
# This program and the accompanying materials
# are licensed and made available under the terms and conditions of the BSD License
# which accompanies this distribution. The full text of the license may be found at
# http://opensource.org/licenses/bsd-license.php
-#
+#
# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
-#
+#
#**/
[Defines]
diff --git a/EmbeddedPkg/EmbeddedPkg.dec b/EmbeddedPkg/EmbeddedPkg.dec index 9d02b80b2c..600d0e54c4 100644 --- a/EmbeddedPkg/EmbeddedPkg.dec +++ b/EmbeddedPkg/EmbeddedPkg.dec @@ -75,7 +75,7 @@ gEmbeddedTokenSpaceGuid.PcdEmbeddedScriptCmd|FALSE|BOOLEAN|0x00000006
gEmbeddedTokenSpaceGuid.PcdEmbeddedPciDebugCmd|FALSE|BOOLEAN|0x00000041
gEmbeddedTokenSpaceGuid.PcdEmbeddedProbeRemovable|TRUE|BOOLEAN|0x00000052
-
+
gEmbeddedTokenSpaceGuid.PcdPrePiProduceMemoryTypeInformationHob|FALSE|BOOLEAN|0x0000001b
gEmbeddedTokenSpaceGuid.PcdCacheEnable|FALSE|BOOLEAN|0x00000042
gEmbeddedTokenSpaceGuid.PcdGdbSerial|FALSE|BOOLEAN|0x00000053
@@ -90,14 +90,14 @@ gEmbeddedTokenSpaceGuid.PcdPrePiHobBase|131072|UINT32|0x00000040
gEmbeddedTokenSpaceGuid.PcdPrePiStackBase|0|UINT32|0x0000000b
gEmbeddedTokenSpaceGuid.PcdPrePiStackSize|131072|UINT32|0x0000000c
-
+
gEmbeddedTokenSpaceGuid.PcdMemoryBase|0x0|UINT32|0x0000004e
gEmbeddedTokenSpaceGuid.PcdMemorySize|0x0|UINT32|0x0000004f
gEmbeddedTokenSpaceGuid.PcdFlashFvMainBase|0x0|UINT32|0x00000043
gEmbeddedTokenSpaceGuid.PcdFlashFvMainOffset|0x0|UINT32|0x00000044
gEmbeddedTokenSpaceGuid.PcdFlashFvMainSize|0x0|UINT32|0x00000045
-
+
# Used to help reduce fragmentation in the EFI memory map
# EFI Pages (4K) are the units used
gEmbeddedTokenSpaceGuid.PcdMemoryTypeEfiACPIReclaimMemory|0|UINT32|0x00000012
@@ -116,7 +116,7 @@ gEmbeddedTokenSpaceGuid.PcdInterruptBaseAddress|0x38e00000|UINT32|0x0000001f
gEmbeddedTokenSpaceGuid.PcdMetronomeTickPeriod|100|UINT32|0x00000020
-
+
gEmbeddedTokenSpaceGuid.PcdEmbeddedFdBaseAddress|0xffff0000|UINT32|0x00000030
gEmbeddedTokenSpaceGuid.PcdEmbeddedFdSize|0x0000000|UINT32|0x00000031
gEmbeddedTokenSpaceGuid.PcdEmbeddedPerformanceCounterFrequencyInHz|0x0000000|UINT64|0x00000032
diff --git a/EmbeddedPkg/EmbeddedPkg.dsc b/EmbeddedPkg/EmbeddedPkg.dsc index c5d4ae6d1a..68224069b6 100644 --- a/EmbeddedPkg/EmbeddedPkg.dsc +++ b/EmbeddedPkg/EmbeddedPkg.dsc @@ -50,7 +50,7 @@ # DebugLib|MdePkg/Library/UefiDebugLibConOut/UefiDebugLibConOut.inf
DebugLib|MdePkg/Library/BaseDebugLibNull/BaseDebugLibNull.inf
-
+
BaseLib|MdePkg/Library/BaseLib/BaseLib.inf
BaseMemoryLib|MdePkg/Library/BaseMemoryLib/BaseMemoryLib.inf
PciLib|MdePkg/Library/BasePciLibCf8/BasePciLibCf8.inf
@@ -58,17 +58,17 @@ PrintLib|MdePkg/Library/BasePrintLib/BasePrintLib.inf
UefiDecompressLib|MdePkg/Library/BaseUefiDecompressLib/BaseUefiDecompressLib.inf
EfiFileLib|EmbeddedPkg/Library/EfiFileLib/EfiFileLib.inf
-
+
TimerLib|MdePkg/Library/BaseTimerLibNullTemplate/BaseTimerLibNullTemplate.inf
-
+
ReportStatusCodeLib|IntelFrameworkModulePkg/Library/PeiDxeDebugLibReportStatusCode/PeiDxeDebugLibReportStatusCode.inf
-
+
PeCoffGetEntryPointLib|MdePkg/Library/BasePeCoffGetEntryPointLib/BasePeCoffGetEntryPointLib.inf
PeCoffLib|MdePkg/Library/BasePeCoffLib/BasePeCoffLib.inf
PeCoffExtraActionLib|MdePkg/Library/BasePeCoffExtraActionLibNull/BasePeCoffExtraActionLibNull.inf
CacheMaintenanceLib|MdePkg/Library/BaseCacheMaintenanceLib/BaseCacheMaintenanceLib.inf
PrePiLib|EmbeddedPkg/Library/PrePiLib/PrePiLib.inf
-
+
SerialPortLib|EmbeddedPkg/Library/TemplateSerialPortLib/TemplateSerialPortLib.inf
SerialPortExtLib|EmbeddedPkg/Library/TemplateSerialPortExtLib/TemplateSerialPortExtLib.inf
RealTimeClockLib|EmbeddedPkg/Library/TemplateRealTimeClockLib/TemplateRealTimeClockLib.inf
@@ -80,7 +80,7 @@ # Need to change this for IPF
#
IoLib|MdePkg/Library/BaseIoLibIntrinsic/BaseIoLibIntrinsic.inf
-
+
MemoryAllocationLib|MdePkg/Library/UefiMemoryAllocationLib/UefiMemoryAllocationLib.inf
UefiLib|MdePkg/Library/UefiLib/UefiLib.inf
HobLib|MdePkg/Library/DxeHobLib/DxeHobLib.inf
@@ -103,7 +103,7 @@ # Networking Requirements
NetLib|MdeModulePkg/Library/DxeNetLib/DxeNetLib.inf
HiiLib|MdeModulePkg/Library/UefiHiiLib/UefiHiiLib.inf
- UefiHiiServicesLib|MdeModulePkg/Library/UefiHiiServicesLib/UefiHiiServicesLib.inf
+ UefiHiiServicesLib|MdeModulePkg/Library/UefiHiiServicesLib/UefiHiiServicesLib.inf
[LibraryClasses.common.DXE_DRIVER]
PcdLib|MdePkg/Library/DxePcdLib/DxePcdLib.inf
@@ -117,7 +117,7 @@ [LibraryClasses.common.UEFI_DRIVER]
PcdLib|MdePkg/Library/DxePcdLib/DxePcdLib.inf
ReportStatusCodeLib|IntelFrameworkModulePkg/Library/DxeReportStatusCodeLibFramework/DxeReportStatusCodeLib.inf
-
+
[LibraryClasses.common.SEC]
ExtractGuidedSectionLib|EmbeddedPkg/Library/PrePiExtractGuidedSectionLib/PrePiExtractGuidedSectionLib.inf
@@ -146,11 +146,11 @@ gEfiMdePkgTokenSpaceGuid.PcdDriverDiagnosticsDisable|FALSE
gEfiMdePkgTokenSpaceGuid.PcdComponentName2Disable|FALSE
gEfiMdePkgTokenSpaceGuid.PcdDriverDiagnostics2Disable|FALSE
-
+
#
# Control what commands are supported from the UI
# Turn these on and off to add features or save size
- #
+ #
gEmbeddedTokenSpaceGuid.PcdEmbeddedMacBoot|TRUE
gEmbeddedTokenSpaceGuid.PcdEmbeddedDirCmd|TRUE
gEmbeddedTokenSpaceGuid.PcdEmbeddedHobCmd|TRUE
@@ -158,7 +158,7 @@ gEmbeddedTokenSpaceGuid.PcdEmbeddedIoEnable|FALSE
gEmbeddedTokenSpaceGuid.PcdEmbeddedScriptCmd|FALSE
gEmbeddedTokenSpaceGuid.PcdEmbeddedPciDebugCmd|TRUE
-
+
gEmbeddedTokenSpaceGuid.PcdPrePiProduceMemoryTypeInformationHob|FALSE
@@ -182,7 +182,7 @@ gEmbeddedTokenSpaceGuid.PcdEmbeddedAutomaticBootCommand|L""
gEmbeddedTokenSpaceGuid.PcdEmbeddedDefaultTextColor|0x07
gEmbeddedTokenSpaceGuid.PcdEmbeddedMemVariableStoreSize|0x10000
-
+
gEmbeddedTokenSpaceGuid.PcdPrePiHobBase|0
gEmbeddedTokenSpaceGuid.PcdPrePiStackBase|0
gEmbeddedTokenSpaceGuid.PcdPrePiStackSize|0
@@ -190,8 +190,8 @@ #
# Optinal feature to help prevent EFI memory map fragments
# Turned on and off via: PcdPrePiProduceMemoryTypeInformationHob
-# Values are in EFI Pages (4K). DXE Core will make sure that
-# at least this much of each type of memory can be allocated
+# Values are in EFI Pages (4K). DXE Core will make sure that
+# at least this much of each type of memory can be allocated
# from a single memory range. This way you only end up with
# maximum of two fragements for each type in the memory map
# (the memory used, and the free memory that was prereserved
@@ -235,11 +235,11 @@ #
################################################################################
[Components.common]
- EmbeddedPkg/Library/EblAddExternalCommandLib/EblAddExternalCommandLib.inf
+ EmbeddedPkg/Library/EblAddExternalCommandLib/EblAddExternalCommandLib.inf
EmbeddedPkg/Library/EblCmdLibNull/EblCmdLibNull.inf
EmbeddedPkg/Library/EfiFileLib/EfiFileLib.inf
- EmbeddedPkg/Library/GdbSerialDebugPortLib/GdbSerialDebugPortLib.inf
- EmbeddedPkg/Library/GdbSerialLib/GdbSerialLib.inf
+ EmbeddedPkg/Library/GdbSerialDebugPortLib/GdbSerialDebugPortLib.inf
+ EmbeddedPkg/Library/GdbSerialLib/GdbSerialLib.inf
EmbeddedPkg/Library/PrePiExtractGuidedSectionLib/PrePiExtractGuidedSectionLib.inf
EmbeddedPkg/Library/PrePiLib/PrePiLib.inf
EmbeddedPkg/Library/TemplateSerialPortLib/TemplateSerialPortLib.inf
diff --git a/EmbeddedPkg/EmbeddedPkg.fdf b/EmbeddedPkg/EmbeddedPkg.fdf index b7f17c043b..c84a5193ef 100644 --- a/EmbeddedPkg/EmbeddedPkg.fdf +++ b/EmbeddedPkg/EmbeddedPkg.fdf @@ -1,4 +1,4 @@ -# This is Ebl FDF file
+# This is Ebl FDF file
#
# Copyright (c) 2008, Intel Corporation. All rights reserved.<BR>
#
@@ -51,21 +51,21 @@ READ_LOCK_STATUS = TRUE #
################################################################################
INF EmbeddedPkg/Ebl/Ebl.inf
-
+
################################################################################
-#
+#
# Rules are use with the [FV] section's module INF type to define
# how an FFS file is created for a given INF file. The following Rule are the default
# rules for the different module type. User can add the customized rules to define the
# content of the FFS file.
-#
+#
################################################################################
-
-
+
+
############################################################################
-# Example of a DXE_DRIVER FFS file with a Checksum encapsulation section #
+# Example of a DXE_DRIVER FFS file with a Checksum encapsulation section #
############################################################################
-#
+#
#[Rule.Common.DXE_DRIVER]
# FILE DRIVER = $(NAMED_GUID) {
# DXE_DEPEX DXE_DEPEX Optional $(INF_OUTPUT)/$(MODULE_NAME).depex
@@ -88,14 +88,14 @@ INF EmbeddedPkg/Ebl/Ebl.inf [Rule.Common.PEI_CORE]
FILE PEI_CORE = $(NAMED_GUID) {
PE32 PE32 $(INF_OUTPUT)/$(MODULE_NAME).efi
- UI STRING ="$(MODULE_NAME)" Optional
+ UI STRING ="$(MODULE_NAME)" Optional
}
[Rule.Common.PEIM]
FILE PEIM = $(NAMED_GUID) {
PEI_DEPEX PEI_DEPEX Optional $(MODULE_NAME).depex
PE32 PE32 $(INF_OUTPUT)/$(MODULE_NAME).efi
- UI STRING="$(MODULE_NAME)" Optional
+ UI STRING="$(MODULE_NAME)" Optional
}
[Rule.Common.PEIM.TIANOCOMPRESSED]
diff --git a/EmbeddedPkg/GdbStub/Arm/Processor.c b/EmbeddedPkg/GdbStub/Arm/Processor.c index 38abb69d7e..80803b2d91 100644 --- a/EmbeddedPkg/GdbStub/Arm/Processor.c +++ b/EmbeddedPkg/GdbStub/Arm/Processor.c @@ -2,7 +2,7 @@ Processor specific parts of the GDB stub
Copyright (c) 2008 - 2009, Apple Inc. All rights reserved.<BR>
-
+
This program and the accompanying materials
are licensed and made available under the terms and conditions of the BSD License
which accompanies this distribution. The full text of the license may be found at
@@ -23,10 +23,10 @@ //
EFI_EXCEPTION_TYPE_ENTRY gExceptionType[] = {
{ EXCEPT_ARM_SOFTWARE_INTERRUPT, GDB_SIGTRAP }
-// { EXCEPT_ARM_UNDEFINED_INSTRUCTION, GDB_SIGTRAP },
-// { EXCEPT_ARM_PREFETCH_ABORT, GDB_SIGTRAP },
-// { EXCEPT_ARM_DATA_ABORT, GDB_SIGEMT },
-// { EXCEPT_ARM_RESERVED, GDB_SIGILL }
+// { EXCEPT_ARM_UNDEFINED_INSTRUCTION, GDB_SIGTRAP },
+// { EXCEPT_ARM_PREFETCH_ABORT, GDB_SIGTRAP },
+// { EXCEPT_ARM_DATA_ABORT, GDB_SIGEMT },
+// { EXCEPT_ARM_RESERVED, GDB_SIGILL }
};
// Shut up some annoying RVCT warnings
@@ -86,8 +86,8 @@ UINTN gRegisterOffsets[] = { /**
Return the number of entries in the gExceptionType[]
-
- @retval UINTN, the number of entries in the gExceptionType[] array.
+
+ @retval UINTN, the number of entries in the gExceptionType[] array.
**/
UINTN
MaxEfiException (
@@ -100,8 +100,8 @@ MaxEfiException ( /**
Return the number of entries in the gRegisters[]
-
- @retval UINTN, the number of entries (registers) in the gRegisters[] array.
+
+ @retval UINTN, the number of entries (registers) in the gRegisters[] array.
**/
UINTN
MaxRegisterCount (
@@ -113,10 +113,10 @@ MaxRegisterCount ( /**
- Check to see if the ISA is supported.
+ Check to see if the ISA is supported.
ISA = Instruction Set Architecture
- @retval TRUE if Isa is supported
+ @retval TRUE if Isa is supported
**/
BOOLEAN
@@ -135,14 +135,14 @@ CheckIsa ( /**
This takes in the register number and the System Context, and returns a pointer to the RegNumber-th register in gdb ordering
It is, by default, set to find the register pointer of the ARM member
- @param SystemContext Register content at time of the exception
+ @param SystemContext Register content at time of the exception
@param RegNumber The register to which we want to find a pointer
@retval the pointer to the RegNumber-th pointer
- **/
+ **/
UINTN *
FindPointerToRegister (
IN EFI_SYSTEM_CONTEXT SystemContext,
- IN UINTN RegNumber
+ IN UINTN RegNumber
)
{
UINT8 *TempPtr;
@@ -168,7 +168,7 @@ BasicReadRegister ( {
UINTN RegSize;
CHAR8 Char;
-
+
if (gRegisterOffsets[RegNumber] > 0xF00) {
AsciiSPrint (OutBufPtr, 9, "00000000");
OutBufPtr += 8;
@@ -182,13 +182,13 @@ BasicReadRegister ( Char = Char - 'A' + 'a';
}
*OutBufPtr++ = Char;
-
+
Char = mHexToStr[(UINT8)((*FindPointerToRegister (SystemContext, RegNumber) >> RegSize) & 0xf)];
if ((Char >= 'A') && (Char <= 'F')) {
Char = Char - 'A' + 'a';
}
*OutBufPtr++ = Char;
-
+
RegSize = RegSize + 8;
}
return OutBufPtr;
@@ -196,7 +196,7 @@ BasicReadRegister ( /**
- Reads the n-th register's value into an output buffer and sends it as a packet
+ Reads the n-th register's value into an output buffer and sends it as a packet
@param SystemContext Register content at time of the exception
@param InBuffer Pointer to the input buffer received from gdb server
**/
@@ -209,29 +209,29 @@ ReadNthRegister ( UINTN RegNumber;
CHAR8 OutBuffer[9]; // 1 reg=8 hex chars, and the end '\0' (escape seq)
CHAR8 *OutBufPtr; // pointer to the output buffer
-
+
RegNumber = AsciiStrHexToUintn (&InBuffer[1]);
-
+
if (RegNumber >= MaxRegisterCount ()) {
- SendError (GDB_EINVALIDREGNUM);
+ SendError (GDB_EINVALIDREGNUM);
return;
}
-
+
OutBufPtr = OutBuffer;
OutBufPtr = BasicReadRegister (SystemContext, RegNumber, OutBufPtr);
-
+
*OutBufPtr = '\0'; // the end of the buffer
SendPacket (OutBuffer);
}
/**
- Reads the general registers into an output buffer and sends it as a packet
+ Reads the general registers into an output buffer and sends it as a packet
@param SystemContext Register content at time of the exception
**/
VOID
EFIAPI
-ReadGeneralRegisters (
+ReadGeneralRegisters (
IN EFI_SYSTEM_CONTEXT SystemContext
)
{
@@ -239,14 +239,14 @@ ReadGeneralRegisters ( CHAR8 *OutBuffer;
CHAR8 *OutBufPtr;
UINTN RegisterCount = MaxRegisterCount ();
-
+
// It is not safe to allocate pool here....
OutBuffer = AllocatePool ((RegisterCount * 8) + 1); // 8 bytes per register in string format plus a null to terminate
OutBufPtr = OutBuffer;
for (Index = 0; Index < RegisterCount; Index++) {
OutBufPtr = BasicReadRegister (SystemContext, Index, OutBufPtr);
}
-
+
*OutBufPtr = '\0';
SendPacket (OutBuffer);
FreePool (OutBuffer);
@@ -270,7 +270,7 @@ CHAR8 UINTN RegSize;
UINTN TempValue; // the value transferred from a hex char
UINT32 NewValue; // the new value of the RegNumber-th Register
-
+
if (gRegisterOffsets[RegNumber] > 0xF00) {
return InBufPtr + 8;
}
@@ -279,21 +279,21 @@ CHAR8 RegSize = 0;
while (RegSize < 32) {
TempValue = HexCharToInt (*InBufPtr++);
-
+
if ((INTN)TempValue < 0) {
- SendError (GDB_EBADMEMDATA);
+ SendError (GDB_EBADMEMDATA);
return NULL;
}
-
+
NewValue += (TempValue << (RegSize+4));
TempValue = HexCharToInt (*InBufPtr++);
-
+
if ((INTN)TempValue < 0) {
- SendError (GDB_EBADMEMDATA);
+ SendError (GDB_EBADMEMDATA);
return NULL;
}
-
- NewValue += (TempValue << RegSize);
+
+ NewValue += (TempValue << RegSize);
RegSize = RegSize + 8;
}
*(FindPointerToRegister (SystemContext, RegNumber)) = NewValue;
@@ -316,19 +316,19 @@ WriteNthRegister ( CHAR8 RegNumBuffer[MAX_REG_NUM_BUF_SIZE]; // put the 'n..' part of the message into this array
CHAR8 *RegNumBufPtr;
CHAR8 *InBufPtr; // pointer to the input buffer
-
+
// find the register number to write
InBufPtr = &InBuffer[1];
RegNumBufPtr = RegNumBuffer;
while (*InBufPtr != '=') {
*RegNumBufPtr++ = *InBufPtr++;
- }
+ }
*RegNumBufPtr = '\0';
- RegNumber = AsciiStrHexToUintn (RegNumBuffer);
-
+ RegNumber = AsciiStrHexToUintn (RegNumBuffer);
+
// check if this is a valid Register Number
if (RegNumber >= MaxRegisterCount ()) {
- SendError (GDB_EINVALIDREGNUM);
+ SendError (GDB_EINVALIDREGNUM);
return;
}
InBufPtr++; // skips the '=' character
@@ -356,21 +356,21 @@ WriteGeneralRegisters ( UINTN RegisterCount = MaxRegisterCount ();
MinLength = (RegisterCount * 8) + 1; // 'G' plus the registers in ASCII format
-
+
if (AsciiStrLen (InBuffer) < MinLength) {
- //Bad message. Message is not the right length
- SendError (GDB_EBADBUFSIZE);
+ //Bad message. Message is not the right length
+ SendError (GDB_EBADBUFSIZE);
return;
}
-
+
InBufPtr = &InBuffer[1];
-
+
// Read the new values for the registers from the input buffer to an array, NewValueArray.
// The values in the array are in the gdb ordering
for (i = 0; i < RegisterCount; i++) {
InBufPtr = BasicWriteRegister (SystemContext, i, InBufPtr);
}
-
+
SendSuccess ();
}
@@ -395,9 +395,9 @@ typedef struct { LIST_ENTRY BreakpointList;
-/**
+/**
Insert Single Step in the SystemContext
-
+
@param SystemContext Register content at time of the exception
**/
VOID
@@ -410,11 +410,11 @@ AddSingleStep ( return;
}
mSingleStepActive = TRUE;
-
+
mSingleStepPC = SystemContext.SystemContextArm->PC;
mSingleStepDataSize = sizeof (UINT32);
- mSingleStepData = (*(UINT32 *)mSingleStepPC);
+ mSingleStepData = (*(UINT32 *)mSingleStepPC);
*(UINT32 *)mSingleStepPC = GDB_ARM_BKPT;
if (*(UINT32 *)mSingleStepPC != GDB_ARM_BKPT) {
// For some reason our breakpoint did not take
@@ -425,10 +425,10 @@ AddSingleStep ( //DEBUG((EFI_D_ERROR, "AddSingleStep at 0x%08x (was: 0x%08x is:0x%08x)\n", SystemContext.SystemContextArm->PC, mSingleStepData, *(UINT32 *)mSingleStepPC));
}
-
-/**
+
+/**
Remove Single Step in the SystemContext
-
+
@param SystemContext Register content at time of the exception
**/
VOID
@@ -439,7 +439,7 @@ RemoveSingleStep ( if (!mSingleStepActive) {
return;
}
-
+
if (mSingleStepDataSize == sizeof (UINT16)) {
*(UINT16 *)mSingleStepPC = (UINT16)mSingleStepData;
} else {
@@ -453,10 +453,10 @@ RemoveSingleStep ( /**
- Continue. addr is Address to resume. If addr is omitted, resume at current
+ Continue. addr is Address to resume. If addr is omitted, resume at current
Address.
-
- @param SystemContext Register content at time of the exception
+
+ @param SystemContext Register content at time of the exception
**/
VOID
EFIAPI
@@ -467,15 +467,15 @@ ContinueAtAddress ( {
if (PacketData[1] != '\0') {
SystemContext.SystemContextArm->PC = AsciiStrHexToUintn (&PacketData[1]);
- }
+ }
}
/** ‘s [addr ]’
- Single step. addr is the Address at which to resume. If addr is omitted, resume
+ Single step. addr is the Address at which to resume. If addr is omitted, resume
at same Address.
-
- @param SystemContext Register content at time of the exception
+
+ @param SystemContext Register content at time of the exception
**/
VOID
EFIAPI
@@ -554,7 +554,7 @@ SetBreakpoint ( Breakpoint->Signature = ARM_SOFTWARE_BREAKPOINT_SIGNATURE;
Breakpoint->Address = Address;
Breakpoint->Instruction = *(UINT32 *)Address;
-
+
// Add it to the list
InsertTailList (&BreakpointList, &Breakpoint->Link);
@@ -645,7 +645,7 @@ RemoveBreakPoint ( switch (Type) {
case 0: //Software breakpoint
break;
-
+
default:
SendError (GDB_EINVALIDBRKPOINTTYPE);
return;
@@ -679,13 +679,13 @@ ValidateAddress ( BOOLEAN
ValidateException (
- IN EFI_EXCEPTION_TYPE ExceptionType,
- IN OUT EFI_SYSTEM_CONTEXT SystemContext
+ IN EFI_EXCEPTION_TYPE ExceptionType,
+ IN OUT EFI_SYSTEM_CONTEXT SystemContext
)
{
UINT32 ExceptionAddress;
UINT32 Instruction;
-
+
// Is it a debugger SWI?
ExceptionAddress = SystemContext.SystemContextArm->PC -= 4;
Instruction = *(UINT32 *)ExceptionAddress;
diff --git a/EmbeddedPkg/GdbStub/GdbStub.c b/EmbeddedPkg/GdbStub/GdbStub.c index 9136c14b2b..213038ad08 100644 --- a/EmbeddedPkg/GdbStub/GdbStub.c +++ b/EmbeddedPkg/GdbStub/GdbStub.c @@ -1,12 +1,12 @@ /** @file
UEFI driver that implements a GDB stub
-
+
Note: Any code in the path of the Serial IO output can not call DEBUG as will
will blow out the stack. Serial IO calls DEBUG, debug calls Serail IO, ...
-
+
Copyright (c) 2008 - 2009, Apple Inc. All rights reserved.<BR>
-
+
This program and the accompanying materials
are licensed and made available under the terms and conditions of the BSD License
which accompanies this distribution. The full text of the license may be found at
@@ -29,7 +29,7 @@ UINTN gMaxProcessorIndex = 0; CHAR8 gInBuffer[MAX_BUF_SIZE];
CHAR8 gOutBuffer[MAX_BUF_SIZE];
-// Assume gdb does a "qXfer:libraries:read::offset,length" when it connects so we can default
+// Assume gdb does a "qXfer:libraries:read::offset,length" when it connects so we can default
// this value to FALSE. Since gdb can reconnect its self a global default is not good enough
BOOLEAN gSymbolTableUpdate = FALSE;
EFI_EVENT gEvent;
@@ -59,12 +59,12 @@ GdbSymbolEventHandler ( /**
The user Entry Point for Application. The user code starts with this function
- as the real entry point for the image goes into a library that calls this
+ as the real entry point for the image goes into a library that calls this
function.
- @param[in] ImageHandle The firmware allocated handle for the EFI image.
+ @param[in] ImageHandle The firmware allocated handle for the EFI image.
@param[in] SystemTable A pointer to the EFI System Table.
-
+
@retval EFI_SUCCESS The entry point is executed successfully.
@retval other Some error occurs when executing this entry point.
@@ -76,7 +76,7 @@ GdbStubEntry ( IN EFI_SYSTEM_TABLE *SystemTable
)
{
- EFI_STATUS Status;
+ EFI_STATUS Status;
EFI_DEBUG_SUPPORT_PROTOCOL *DebugSupport;
UINTN HandleCount;
EFI_HANDLE *Handles;
@@ -101,7 +101,7 @@ GdbStubEntry ( return Status;
}
-
+
DebugSupport = NULL;
IsaSupported = FALSE;
do {
@@ -120,19 +120,19 @@ GdbStubEntry ( }
} while (HandleCount > 0);
FreePool (Handles);
-
+
if (!IsaSupported) {
DEBUG ((EFI_D_ERROR, "Debug Support Protocol does not support our ISA\n"));
return EFI_NOT_FOUND;
}
-
+
Status = DebugSupport->GetMaximumProcessorIndex (DebugSupport, &gMaxProcessorIndex);
ASSERT_EFI_ERROR (Status);
-
+
DEBUG ((EFI_D_INFO, "Debug Support Protocol ISA %x\n", DebugSupport->Isa));
DEBUG ((EFI_D_INFO, "Debug Support Protocol Processor Index %d\n", gMaxProcessorIndex));
-
+
// Call processor-specific init routine
InitializeProcessor ();
@@ -147,10 +147,10 @@ GdbStubEntry ( Status = DebugSupport->RegisterPeriodicCallback (DebugSupport, Processor, GdbPeriodicCallBack);
ASSERT_EFI_ERROR (Status);
}
-
+
//
// This even fires every time an image is added. This allows the stub to know when gdb needs
- // to update the symbol table.
+ // to update the symbol table.
//
Status = gBS->CreateEvent (
EVT_NOTIFY_SIGNAL,
@@ -171,11 +171,11 @@ GdbStubEntry ( );
ASSERT_EFI_ERROR (Status);
-
+
if (PcdGetBool (PcdGdbSerial)) {
GdbInitializeSerialConsole ();
}
-
+
return EFI_SUCCESS;
}
@@ -196,14 +196,14 @@ TransferFromInBufToMem ( {
CHAR8 c1;
CHAR8 c2;
-
+
while (Length-- > 0) {
c1 = (CHAR8)HexCharToInt (*NewData++);
c2 = (CHAR8)HexCharToInt (*NewData++);
if ((c1 < 0) || (c2 < 0)) {
Print ((CHAR16 *)L"Bad message from write to memory..\n");
- SendError (GDB_EBADMEMDATA);
+ SendError (GDB_EBADMEMDATA);
return;
}
*Address++ = (UINT8)((c1 << 4) + c2);
@@ -239,7 +239,7 @@ TransferFromMemToOutBufAndSend ( OutBufPtr = OutBuffer;
while (Length > 0) {
-
+
Char = mHexToStr[*Address >> 4];
if ((Char >= 'A') && (Char <= 'F')) {
Char = Char - 'A' + 'a';
@@ -264,16 +264,16 @@ TransferFromMemToOutBufAndSend ( /**
Send a GDB Remote Serial Protocol Packet
-
- $PacketData#checksum PacketData is passed in and this function adds the packet prefix '$',
+
+ $PacketData#checksum PacketData is passed in and this function adds the packet prefix '$',
the packet teminating character '#' and the two digit checksum.
-
- If an ack '+' is not sent resend the packet, but timeout eventually so we don't end up
+
+ If an ack '+' is not sent resend the packet, but timeout eventually so we don't end up
in an infinit loop. This is so if you unplug the debugger code just keeps running
- @param PacketData Payload data for the packet
+ @param PacketData Payload data for the packet
+
-
@retval Number of bytes of packet data sent.
**/
@@ -287,7 +287,7 @@ SendPacket ( CHAR8 *Ptr;
CHAR8 TestChar;
UINTN Count;
-
+
Timeout = PcdGet32 (PcdGdbMaxPacketRetryCount);
Count = 0;
@@ -299,38 +299,38 @@ SendPacket ( // Only try a finite number of times so we don't get stuck in the loop
return Count;
}
-
+
// Packet prefix
GdbPutChar ('$');
-
+
for (CheckSum = 0, Count =0 ; *Ptr != '\0'; Ptr++, Count++) {
GdbPutChar (*Ptr);
CheckSum = CheckSum + *Ptr;
}
-
- // Packet terminating character and checksum
+
+ // Packet terminating character and checksum
GdbPutChar ('#');
GdbPutChar (mHexToStr[CheckSum >> 4]);
GdbPutChar (mHexToStr[CheckSum & 0x0F]);
-
+
TestChar = GdbGetChar ();
} while (TestChar != '+');
-
+
return Count;
}
/**
Receive a GDB Remote Serial Protocol Packet
-
- $PacketData#checksum PacketData is passed in and this function adds the packet prefix '$',
+
+ $PacketData#checksum PacketData is passed in and this function adds the packet prefix '$',
the packet teminating character '#' and the two digit checksum.
-
+
If host re-starts sending a packet without ending the previous packet, only the last valid packet is proccessed.
(In other words, if received packet is '$12345$12345$123456#checksum', only '$123456#checksum' will be processed.)
-
+
If an ack '+' is not sent resend the packet
- @param PacketData Payload data for the packet
+ @param PacketData Payload data for the packet
@retval Number of bytes of packet data received.
@@ -346,16 +346,16 @@ ReceivePacket ( CHAR8 Char;
CHAR8 SumString[3];
CHAR8 TestChar;
-
+
ZeroMem (PacketData, PacketDataSize);
-
+
for (;;) {
// wait for the start of a packet
TestChar = GdbGetChar ();
while (TestChar != '$') {
TestChar = GdbGetChar ();
};
-
+
retry:
for (Index = 0, CheckSum = 0; Index < (PacketDataSize - 1); Index++) {
Char = GdbGetChar ();
@@ -375,14 +375,14 @@ ReceivePacket ( continue;
}
- SumString[0] = GdbGetChar ();
+ SumString[0] = GdbGetChar ();
SumString[1] = GdbGetChar ();
SumString[2] = '\0';
-
+
if (AsciiStrHexToUintn (SumString) == CheckSum) {
// Ack: Success
GdbPutChar ('+');
-
+
// Null terminate the callers string
PacketData[Index] = '\0';
return Index;
@@ -391,27 +391,27 @@ ReceivePacket ( GdbPutChar ('-');
}
}
-
+
//return 0;
}
/**
- Empties the given buffer
+ Empties the given buffer
@param Buf pointer to the first element in buffer to be emptied
**/
VOID
-EmptyBuffer (
+EmptyBuffer (
IN CHAR8 *Buf
)
-{
+{
*Buf = '\0';
}
/**
Converts an 8-bit Hex Char into a INTN.
-
+
@param Char the hex character to be converted into UINTN
@retval a INTN, from 0 to 15, that corressponds to Char
-1 if Char is not a hex character
@@ -428,7 +428,7 @@ HexCharToInt ( } else if ((Char >= '0') && (Char <= '9')) {
return Char - '0';
} else { // if not a hex value, return a negative value
- return -1;
+ return -1;
}
}
@@ -439,7 +439,7 @@ CHAR8 *gError = "E__"; Send an error with the given error number after converting to hex.
The error number is put into the buffer in hex. '255' is the biggest errno we can send.
ex: 162 will be sent as A2.
-
+
@param errno the error number that will be sent
**/
VOID
@@ -453,7 +453,7 @@ SendError ( //
gError[1] = mHexToStr [ErrorNum >> 4];
gError[2] = mHexToStr [ErrorNum & 0x0f];
-
+
SendPacket (gError); // send buffer
}
@@ -466,7 +466,7 @@ VOID EFIAPI
SendSuccess (
VOID
- )
+ )
{
SendPacket ("OK"); // send buffer
}
@@ -475,11 +475,11 @@ SendSuccess ( /**
Send empty packet to specify that particular command/functionality is not supported.
**/
-VOID
-EFIAPI
+VOID
+EFIAPI
SendNotSupported (
- VOID
- )
+ VOID
+ )
{
SendPacket ("");
}
@@ -487,7 +487,7 @@ SendNotSupported ( /**
Send the T signal with the given exception type (in gdb order) and possibly with n:r pairs related to the watchpoints
-
+
@param SystemContext Register content at time of the exception
@param GdbExceptionType GDB exception type
**/
@@ -513,9 +513,9 @@ GdbSendTSignal ( //
// replace _, or previous value, with Exception type
//
- *TSignalPtr++ = mHexToStr [GdbExceptionType >> 4];
+ *TSignalPtr++ = mHexToStr [GdbExceptionType >> 4];
*TSignalPtr++ = mHexToStr [GdbExceptionType & 0x0f];
-
+
if (GdbExceptionType == GDB_SIGTRAP) {
if (gSymbolTableUpdate) {
//
@@ -531,17 +531,17 @@ GdbSendTSignal ( //
// possible n:r pairs
- //
+ //
//Retrieve the breakpoint number
BreakpointDetected = GetBreakpointDetected (SystemContext);
//Figure out if the exception is happend due to watch, rwatch or awatch.
- BreakType = GetBreakpointType (SystemContext, BreakpointDetected);
+ BreakType = GetBreakpointType (SystemContext, BreakpointDetected);
//INFO: rwatch is not supported due to the way IA32 debug registers work
if ((BreakType == DataWrite) || (BreakType == DataRead) || (BreakType == DataReadWrite)) {
-
+
//Construct n:r pair
DataAddress = GetBreakpointDataAddress (SystemContext, BreakpointDetected);
@@ -559,7 +559,7 @@ GdbSendTSignal ( }
*TSignalPtr++ = ':';
-
+
//Set up series of bytes in big-endian byte order. "awatch" won't work with little-endian byte order.
RegSize = REG_SIZE;
while (RegSize > 0) {
@@ -575,23 +575,23 @@ GdbSendTSignal ( *TSignalPtr = '\0';
- SendPacket (TSignalBuffer);
+ SendPacket (TSignalBuffer);
}
/**
Translates the EFI mapping to GDB mapping
-
+
@param EFIExceptionType EFI Exception that is being processed
@retval UINTN that corresponds to EFIExceptionType's GDB exception type number
**/
UINT8
-ConvertEFItoGDBtype (
+ConvertEFItoGDBtype (
IN EFI_EXCEPTION_TYPE EFIExceptionType
)
-{
+{
UINTN Index;
-
+
for (Index = 0; Index < MaxEfiException () ; Index++) {
if (gExceptionType[Index].Exception == EFIExceptionType) {
return gExceptionType[Index].SignalNo;
@@ -602,8 +602,8 @@ ConvertEFItoGDBtype ( /** "m addr,length"
- Find the Length of the area to read and the start addres. Finally, pass them to
- another function, TransferFromMemToOutBufAndSend, that will read from that memory space and
+ Find the Length of the area to read and the start addres. Finally, pass them to
+ another function, TransferFromMemToOutBufAndSend, that will read from that memory space and
send it as a packet.
**/
@@ -618,39 +618,39 @@ ReadFromMemory ( CHAR8 AddressBuffer[MAX_ADDR_SIZE]; // the buffer that will hold the address in hex chars
CHAR8 *AddrBufPtr; // pointer to the address buffer
CHAR8 *InBufPtr; /// pointer to the input buffer
-
+
AddrBufPtr = AddressBuffer;
InBufPtr = &PacketData[1];
while (*InBufPtr != ',') {
*AddrBufPtr++ = *InBufPtr++;
}
*AddrBufPtr = '\0';
-
+
InBufPtr++; // this skips ',' in the buffer
-
+
/* Error checking */
if (AsciiStrLen (AddressBuffer) >= MAX_ADDR_SIZE) {
Print((CHAR16 *)L"Address is too long\n");
- SendError (GDB_EBADMEMADDRBUFSIZE);
+ SendError (GDB_EBADMEMADDRBUFSIZE);
return;
}
-
+
// 2 = 'm' + ','
if (AsciiStrLen (PacketData) - AsciiStrLen (AddressBuffer) - 2 >= MAX_LENGTH_SIZE) {
Print((CHAR16 *)L"Length is too long\n");
- SendError (GDB_EBADMEMLENGTH);
+ SendError (GDB_EBADMEMLENGTH);
return;
}
-
+
Address = AsciiStrHexToUintn (AddressBuffer);
Length = AsciiStrHexToUintn (InBufPtr);
-
+
TransferFromMemToOutBufAndSend (Length, (unsigned char *)Address);
}
/** "M addr,length :XX..."
- Find the Length of the area in bytes to write and the start addres. Finally, pass them to
+ Find the Length of the area in bytes to write and the start addres. Finally, pass them to
another function, TransferFromInBufToMem, that will write to that memory space the info in
the input buffer.
**/
@@ -668,50 +668,50 @@ WriteToMemory ( CHAR8 *AddrBufPtr; // pointer to the Address buffer
CHAR8 *LengthBufPtr; // pointer to the Length buffer
CHAR8 *InBufPtr; /// pointer to the input buffer
-
+
AddrBufPtr = AddressBuffer;
LengthBufPtr = LengthBuffer;
InBufPtr = &PacketData[1];
-
+
while (*InBufPtr != ',') {
*AddrBufPtr++ = *InBufPtr++;
}
*AddrBufPtr = '\0';
-
+
InBufPtr++; // this skips ',' in the buffer
-
+
while (*InBufPtr != ':') {
*LengthBufPtr++ = *InBufPtr++;
}
*LengthBufPtr = '\0';
-
+
InBufPtr++; // this skips ':' in the buffer
-
+
Address = AsciiStrHexToUintn (AddressBuffer);
Length = AsciiStrHexToUintn (LengthBuffer);
-
+
/* Error checking */
-
+
//Check if Address is not too long.
if (AsciiStrLen (AddressBuffer) >= MAX_ADDR_SIZE) {
Print ((CHAR16 *)L"Address too long..\n");
- SendError (GDB_EBADMEMADDRBUFSIZE);
+ SendError (GDB_EBADMEMADDRBUFSIZE);
return;
}
-
+
//Check if message length is not too long
if (AsciiStrLen (LengthBuffer) >= MAX_LENGTH_SIZE) {
Print ((CHAR16 *)L"Length too long..\n");
- SendError (GDB_EBADMEMLENGBUFSIZE);
+ SendError (GDB_EBADMEMLENGBUFSIZE);
return;
}
-
+
// Check if Message is not too long/short.
// 3 = 'M' + ',' + ':'
MessageLength = (AsciiStrLen (PacketData) - AsciiStrLen (AddressBuffer) - AsciiStrLen (LengthBuffer) - 3);
if (MessageLength != (2*Length)) {
//Message too long/short. New data is not the right size.
- SendError (GDB_EBADMEMDATASIZE);
+ SendError (GDB_EBADMEMDATASIZE);
return;
}
TransferFromInBufToMem (Length, (unsigned char *)Address, InBufPtr);
@@ -800,7 +800,7 @@ gXferObjectReadResponse ( *OutBufPtr++ = Type;
Count = 1;
- // Binary data encoding
+ // Binary data encoding
OutBufPtr = gOutBuffer;
while (*Str != '\0') {
Char = *Str++;
@@ -816,17 +816,17 @@ gXferObjectReadResponse ( *OutBufPtr = '\0' ; // the end of the buffer
SendPacket (gOutBuffer);
-
+
return Count;
}
/**
- Note: This should be a library function. In the Apple case you have to add
- the size of the PE/COFF header into the starting address to make things work
+ Note: This should be a library function. In the Apple case you have to add
+ the size of the PE/COFF header into the starting address to make things work
right as there is no way to pad the Mach-O for the size of the PE/COFF header.
-
-
+
+
Returns a pointer to the PDB file name for a PE/COFF image that has been
loaded into system memory with the PE/COFF Loader Library functions.
@@ -844,7 +844,7 @@ gXferObjectReadResponse ( @return The PDB file name for the PE/COFF image specified by Pe32Data or NULL
if it cannot be retrieved. DebugBase is only valid if PDB file name is
- valid.
+ valid.
**/
VOID *
@@ -895,14 +895,14 @@ PeCoffLoaderGetDebuggerInfo ( TEImageAdjust);
}
SizeOfHeaders = sizeof (EFI_TE_IMAGE_HEADER) + (UINTN)Hdr.Te->BaseOfCode - (UINTN)Hdr.Te->StrippedSize;
-
+
// __APPLE__ check this math...
*DebugBase = ((CHAR8 *)Pe32Data) - TEImageAdjust;
} else if (Hdr.Pe32->Signature == EFI_IMAGE_NT_SIGNATURE) {
-
+
*DebugBase = Pe32Data;
-
-
+
+
//
// NOTE: We use Machine field to identify PE32/PE32+, instead of Magic.
// It is due to backward-compatibility, for some system might
@@ -983,38 +983,38 @@ PeCoffLoaderGetDebuggerInfo ( }
-/**
+/**
Process "qXfer:object:read:annex:offset,length" request.
-
- Returns an XML document that contains loaded libraries. In our case it is
+
+ Returns an XML document that contains loaded libraries. In our case it is
information in the EFI Debug Image Table converted into an XML document.
-
- GDB will call with an arbitrary length (it can't know the real length and
- will reply with chunks of XML that are easy for us to deal with. Gdb will
+
+ GDB will call with an arbitrary length (it can't know the real length and
+ will reply with chunks of XML that are easy for us to deal with. Gdb will
keep calling until we say we are done. XML doc looks like:
-
+
<library-list>
<library name="/a/a/c/d.dSYM"><segment address="0x10000000"/></library>
<library name="/a/m/e/e.pdb"><segment address="0x20000000"/></library>
<library name="/a/l/f/f.dll"><segment address="0x30000000"/></library>
</library-list>
-
+
Since we can not allocate memory in interrupt context this module has
assumptions about how it will get called:
1) Length will generally be max remote packet size (big enough)
2) First Offset of an XML document read needs to be 0
3) This code will return back small chunks of the XML document on every read.
Each subsequent call will ask for the next available part of the document.
-
+
Note: The only variable size element in the XML is:
- " <library name=\"%s\"><segment address=\"%p\"/></library>\n" and it is
+ " <library name=\"%s\"><segment address=\"%p\"/></library>\n" and it is
based on the file path and name of the symbol file. If the symbol file name
is bigger than the max gdb remote packet size we could update this code
to respond back in chunks.
@param Offset offset into special data area
- @param Length number of bytes to read starting at Offset
-
+ @param Length number of bytes to read starting at Offset
+
**/
VOID
QxferLibrary (
@@ -1029,8 +1029,8 @@ QxferLibrary ( if (Offset != gPacketqXferLibraryOffset) {
SendError (GDB_EINVALIDARG);
Print (L"\nqXferLibrary (%d, %d) != %d\n", Offset, Length, gPacketqXferLibraryOffset);
-
- // Force a retry from the beginning
+
+ // Force a retry from the beginning
gPacketqXferLibraryOffset = 0;
return;
@@ -1038,41 +1038,41 @@ QxferLibrary ( if (Offset == 0) {
gPacketqXferLibraryOffset += gXferObjectReadResponse ('m', "<library-list>\n");
-
+
// The owner of the table may have had to ralloc it so grab a fresh copy every time
- // we assume qXferLibrary will get called over and over again until the entire XML table is
+ // we assume qXferLibrary will get called over and over again until the entire XML table is
// returned in a tight loop. Since we are in the debugger the table should not get updated
gDebugTable = gDebugImageTableHeader->EfiDebugImageInfoTable;
gEfiDebugImageTableEntry = 0;
return;
}
-
+
if (gDebugTable != NULL) {
for (; gEfiDebugImageTableEntry < gDebugImageTableHeader->TableSize; gEfiDebugImageTableEntry++, gDebugTable++) {
if (gDebugTable->NormalImage != NULL) {
- if ((gDebugTable->NormalImage->ImageInfoType == EFI_DEBUG_IMAGE_INFO_TYPE_NORMAL) &&
+ if ((gDebugTable->NormalImage->ImageInfoType == EFI_DEBUG_IMAGE_INFO_TYPE_NORMAL) &&
(gDebugTable->NormalImage->LoadedImageProtocolInstance != NULL)) {
Pdb = PeCoffLoaderGetDebuggerInfo (
- gDebugTable->NormalImage->LoadedImageProtocolInstance->ImageBase,
+ gDebugTable->NormalImage->LoadedImageProtocolInstance->ImageBase,
&LoadAddress
);
if (Pdb != NULL) {
Size = AsciiSPrint (
- gXferLibraryBuffer,
- sizeof (gXferLibraryBuffer),
- " <library name=\"%a\"><segment address=\"0x%p\"/></library>\n",
+ gXferLibraryBuffer,
+ sizeof (gXferLibraryBuffer),
+ " <library name=\"%a\"><segment address=\"0x%p\"/></library>\n",
Pdb,
LoadAddress
);
if ((Size != 0) && (Size != (sizeof (gXferLibraryBuffer) - 1))) {
gPacketqXferLibraryOffset += gXferObjectReadResponse ('m', gXferLibraryBuffer);
-
+
// Update loop variables so we are in the right place when we get back
gEfiDebugImageTableEntry++;
gDebugTable++;
return;
} else {
- // We could handle <library> entires larger than sizeof (gXferLibraryBuffer) here if
+ // We could handle <library> entires larger than sizeof (gXferLibraryBuffer) here if
// needed by breaking up into N packets
// "<library name=\"%s
// the rest of the string (as many packets as required
@@ -1080,13 +1080,13 @@ QxferLibrary ( //
// But right now we just skip any entry that is too big
}
- }
+ }
}
- }
+ }
}
}
-
-
+
+
gXferObjectReadResponse ('l', "</library-list>\n");
gPacketqXferLibraryOffset = 0;
return;
@@ -1096,55 +1096,55 @@ QxferLibrary ( /**
Exception Hanldler for GDB. It will be called for all exceptions
registered via the gExceptionType[] array.
-
+
@param ExceptionType Exception that is being processed
- @param SystemContext Register content at time of the exception
+ @param SystemContext Register content at time of the exception
**/
VOID
EFIAPI
-GdbExceptionHandler (
- IN EFI_EXCEPTION_TYPE ExceptionType,
- IN OUT EFI_SYSTEM_CONTEXT SystemContext
+GdbExceptionHandler (
+ IN EFI_EXCEPTION_TYPE ExceptionType,
+ IN OUT EFI_SYSTEM_CONTEXT SystemContext
)
{
UINT8 GdbExceptionType;
CHAR8 *Ptr;
-
-
+
+
if (ValidateException (ExceptionType, SystemContext) == FALSE) {
return;
}
RemoveSingleStep (SystemContext);
-
+
GdbExceptionType = ConvertEFItoGDBtype (ExceptionType);
GdbSendTSignal (SystemContext, GdbExceptionType);
-
+
for( ; ; ) {
ReceivePacket (gInBuffer, MAX_BUF_SIZE);
-
+
switch (gInBuffer[0]) {
case '?':
GdbSendTSignal (SystemContext, GdbExceptionType);
break;
-
+
case 'c':
- ContinueAtAddress (SystemContext, gInBuffer);
+ ContinueAtAddress (SystemContext, gInBuffer);
return;
case 'g':
ReadGeneralRegisters (SystemContext);
break;
-
+
case 'G':
WriteGeneralRegisters (SystemContext, gInBuffer);
break;
-
+
case 'H':
- //Return "OK" packet since we don't have more than one thread.
+ //Return "OK" packet since we don't have more than one thread.
SendSuccess ();
break;
-
+
case 'm':
ReadFromMemory (gInBuffer);
break;
@@ -1160,7 +1160,7 @@ GdbExceptionHandler ( //
// Still debugging this code. Not used in Darwin
//
- case 'q':
+ case 'q':
// General Query Packets
if (AsciiStrnCmp (gInBuffer, "qSupported", 10) == 0) {
// return what we currently support, we don't parse what gdb suports
@@ -1170,7 +1170,7 @@ GdbExceptionHandler ( // ‘qXfer:libraries:read::offset,length
// gInBuffer[22] is offset string, ++Ptr is length string’
for (Ptr = &gInBuffer[22]; *Ptr != ','; Ptr++);
-
+
// Not sure if multi-radix support is required. Currently only support decimal
QxferLibrary (AsciiStrHexToUintn (&gInBuffer[22]), AsciiStrHexToUintn (++Ptr));
} if (AsciiStrnCmp (gInBuffer, "qOffsets", 10) == 0) {
@@ -1183,18 +1183,18 @@ GdbExceptionHandler ( break;
case 's':
- SingleStep (SystemContext, gInBuffer);
+ SingleStep (SystemContext, gInBuffer);
return;
-
+
case 'z':
RemoveBreakPoint (SystemContext, gInBuffer);
break;
-
+
case 'Z':
InsertBreakPoint (SystemContext, gInBuffer);
break;
-
- default:
+
+ default:
//Send empty packet
SendNotSupported ();
break;
@@ -1204,28 +1204,28 @@ GdbExceptionHandler ( /**
- Periodic callback for GDB. This function is used to catch a ctrl-c or other
+ Periodic callback for GDB. This function is used to catch a ctrl-c or other
break in type command from GDB.
-
- @param SystemContext Register content at time of the call
+
+ @param SystemContext Register content at time of the call
**/
VOID
EFIAPI
-GdbPeriodicCallBack (
- IN OUT EFI_SYSTEM_CONTEXT SystemContext
+GdbPeriodicCallBack (
+ IN OUT EFI_SYSTEM_CONTEXT SystemContext
)
{
//
- // gCtrlCBreakFlag may have been set from a previous F response package
- // and we set the global as we need to process it at a point where we
+ // gCtrlCBreakFlag may have been set from a previous F response package
+ // and we set the global as we need to process it at a point where we
// can update the system context. If we are in the middle of processing
// a F Packet it is not safe to read the GDB serial stream so we need
// to skip it on this check
//
if (!gCtrlCBreakFlag && !gProcessingFPacket) {
//
- // Ctrl-C was not pending so grab any pending characters and see if they
- // are a Ctrl-c (0x03). If so set the Ctrl-C global.
+ // Ctrl-C was not pending so grab any pending characters and see if they
+ // are a Ctrl-c (0x03). If so set the Ctrl-C global.
//
while (TRUE) {
if (!GdbIsCharAvailable ()) {
@@ -1234,7 +1234,7 @@ GdbPeriodicCallBack ( //
break;
}
-
+
if (GdbGetChar () == 0x03) {
gCtrlCBreakFlag = TRUE;
//
@@ -1244,7 +1244,7 @@ GdbPeriodicCallBack ( }
}
}
-
+
if (gCtrlCBreakFlag) {
//
// Update the context to force a single step trap when we exit the GDB
diff --git a/EmbeddedPkg/GdbStub/GdbStub.inf b/EmbeddedPkg/GdbStub/GdbStub.inf index fd4e9d2e1a..ecb5c61b82 100644 --- a/EmbeddedPkg/GdbStub/GdbStub.inf +++ b/EmbeddedPkg/GdbStub/GdbStub.inf @@ -34,39 +34,39 @@ [Sources.ARM]
Arm/Processor.c
-
+
[Sources.IA32]
Ia32/Processor.c
-
+
[Sources.X64]
X64/Processor.c
-
-
+
+
[Packages]
MdePkg/MdePkg.dec
EmbeddedPkg/EmbeddedPkg.dec
-
+
[LibraryClasses]
- BaseLib
- DebugLib
- UefiLib
- UefiDriverEntryPoint
- UefiBootServicesTableLib
- UefiRuntimeServicesTableLib
- BaseMemoryLib
- MemoryAllocationLib
- DevicePathLib
- PcdLib
+ BaseLib
+ DebugLib
+ UefiLib
+ UefiDriverEntryPoint
+ UefiBootServicesTableLib
+ UefiRuntimeServicesTableLib
+ BaseMemoryLib
+ MemoryAllocationLib
+ DevicePathLib
+ PcdLib
GdbSerialLib
PrintLib
CacheMaintenanceLib
-[Protocols]
- gEfiDebugSupportProtocolGuid
- gEfiDebugPortProtocolGuid
- gEfiSerialIoProtocolGuid
-
+[Protocols]
+ gEfiDebugSupportProtocolGuid
+ gEfiDebugPortProtocolGuid
+ gEfiSerialIoProtocolGuid
+
[Guids]
gEfiDebugImageInfoTableGuid
diff --git a/EmbeddedPkg/GdbStub/GdbStubInternal.h b/EmbeddedPkg/GdbStub/GdbStubInternal.h index e84ca3a0ab..659be6b38f 100644 --- a/EmbeddedPkg/GdbStub/GdbStubInternal.h +++ b/EmbeddedPkg/GdbStub/GdbStubInternal.h @@ -37,7 +37,7 @@ extern CONST CHAR8 mHexToStr[];
// maximum size of input and output buffers
-// This value came from the show remote command of the gdb we tested against
+// This value came from the show remote command of the gdb we tested against
#define MAX_BUF_SIZE 2000
// maximum size of address buffer
@@ -59,7 +59,7 @@ extern CONST CHAR8 mHexToStr[]; //
// GDB Signal definitions - generic names for interrupts
//
-#define GDB_SIGILL 4 // Illegal instruction
+#define GDB_SIGILL 4 // Illegal instruction
#define GDB_SIGTRAP 5 // Trace Trap (Breakpoint and SingleStep)
#define GDB_SIGEMT 7 // Emulator Trap
#define GDB_SIGFPE 8 // Floating point exception
@@ -71,9 +71,9 @@ extern CONST CHAR8 mHexToStr[]; // Includes all general GDB Unix like error values
//
#define GDB_EBADMEMADDRBUFSIZE 11 // the buffer that stores memory Address to be read from/written to is not the right size
-#define GDB_EBADMEMLENGBUFSIZE 12 // the buffer that stores Length is not the right size
+#define GDB_EBADMEMLENGBUFSIZE 12 // the buffer that stores Length is not the right size
#define GDB_EBADMEMLENGTH 13 // Length, the given number of bytes to read or write, is not the right size
-#define GDB_EBADMEMDATA 14 // one of the bytes or nibbles of the memory is leess than 0
+#define GDB_EBADMEMDATA 14 // one of the bytes or nibbles of the memory is leess than 0
#define GDB_EBADMEMDATASIZE 15 // the memory data, 'XX..', is too short or too long
#define GDB_EBADBUFSIZE 21 // the buffer created is not the correct size
#define GDB_EINVALIDARG 31 // argument is invalid
@@ -93,7 +93,7 @@ extern CONST CHAR8 mHexToStr[]; //
//Define Register size for different architectures
//
-#if defined (MDE_CPU_IA32)
+#if defined (MDE_CPU_IA32)
#define REG_SIZE 32
#elif defined (MDE_CPU_X64)
#define REG_SIZE 64
@@ -151,7 +151,7 @@ typedef union { UINT32 B1:1; // Breakpoint condition detected
UINT32 B2:1; // Breakpoint condition detected
UINT32 B3:1; // Breakpoint condition detected
- UINT32 Reserved_1:9; // Reserved
+ UINT32 Reserved_1:9; // Reserved
UINT32 BD:1; // Debug register access detected
UINT32 BS:1; // Single step
UINT32 BT:1; // Task switch
@@ -210,7 +210,7 @@ extern EFI_EXCEPTION_TYPE_ENTRY gExceptionType[]; //
// Set TRUE if F Reply package signals a ctrl-c. We can not process the Ctrl-c
-// here we need to wait for the periodic callback to do this.
+// here we need to wait for the periodic callback to do this.
//
extern BOOLEAN gCtrlCBreakFlag;
@@ -229,8 +229,8 @@ extern UINTN gRegisterOffsets[]; /**
Return the number of entries in the gExceptionType[]
-
- @retval UINTN, the number of entries in the gExceptionType[] array.
+
+ @retval UINTN, the number of entries in the gExceptionType[] array.
**/
UINTN
MaxEfiException (
@@ -240,8 +240,8 @@ MaxEfiException ( /**
Return the number of entries in the gRegisters[]
-
- @retval UINTN, the number of entries (registers) in the gRegisters[] array.
+
+ @retval UINTN, the number of entries (registers) in the gRegisters[] array.
**/
UINTN
MaxRegisterCount (
@@ -250,9 +250,9 @@ MaxRegisterCount ( /**
- Check to see if the ISA is supported.
+ Check to see if the ISA is supported.
ISA = Instruction Set Architecture
-
+
@retval TRUE if Isa is supported,
FALSE otherwise.
**/
@@ -264,7 +264,7 @@ CheckIsa ( /**
Send the T signal with the given exception type (in gdb order) and possibly with n:r pairs related to the watchpoints
-
+
@param SystemContext Register content at time of the exception
@param GdbExceptionType GDB exception type
**/
@@ -278,29 +278,29 @@ GdbSendTSignal ( /**
Translates the EFI mapping to GDB mapping
-
+
@param EFIExceptionType EFI Exception that is being processed
@retval UINTN that corresponds to EFIExceptionType's GDB exception type number
**/
UINT8
-ConvertEFItoGDBtype (
+ConvertEFItoGDBtype (
IN EFI_EXCEPTION_TYPE EFIExceptionType
);
/**
- Empties the given buffer
+ Empties the given buffer
@param *Buf pointer to the first element in buffer to be emptied
**/
VOID
-EmptyBuffer (
+EmptyBuffer (
IN CHAR8 *Buf
);
/**
Converts an 8-bit Hex Char into a INTN.
-
+
@param Char - the hex character to be converted into UINTN
@retval a INTN, from 0 to 15, that corressponds to Char
-1 if Char is not a hex character
@@ -315,7 +315,7 @@ HexCharToInt ( Send an error with the given error number after converting to hex.
The error number is put into the buffer in hex. '255' is the biggest errno we can send.
ex: 162 will be sent as A2.
-
+
@param errno the error number that will be sent
**/
VOID
@@ -342,8 +342,8 @@ SendNotSupported ( VOID
);
-/** ‘p n’
- Reads the n-th register's value into an output buffer and sends it as a packet
+/** ‘p n’
+ Reads the n-th register's value into an output buffer and sends it as a packet
@param SystemContext Register content at time of the exception
@param InBuffer This is the input buffer received from gdb server
**/
@@ -354,12 +354,12 @@ ReadNthRegister ( );
-/** ‘g’
- Reads the general registers into an output buffer and sends it as a packet
+/** ‘g’
+ Reads the general registers into an output buffer and sends it as a packet
@param SystemContext Register content at time of the exception
**/
VOID
-ReadGeneralRegisters (
+ReadGeneralRegisters (
IN EFI_SYSTEM_CONTEXT SystemContext
);
@@ -390,10 +390,10 @@ WriteGeneralRegisters ( /** ‘m addr,length ’
- Find the Length of the area to read and the start addres. Finally, pass them to
- another function, TransferFromMemToOutBufAndSend, that will read from that memory space and
+ Find the Length of the area to read and the start addres. Finally, pass them to
+ another function, TransferFromMemToOutBufAndSend, that will read from that memory space and
send it as a packet.
-
+
@param *PacketData Pointer to Payload data for the packet
**/
VOID
@@ -403,10 +403,10 @@ ReadFromMemory ( /** ‘M addr,length :XX...’
- Find the Length of the area in bytes to write and the start addres. Finally, pass them to
+ Find the Length of the area in bytes to write and the start addres. Finally, pass them to
another function, TransferFromInBufToMem, that will write to that memory space the info in
the input buffer.
-
+
@param PacketData Pointer to Payload data for the packet
**/
VOID
@@ -415,11 +415,11 @@ WriteToMemory ( );
-/** ‘c [addr ]’
- Continue. addr is Address to resume. If addr is omitted, resume at current
+/** ‘c [addr ]’
+ Continue. addr is Address to resume. If addr is omitted, resume at current
Address.
-
- @param SystemContext Register content at time of the exception
+
+ @param SystemContext Register content at time of the exception
@param *PacketData Pointer to PacketData
**/
@@ -431,9 +431,9 @@ ContinueAtAddress ( /** ‘s [addr ]’
- Single step. addr is the Address at which to resume. If addr is omitted, resume
+ Single step. addr is the Address at which to resume. If addr is omitted, resume
at same Address.
-
+
@param SystemContext Register content at time of the exception
@param PacketData Pointer to Payload data for the packet
**/
@@ -443,27 +443,27 @@ SingleStep ( IN CHAR8 *PacketData
);
-/**
+/**
Insert Single Step in the SystemContext
-
+
@param SystemContext Register content at time of the exception
**/
VOID
AddSingleStep (
IN EFI_SYSTEM_CONTEXT SystemContext
);
-
-/**
+
+/**
Remove Single Step in the SystemContext
-
+
@param SystemContext Register content at time of the exception
**/
VOID
RemoveSingleStep (
IN EFI_SYSTEM_CONTEXT SystemContext
);
-
-
+
+
/**
‘Z1, [addr], [length]’
‘Z2, [addr], [length]’
@@ -507,36 +507,36 @@ RemoveBreakPoint( /**
Exception Hanldler for GDB. It will be called for all exceptions
registered via the gExceptionType[] array.
-
+
@param ExceptionType Exception that is being processed
- @param SystemContext Register content at time of the exception
-
+ @param SystemContext Register content at time of the exception
+
**/
VOID
EFIAPI
-GdbExceptionHandler (
- IN EFI_EXCEPTION_TYPE ExceptionType,
- IN OUT EFI_SYSTEM_CONTEXT SystemContext
+GdbExceptionHandler (
+ IN EFI_EXCEPTION_TYPE ExceptionType,
+ IN OUT EFI_SYSTEM_CONTEXT SystemContext
);
/**
- Periodic callback for GDB. This function is used to catch a ctrl-c or other
+ Periodic callback for GDB. This function is used to catch a ctrl-c or other
break in type command from GDB.
-
+
@param SystemContext Register content at time of the call
-
+
**/
VOID
EFIAPI
-GdbPeriodicCallBack (
- IN OUT EFI_SYSTEM_CONTEXT SystemContext
+GdbPeriodicCallBack (
+ IN OUT EFI_SYSTEM_CONTEXT SystemContext
);
/**
Make two serail consoles: 1) StdIn and StdOut via GDB. 2) StdErr via GDB.
-
+
These console show up on the remote system running GDB
**/
@@ -549,15 +549,15 @@ GdbInitializeSerialConsole ( /**
Send a GDB Remote Serial Protocol Packet
-
- $PacketData#checksum PacketData is passed in and this function adds the packet prefix '$',
+
+ $PacketData#checksum PacketData is passed in and this function adds the packet prefix '$',
the packet teminating character '#' and the two digit checksum.
-
- If an ack '+' is not sent resend the packet, but timeout eventually so we don't end up
+
+ If an ack '+' is not sent resend the packet, but timeout eventually so we don't end up
in an infinit loop. This is so if you unplug the debugger code just keeps running
- @param PacketData Payload data for the packet
-
+ @param PacketData Payload data for the packet
+
@retval Number of bytes of packet data sent.
**/
@@ -565,21 +565,21 @@ UINTN SendPacket (
IN CHAR8 *PacketData
);
-
+
/**
Receive a GDB Remote Serial Protocol Packet
-
- $PacketData#checksum PacketData is passed in and this function adds the packet prefix '$',
+
+ $PacketData#checksum PacketData is passed in and this function adds the packet prefix '$',
the packet teminating character '#' and the two digit checksum.
-
+
If host re-starts sending a packet without ending the previous packet, only the last valid packet is proccessed.
(In other words, if received packet is '$12345$12345$123456#checksum', only '$123456#checksum' will be processed.)
-
+
If an ack '+' is not sent resend the packet
-
- @param PacketData Payload data for the packet
-
+
+ @param PacketData Payload data for the packet
+
@retval Number of bytes of packet data received.
**/
@@ -588,15 +588,15 @@ ReceivePacket ( OUT CHAR8 *PacketData,
IN UINTN PacketDataSize
);
-
+
/**
- Read data from a FileDescriptor. On success number of bytes read is returned. Zero indicates
+ Read data from a FileDescriptor. On success number of bytes read is returned. Zero indicates
the end of a file. On error -1 is returned. If count is zero, GdbRead returns zero.
@param FileDescriptor Device to talk to.
@param Buffer Buffer to hold Count bytes that were read
- @param Count Number of bytes to transfer.
+ @param Count Number of bytes to transfer.
@retval -1 Error
@retval {other} Number of bytes read.
@@ -608,15 +608,15 @@ GdbRead ( OUT VOID *Buffer,
IN UINTN Count
);
-
+
/**
- Write data to a FileDescriptor. On success number of bytes written is returned. Zero indicates
- nothing was written. On error -1 is returned.
+ Write data to a FileDescriptor. On success number of bytes written is returned. Zero indicates
+ nothing was written. On error -1 is returned.
@param FileDescriptor Device to talk to.
@param Buffer Buffer to hold Count bytes that are to be written
- @param Count Number of bytes to transfer.
+ @param Count Number of bytes to transfer.
@retval -1 Error
@retval {other} Number of bytes written.
@@ -629,13 +629,13 @@ GdbWrite ( IN UINTN Count
);
-UINTN *
+UINTN *
FindPointerToRegister (
IN EFI_SYSTEM_CONTEXT SystemContext,
- IN UINTN RegNumber
+ IN UINTN RegNumber
);
-CHAR8 *
+CHAR8 *
BasicReadRegister (
IN EFI_SYSTEM_CONTEXT SystemContext,
IN UINTN RegNumber,
@@ -662,7 +662,7 @@ BasicWriteRegister ( IN CHAR8 *InBufPtr
);
-VOID
+VOID
PrintReg (
EFI_SYSTEM_CONTEXT SystemContext
);
@@ -678,7 +678,7 @@ ParseBreakpointPacket ( UINTN
GetBreakpointDataAddress (
IN EFI_SYSTEM_CONTEXT SystemContext,
- IN UINTN BreakpointNumber
+ IN UINTN BreakpointNumber
);
UINTN
@@ -689,7 +689,7 @@ GetBreakpointDetected ( BREAK_TYPE
GetBreakpointType (
IN EFI_SYSTEM_CONTEXT SystemContext,
- IN UINTN BreakpointNumber
+ IN UINTN BreakpointNumber
);
UINTN
@@ -739,8 +739,8 @@ ValidateAddress ( BOOLEAN
ValidateException (
- IN EFI_EXCEPTION_TYPE ExceptionType,
- IN OUT EFI_SYSTEM_CONTEXT SystemContext
+ IN EFI_EXCEPTION_TYPE ExceptionType,
+ IN OUT EFI_SYSTEM_CONTEXT SystemContext
);
#endif
diff --git a/EmbeddedPkg/GdbStub/Ia32/Processor.c b/EmbeddedPkg/GdbStub/Ia32/Processor.c index e327b3e6db..a4c4ded0c0 100644 --- a/EmbeddedPkg/GdbStub/Ia32/Processor.c +++ b/EmbeddedPkg/GdbStub/Ia32/Processor.c @@ -2,7 +2,7 @@ Processor specific parts of the GDB stub
Copyright (c) 2008 - 2009, Apple Inc. All rights reserved.<BR>
-
+
This program and the accompanying materials
are licensed and made available under the terms and conditions of the BSD License
which accompanies this distribution. The full text of the license may be found at
@@ -20,7 +20,7 @@ // {EFI mapping, GDB mapping}
//
EFI_EXCEPTION_TYPE_ENTRY gExceptionType[] = {
- { EXCEPT_IA32_DIVIDE_ERROR, GDB_SIGFPE },
+ { EXCEPT_IA32_DIVIDE_ERROR, GDB_SIGFPE },
{ EXCEPT_IA32_DEBUG, GDB_SIGTRAP },
{ EXCEPT_IA32_NMI, GDB_SIGEMT },
{ EXCEPT_IA32_BREAKPOINT, GDB_SIGTRAP },
@@ -62,7 +62,7 @@ UINTN gRegisterOffsets[] = { //Debug only..
-VOID
+VOID
PrintReg (
IN EFI_SYSTEM_CONTEXT SystemContext
)
@@ -80,7 +80,7 @@ PrintReg ( }
//Debug only..
-VOID
+VOID
PrintDRreg (
IN EFI_SYSTEM_CONTEXT SystemContext
)
@@ -96,8 +96,8 @@ PrintDRreg ( /**
Return the number of entries in the gExceptionType[]
-
- @retval UINTN, the number of entries in the gExceptionType[] array.
+
+ @retval UINTN, the number of entries in the gExceptionType[] array.
**/
UINTN
MaxEfiException (
@@ -110,8 +110,8 @@ MaxEfiException ( /**
Return the number of entries in the gRegisters[]
-
- @retval UINTN, the number of entries (registers) in the gRegisters[] array.
+
+ @retval UINTN, the number of entries (registers) in the gRegisters[] array.
**/
UINTN
MaxRegisterCount (
@@ -123,9 +123,9 @@ MaxRegisterCount ( /**
- Check to see if the ISA is supported.
+ Check to see if the ISA is supported.
ISA = Instruction Set Architecture
-
+
@retval TRUE if Isa is supported,
FALSE otherwise.
**/
@@ -142,14 +142,14 @@ CheckIsa ( This takes in the register number and the System Context, and returns a pointer to the RegNumber-th register in gdb ordering
It is, by default, set to find the register pointer of the IA32 member
- @param SystemContext Register content at time of the exception
+ @param SystemContext Register content at time of the exception
@param RegNumber The register to which we want to find a pointer
@retval the pointer to the RegNumber-th pointer
**/
UINTN *
FindPointerToRegister (
IN EFI_SYSTEM_CONTEXT SystemContext,
- IN UINTN RegNumber
+ IN UINTN RegNumber
)
{
UINT8 *TempPtr;
@@ -174,7 +174,7 @@ BasicReadRegister ( )
{
UINTN RegSize;
-
+
RegSize = 0;
while (RegSize < REG_SIZE) {
*OutBufPtr++ = mHexToStr[((*FindPointerToRegister (SystemContext, RegNumber) >> (RegSize+4)) & 0xf)];
@@ -185,8 +185,8 @@ BasicReadRegister ( }
-/** ‘p n’
- Reads the n-th register's value into an output buffer and sends it as a packet
+/** ‘p n’
+ Reads the n-th register's value into an output buffer and sends it as a packet
@param SystemContext Register content at time of the exception
@param InBuffer Pointer to the input buffer received from gdb server
@@ -201,7 +201,7 @@ ReadNthRegister ( UINTN RegNumber;
CHAR8 OutBuffer[9]; // 1 reg=8 hex chars, and the end '\0' (escape seq)
CHAR8 *OutBufPtr; // pointer to the output buffer
-
+
RegNumber = AsciiStrHexToUintn (&InBuffer[1]);
if ((RegNumber < 0) || (RegNumber >= MaxRegisterCount())) {
@@ -217,14 +217,14 @@ ReadNthRegister ( }
-/** ‘g’
- Reads the general registers into an output buffer and sends it as a packet
+/** ‘g’
+ Reads the general registers into an output buffer and sends it as a packet
@param SystemContext Register content at time of the exception
**/
VOID
EFIAPI
-ReadGeneralRegisters (
+ReadGeneralRegisters (
IN EFI_SYSTEM_CONTEXT SystemContext
)
{
@@ -233,7 +233,7 @@ ReadGeneralRegisters ( CHAR8 *OutBufPtr; // pointer to the output buffer
OutBufPtr = OutBuffer;
- for (i = 0 ; i < MaxRegisterCount() ; i++) { // there are only 16 registers to read
+ for (i = 0 ; i < MaxRegisterCount() ; i++) { // there are only 16 registers to read
OutBufPtr = BasicReadRegister (SystemContext, i, OutBufPtr);
}
@@ -260,26 +260,26 @@ BasicWriteRegister ( UINTN RegSize;
UINTN TempValue; // the value transferred from a hex char
UINT32 NewValue; // the new value of the RegNumber-th Register
-
+
NewValue = 0;
RegSize = 0;
while (RegSize < REG_SIZE) {
TempValue = HexCharToInt(*InBufPtr++);
-
+
if (TempValue < 0) {
- SendError (GDB_EBADMEMDATA);
+ SendError (GDB_EBADMEMDATA);
return NULL;
}
NewValue += (TempValue << (RegSize+4));
TempValue = HexCharToInt(*InBufPtr++);
-
+
if (TempValue < 0) {
- SendError (GDB_EBADMEMDATA);
+ SendError (GDB_EBADMEMDATA);
return NULL;
}
-
- NewValue += (TempValue << RegSize);
+
+ NewValue += (TempValue << RegSize);
RegSize = RegSize + 8;
}
*(FindPointerToRegister (SystemContext, RegNumber)) = NewValue;
@@ -304,19 +304,19 @@ WriteNthRegister ( CHAR8 RegNumBuffer[MAX_REG_NUM_BUF_SIZE]; // put the 'n..' part of the message into this array
CHAR8 *RegNumBufPtr;
CHAR8 *InBufPtr; // pointer to the input buffer
-
+
// find the register number to write
InBufPtr = &InBuffer[1];
RegNumBufPtr = RegNumBuffer;
while (*InBufPtr != '=') {
*RegNumBufPtr++ = *InBufPtr++;
- }
+ }
*RegNumBufPtr = '\0';
- RegNumber = AsciiStrHexToUintn (RegNumBuffer);
+ RegNumber = AsciiStrHexToUintn (RegNumBuffer);
// check if this is a valid Register Number
if ((RegNumber < 0) || (RegNumber >= MaxRegisterCount())) {
- SendError (GDB_EINVALIDREGNUM);
+ SendError (GDB_EINVALIDREGNUM);
return;
}
InBufPtr++; // skips the '=' character
@@ -341,16 +341,16 @@ WriteGeneralRegisters ( UINTN i;
CHAR8 *InBufPtr; /// pointer to the input buffer
- // check to see if the buffer is the right size which is
- // 1 (for 'G') + 16 (for 16 registers) * 8 ( for 8 hex chars each) = 129
+ // check to see if the buffer is the right size which is
+ // 1 (for 'G') + 16 (for 16 registers) * 8 ( for 8 hex chars each) = 129
if (AsciiStrLen(InBuffer) != 129) { // 16 regs, 8 hex chars each, and the end '\0' (escape seq)
- //Bad message. Message is not the right length
- SendError (GDB_EBADBUFSIZE);
+ //Bad message. Message is not the right length
+ SendError (GDB_EBADBUFSIZE);
return;
}
InBufPtr = &InBuffer[1];
-
+
// Read the new values for the registers from the input buffer to an array, NewValueArray.
// The values in the array are in the gdb ordering
for (i=0; i < MaxRegisterCount(); i++) { // there are only 16 registers to write
@@ -361,9 +361,9 @@ WriteGeneralRegisters ( }
-/**
+/**
Insert Single Step in the SystemContext
-
+
@param SystemContext Register content at time of the exception
**/
VOID
@@ -374,10 +374,10 @@ AddSingleStep ( SystemContext.SystemContextIa32->Eflags |= TF_BIT; //Setting the TF bit.
}
-
-/**
+
+/**
Remove Single Step in the SystemContext
-
+
@param SystemContext Register content at time of the exception
**/
VOID
@@ -390,11 +390,11 @@ RemoveSingleStep ( -/** ‘c [addr ]’
- Continue. addr is Address to resume. If addr is omitted, resume at current
+/** ‘c [addr ]’
+ Continue. addr is Address to resume. If addr is omitted, resume at current
Address.
-
- @param SystemContext Register content at time of the exception
+
+ @param SystemContext Register content at time of the exception
**/
VOID
EFIAPI
@@ -405,15 +405,15 @@ ContinueAtAddress ( {
if (PacketData[1] != '\0') {
SystemContext.SystemContextIa32->Eip = AsciiStrHexToUintn (&PacketData[1]);
- }
+ }
}
/** ‘s [addr ]’
- Single step. addr is the Address at which to resume. If addr is omitted, resume
+ Single step. addr is the Address at which to resume. If addr is omitted, resume
at same Address.
-
- @param SystemContext Register content at time of the exception
+
+ @param SystemContext Register content at time of the exception
**/
VOID
EFIAPI
@@ -425,7 +425,7 @@ SingleStep ( if (PacketData[1] != '\0') {
SystemContext.SystemContextIa32->Eip = AsciiStrHexToUintn (&PacketData[1]);
}
-
+
AddSingleStep (SystemContext);
}
@@ -469,9 +469,9 @@ GetBreakpointDataAddress ( @param SystemContext Register content at time of the exception
- @retval {1-4} Currently detected breakpoint value
+ @retval {1-4} Currently detected breakpoint value
@retval 0 No breakpoint detected.
-
+
**/
UINTN
GetBreakpointDetected (
@@ -492,7 +492,7 @@ GetBreakpointDetected ( } else if (Dr6.Bits.B3 == 1) {
BreakpointNumber = 4;
} else {
- BreakpointNumber = 0; //No breakpoint detected
+ BreakpointNumber = 0; //No breakpoint detected
}
return BreakpointNumber;
@@ -502,13 +502,13 @@ GetBreakpointDetected ( /**
Returns Breakpoint type (InstructionExecution, DataWrite, DataRead or DataReadWrite)
based on the Breakpoint number
-
+
@param SystemContext Register content at time of the exception
@param BreakpointNumber Breakpoint number
-
+
@retval BREAK_TYPE Breakpoint type value read from register DR7 RWn field
For unknown value, it returns NotSupported.
-
+
**/
BREAK_TYPE
GetBreakpointType (
@@ -522,22 +522,22 @@ GetBreakpointType ( Dr7.UintN = SystemContext.SystemContextIa32->Dr7;
if (BreakpointNumber == 1) {
- Type = (BREAK_TYPE) Dr7.Bits.RW0;
+ Type = (BREAK_TYPE) Dr7.Bits.RW0;
} else if (BreakpointNumber == 2) {
- Type = (BREAK_TYPE) Dr7.Bits.RW1;
+ Type = (BREAK_TYPE) Dr7.Bits.RW1;
} else if (BreakpointNumber == 3) {
- Type = (BREAK_TYPE) Dr7.Bits.RW2;
+ Type = (BREAK_TYPE) Dr7.Bits.RW2;
} else if (BreakpointNumber == 4) {
- Type = (BREAK_TYPE) Dr7.Bits.RW3;
+ Type = (BREAK_TYPE) Dr7.Bits.RW3;
}
return Type;
}
-/**
+/**
Parses Length and returns the length which DR7 LENn field accepts.
- For example: If we receive 1-Byte length then we should return 0.
+ For example: If we receive 1-Byte length then we should return 0.
Zero gets written to DR7 LENn field.
@param Length Breakpoint length in Bytes (1 byte, 2 byte, 4 byte)
@@ -550,7 +550,7 @@ ConvertLengthData ( IN UINTN Length
)
{
- if (Length == 1) { //1-Byte length
+ if (Length == 1) { //1-Byte length
return 0;
} else if (Length == 2) { //2-Byte length
return 1;
@@ -563,8 +563,8 @@ ConvertLengthData ( /**
- Finds the next free debug register. If all the registers are occupied then
- EFI_OUT_OF_RESOURCES is returned.
+ Finds the next free debug register. If all the registers are occupied then
+ EFI_OUT_OF_RESOURCES is returned.
@param SystemContext Register content at time of the exception
@param Register Register value (0 - 3 for the first free debug register)
@@ -601,11 +601,11 @@ FindNextFreeDebugRegister ( /**
Enables the debug register. Writes Address value to appropriate DR0-3 register.
Sets LENn, Gn, RWn bits in DR7 register.
-
+
@param SystemContext Register content at time of the exception
- @param Register Register value (0 - 3)
+ @param Register Register value (0 - 3)
@param Address Breakpoint address value
- @param Type Breakpoint type (Instruction, Data write, Data read
+ @param Type Breakpoint type (Instruction, Data write, Data read
or write etc.)
@retval EFI_STATUS Appropriate status value.
@@ -625,15 +625,15 @@ EnableDebugRegister ( //Convert length data
Length = ConvertLengthData (Length);
- //For Instruction execution, length should be 0
+ //For Instruction execution, length should be 0
//(Ref. Intel reference manual 18.2.4)
if ((Type == 0) && (Length != 0)) {
return EFI_INVALID_PARAMETER;
}
-
+
//Hardware doesn't support ReadWatch (z3 packet) type. GDB can handle
//software breakpoint. We should send empty packet in both these cases.
- if ((Type == (BREAK_TYPE)DataRead) ||
+ if ((Type == (BREAK_TYPE)DataRead) ||
(Type == (BREAK_TYPE)SoftwareBreakpoint)) {
return EFI_UNSUPPORTED;
}
@@ -665,7 +665,7 @@ EnableDebugRegister ( return EFI_INVALID_PARAMETER;
}
- //Update Dr7 with appropriate Gn, RWn and LENn bits
+ //Update Dr7 with appropriate Gn, RWn and LENn bits
SystemContext.SystemContextIa32->Dr7 = Dr7.UintN;
return EFI_SUCCESS;
@@ -681,7 +681,7 @@ EnableDebugRegister ( @param SystemContext Register content at time of the exception
@param Address Breakpoint address value
@param Length Breakpoint length value
- @param Type Breakpoint type (Instruction, Data write,
+ @param Type Breakpoint type (Instruction, Data write,
Data read or write etc.)
@param Register Register value to be returned
@@ -701,7 +701,7 @@ FindMatchingDebugRegister ( //Hardware doesn't support ReadWatch (z3 packet) type. GDB can handle
//software breakpoint. We should send empty packet in both these cases.
- if ((Type == (BREAK_TYPE)DataRead) ||
+ if ((Type == (BREAK_TYPE)DataRead) ||
(Type == (BREAK_TYPE)SoftwareBreakpoint)) {
return EFI_UNSUPPORTED;
}
@@ -711,24 +711,24 @@ FindMatchingDebugRegister ( Dr7.UintN = SystemContext.SystemContextIa32->Dr7;
- if ((Dr7.Bits.G0 == 1) &&
+ if ((Dr7.Bits.G0 == 1) &&
(Dr7.Bits.LEN0 == Length) &&
- (Dr7.Bits.RW0 == Type) &&
+ (Dr7.Bits.RW0 == Type) &&
(Address == SystemContext.SystemContextIa32->Dr0)) {
*Register = 0;
- } else if ((Dr7.Bits.G1 == 1) &&
+ } else if ((Dr7.Bits.G1 == 1) &&
(Dr7.Bits.LEN1 == Length) &&
- (Dr7.Bits.RW1 == Type) &&
+ (Dr7.Bits.RW1 == Type) &&
(Address == SystemContext.SystemContextIa32->Dr1)) {
*Register = 1;
- } else if ((Dr7.Bits.G2 == 1) &&
+ } else if ((Dr7.Bits.G2 == 1) &&
(Dr7.Bits.LEN2 == Length) &&
- (Dr7.Bits.RW2 == Type) &&
+ (Dr7.Bits.RW2 == Type) &&
(Address == SystemContext.SystemContextIa32->Dr2)) {
*Register = 2;
- } else if ((Dr7.Bits.G3 == 1) &&
+ } else if ((Dr7.Bits.G3 == 1) &&
(Dr7.Bits.LEN3 == Length) &&
- (Dr7.Bits.RW3 == Type) &&
+ (Dr7.Bits.RW3 == Type) &&
(Address == SystemContext.SystemContextIa32->Dr3)) {
*Register = 3;
} else {
@@ -752,12 +752,12 @@ FindMatchingDebugRegister ( EFI_STATUS
DisableDebugRegister (
IN EFI_SYSTEM_CONTEXT SystemContext,
- IN UINTN Register
+ IN UINTN Register
)
{
IA32_DR7 Dr7;
UINTN Address = 0;
-
+
//Read DR7 register so appropriate Gn, RWn and LENn bits can be turned off.
Dr7.UintN = SystemContext.SystemContextIa32->Dr7;
@@ -914,15 +914,15 @@ RemoveBreakPoint ( }
switch (Type) {
-
+
case 0: //Software breakpoint
BreakType = SoftwareBreakpoint;
break;
-
+
case 1: //Hardware breakpoint
BreakType = InstructionExecution;
break;
-
+
case 2: //Write watchpoint
BreakType = DataWrite;
break;
@@ -984,8 +984,8 @@ ValidateAddress ( BOOLEAN
ValidateException (
- IN EFI_EXCEPTION_TYPE ExceptionType,
- IN OUT EFI_SYSTEM_CONTEXT SystemContext
+ IN EFI_EXCEPTION_TYPE ExceptionType,
+ IN OUT EFI_SYSTEM_CONTEXT SystemContext
)
{
return TRUE;
diff --git a/EmbeddedPkg/GdbStub/SerialIo.c b/EmbeddedPkg/GdbStub/SerialIo.c index ed06268443..32ceaf1233 100644 --- a/EmbeddedPkg/GdbStub/SerialIo.c +++ b/EmbeddedPkg/GdbStub/SerialIo.c @@ -1,13 +1,13 @@ /** @file
- Serial IO Abstraction for GDB stub. This allows an EFI consoles that shows up on the system
+ Serial IO Abstraction for GDB stub. This allows an EFI consoles that shows up on the system
running GDB. One consle for error information and another console for user input/output.
-
- Basic packet format is $packet-data#checksum. So every comand has 4 bytes of overhead: $,
- #, 0, 0. The 0 and 0 are the ascii characters for the checksum.
-
+
+ Basic packet format is $packet-data#checksum. So every comand has 4 bytes of overhead: $,
+ #, 0, 0. The 0 and 0 are the ascii characters for the checksum.
+
Copyright (c) 2008 - 2009, Apple Inc. All rights reserved.<BR>
-
+
This program and the accompanying materials
are licensed and made available under the terms and conditions of the BSD License
which accompanies this distribution. The full text of the license may be found at
@@ -22,7 +22,7 @@ //
// Set TRUE if F Reply package signals a ctrl-c. We can not process the Ctrl-c
-// here we need to wait for the periodic callback to do this.
+// here we need to wait for the periodic callback to do this.
//
BOOLEAN gCtrlCBreakFlag = FALSE;
@@ -34,9 +34,9 @@ BOOLEAN gCtrlCBreakFlag = FALSE; BOOLEAN gProcessingFPacket = FALSE;
/**
- Process a control-C break message.
-
- Currently a place holder, remove the ASSERT when it gets implemented.
+ Process a control-C break message.
+
+ Currently a place holder, remove the ASSERT when it gets implemented.
@param ErrNo Error infomration from the F reply packet or other source
@@ -62,55 +62,55 @@ GdbCtrlCBreakMessage ( @param Packet Packet to parse like an F reply packet
@param ErrNo Buffer to hold Count bytes that were read
- @retval -1 Error, not a valid F reply packet
- @retval other Return the return code from the F reply packet
+ @retval -1 Error, not a valid F reply packet
+ @retval other Return the return code from the F reply packet
**/
INTN
GdbParseFReplyPacket (
IN CHAR8 *Packet,
- OUT UINTN *ErrNo
+ OUT UINTN *ErrNo
)
{
INTN RetCode;
-
+
if (Packet[0] != 'F') {
// A valid responce would be an F packet
return -1;
}
-
+
RetCode = AsciiStrHexToUintn (&Packet[1]);
-
- // Find 1st comma
- for (;*Packet != '\0' && *Packet != ','; Packet++);
+
+ // Find 1st comma
+ for (;*Packet != '\0' && *Packet != ','; Packet++);
if (*Packet == '\0') {
*ErrNo = 0;
return RetCode;
}
-
+
*ErrNo = AsciiStrHexToUintn (++Packet);
- // Find 2nd comma
- for (;*Packet != '\0' && *Packet != ','; Packet++);
+ // Find 2nd comma
+ for (;*Packet != '\0' && *Packet != ','; Packet++);
if (*Packet == '\0') {
return RetCode;
}
-
+
if (*(++Packet) == 'C') {
- GdbCtrlCBreakMessage (*ErrNo);
+ GdbCtrlCBreakMessage (*ErrNo);
}
-
+
return RetCode;
}
/**
- Read data from a FileDescriptor. On success number of bytes read is returned. Zero indicates
+ Read data from a FileDescriptor. On success number of bytes read is returned. Zero indicates
the end of a file. On error -1 is returned. If count is zero, GdbRead returns zero.
@param FileDescriptor Device to talk to.
@param Buffer Buffer to hold Count bytes that were read
- @param Count Number of bytes to transfer.
+ @param Count Number of bytes to transfer.
@retval -1 Error
@retval {other} Number of bytes read.
@@ -128,19 +128,19 @@ GdbRead ( INTN RetCode;
UINTN ErrNo;
BOOLEAN ReceiveDone = FALSE;
-
+
// Send:
// "Fread,XX,YYYYYYYY,XX
//
// XX - FileDescriptor in ASCII
- // YYYYYYYY - Buffer address in ASCII
+ // YYYYYYYY - Buffer address in ASCII
// XX - Count in ASCII
// SS - check sum
//
Size = AsciiSPrint (Packet, sizeof (Packet), "Fread,%x,%x,%x", FileDescriptor, Buffer, Count);
// Packet array is too small if you got this ASSERT
ASSERT (Size < sizeof (Packet));
-
+
gProcessingFPacket = TRUE;
SendPacket (Packet);
Print ((CHAR16 *)L"Packet sent..\n");
@@ -175,25 +175,25 @@ GdbRead ( RetCode = GdbParseFReplyPacket (Packet, &ErrNo);
Print ((CHAR16 *)L"RetCode: %x..ErrNo: %x..\n", RetCode, ErrNo);
-
+
if (ErrNo > 0) {
//Send error to the host if there is any.
SendError ((UINT8)ErrNo);
}
-
+
gProcessingFPacket = FALSE;
return RetCode;
-}
-
+}
+
/**
- Write data to a FileDescriptor. On success number of bytes written is returned. Zero indicates
- nothing was written. On error -1 is returned.
+ Write data to a FileDescriptor. On success number of bytes written is returned. Zero indicates
+ nothing was written. On error -1 is returned.
@param FileDescriptor Device to talk to.
@param Buffer Buffer to hold Count bytes that are to be written
- @param Count Number of bytes to transfer.
+ @param Count Number of bytes to transfer.
@retval -1 Error
@retval {other} Number of bytes written.
@@ -216,14 +216,14 @@ GdbWrite ( // #Fwrite,XX,YYYYYYYY,XX$SS
//
// XX - FileDescriptor in ASCII
- // YYYYYYYY - Buffer address in ASCII
+ // YYYYYYYY - Buffer address in ASCII
// XX - Count in ASCII
// SS - check sum
//
Size = AsciiSPrint (Packet, sizeof (Packet), "Fwrite,%x,%x,%x", FileDescriptor, Buffer, Count);
// Packet array is too small if you got this ASSERT
ASSERT (Size < sizeof (Packet));
-
+
SendPacket (Packet);
Print ((CHAR16 *)L"Packet sent..\n");
@@ -235,7 +235,7 @@ GdbWrite ( // Process GDB commands
switch (Packet[0]) {
//Read memory command.
- //m addr,length.
+ //m addr,length.
case 'm':
ReadFromMemory (Packet);
break;
@@ -243,13 +243,13 @@ GdbWrite ( //Fretcode, errno, Ctrl-C flag
//retcode - Count read
case 'F':
- //Once target receives F reply packet that means the previous
+ //Once target receives F reply packet that means the previous
//transactions are finished.
ReceiveDone = TRUE;
break;
-
+
//Send empty buffer
- default :
+ default :
SendNotSupported();
break;
}
@@ -262,7 +262,7 @@ GdbWrite ( if (ErrNo > 0) {
SendError((UINT8)ErrNo);
}
-
+
return RetCode;
}
@@ -271,7 +271,7 @@ GdbWrite ( Reset the serial device.
@param This Protocol instance pointer.
-
+
@retval EFI_SUCCESS The device was reset.
@retval EFI_DEVICE_ERROR The serial device could not be reset.
@@ -287,7 +287,7 @@ GdbSerialReset ( /**
- Sets the baud rate, receive FIFO depth, transmit/receice time out, parity,
+ Sets the baud rate, receive FIFO depth, transmit/receice time out, parity,
data buts, and stop bits on a serial device.
@param This Protocol instance pointer.
@@ -355,7 +355,7 @@ GdbSerialSetControl ( @param This Protocol instance pointer.
@param Control A pointer to return the current Control signals from the serial device.
-
+
@retval EFI_SUCCESS The control bits were read from the serial device.
@retval EFI_DEVICE_ERROR The serial device is not functioning correctly.
@@ -396,16 +396,16 @@ GdbSerialWrite ( UINTN Return;
SerialDev = GDB_SERIAL_DEV_FROM_THIS (This);
-
+
Return = GdbWrite (SerialDev->OutFileDescriptor, Buffer, *BufferSize);
if (Return == (UINTN)-1) {
return EFI_DEVICE_ERROR;
}
-
+
if (Return != *BufferSize) {
*BufferSize = Return;
}
-
+
return EFI_SUCCESS;
}
@@ -435,27 +435,27 @@ GdbSerialRead ( UINTN Return;
SerialDev = GDB_SERIAL_DEV_FROM_THIS (This);
-
+
Return = GdbRead (SerialDev->InFileDescriptor, Buffer, *BufferSize);
if (Return == (UINTN)-1) {
return EFI_DEVICE_ERROR;
}
-
+
if (Return != *BufferSize) {
*BufferSize = Return;
}
-
+
return EFI_SUCCESS;
}
-//
+//
// Template used to initailize the GDB Serial IO protocols
//
GDB_SERIAL_DEV gdbSerialDevTemplate = {
GDB_SERIAL_DEV_SIGNATURE,
NULL,
-
+
{ // SerialIo
SERIAL_IO_INTERFACE_REVISION,
GdbSerialReset,
@@ -504,7 +504,7 @@ GDB_SERIAL_DEV gdbSerialDevTemplate = { /**
Make two serial consoles: 1) StdIn and StdOut via GDB. 2) StdErr via GDB.
-
+
These console show up on the remote system running GDB
**/
@@ -520,21 +520,21 @@ GdbInitializeSerialConsole ( // Use the template to make a copy of the Serial Console private data structure.
StdOutSerialDev = AllocateCopyPool (sizeof (GDB_SERIAL_DEV), &gdbSerialDevTemplate);
ASSERT (StdOutSerialDev != NULL);
-
+
// Fixup pointer after the copy
StdOutSerialDev->SerialIo.Mode = &StdOutSerialDev->SerialMode;
-
+
StdErrSerialDev = AllocateCopyPool (sizeof (GDB_SERIAL_DEV), &gdbSerialDevTemplate);
ASSERT (StdErrSerialDev != NULL);
// Fixup pointer and modify stuff that is different for StdError
- StdErrSerialDev->SerialIo.Mode = &StdErrSerialDev->SerialMode;
+ StdErrSerialDev->SerialIo.Mode = &StdErrSerialDev->SerialMode;
StdErrSerialDev->DevicePath.Index = 1;
StdErrSerialDev->OutFileDescriptor = GDB_STDERR;
-
+
// Make a new handle with Serial IO protocol and its device path on it.
Status = gBS->InstallMultipleProtocolInterfaces (
- &StdOutSerialDev->Handle,
+ &StdOutSerialDev->Handle,
&gEfiSerialIoProtocolGuid, &StdOutSerialDev->SerialIo,
&gEfiDevicePathProtocolGuid, &StdOutSerialDev->DevicePath,
NULL
@@ -543,7 +543,7 @@ GdbInitializeSerialConsole ( // Make a new handle with Serial IO protocol and its device path on it.
Status = gBS->InstallMultipleProtocolInterfaces (
- &StdErrSerialDev->Handle,
+ &StdErrSerialDev->Handle,
&gEfiSerialIoProtocolGuid, &StdErrSerialDev->SerialIo,
&gEfiDevicePathProtocolGuid, &StdErrSerialDev->DevicePath,
NULL
diff --git a/EmbeddedPkg/GdbStub/X64/Processor.c b/EmbeddedPkg/GdbStub/X64/Processor.c index 5d13c937ee..8a39c4828f 100644 --- a/EmbeddedPkg/GdbStub/X64/Processor.c +++ b/EmbeddedPkg/GdbStub/X64/Processor.c @@ -2,7 +2,7 @@ Processor specific parts of the GDB stub
Copyright (c) 2008 - 2009, Apple Inc. All rights reserved.<BR>
-
+
This program and the accompanying materials
are licensed and made available under the terms and conditions of the BSD License
which accompanies this distribution. The full text of the license may be found at
@@ -19,7 +19,7 @@ // Array of exception types that need to be hooked by the debugger
//
EFI_EXCEPTION_TYPE_ENTRY gExceptionType[] = {
- { EXCEPT_X64_DIVIDE_ERROR, GDB_SIGFPE },
+ { EXCEPT_X64_DIVIDE_ERROR, GDB_SIGFPE },
{ EXCEPT_X64_DEBUG, GDB_SIGTRAP },
{ EXCEPT_X64_NMI, GDB_SIGEMT },
{ EXCEPT_X64_BREAKPOINT, GDB_SIGTRAP },
@@ -37,7 +37,7 @@ EFI_EXCEPTION_TYPE_ENTRY gExceptionType[] = { // The offsets of registers SystemContextX64.
-// The fields in the array are in the gdb ordering.
+// The fields in the array are in the gdb ordering.
// HAVE TO DOUBLE-CHECK THE ORDER of the 24 regs
//
UINTN gRegisterOffsets[] = {
@@ -70,8 +70,8 @@ UINTN gRegisterOffsets[] = { /**
Return the number of entries in the gExceptionType[]
-
- @retval UINTN, the number of entries in the gExceptionType[] array.
+
+ @retval UINTN, the number of entries in the gExceptionType[] array.
**/
UINTN
MaxEfiException (
@@ -84,8 +84,8 @@ MaxEfiException ( /**
Return the number of entries in the gRegisters[]
-
- @retval UINTN, the number of entries (registers) in the gRegisters[] array.
+
+ @retval UINTN, the number of entries (registers) in the gRegisters[] array.
**/
UINTN
MaxRegisterCount (
@@ -95,9 +95,9 @@ MaxRegisterCount ( return sizeof (gRegisterOffsets)/sizeof (UINTN);
}
-
+
/**
- Check to see if the ISA is supported.
+ Check to see if the ISA is supported.
ISA = Instruction Set Architecture
@retval TRUE if Isa is supported
@@ -114,14 +114,14 @@ CheckIsa ( /**
This takes in the register number and the System Context, and returns a pointer to the RegNumber-th register in gdb ordering
It is, by default, set to find the register pointer of the X64 member
- @param SystemContext Register content at time of the exception
+ @param SystemContext Register content at time of the exception
@param RegNumber The register to which we want to find a pointer
@retval the pointer to the RegNumber-th pointer
**/
UINTN *
FindPointerToRegister(
IN EFI_SYSTEM_CONTEXT SystemContext,
- IN UINTN RegNumber
+ IN UINTN RegNumber
)
{
UINT8 *TempPtr;
@@ -145,7 +145,7 @@ BasicReadRegister ( )
{
UINTN RegSize;
-
+
RegSize = 0;
while (RegSize < 64) {
*OutBufPtr++ = mHexToStr[((*FindPointerToRegister(SystemContext, RegNumber) >> (RegSize+4)) & 0xf)];
@@ -156,8 +156,8 @@ BasicReadRegister ( }
-/** ‘p n’
- Reads the n-th register's value into an output buffer and sends it as a packet
+/** ‘p n’
+ Reads the n-th register's value into an output buffer and sends it as a packet
@param SystemContext Register content at time of the exception
@param InBuffer Pointer to the input buffer received from gdb server
**/
@@ -170,42 +170,42 @@ ReadNthRegister ( UINTN RegNumber;
CHAR8 OutBuffer[17]; // 1 reg=16 hex chars, and the end '\0' (escape seq)
CHAR8 *OutBufPtr; // pointer to the output buffer
-
+
RegNumber = AsciiStrHexToUintn (&InBuffer[1]);
-
+
if ((RegNumber < 0) || (RegNumber >= MaxRegisterCount())) {
- SendError (GDB_EINVALIDREGNUM);
+ SendError (GDB_EINVALIDREGNUM);
return;
}
-
+
OutBufPtr = OutBuffer;
OutBufPtr = BasicReadRegister(SystemContext, RegNumber, OutBufPtr);
-
+
*OutBufPtr = '\0'; // the end of the buffer
SendPacket (OutBuffer);
}
-/** ‘g’
- Reads the general registers into an output buffer and sends it as a packet
+/** ‘g’
+ Reads the general registers into an output buffer and sends it as a packet
@param SystemContext Register content at time of the exception
**/
VOID
EFIAPI
-ReadGeneralRegisters (
+ReadGeneralRegisters (
IN EFI_SYSTEM_CONTEXT SystemContext
)
{
UINTN i;
CHAR8 OutBuffer[385]; // 24 regs, 16 hex chars each, and the end '\0' (escape seq)
CHAR8 *OutBufPtr; // pointer to the output buffer
-
+
OutBufPtr = OutBuffer;
- for(i = 0 ; i < MaxRegisterCount() ; i++) { // there are only 24 registers to read
+ for(i = 0 ; i < MaxRegisterCount() ; i++) { // there are only 24 registers to read
OutBufPtr = BasicReadRegister(SystemContext, i, OutBufPtr);
}
-
+
*OutBufPtr = '\0'; // the end of the buffer
SendPacket (OutBuffer);
}
@@ -229,26 +229,26 @@ BasicWriteRegister ( UINTN RegSize;
UINTN TempValue; // the value transferred from a hex char
UINT64 NewValue; // the new value of the RegNumber-th Register
-
+
NewValue = 0;
RegSize = 0;
while (RegSize < 64) {
TempValue = HexCharToInt(*InBufPtr++);
-
+
if (TempValue < 0) {
- SendError (GDB_EBADMEMDATA);
+ SendError (GDB_EBADMEMDATA);
return NULL;
}
-
+
NewValue += (TempValue << (RegSize+4));
TempValue = HexCharToInt(*InBufPtr++);
-
+
if (TempValue < 0) {
- SendError (GDB_EBADMEMDATA);
+ SendError (GDB_EBADMEMDATA);
return NULL;
}
-
- NewValue += (TempValue << RegSize);
+
+ NewValue += (TempValue << RegSize);
RegSize = RegSize + 8;
}
*(FindPointerToRegister(SystemContext, RegNumber)) = NewValue;
@@ -273,19 +273,19 @@ WriteNthRegister ( CHAR8 RegNumBuffer[MAX_REG_NUM_BUF_SIZE]; // put the 'n..' part of the message into this array
CHAR8 *RegNumBufPtr;
CHAR8 *InBufPtr; // pointer to the input buffer
-
+
// find the register number to write
InBufPtr = &InBuffer[1];
RegNumBufPtr = RegNumBuffer;
while (*InBufPtr != '=') {
*RegNumBufPtr++ = *InBufPtr++;
- }
+ }
*RegNumBufPtr = '\0';
- RegNumber = AsciiStrHexToUintn (RegNumBuffer);
+ RegNumber = AsciiStrHexToUintn (RegNumBuffer);
// check if this is a valid Register Number
if ((RegNumber < 0) || (RegNumber >= MaxRegisterCount())) {
- SendError (GDB_EINVALIDREGNUM);
+ SendError (GDB_EINVALIDREGNUM);
return;
}
InBufPtr++; // skips the '=' character
@@ -309,30 +309,30 @@ WriteGeneralRegisters ( {
UINTN i;
CHAR8 *InBufPtr; /// pointer to the input buffer
-
- // check to see if the buffer is the right size which is
- // 1 (for 'G') + 16 (for 16 registers) * 8 ( for 8 hex chars each) = 385
+
+ // check to see if the buffer is the right size which is
+ // 1 (for 'G') + 16 (for 16 registers) * 8 ( for 8 hex chars each) = 385
if (AsciiStrLen(InBuffer) != 385) { // 24 regs, 16 hex chars each, and the end '\0' (escape seq)
- //Bad message. Message is not the right length
- SendError (GDB_EBADBUFSIZE);
+ //Bad message. Message is not the right length
+ SendError (GDB_EBADBUFSIZE);
return;
}
-
+
InBufPtr = &InBuffer[1];
-
+
// Read the new values for the registers from the input buffer to an array, NewValueArray.
// The values in the array are in the gdb ordering
for(i=0; i < MaxRegisterCount(); i++) { // there are only 16 registers to write
InBufPtr = BasicWriteRegister(SystemContext, i, InBufPtr);
}
-
+
SendSuccess();
}
- /**
+ /**
Insert Single Step in the SystemContext
-
+
@param SystemContext Register content at time of the exception
**/
VOID
@@ -343,11 +343,11 @@ AddSingleStep ( SystemContext.SystemContextX64->Rflags |= TF_BIT; //Setting the TF bit.
}
-
-
-/**
+
+
+/**
Remove Single Step in the SystemContext
-
+
@param SystemContext Register content at time of the exception
**/
VOID
@@ -360,11 +360,11 @@ RemoveSingleStep ( -/** ‘c [addr ]’
- Continue. addr is Address to resume. If addr is omitted, resume at current
+/** ‘c [addr ]’
+ Continue. addr is Address to resume. If addr is omitted, resume at current
Address.
-
- @param SystemContext Register content at time of the exception
+
+ @param SystemContext Register content at time of the exception
**/
VOID
EFIAPI
@@ -375,15 +375,15 @@ ContinueAtAddress ( {
if (PacketData[1] != '\0') {
SystemContext.SystemContextX64->Rip = AsciiStrHexToUintn(&PacketData[1]);
- }
+ }
}
/** ‘s [addr ]’
- Single step. addr is the Address at which to resume. If addr is omitted, resume
+ Single step. addr is the Address at which to resume. If addr is omitted, resume
at same Address.
-
- @param SystemContext Register content at time of the exception
+
+ @param SystemContext Register content at time of the exception
**/
VOID
EFIAPI
@@ -395,19 +395,19 @@ SingleStep ( if (PacketData[1] != '\0') {
SystemContext.SystemContextX64->Rip = AsciiStrHexToUintn (&PacketData[1]);
}
-
+
AddSingleStep (SystemContext);
}
/**
- Returns breakpoint data address from DR0-DR3 based on the input breakpoint
+ Returns breakpoint data address from DR0-DR3 based on the input breakpoint
number
@param SystemContext Register content at time of the exception
@param BreakpointNumber Breakpoint number
- @retval Address Data address from DR0-DR3 based on the
+ @retval Address Data address from DR0-DR3 based on the
breakpoint number.
**/
@@ -435,7 +435,7 @@ GetBreakpointDataAddress ( }
/**
- Returns currently detected breakpoint value based on the register
+ Returns currently detected breakpoint value based on the register
DR6 B0-B3 field.
If no breakpoint is detected then it returns 0.
@@ -471,13 +471,13 @@ GetBreakpointDetected ( }
/**
- Returns Breakpoint type (InstructionExecution, DataWrite, DataRead
+ Returns Breakpoint type (InstructionExecution, DataWrite, DataRead
or DataReadWrite) based on the Breakpoint number
@param SystemContext Register content at time of the exception
@param BreakpointNumber Breakpoint number
- @retval BREAK_TYPE Breakpoint type value read from register DR7 RWn
+ @retval BREAK_TYPE Breakpoint type value read from register DR7 RWn
field. For unknown value, it returns NotSupported.
**/
@@ -506,9 +506,9 @@ GetBreakpointType ( }
-/**
+/**
Parses Length and returns the length which DR7 LENn field accepts.
- For example: If we receive 1-Byte length then we should return 0.
+ For example: If we receive 1-Byte length then we should return 0.
Zero gets written to DR7 LENn field.
@param Length Breakpoint length in Bytes (1 byte, 2 byte, 4 byte)
@@ -521,7 +521,7 @@ ConvertLengthData ( IN UINTN Length
)
{
- if (Length == 1) { //1-Byte length
+ if (Length == 1) { //1-Byte length
return 0;
} else if (Length == 2) { //2-Byte length
return 1;
@@ -576,7 +576,7 @@ FindNextFreeDebugRegister ( @param SystemContext Register content at time of the exception
@param Register Register value (0 - 3)
@param Address Breakpoint address value
- @param Type Breakpoint type (Instruction, Data write,
+ @param Type Breakpoint type (Instruction, Data write,
Data read or write etc.)
@retval EFI_STATUS Appropriate status value.
@@ -596,7 +596,7 @@ EnableDebugRegister ( //Convert length data
Length = ConvertLengthData (Length);
- //For Instruction execution, length should be 0
+ //For Instruction execution, length should be 0
//(Ref. Intel reference manual 18.2.4)
if ((Type == 0) && (Length != 0)) {
return EFI_INVALID_PARAMETER;
@@ -604,7 +604,7 @@ EnableDebugRegister ( //Hardware doesn't support ReadWatch (z3 packet) type. GDB can handle
//software breakpoint. We should send empty packet in both these cases.
- if ((Type == (BREAK_TYPE)DataRead) ||
+ if ((Type == (BREAK_TYPE)DataRead) ||
(Type == (BREAK_TYPE)SoftwareBreakpoint)) {
return EFI_UNSUPPORTED;
}
@@ -643,14 +643,14 @@ EnableDebugRegister ( }
-/**
- Returns register number 0 - 3 for the maching debug register.
- This function compares incoming Address, Type, Length and
+/**
+ Returns register number 0 - 3 for the maching debug register.
+ This function compares incoming Address, Type, Length and
if there is a match then it returns the appropriate register number.
In case of mismatch, function returns EFI_NOT_FOUND message.
@param SystemContext Register content at time of the exception
- @param Address Breakpoint address value
+ @param Address Breakpoint address value
@param Length Breakpoint length value
@param Type Breakpoint type (Instruction, Data write, Data read
or write etc.)
@@ -672,7 +672,7 @@ FindMatchingDebugRegister ( //Hardware doesn't support ReadWatch (z3 packet) type. GDB can handle
//software breakpoint. We should send empty packet in both these cases.
- if ((Type == (BREAK_TYPE)DataRead) ||
+ if ((Type == (BREAK_TYPE)DataRead) ||
(Type == (BREAK_TYPE)SoftwareBreakpoint)) {
return EFI_UNSUPPORTED;
}
@@ -682,24 +682,24 @@ FindMatchingDebugRegister ( Dr7.UintN = SystemContext.SystemContextIa32->Dr7;
- if ((Dr7.Bits.G0 == 1) &&
+ if ((Dr7.Bits.G0 == 1) &&
(Dr7.Bits.LEN0 == Length) &&
- (Dr7.Bits.RW0 == Type) &&
+ (Dr7.Bits.RW0 == Type) &&
(Address == SystemContext.SystemContextIa32->Dr0)) {
*Register = 0;
- } else if ((Dr7.Bits.G1 == 1) &&
+ } else if ((Dr7.Bits.G1 == 1) &&
(Dr7.Bits.LEN1 == Length) &&
- (Dr7.Bits.RW1 == Type) &&
+ (Dr7.Bits.RW1 == Type) &&
(Address == SystemContext.SystemContextIa32->Dr1)) {
*Register = 1;
- } else if ((Dr7.Bits.G2 == 1) &&
+ } else if ((Dr7.Bits.G2 == 1) &&
(Dr7.Bits.LEN2 == Length) &&
- (Dr7.Bits.RW2 == Type) &&
+ (Dr7.Bits.RW2 == Type) &&
(Address == SystemContext.SystemContextIa32->Dr2)) {
*Register = 2;
- } else if ((Dr7.Bits.G3 == 1) &&
+ } else if ((Dr7.Bits.G3 == 1) &&
(Dr7.Bits.LEN3 == Length) &&
- (Dr7.Bits.RW3 == Type) &&
+ (Dr7.Bits.RW3 == Type) &&
(Address == SystemContext.SystemContextIa32->Dr3)) {
*Register = 3;
} else {
@@ -884,15 +884,15 @@ RemoveBreakPoint ( }
switch (Type) {
-
+
case 0: //Software breakpoint
BreakType = SoftwareBreakpoint;
break;
-
+
case 1: //Hardware breakpoint
BreakType = InstructionExecution;
break;
-
+
case 2: //Write watchpoint
BreakType = DataWrite;
break;
@@ -954,8 +954,8 @@ ValidateAddress ( BOOLEAN
ValidateException (
- IN EFI_EXCEPTION_TYPE ExceptionType,
- IN OUT EFI_SYSTEM_CONTEXT SystemContext
+ IN EFI_EXCEPTION_TYPE ExceptionType,
+ IN OUT EFI_SYSTEM_CONTEXT SystemContext
)
{
return TRUE;
diff --git a/EmbeddedPkg/Include/Guid/ExtractSection.h b/EmbeddedPkg/Include/Guid/ExtractSection.h index 6f0e0efe07..f471e876a1 100644 --- a/EmbeddedPkg/Include/Guid/ExtractSection.h +++ b/EmbeddedPkg/Include/Guid/ExtractSection.h @@ -28,7 +28,7 @@ typedef struct { } EXTRACT_SECTION_DATA;
typedef struct {
- EFI_HOB_GUID_TYPE Hob;
+ EFI_HOB_GUID_TYPE Hob;
EXTRACT_SECTION_DATA Data;
} EXTRACT_SECTION_HOB;
diff --git a/EmbeddedPkg/Include/Library/DebugAgentTimerLib.h b/EmbeddedPkg/Include/Library/DebugAgentTimerLib.h index 1b9769509b..0a5e5d491e 100755 --- a/EmbeddedPkg/Include/Library/DebugAgentTimerLib.h +++ b/EmbeddedPkg/Include/Library/DebugAgentTimerLib.h @@ -1,10 +1,10 @@ /** @file
- Platform specific Debug Agent abstraction for timer used by the agent.
+ Platform specific Debug Agent abstraction for timer used by the agent.
The timer is used by the debugger to break into a running program.
Copyright (c) 2008 - 2010, Apple Inc. All rights reserved.<BR>
-
+
This program and the accompanying materials
are licensed and made available under the terms and conditions of the BSD License
which accompanies this distribution. The full text of the license may be found at
@@ -31,33 +31,32 @@ EFIAPI DebugAgentTimerIntialize (
VOID
);
-
+
/**
Set the period for the debug agent timer. Zero means disable the timer.
@param[in] TimerPeriodMilliseconds Frequency of the debug agent timer.
-**/
+**/
VOID
EFIAPI
DebugAgentTimerSetPeriod (
IN UINT32 TimerPeriodMilliseconds
);
-
+
/**
- Perform End Of Interrupt for the debug agent timer. This is called in the
- interrupt handler after the interrupt has been processed.
+ Perform End Of Interrupt for the debug agent timer. This is called in the
+ interrupt handler after the interrupt has been processed.
-**/
+**/
VOID
EFIAPI
DebugAgentTimerEndOfInterrupt (
VOID
);
-
+
#endif
-
\ No newline at end of file diff --git a/EmbeddedPkg/Include/Library/DmaLib.h b/EmbeddedPkg/Include/Library/DmaLib.h index 6e876dd26a..3814291c28 100755 --- a/EmbeddedPkg/Include/Library/DmaLib.h +++ b/EmbeddedPkg/Include/Library/DmaLib.h @@ -1,13 +1,13 @@ /** @file
DMA abstraction library APIs. Based on UEFI PCI IO protocol DMA abstractions.
- At some point these functions will probably end up in a non PCI protocol
+ At some point these functions will probably end up in a non PCI protocol
for embedded systems.
DMA Bus Master Read Operation:
- Call DmaMap() for MapOperationBusMasterRead.
- Program the DMA Bus Master with the DeviceAddress returned by DmaMap().
- Start the DMA Bus Master.
- Wait for DMA Bus Master to complete the read operation.
+ Call DmaMap() for MapOperationBusMasterRead.
+ Program the DMA Bus Master with the DeviceAddress returned by DmaMap().
+ Start the DMA Bus Master.
+ Wait for DMA Bus Master to complete the read operation.
Call DmaUnmap().
DMA Bus Master Write Operation:
@@ -18,11 +18,11 @@ Call DmaUnmap().
DMA Bus Master Common Buffer Operation:
- Call DmaAllocateBuffer() to allocate a common buffer.
- Call DmaMap() for MapOperationBusMasterCommonBuffer.
- Program the DMA Bus Master with the DeviceAddress returned by DmaMap().
- The common buffer can now be accessed equally by the processor and the DMA bus master.
- Call DmaUnmap().
+ Call DmaAllocateBuffer() to allocate a common buffer.
+ Call DmaMap() for MapOperationBusMasterCommonBuffer.
+ Program the DMA Bus Master with the DeviceAddress returned by DmaMap().
+ The common buffer can now be accessed equally by the processor and the DMA bus master.
+ Call DmaUnmap().
Call DmaFreeBuffer().
Copyright (c) 2008 - 2010, Apple Inc. All rights reserved.<BR>
@@ -60,25 +60,25 @@ typedef enum { -/**
+/**
Provides the DMA controller-specific addresses needed to access system memory.
-
+
Operation is relative to the DMA bus master.
-
+
@param Operation Indicates if the bus master is going to read or write to system memory.
@param HostAddress The system memory address to map to the DMA controller.
@param NumberOfBytes On input the number of bytes to map. On output the number of bytes
- that were mapped.
+ that were mapped.
@param DeviceAddress The resulting map address for the bus master controller to use to
- access the hosts HostAddress.
+ access the hosts HostAddress.
@param Mapping A resulting value to pass to DmaUnmap().
-
+
@retval EFI_SUCCESS The range was mapped for the returned NumberOfBytes.
- @retval EFI_UNSUPPORTED The HostAddress cannot be mapped as a common buffer.
+ @retval EFI_UNSUPPORTED The HostAddress cannot be mapped as a common buffer.
@retval EFI_INVALID_PARAMETER One or more parameters are invalid.
@retval EFI_OUT_OF_RESOURCES The request could not be completed due to a lack of resources.
@retval EFI_DEVICE_ERROR The system hardware could not map the requested address.
-
+
**/
EFI_STATUS
EFIAPI
@@ -93,15 +93,15 @@ DmaMap ( -/**
+/**
Completes the DmaMapBusMasterRead, DmaMapBusMasterWrite, or DmaMapBusMasterCommonBuffer
operation and releases any corresponding resources.
-
+
@param Mapping The mapping value returned from DmaMap().
-
+
@retval EFI_SUCCESS The range was unmapped.
@retval EFI_DEVICE_ERROR The data was not committed to the target system memory.
-
+
**/
EFI_STATUS
EFIAPI
@@ -110,22 +110,22 @@ DmaUnmap ( );
-/**
+/**
Allocates pages that are suitable for an DmaMap() of type MapOperationBusMasterCommonBuffer.
- mapping.
-
+ mapping.
+
@param MemoryType The type of memory to allocate, EfiBootServicesData or
- EfiRuntimeServicesData.
- @param Pages The number of pages to allocate.
+ EfiRuntimeServicesData.
+ @param Pages The number of pages to allocate.
@param HostAddress A pointer to store the base system memory address of the
- allocated range.
+ allocated range.
@retval EFI_SUCCESS The requested memory pages were allocated.
@retval EFI_UNSUPPORTED Attributes is unsupported. The only legal attribute bits are
- MEMORY_WRITE_COMBINE and MEMORY_CACHED.
+ MEMORY_WRITE_COMBINE and MEMORY_CACHED.
@retval EFI_INVALID_PARAMETER One or more parameters are invalid.
- @retval EFI_OUT_OF_RESOURCES The memory pages could not be allocated.
-
+ @retval EFI_OUT_OF_RESOURCES The memory pages could not be allocated.
+
**/
EFI_STATUS
EFIAPI
@@ -136,16 +136,16 @@ DmaAllocateBuffer ( );
-/**
+/**
Frees memory that was allocated with DmaAllocateBuffer().
-
- @param Pages The number of pages to free.
- @param HostAddress The base system memory address of the allocated range.
-
+
+ @param Pages The number of pages to free.
+ @param HostAddress The base system memory address of the allocated range.
+
@retval EFI_SUCCESS The requested memory pages were freed.
@retval EFI_INVALID_PARAMETER The memory range specified by HostAddress and Pages
was not allocated with DmaAllocateBuffer().
-
+
**/
EFI_STATUS
EFIAPI
@@ -155,5 +155,5 @@ DmaFreeBuffer ( );
-#endif
+#endif
diff --git a/EmbeddedPkg/Include/Library/EblAddExternalCommandLib.h b/EmbeddedPkg/Include/Library/EblAddExternalCommandLib.h index f760f8e2af..65aedddddd 100644 --- a/EmbeddedPkg/Include/Library/EblAddExternalCommandLib.h +++ b/EmbeddedPkg/Include/Library/EblAddExternalCommandLib.h @@ -42,7 +42,7 @@ EblAddExternalCommands ( @param TimeoutInSec Number of seconds to wait to timeout
- @param CallBack Callback called every second during the timeout wait
+ @param CallBack Callback called every second during the timeout wait
@@ -86,7 +86,7 @@ EblGetCharKey ( string. This depends on the last print done before calling this function.
- CurrentRow is updated by one on a call or set back to zero if a prompt is
+ CurrentRow is updated by one on a call or set back to zero if a prompt is
needed.
diff --git a/EmbeddedPkg/Include/Library/EblCmdLib.h b/EmbeddedPkg/Include/Library/EblCmdLib.h index 5c21d05f00..5df71e634a 100644 --- a/EmbeddedPkg/Include/Library/EblCmdLib.h +++ b/EmbeddedPkg/Include/Library/EblCmdLib.h @@ -34,7 +34,7 @@ EblAddCommands ( //
-// LIbrary constructor called directly from Ebl Code.
+// LIbrary constructor called directly from Ebl Code.
// This module calls EblAddCommand () or EblAddCommands () to register new commands
//
VOID
diff --git a/EmbeddedPkg/Include/Library/EblNetworkLib.h b/EmbeddedPkg/Include/Library/EblNetworkLib.h index 9292cf9b0f..66dc6ac305 100644 --- a/EmbeddedPkg/Include/Library/EblNetworkLib.h +++ b/EmbeddedPkg/Include/Library/EblNetworkLib.h @@ -49,7 +49,7 @@ EblSetStationIp ( IN EFI_IP_ADDRESS *NewStationIp, OPTIONAL
IN EFI_IP_ADDRESS *NewSubnetMask OPTIONAL
);
-
+
EFI_STATUS
EFIAPI
EblMtftp (
@@ -63,6 +63,6 @@ EblMtftp ( IN EFI_PXE_BASE_CODE_MTFTP_INFO *Info OPTIONAL,
IN BOOLEAN DontUseBuffer
);
-
+
#endif
diff --git a/EmbeddedPkg/Include/Library/EfiFileLib.h b/EmbeddedPkg/Include/Library/EfiFileLib.h index 033375cea0..e86be4c95b 100644 --- a/EmbeddedPkg/Include/Library/EfiFileLib.h +++ b/EmbeddedPkg/Include/Library/EfiFileLib.h @@ -1,6 +1,6 @@ /** @file
- Library functions that perform file IO. Memory buffer, file system, and
- fimrware volume operations are supproted.
+ Library functions that perform file IO. Memory buffer, file system, and
+ fimrware volume operations are supproted.
Copyright (c) 2007, Intel Corporation. All rights reserved.<BR>
Portions copyright (c) 2008 - 2009, Apple Inc. All rights reserved.<BR>
@@ -18,7 +18,7 @@ current mounted device concept of current working directory concept implement
by this library.
- Device names are case insensative and only check the leading characters for
+ Device names are case insensative and only check the leading characters for
unique matches. Thus the following are all the same:
LoadFile0:
l0:
@@ -32,7 +32,7 @@ fs3: - EFI Simple File System device 3
Fv2: - EFI Firmware VOlume device 2
1.2.3.4:name - TFTP IP and file name
-
+
**/
#ifndef __EFI_FILE_LIB_H__
@@ -50,7 +50,7 @@ #define MAX_PATHNAME 0x200
-/// Type of the file that has been opened
+/// Type of the file that has been opened
typedef enum {
EfiOpenLoadFile,
EfiOpenMemoryBuffer,
@@ -64,11 +64,11 @@ typedef enum { /// Public information about the open file
typedef struct {
- UINTN Version; // Common information
+ UINTN Version; // Common information
EFI_OPEN_FILE_TYPE Type;
EFI_DEVICE_PATH_PROTOCOL *DevicePath;
EFI_STATUS LastError;
- EFI_HANDLE EfiHandle;
+ EFI_HANDLE EfiHandle;
CHAR8 *DeviceName;
CHAR8 *FileName;
@@ -76,18 +76,18 @@ typedef struct { UINT64 MaxPosition;
UINTN BaseOffset; // Base offset for hexdump command
-
+
UINTN Size; // Valid for all types other than l#:
UINT8 *Buffer; // Information valid for A#:
- EFI_FIRMWARE_VOLUME2_PROTOCOL *Fv; // Information valid for Fv#:
- EFI_GUID FvNameGuid;
- EFI_SECTION_TYPE FvSectionType;
- EFI_FV_FILETYPE FvType;
- EFI_FV_FILE_ATTRIBUTES FvAttributes;
+ EFI_FIRMWARE_VOLUME2_PROTOCOL *Fv; // Information valid for Fv#:
+ EFI_GUID FvNameGuid;
+ EFI_SECTION_TYPE FvSectionType;
+ EFI_FV_FILETYPE FvType;
+ EFI_FV_FILE_ATTRIBUTES FvAttributes;
- EFI_PHYSICAL_ADDRESS FvStart;
- UINTN FvSize;
+ EFI_PHYSICAL_ADDRESS FvStart;
+ UINTN FvSize;
UINTN FvHeaderSize;
EFI_FILE *FsFileHandle; // Information valid for Fs#:
@@ -99,11 +99,11 @@ typedef struct { UINTN DiskOffset; // Information valid for B#:
EFI_LOAD_FILE_PROTOCOL *LoadFile; // Information valid for l#:
-
+
EFI_IP_ADDRESS ServerIp; // Information valid for t:
BOOLEAN IsDirty;
BOOLEAN IsBufferValid;
-
+
} EFI_OPEN_FILE;
@@ -117,17 +117,17 @@ typedef enum { /**
- Open a device named by PathName. The PathName includes a device name and
+ Open a device named by PathName. The PathName includes a device name and
path separated by a :. See file header for more details on the PathName
syntax. There is no checking to prevent a file from being opened more than
- one type.
+ one type.
SectionType is only used to open an FV. Each file in an FV contains multiple
sections and only the SectionType section is opened.
For any file that is opened with EfiOpen() must be closed with EfiClose().
- @param PathName Path to parse to open
+ @param PathName Path to parse to open
@param OpenMode Same as EFI_FILE.Open()
@param SectionType Section in FV to open.
@@ -182,9 +182,9 @@ EfiClose ( /**
- Return the size of the file represented by Stream. Also return the current
+ Return the size of the file represented by Stream. Also return the current
Seek position. Opening a file will enable a valid file size to be returned.
- LoadFile is an exception as a load file size is set to zero.
+ LoadFile is an exception as a load file size is set to zero.
@param Stream Open File Handle
@@ -200,16 +200,16 @@ EfiTell ( /**
Seek to the Offset location in the file. LoadFile and FV device types do
- not support EfiSeek(). It is not possible to grow the file size using
+ not support EfiSeek(). It is not possible to grow the file size using
EfiSeek().
-
+
SeekType defines how use Offset to calculate the new file position:
EfiSeekStart : Position = Offset
EfiSeekCurrent: Position is Offset bytes from the current position
EfiSeekEnd : Only supported if Offset is zero to seek to end of file.
@param Stream Open File Handle
- @param Offset Offset to seek too.
+ @param Offset Offset to seek too.
@param SeekType Type of seek to perform
@@ -229,10 +229,10 @@ EfiSeek ( /**
Read BufferSize bytes from the current location in the file. For load file
- and FV case you must read the entire file.
+ and FV case you must read the entire file.
@param Stream Open File Handle
- @param Buffer Caller allocated buffer.
+ @param Buffer Caller allocated buffer.
@param BufferSize Size of buffer in bytes.
@@ -253,13 +253,13 @@ EfiRead ( /**
Read the entire file into a buffer. This routine allocates the buffer and
- returns it to the user full of the read data.
+ returns it to the user full of the read data.
This is very useful for load file where it's hard to know how big the buffer
must be.
@param Stream Open File Handle
- @param Buffer Pointer to buffer to return.
+ @param Buffer Pointer to buffer to return.
@param BufferSize Pointer to Size of buffer return..
@@ -279,10 +279,10 @@ EfiReadAllocatePool ( /**
- Write data back to the file.
+ Write data back to the file.
@param Stream Open File Handle
- @param Buffer Pointer to buffer to return.
+ @param Buffer Pointer to buffer to return.
@param BufferSize Pointer to Size of buffer return..
@@ -313,12 +313,12 @@ UINTN EfiGetDeviceCounts (
IN EFI_OPEN_FILE_TYPE Type
);
-
+
/**
Set the Current Working Directory (CWD). If a call is made to EfiOpen () and
the path does not contain a device name, The CWD is prepended to the path.
-
+
@param Cwd Current Working Directory to set
@@ -329,22 +329,22 @@ EfiGetDeviceCounts ( EFI_STATUS
EfiSetCwd (
IN CHAR8 *Cwd
- );
+ );
/**
Set the Current Working Directory (CWD). If a call is made to EfiOpen () and
the path does not contain a device name, The CWD is prepended to the path.
-
- @param Cwd Current Working Directory
+
+ @param Cwd Current Working Directory
@return NULL No CWD set
@return 'other' malloc'ed buffer contains CWD.
-
+
**/
CHAR8 *
EfiGetCwd (
VOID
- );
+ );
#endif
diff --git a/EmbeddedPkg/Include/Library/EfiResetSystemLib.h b/EmbeddedPkg/Include/Library/EfiResetSystemLib.h index 89e0a11c7d..83b95c9ddb 100644 --- a/EmbeddedPkg/Include/Library/EfiResetSystemLib.h +++ b/EmbeddedPkg/Include/Library/EfiResetSystemLib.h @@ -36,7 +36,7 @@ LibResetSystem ( IN UINTN DataSize,
IN CHAR16 *ResetData OPTIONAL
);
-
+
/**
@@ -44,7 +44,7 @@ LibResetSystem ( @param ImageHandle The firmware allocated handle for the EFI image.
@param SystemTable A pointer to the EFI System Table.
-
+
@retval EFI_SUCCESS The constructor always returns EFI_SUCCESS.
**/
diff --git a/EmbeddedPkg/Include/Library/GdbSerialLib.h b/EmbeddedPkg/Include/Library/GdbSerialLib.h index 6e8eeb4e6f..aa4c3ff640 100644 --- a/EmbeddedPkg/Include/Library/GdbSerialLib.h +++ b/EmbeddedPkg/Include/Library/GdbSerialLib.h @@ -19,7 +19,7 @@ /**
- Sets the baud rate, receive FIFO depth, transmit/receice time out, parity,
+ Sets the baud rate, receive FIFO depth, transmit/receice time out, parity,
data buts, and stop bits on a serial device. This call is optional as the serial
port will be set up with defaults base on PCD values.
@@ -40,11 +40,11 @@ RETURN_STATUS
EFIAPI
GdbSerialInit (
- IN UINT64 BaudRate,
- IN UINT8 Parity,
- IN UINT8 DataBits,
- IN UINT8 StopBits
- );
+ IN UINT64 BaudRate,
+ IN UINT8 Parity,
+ IN UINT8 DataBits,
+ IN UINT8 StopBits
+ );
/**
@@ -53,7 +53,7 @@ GdbSerialInit ( @return TRUE - Character availible
@return FALSE - Character not availible
-
+
**/
BOOLEAN
EFIAPI
@@ -65,7 +65,7 @@ GdbIsCharAvailable ( Get a character from GDB. This function must be able to run in interrupt context.
@return A character from GDB
-
+
**/
CHAR8
EFIAPI
diff --git a/EmbeddedPkg/Include/Library/PrePiHobListPointerLib.h b/EmbeddedPkg/Include/Library/PrePiHobListPointerLib.h index 7a666df25d..16b9ed2e24 100644 --- a/EmbeddedPkg/Include/Library/PrePiHobListPointerLib.h +++ b/EmbeddedPkg/Include/Library/PrePiHobListPointerLib.h @@ -1,14 +1,14 @@ /** @file
*
* Copyright (c) 2011, ARM Limited. All rights reserved.
-*
-* This program and the accompanying materials
-* are licensed and made available under the terms and conditions of the BSD License
-* which accompanies this distribution. The full text of the license may be found at
-* http://opensource.org/licenses/bsd-license.php
*
-* THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
-* WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
+* This program and the accompanying materials
+* are licensed and made available under the terms and conditions of the BSD License
+* which accompanies this distribution. The full text of the license may be found at
+* http://opensource.org/licenses/bsd-license.php
+*
+* THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
+* WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
*
**/
@@ -33,7 +33,7 @@ PrePeiGetHobList ( Updates the pointer to the HOB list.
@param HobList Hob list pointer to store
-
+
**/
EFI_STATUS
EFIAPI
diff --git a/EmbeddedPkg/Include/Library/PrePiLib.h b/EmbeddedPkg/Include/Library/PrePiLib.h index 6144513a86..9ac7f38a1f 100644 --- a/EmbeddedPkg/Include/Library/PrePiLib.h +++ b/EmbeddedPkg/Include/Library/PrePiLib.h @@ -83,7 +83,7 @@ FfsFindSectionData ( /**
Find a file in the volume by name
-
+
@param FileName A pointer to the name of the file to
find within the firmware volume.
@@ -117,15 +117,15 @@ FfsFindByName ( information.
@retval EFI_SUCCESS File information returned.
-
+
@retval EFI_INVALID_PARAMETER If FileHandle does not
represent a valid file.
-
+
@retval EFI_INVALID_PARAMETER If FileInfo is NULL.
-
+
**/
EFI_STATUS
-EFIAPI
+EFIAPI
FfsGetFileInfo (
IN CONST EFI_PEI_FILE_HANDLE FileHandle,
OUT EFI_FV_FILE_INFO *FileInfo
@@ -141,10 +141,10 @@ FfsGetFileInfo ( information.
@retval EFI_SUCCESS File information returned.
-
+
@retval EFI_INVALID_PARAMETER If FileHandle does not
represent a valid file.
-
+
@retval EFI_INVALID_PARAMETER If FileInfo is NULL.
**/
@@ -180,7 +180,7 @@ FfsProcessFvFile ( @param FileType File handle of a Fv type file.
@param Volumehandle On succes Volume Handle of the match
@param FileHandle On success File Handle of the match
-
+
@retval EFI_NOT_FOUND FV image can't be found.
@retval EFI_SUCCESS Successfully found FileType
@@ -212,10 +212,10 @@ FfsProcessFvFile ( /**
- This service enables PEIMs to ascertain the present value of the boot mode.
+ This service enables PEIMs to ascertain the present value of the boot mode.
- @retval BootMode
+ @retval BootMode
**/
EFI_BOOT_MODE
@@ -226,7 +226,7 @@ GetBootMode ( /**
- This service enables PEIMs to update the boot mode variable.
+ This service enables PEIMs to update the boot mode variable.
@param BootMode The value of the boot mode to set.
@@ -251,7 +251,7 @@ SetBootMode ( VOID *
EFIAPI
GetHobList (
- VOID
+ VOID
);
@@ -259,7 +259,7 @@ GetHobList ( Updates the pointer to the HOB list.
@param HobList Hob list pointer to store
-
+
**/
EFI_STATUS
EFIAPI
@@ -313,7 +313,7 @@ CreateHob ( /**
Returns the next instance of a HOB type from the starting HOB.
- This function searches the first instance of a HOB type from the starting HOB pointer.
+ This function searches the first instance of a HOB type from the starting HOB pointer.
If there does not exist such HOB type from the starting HOB pointer, it will return NULL.
In contrast with macro GET_NEXT_HOB(), this function does not skip the starting HOB pointer
unconditionally: it returns HobStart back if HobStart itself meets the requirement;
@@ -336,8 +336,8 @@ GetNextHob ( /**
Returns the first instance of a HOB type among the whole HOB list.
- This function searches the first instance of a HOB type among the whole HOB list.
- If there does not exist such HOB type in the HOB list, it will return NULL.
+ This function searches the first instance of a HOB type among the whole HOB list.
+ If there does not exist such HOB type in the HOB list, it will return NULL.
@param Type The HOB type to return.
@@ -351,10 +351,10 @@ GetFirstHob ( );
/**
- This function searches the first instance of a HOB from the starting HOB pointer.
- Such HOB should satisfy two conditions:
- its HOB type is EFI_HOB_TYPE_GUID_EXTENSION and its GUID Name equals to the input Guid.
- If there does not exist such HOB from the starting HOB pointer, it will return NULL.
+ This function searches the first instance of a HOB from the starting HOB pointer.
+ Such HOB should satisfy two conditions:
+ its HOB type is EFI_HOB_TYPE_GUID_EXTENSION and its GUID Name equals to the input Guid.
+ If there does not exist such HOB from the starting HOB pointer, it will return NULL.
Caller is required to apply GET_GUID_HOB_DATA () and GET_GUID_HOB_DATA_SIZE ()
to extract the data section and its size info respectively.
In contrast with macro GET_NEXT_HOB(), this function does not skip the starting HOB pointer
@@ -377,7 +377,7 @@ GetNextGuidHob ( );
/**
- This function searches the first instance of a HOB among the whole HOB list.
+ This function searches the first instance of a HOB among the whole HOB list.
Such HOB should satisfy two conditions:
its HOB type is EFI_HOB_TYPE_GUID_EXTENSION and its GUID Name equals to the input Guid.
If there does not exist such HOB from the starting HOB pointer, it will return NULL.
@@ -447,8 +447,8 @@ BuildResourceDescriptorHob ( /**
Builds a GUID HOB with a certain data length.
- This function builds a customized HOB tagged with a GUID for identification
- and returns the start address of GUID HOB data so that caller can fill the customized data.
+ This function builds a customized HOB tagged with a GUID for identification
+ and returns the start address of GUID HOB data so that caller can fill the customized data.
The HOB Header and Name field is already stripped.
It can only be invoked during PEI phase;
for DXE phase, it will ASSERT() since PEI HOB is read-only for DXE phase.
@@ -517,7 +517,7 @@ BuildFvHob ( );
/**
- Builds a Firmware Volume HOB and a resrouce descriptor hob
+ Builds a Firmware Volume HOB and a resrouce descriptor hob
This function builds a Firmware Volume HOB.
It can only be invoked during PEI phase;
@@ -530,11 +530,11 @@ BuildFvHob ( **/
VOID
EFIAPI
-BuildFvHobs (
+BuildFvHobs (
IN EFI_PHYSICAL_ADDRESS PhysicalStart,
IN UINT64 NumberOfBytes,
IN EFI_RESOURCE_ATTRIBUTE_TYPE *ResourceAttribute OPTIONAL
- );
+ );
/**
@@ -549,7 +549,7 @@ BuildFvHobs ( @param Length The size of the Firmware Volume in bytes.
@param FvName The name of the Firmware Volume.
@param FileName The name of the file.
-
+
**/
VOID
EFIAPI
@@ -702,12 +702,12 @@ BuildPeCoffLoaderHob ( @return A pointer to the allocated buffer or NULL if allocation fails.
**/
-VOID *
+VOID *
EFIAPI
AllocatePages (
IN UINTN Pages
);
-
+
/**
Allocates a buffer of type EfiBootServicesData.
@@ -725,8 +725,8 @@ EFIAPI AllocatePool (
IN UINTN AllocationSize
);
-
-
+
+
/**
Allocates one or more 4KB pages of type EfiBootServicesData at a specified alignment.
diff --git a/EmbeddedPkg/Include/Library/RealTimeClockLib.h b/EmbeddedPkg/Include/Library/RealTimeClockLib.h index 2545844bb3..59a34aad13 100644 --- a/EmbeddedPkg/Include/Library/RealTimeClockLib.h +++ b/EmbeddedPkg/Include/Library/RealTimeClockLib.h @@ -1,6 +1,6 @@ /** @file
Implement EFI RealTimeClock runtime services via Lib.
-
+
Currently this driver does not support runtime virtual calling.
Copyright (c) 2008 - 2009, Apple Inc. All rights reserved.<BR>
diff --git a/EmbeddedPkg/Include/Library/SerialPortExtLib.h b/EmbeddedPkg/Include/Library/SerialPortExtLib.h index a32365bf78..29a7537b15 100644 --- a/EmbeddedPkg/Include/Library/SerialPortExtLib.h +++ b/EmbeddedPkg/Include/Library/SerialPortExtLib.h @@ -1,7 +1,7 @@ /** @file
Copyright (c) 2012, ARM Ltd. All rights reserved.
-
+
This program and the accompanying materials
are licensed and made available under the terms and conditions of the BSD License
which accompanies this distribution. The full text of the license may be found at
diff --git a/EmbeddedPkg/Include/Protocol/DebugSupportPeriodicCallback.h b/EmbeddedPkg/Include/Protocol/DebugSupportPeriodicCallback.h index 105e4a23c9..3d95f930b9 100644 --- a/EmbeddedPkg/Include/Protocol/DebugSupportPeriodicCallback.h +++ b/EmbeddedPkg/Include/Protocol/DebugSupportPeriodicCallback.h @@ -1,6 +1,6 @@ /** @file
Protocol is used to help implement DebugSupport.RegisterPeriodicCallback() functionality.
- This enables the DXE timer driver to support the periodic callback function so the
+ This enables the DXE timer driver to support the periodic callback function so the
DebugSupport driver does not need to contain platform specific information about how a timer
works.
@@ -39,4 +39,4 @@ struct _EFI_DEBUG_SUPPORT_PERIODIC_CALLBACK_PROTOCOL { extern EFI_GUID gEfiDebugSupportPeriodicCallbackProtocolGuid;
-#endif
+#endif
diff --git a/EmbeddedPkg/Include/Protocol/EblAddCommand.h b/EmbeddedPkg/Include/Protocol/EblAddCommand.h index a7809b27b3..4a9f494c5d 100644 --- a/EmbeddedPkg/Include/Protocol/EblAddCommand.h +++ b/EmbeddedPkg/Include/Protocol/EblAddCommand.h @@ -46,7 +46,7 @@ typedef struct { /**
Add a single command table entry.
-
+
@param EntryArray Pointer EBL_COMMAND_TABLE of the command that is being added
**/
@@ -73,7 +73,7 @@ VOID );
-typedef
+typedef
VOID
(EFIAPI *EBL_GET_CHAR_CALL_BACK) (
IN UINTN ElapsedTime
@@ -86,13 +86,13 @@ VOID @param Key EFI Key information returned
@param TimeoutInSec Number of seconds to wait to timeout
- @param CallBack Callback called every second during the timeout wait
+ @param CallBack Callback called every second during the timeout wait
@return EFI_SUCCESS Key was returned
@return EFI_TIMEOUT If the TimoutInSec expired
**/
-typedef
+typedef
EFI_STATUS
(EFIAPI *EBL_GET_CHAR_KEY) (
IN OUT EFI_INPUT_KEY *Key,
@@ -108,7 +108,7 @@ EFI_STATUS If the use hits Q to quit return TRUE else for any other key return FALSE.
PrefixNewline is used to figure out if a newline is needed before the prompt
string. This depends on the last print done before calling this function.
- CurrentRow is updated by one on a call or set back to zero if a prompt is
+ CurrentRow is updated by one on a call or set back to zero if a prompt is
needed.
@param CurrentRow Used to figure out if its the end of the page and updated
diff --git a/EmbeddedPkg/Include/Protocol/EmbeddedDevice.h b/EmbeddedPkg/Include/Protocol/EmbeddedDevice.h index c41e5b41a6..a999a97557 100644 --- a/EmbeddedPkg/Include/Protocol/EmbeddedDevice.h +++ b/EmbeddedPkg/Include/Protocol/EmbeddedDevice.h @@ -1,16 +1,16 @@ /** @file
Deal with devices that just exist in memory space.
-
+
To follow the EFI driver model you need a root handle to start with. An
- EFI driver will have a driver binding protocol (Supported, Start, Stop)
- that is used to layer on top of a handle via a gBS->ConnectController.
+ EFI driver will have a driver binding protocol (Supported, Start, Stop)
+ that is used to layer on top of a handle via a gBS->ConnectController.
The first handle has to just be in the system to make that work. For
- PCI it is a PCI Root Bridge IO protocol that provides the root.
-
- On an embedded system with MMIO device we need a handle to just
- show up. That handle will have this protocol and a device path
- protocol on it.
-
+ PCI it is a PCI Root Bridge IO protocol that provides the root.
+
+ On an embedded system with MMIO device we need a handle to just
+ show up. That handle will have this protocol and a device path
+ protocol on it.
+
For an ethernet device the device path must contain a MAC address device path
node.
diff --git a/EmbeddedPkg/Include/Protocol/EmbeddedExternalDevice.h b/EmbeddedPkg/Include/Protocol/EmbeddedExternalDevice.h index 603dc5ed86..5fe06eb8ce 100644 --- a/EmbeddedPkg/Include/Protocol/EmbeddedExternalDevice.h +++ b/EmbeddedPkg/Include/Protocol/EmbeddedExternalDevice.h @@ -48,7 +48,7 @@ Arguments: Offset - starting register number
Length - number of bytes to read
Buffer - destination buffer
-
+
Returns:
EFI_SUCCESS - registers read successfully
@@ -76,7 +76,7 @@ Arguments: Offset - starting register number
Length - number of bytes to write
Buffer - source buffer
-
+
Returns:
EFI_SUCCESS - registers written successfully
diff --git a/EmbeddedPkg/Include/Protocol/EmbeddedGpio.h b/EmbeddedPkg/Include/Protocol/EmbeddedGpio.h index 77ea7ad034..4e7c8dbcd6 100644 --- a/EmbeddedPkg/Include/Protocol/EmbeddedGpio.h +++ b/EmbeddedPkg/Include/Protocol/EmbeddedGpio.h @@ -68,7 +68,7 @@ Arguments: This - pointer to protocol
Gpio - which pin to read
Value - state of the pin
-
+
Returns:
EFI_SUCCESS - GPIO state returned in Value
@@ -94,7 +94,7 @@ Arguments: This - pointer to protocol
Gpio - which pin to modify
Mode - mode to set
-
+
Returns:
EFI_SUCCESS - GPIO set as requested
@@ -120,7 +120,7 @@ Arguments: This - pointer to protocol
Gpio - which pin
Mode - pointer to output mode value
-
+
Returns:
EFI_SUCCESS - mode value retrieved
@@ -146,7 +146,7 @@ Arguments: This - pointer to protocol
Gpio - which pin
Direction - pull-up, pull-down, or none
-
+
Returns:
EFI_SUCCESS - pin was set
@@ -164,4 +164,4 @@ struct _EMBEDDED_GPIO { extern EFI_GUID gEmbeddedGpioProtocolGuid;
-#endif
+#endif
diff --git a/EmbeddedPkg/Include/Protocol/HardwareInterrupt.h b/EmbeddedPkg/Include/Protocol/HardwareInterrupt.h index 53651dd822..c4b5b9fa62 100644 --- a/EmbeddedPkg/Include/Protocol/HardwareInterrupt.h +++ b/EmbeddedPkg/Include/Protocol/HardwareInterrupt.h @@ -1,11 +1,11 @@ /** @file
Abstraction for hardware based interrupt routine
-
+
On non IA-32 systems it is common to have a single hardware interrupt vector
and a 2nd layer of software that routes the interrupt handlers based on the
- interrupt source. This protocol enables this routing. The driver implementing
- this protocol is responsible for clearing the pending interrupt in the
- interrupt routing hardware. The HARDWARE_INTERRUPT_HANDLER is responsible
+ interrupt source. This protocol enables this routing. The driver implementing
+ this protocol is responsible for clearing the pending interrupt in the
+ interrupt routing hardware. The HARDWARE_INTERRUPT_HANDLER is responsible
for clearing interrupt sources from individual devices.
@@ -48,7 +48,7 @@ typedef UINTN HARDWARE_INTERRUPT_SOURCE; @param Source Source of the interrupt. Hardware routing off a specific platform defines
what source means.
@param SystemContext Pointer to system register context. Mostly used by debuggers and will
- update the system context after the return from the interrupt if
+ update the system context after the return from the interrupt if
modified. Don't change these values unless you know what you are doing
**/
@@ -56,7 +56,7 @@ typedef VOID
(EFIAPI *HARDWARE_INTERRUPT_HANDLER) (
IN HARDWARE_INTERRUPT_SOURCE Source,
- IN EFI_SYSTEM_CONTEXT SystemContext
+ IN EFI_SYSTEM_CONTEXT SystemContext
);
@@ -133,11 +133,11 @@ EFI_STATUS (EFIAPI *HARDWARE_INTERRUPT_INTERRUPT_STATE) (
IN EFI_HARDWARE_INTERRUPT_PROTOCOL *This,
IN HARDWARE_INTERRUPT_SOURCE Source,
- IN BOOLEAN *InterruptState
+ IN BOOLEAN *InterruptState
);
/**
- Signal to the hardware that the End Of Intrrupt state
+ Signal to the hardware that the End Of Intrrupt state
has been reached.
@param This Instance pointer for this protocol
diff --git a/EmbeddedPkg/Include/Protocol/MmcHost.h b/EmbeddedPkg/Include/Protocol/MmcHost.h index 08f2ad9349..89f2e80b5c 100644 --- a/EmbeddedPkg/Include/Protocol/MmcHost.h +++ b/EmbeddedPkg/Include/Protocol/MmcHost.h @@ -2,14 +2,14 @@ Definition of the MMC Host Protocol
Copyright (c) 2011-2014, ARM Limited. All rights reserved.
-
- This program and the accompanying materials
- are licensed and made available under the terms and conditions of the BSD License
- which accompanies this distribution. The full text of the license may be found at
- http://opensource.org/licenses/bsd-license.php
-
- THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
- WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
+
+ This program and the accompanying materials
+ are licensed and made available under the terms and conditions of the BSD License
+ which accompanies this distribution. The full text of the license may be found at
+ http://opensource.org/licenses/bsd-license.php
+
+ THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
+ WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
**/
diff --git a/EmbeddedPkg/Include/Protocol/PeCoffLoader.h b/EmbeddedPkg/Include/Protocol/PeCoffLoader.h index 91332e3f57..1f93cefd17 100644 --- a/EmbeddedPkg/Include/Protocol/PeCoffLoader.h +++ b/EmbeddedPkg/Include/Protocol/PeCoffLoader.h @@ -2,13 +2,13 @@ Copyright (c) 2006 - 2008, Intel Corporation. All rights reserved.<BR>
Portions copyright (c) 2010, Apple Inc. All rights reserved.<BR>
- This program and the accompanying materials
- are licensed and made available under the terms and conditions of the BSD License
- which accompanies this distribution. The full text of the license may be found at
- http://opensource.org/licenses/bsd-license.php
+ This program and the accompanying materials
+ are licensed and made available under the terms and conditions of the BSD License
+ which accompanies this distribution. The full text of the license may be found at
+ http://opensource.org/licenses/bsd-license.php
- THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
- WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
+ THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
+ WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
**/
@@ -30,16 +30,16 @@ typedef struct _PE_COFF_LOADER_PROTOCOL PE_COFF_LOADER_PROTOCOL; /**
Retrieves information about a PE/COFF image.
- Computes the PeCoffHeaderOffset, IsTeImage, ImageType, ImageAddress, ImageSize,
- DestinationAddress, RelocationsStripped, SectionAlignment, SizeOfHeaders, and
- DebugDirectoryEntryRva fields of the ImageContext structure.
- If ImageContext is NULL, then return RETURN_INVALID_PARAMETER.
- If the PE/COFF image accessed through the ImageRead service in the ImageContext
- structure is not a supported PE/COFF image type, then return RETURN_UNSUPPORTED.
- If any errors occur while computing the fields of ImageContext,
- then the error status is returned in the ImageError field of ImageContext.
+ Computes the PeCoffHeaderOffset, IsTeImage, ImageType, ImageAddress, ImageSize,
+ DestinationAddress, RelocationsStripped, SectionAlignment, SizeOfHeaders, and
+ DebugDirectoryEntryRva fields of the ImageContext structure.
+ If ImageContext is NULL, then return RETURN_INVALID_PARAMETER.
+ If the PE/COFF image accessed through the ImageRead service in the ImageContext
+ structure is not a supported PE/COFF image type, then return RETURN_UNSUPPORTED.
+ If any errors occur while computing the fields of ImageContext,
+ then the error status is returned in the ImageError field of ImageContext.
If the image is a TE image, then SectionAlignment is set to 0.
- The ImageRead and Handle fields of ImageContext structure must be valid prior
+ The ImageRead and Handle fields of ImageContext structure must be valid prior
to invoking this service.
@param ImageContext Pointer to the image context structure that describes the PE/COFF
@@ -64,12 +64,12 @@ RETURN_STATUS ImageContext as the relocation base address. Otherwise, use the DestinationAddress field
of ImageContext as the relocation base address. The caller must allocate the relocation
fixup log buffer and fill in the FixupData field of ImageContext prior to calling this function.
-
- The ImageRead, Handle, PeCoffHeaderOffset, IsTeImage, Machine, ImageType, ImageAddress,
- ImageSize, DestinationAddress, RelocationsStripped, SectionAlignment, SizeOfHeaders,
- DebugDirectoryEntryRva, EntryPoint, FixupDataSize, CodeView, PdbPointer, and FixupData of
+
+ The ImageRead, Handle, PeCoffHeaderOffset, IsTeImage, Machine, ImageType, ImageAddress,
+ ImageSize, DestinationAddress, RelocationsStripped, SectionAlignment, SizeOfHeaders,
+ DebugDirectoryEntryRva, EntryPoint, FixupDataSize, CodeView, PdbPointer, and FixupData of
the ImageContext structure must be valid prior to invoking this service.
-
+
If ImageContext is NULL, then ASSERT().
Note that if the platform does not maintain coherency between the instruction cache(s) and the data
@@ -101,10 +101,10 @@ RETURN_STATUS specified by the ImageAddress and ImageSize fields of ImageContext. The caller must allocate
the load buffer and fill in the ImageAddress and ImageSize fields prior to calling this function.
The EntryPoint, FixupDataSize, CodeView, PdbPointer and HiiResourceData fields of ImageContext are computed.
- The ImageRead, Handle, PeCoffHeaderOffset, IsTeImage, Machine, ImageType, ImageAddress, ImageSize,
- DestinationAddress, RelocationsStripped, SectionAlignment, SizeOfHeaders, and DebugDirectoryEntryRva
+ The ImageRead, Handle, PeCoffHeaderOffset, IsTeImage, Machine, ImageType, ImageAddress, ImageSize,
+ DestinationAddress, RelocationsStripped, SectionAlignment, SizeOfHeaders, and DebugDirectoryEntryRva
fields of the ImageContext structure must be valid prior to invoking this service.
-
+
If ImageContext is NULL, then ASSERT().
Note that if the platform does not maintain coherency between the instruction cache(s) and the data
@@ -135,25 +135,25 @@ RETURN_STATUS /**
Reads contents of a PE/COFF image from a buffer in system memory.
-
- This is the default implementation of a PE_COFF_LOADER_READ_FILE function
- that assumes FileHandle pointer to the beginning of a PE/COFF image.
- This function reads contents of the PE/COFF image that starts at the system memory
- address specified by FileHandle. The read operation copies ReadSize bytes from the
- PE/COFF image starting at byte offset FileOffset into the buffer specified by Buffer.
+
+ This is the default implementation of a PE_COFF_LOADER_READ_FILE function
+ that assumes FileHandle pointer to the beginning of a PE/COFF image.
+ This function reads contents of the PE/COFF image that starts at the system memory
+ address specified by FileHandle. The read operation copies ReadSize bytes from the
+ PE/COFF image starting at byte offset FileOffset into the buffer specified by Buffer.
The size of the buffer actually read is returned in ReadSize.
-
+
If FileHandle is NULL, then ASSERT().
If ReadSize is NULL, then ASSERT().
If Buffer is NULL, then ASSERT().
@param FileHandle Pointer to base of the input stream
@param FileOffset Offset into the PE/COFF image to begin the read operation.
- @param ReadSize On input, the size in bytes of the requested read operation.
+ @param ReadSize On input, the size in bytes of the requested read operation.
On output, the number of bytes actually read.
@param Buffer Output buffer that contains the data read from the PE/COFF image.
- @retval RETURN_SUCCESS Data is read from FileOffset from the Handle into
+ @retval RETURN_SUCCESS Data is read from FileOffset from the Handle into
the buffer.
**/
typedef
@@ -169,26 +169,26 @@ RETURN_STATUS /**
Reapply fixups on a fixed up PE32/PE32+ image to allow virutal calling at EFI
- runtime.
-
- This function reapplies relocation fixups to the PE/COFF image specified by ImageBase
- and ImageSize so the image will execute correctly when the PE/COFF image is mapped
- to the address specified by VirtualImageBase. RelocationData must be identical
- to the FiuxupData buffer from the PE_COFF_LOADER_IMAGE_CONTEXT structure
+ runtime.
+
+ This function reapplies relocation fixups to the PE/COFF image specified by ImageBase
+ and ImageSize so the image will execute correctly when the PE/COFF image is mapped
+ to the address specified by VirtualImageBase. RelocationData must be identical
+ to the FiuxupData buffer from the PE_COFF_LOADER_IMAGE_CONTEXT structure
after this PE/COFF image was relocated with PeCoffLoaderRelocateImage().
Note that if the platform does not maintain coherency between the instruction cache(s) and the data
cache(s) in hardware, then the caller is responsible for performing cache maintenance operations
prior to transferring control to a PE/COFF image that is loaded using this library.
- @param ImageBase Base address of a PE/COFF image that has been loaded
+ @param ImageBase Base address of a PE/COFF image that has been loaded
and relocated into system memory.
@param VirtImageBase The request virtual address that the PE/COFF image is to
be fixed up for.
@param ImageSize The size, in bytes, of the PE/COFF image.
- @param RelocationData A pointer to the relocation data that was collected when the PE/COFF
+ @param RelocationData A pointer to the relocation data that was collected when the PE/COFF
image was relocated using PeCoffLoaderRelocateImage().
-
+
**/
typedef
VOID
@@ -203,15 +203,15 @@ VOID /**
Unloads a loaded PE/COFF image from memory and releases its taken resource.
- Releases any environment specific resources that were allocated when the image
- specified by ImageContext was loaded using PeCoffLoaderLoadImage().
-
+ Releases any environment specific resources that were allocated when the image
+ specified by ImageContext was loaded using PeCoffLoaderLoadImage().
+
For NT32 emulator, the PE/COFF image loaded by system needs to release.
- For real platform, the PE/COFF image loaded by Core doesn't needs to be unloaded,
+ For real platform, the PE/COFF image loaded by Core doesn't needs to be unloaded,
this function can simply return RETURN_SUCCESS.
-
+
If ImageContext is NULL, then ASSERT().
-
+
@param ImageContext Pointer to the image context structure that describes the PE/COFF
image to be unloaded.
diff --git a/EmbeddedPkg/Include/libfdt_env.h b/EmbeddedPkg/Include/libfdt_env.h index a8ab463493..3e24db9409 100644 --- a/EmbeddedPkg/Include/libfdt_env.h +++ b/EmbeddedPkg/Include/libfdt_env.h @@ -1,14 +1,14 @@ /** @file
*
* Copyright (c) 2011-2014, ARM Limited. All rights reserved.
-*
-* This program and the accompanying materials
-* are licensed and made available under the terms and conditions of the BSD License
-* which accompanies this distribution. The full text of the license may be found at
-* http://opensource.org/licenses/bsd-license.php
*
-* THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
-* WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
+* This program and the accompanying materials
+* are licensed and made available under the terms and conditions of the BSD License
+* which accompanies this distribution. The full text of the license may be found at
+* http://opensource.org/licenses/bsd-license.php
+*
+* THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
+* WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
*
**/
diff --git a/EmbeddedPkg/Library/DebugAgentTimerLibNull/DebugAgentTimerLib.c b/EmbeddedPkg/Library/DebugAgentTimerLibNull/DebugAgentTimerLib.c index 7fab09bad6..bb1ea132cf 100755 --- a/EmbeddedPkg/Library/DebugAgentTimerLibNull/DebugAgentTimerLib.c +++ b/EmbeddedPkg/Library/DebugAgentTimerLibNull/DebugAgentTimerLib.c @@ -6,7 +6,7 @@ program with the debugger.
Copyright (c) 2008 - 2010, Apple Inc. All rights reserved.<BR>
-
+
This program and the accompanying materials
are licensed and made available under the terms and conditions of the BSD License
which accompanies this distribution. The full text of the license may be found at
@@ -31,14 +31,14 @@ DebugAgentTimerIntialize ( )
{
}
-
-
+
+
/**
Set the period for the debug agent timer. Zero means disable the timer.
@param[in] TimerPeriodMilliseconds Frequency of the debug agent timer.
-**/
+**/
VOID
EFIAPI
DebugAgentTimerSetPeriod (
@@ -46,13 +46,13 @@ DebugAgentTimerSetPeriod ( )
{
}
-
+
/**
- Perform End Of Interrupt for the debug agent timer. This is called in the
- interrupt handler after the interrupt has been processed.
+ Perform End Of Interrupt for the debug agent timer. This is called in the
+ interrupt handler after the interrupt has been processed.
-**/
+**/
VOID
EFIAPI
DebugAgentTimerEndOfInterrupt (
@@ -60,5 +60,4 @@ DebugAgentTimerEndOfInterrupt ( )
{
}
-
-
\ No newline at end of file +
diff --git a/EmbeddedPkg/Library/DxeHobPeCoffLib/DxeHobPeCoff.c b/EmbeddedPkg/Library/DxeHobPeCoffLib/DxeHobPeCoff.c index 1757c8e82f..bcc694816a 100644 --- a/EmbeddedPkg/Library/DxeHobPeCoffLib/DxeHobPeCoff.c +++ b/EmbeddedPkg/Library/DxeHobPeCoffLib/DxeHobPeCoff.c @@ -1,5 +1,5 @@ /** @file
- PE/COFF Loader Library implementation that wraps a protocol passed up from
+ PE/COFF Loader Library implementation that wraps a protocol passed up from
SEC/PEI via a HOB. This is done to save space.
Copyright (c) 2010, Intel Corporation. All rights reserved.<BR>
@@ -27,16 +27,16 @@ PE_COFF_LOADER_PROTOCOL *gPeCoffLoader = NULL; /**
Retrieves information about a PE/COFF image.
- Computes the PeCoffHeaderOffset, IsTeImage, ImageType, ImageAddress, ImageSize,
- DestinationAddress, RelocationsStripped, SectionAlignment, SizeOfHeaders, and
- DebugDirectoryEntryRva fields of the ImageContext structure.
- If ImageContext is NULL, then return RETURN_INVALID_PARAMETER.
- If the PE/COFF image accessed through the ImageRead service in the ImageContext
- structure is not a supported PE/COFF image type, then return RETURN_UNSUPPORTED.
- If any errors occur while computing the fields of ImageContext,
- then the error status is returned in the ImageError field of ImageContext.
+ Computes the PeCoffHeaderOffset, IsTeImage, ImageType, ImageAddress, ImageSize,
+ DestinationAddress, RelocationsStripped, SectionAlignment, SizeOfHeaders, and
+ DebugDirectoryEntryRva fields of the ImageContext structure.
+ If ImageContext is NULL, then return RETURN_INVALID_PARAMETER.
+ If the PE/COFF image accessed through the ImageRead service in the ImageContext
+ structure is not a supported PE/COFF image type, then return RETURN_UNSUPPORTED.
+ If any errors occur while computing the fields of ImageContext,
+ then the error status is returned in the ImageError field of ImageContext.
If the image is a TE image, then SectionAlignment is set to 0.
- The ImageRead and Handle fields of ImageContext structure must be valid prior
+ The ImageRead and Handle fields of ImageContext structure must be valid prior
to invoking this service.
@param ImageContext Pointer to the image context structure that describes the PE/COFF
@@ -64,12 +64,12 @@ PeCoffLoaderGetImageInfo ( ImageContext as the relocation base address. Otherwise, use the DestinationAddress field
of ImageContext as the relocation base address. The caller must allocate the relocation
fixup log buffer and fill in the FixupData field of ImageContext prior to calling this function.
-
- The ImageRead, Handle, PeCoffHeaderOffset, IsTeImage, Machine, ImageType, ImageAddress,
- ImageSize, DestinationAddress, RelocationsStripped, SectionAlignment, SizeOfHeaders,
- DebugDirectoryEntryRva, EntryPoint, FixupDataSize, CodeView, PdbPointer, and FixupData of
+
+ The ImageRead, Handle, PeCoffHeaderOffset, IsTeImage, Machine, ImageType, ImageAddress,
+ ImageSize, DestinationAddress, RelocationsStripped, SectionAlignment, SizeOfHeaders,
+ DebugDirectoryEntryRva, EntryPoint, FixupDataSize, CodeView, PdbPointer, and FixupData of
the ImageContext structure must be valid prior to invoking this service.
-
+
If ImageContext is NULL, then ASSERT().
Note that if the platform does not maintain coherency between the instruction cache(s) and the data
@@ -103,10 +103,10 @@ PeCoffLoaderRelocateImage ( specified by the ImageAddress and ImageSize fields of ImageContext. The caller must allocate
the load buffer and fill in the ImageAddress and ImageSize fields prior to calling this function.
The EntryPoint, FixupDataSize, CodeView, PdbPointer and HiiResourceData fields of ImageContext are computed.
- The ImageRead, Handle, PeCoffHeaderOffset, IsTeImage, Machine, ImageType, ImageAddress, ImageSize,
- DestinationAddress, RelocationsStripped, SectionAlignment, SizeOfHeaders, and DebugDirectoryEntryRva
+ The ImageRead, Handle, PeCoffHeaderOffset, IsTeImage, Machine, ImageType, ImageAddress, ImageSize,
+ DestinationAddress, RelocationsStripped, SectionAlignment, SizeOfHeaders, and DebugDirectoryEntryRva
fields of the ImageContext structure must be valid prior to invoking this service.
-
+
If ImageContext is NULL, then ASSERT().
Note that if the platform does not maintain coherency between the instruction cache(s) and the data
@@ -140,25 +140,25 @@ PeCoffLoaderLoadImage ( /**
Reads contents of a PE/COFF image from a buffer in system memory.
-
- This is the default implementation of a PE_COFF_LOADER_READ_FILE function
- that assumes FileHandle pointer to the beginning of a PE/COFF image.
- This function reads contents of the PE/COFF image that starts at the system memory
- address specified by FileHandle. The read operation copies ReadSize bytes from the
- PE/COFF image starting at byte offset FileOffset into the buffer specified by Buffer.
+
+ This is the default implementation of a PE_COFF_LOADER_READ_FILE function
+ that assumes FileHandle pointer to the beginning of a PE/COFF image.
+ This function reads contents of the PE/COFF image that starts at the system memory
+ address specified by FileHandle. The read operation copies ReadSize bytes from the
+ PE/COFF image starting at byte offset FileOffset into the buffer specified by Buffer.
The size of the buffer actually read is returned in ReadSize.
-
+
If FileHandle is NULL, then ASSERT().
If ReadSize is NULL, then ASSERT().
If Buffer is NULL, then ASSERT().
@param FileHandle Pointer to base of the input stream
@param FileOffset Offset into the PE/COFF image to begin the read operation.
- @param ReadSize On input, the size in bytes of the requested read operation.
+ @param ReadSize On input, the size in bytes of the requested read operation.
On output, the number of bytes actually read.
@param Buffer Output buffer that contains the data read from the PE/COFF image.
- @retval RETURN_SUCCESS Data is read from FileOffset from the Handle into
+ @retval RETURN_SUCCESS Data is read from FileOffset from the Handle into
the buffer.
**/
RETURN_STATUS
@@ -176,33 +176,33 @@ PeCoffLoaderImageReadFromMemory ( ReadSize,
Buffer
);
-
+
}
/**
Reapply fixups on a fixed up PE32/PE32+ image to allow virutal calling at EFI
- runtime.
-
- This function reapplies relocation fixups to the PE/COFF image specified by ImageBase
- and ImageSize so the image will execute correctly when the PE/COFF image is mapped
- to the address specified by VirtualImageBase. RelocationData must be identical
- to the FiuxupData buffer from the PE_COFF_LOADER_IMAGE_CONTEXT structure
+ runtime.
+
+ This function reapplies relocation fixups to the PE/COFF image specified by ImageBase
+ and ImageSize so the image will execute correctly when the PE/COFF image is mapped
+ to the address specified by VirtualImageBase. RelocationData must be identical
+ to the FiuxupData buffer from the PE_COFF_LOADER_IMAGE_CONTEXT structure
after this PE/COFF image was relocated with PeCoffLoaderRelocateImage().
Note that if the platform does not maintain coherency between the instruction cache(s) and the data
cache(s) in hardware, then the caller is responsible for performing cache maintenance operations
prior to transferring control to a PE/COFF image that is loaded using this library.
- @param ImageBase Base address of a PE/COFF image that has been loaded
+ @param ImageBase Base address of a PE/COFF image that has been loaded
and relocated into system memory.
@param VirtImageBase The request virtual address that the PE/COFF image is to
be fixed up for.
@param ImageSize The size, in bytes, of the PE/COFF image.
- @param RelocationData A pointer to the relocation data that was collected when the PE/COFF
+ @param RelocationData A pointer to the relocation data that was collected when the PE/COFF
image was relocated using PeCoffLoaderRelocateImage().
-
+
**/
VOID
EFIAPI
@@ -224,15 +224,15 @@ PeCoffLoaderRelocateImageForRuntime ( /**
Unloads a loaded PE/COFF image from memory and releases its taken resource.
- Releases any environment specific resources that were allocated when the image
- specified by ImageContext was loaded using PeCoffLoaderLoadImage().
-
+ Releases any environment specific resources that were allocated when the image
+ specified by ImageContext was loaded using PeCoffLoaderLoadImage().
+
For NT32 emulator, the PE/COFF image loaded by system needs to release.
- For real platform, the PE/COFF image loaded by Core doesn't needs to be unloaded,
+ For real platform, the PE/COFF image loaded by Core doesn't needs to be unloaded,
this function can simply return RETURN_SUCCESS.
-
+
If ImageContext is NULL, then ASSERT().
-
+
@param ImageContext Pointer to the image context structure that describes the PE/COFF
image to be unloaded.
@@ -280,7 +280,7 @@ DxeHobPeCoffLibConstructor ( if (Hob == NULL) {
return EFI_NOT_FOUND;
}
-
+
gPeCoffLoader = Hob->Interface;
return EFI_SUCCESS;
}
diff --git a/EmbeddedPkg/Library/DxeHobPeCoffLib/DxeHobPeCoffLib.inf b/EmbeddedPkg/Library/DxeHobPeCoffLib/DxeHobPeCoffLib.inf index 048394b9bb..d6eb1cf0cf 100644 --- a/EmbeddedPkg/Library/DxeHobPeCoffLib/DxeHobPeCoffLib.inf +++ b/EmbeddedPkg/Library/DxeHobPeCoffLib/DxeHobPeCoffLib.inf @@ -1,5 +1,5 @@ #/** @file
-# PE/COFF Loader Library implementation that wraps a protocol passed up from
+# PE/COFF Loader Library implementation that wraps a protocol passed up from
# SEC/PEI via a HOB. This is done to save space.
#
# Copyright (c) 2010, Intel Corporation. All rights reserved.<BR>
@@ -20,7 +20,7 @@ FILE_GUID = 671C6FD7-99FB-4EE3-B640-4B1D463BC3B5
MODULE_TYPE = DXE_DRIVER
VERSION_STRING = 1.0
- LIBRARY_CLASS = PeCoffLib
+ LIBRARY_CLASS = PeCoffLib
CONSTRUCTOR = DxeHobPeCoffLibConstructor
diff --git a/EmbeddedPkg/Library/EblAddExternalCommandLib/EblAddExternalCommandLib.c b/EmbeddedPkg/Library/EblAddExternalCommandLib/EblAddExternalCommandLib.c index 90ae8d44d5..3b9f1846d3 100644 --- a/EmbeddedPkg/Library/EblAddExternalCommandLib/EblAddExternalCommandLib.c +++ b/EmbeddedPkg/Library/EblAddExternalCommandLib/EblAddExternalCommandLib.c @@ -36,7 +36,7 @@ EBL_ADD_COMMAND_PROTOCOL *gEblExternalCommand = NULL; @param Key EFI Key information returned
@param TimeoutInSec Number of seconds to wait to timeout
- @param CallBack Callback called every second during the timeout wait
+ @param CallBack Callback called every second during the timeout wait
@return EFI_SUCCESS Key was returned
@return EFI_TIMEOUT If the TimoutInSec expired
@@ -64,7 +64,7 @@ EblGetCharKey ( If the use hits Q to quit return TRUE else for any other key return FALSE.
PrefixNewline is used to figure out if a newline is needed before the prompt
string. This depends on the last print done before calling this function.
- CurrentRow is updated by one on a call or set back to zero if a prompt is
+ CurrentRow is updated by one on a call or set back to zero if a prompt is
needed.
@param CurrentRow Used to figure out if its the end of the page and updated
@@ -118,12 +118,12 @@ EblAddCommandNotificationEvent ( /**
The user Entry Point for the driver. The user code starts with this function
- as the real entry point for the image goes into a library that calls this
+ as the real entry point for the image goes into a library that calls this
function.
- @param[in] ImageHandle The firmware allocated handle for the EFI image.
+ @param[in] ImageHandle The firmware allocated handle for the EFI image.
@param[in] SystemTable A pointer to the EFI System Table.
-
+
@retval EFI_SUCCESS The entry point is executed successfully.
@retval other Some error occurs when executing this entry point.
@@ -141,7 +141,7 @@ EblAddExternalCommands ( mAddExternalCmdLibTemplate = EntryArray;
mAddExternalCmdLibTemplateSize = ArrayCount;
-
+
EfiCreateProtocolNotifyEvent (
&gEfiEblAddCommandProtocolGuid,
TPL_CALLBACK,
@@ -149,7 +149,7 @@ EblAddExternalCommands ( NULL,
&mEblCommandRegistration
);
-
+
return EFI_SUCCESS;
}
diff --git a/EmbeddedPkg/Library/EblAddExternalCommandLib/EblAddExternalCommandLib.inf b/EmbeddedPkg/Library/EblAddExternalCommandLib/EblAddExternalCommandLib.inf index 03258751c0..335386a8c8 100644 --- a/EmbeddedPkg/Library/EblAddExternalCommandLib/EblAddExternalCommandLib.inf +++ b/EmbeddedPkg/Library/EblAddExternalCommandLib/EblAddExternalCommandLib.inf @@ -20,7 +20,7 @@ FILE_GUID = 9195D970-C6F7-484E-8013-5B03C89C3B81
MODULE_TYPE = UEFI_DRIVER
VERSION_STRING = 1.0
- LIBRARY_CLASS = EblAddExternalCommandLib|DXE_DRIVER UEFI_APPLICATION UEFI_DRIVER
+ LIBRARY_CLASS = EblAddExternalCommandLib|DXE_DRIVER UEFI_APPLICATION UEFI_DRIVER
#
@@ -40,9 +40,8 @@ UefiBootServicesTableLib
UefiLib
EblAddExternalCommandLib
-
+
[Protocols]
gEfiEblAddCommandProtocolGuid
-
+
[Guids]
-
\ No newline at end of file diff --git a/EmbeddedPkg/Library/EblCmdLibNull/EblCmdLibNull.inf b/EmbeddedPkg/Library/EblCmdLibNull/EblCmdLibNull.inf index 52e343997d..c7935ae37e 100644 --- a/EmbeddedPkg/Library/EblCmdLibNull/EblCmdLibNull.inf +++ b/EmbeddedPkg/Library/EblCmdLibNull/EblCmdLibNull.inf @@ -20,7 +20,7 @@ FILE_GUID = 3513C4E2-06D6-4921-9C2B-E938777BA79E
MODULE_TYPE = UEFI_DRIVER
VERSION_STRING = 1.0
- LIBRARY_CLASS = EfiCmdLib|DXE_DRIVER UEFI_APPLICATION UEFI_DRIVER
+ LIBRARY_CLASS = EfiCmdLib|DXE_DRIVER UEFI_APPLICATION UEFI_DRIVER
#
@@ -37,8 +37,7 @@ EmbeddedPkg/EmbeddedPkg.dec
[LibraryClasses]
-
+
[Protocols]
-
+
[Guids]
-
\ No newline at end of file diff --git a/EmbeddedPkg/Library/EblNetworkLib/EblNetworkLib.c b/EmbeddedPkg/Library/EblNetworkLib/EblNetworkLib.c index 3b0f6a1c71..1c945cd33b 100644 --- a/EmbeddedPkg/Library/EblNetworkLib/EblNetworkLib.c +++ b/EmbeddedPkg/Library/EblNetworkLib/EblNetworkLib.c @@ -1,7 +1,7 @@ /** @file
Copyright (c) 2008 - 2009, Apple Inc. All rights reserved.<BR>
-
+
This program and the accompanying materials
are licensed and made available under the terms and conditions of the BSD License
which accompanies this distribution. The full text of the license may be found at
@@ -32,7 +32,7 @@ EblGetCurrentIpAddress ( {
EFI_STATUS Status;
EFI_PXE_BASE_CODE_PROTOCOL *Pxe;
-
+
Status = gBS->LocateProtocol (&gEfiPxeBaseCodeProtocolGuid, NULL, (VOID **)&Pxe);
if (EFI_ERROR(Status)) {
return Status;
@@ -76,13 +76,13 @@ EblLoadFileBootTypeString ( {
EFI_STATUS Status;
VOID *NullPtr;
-
+
Status = gBS->HandleProtocol (Handle, &gEfiPxeBaseCodeProtocolGuid, &NullPtr);
if (!EFI_ERROR (Status)) {
return "EFI PXE Network Boot";
}
-
- return "";
+
+ return "";
}
EFI_STATUS
@@ -93,7 +93,7 @@ EblPerformDHCP ( {
EFI_STATUS Status;
EFI_PXE_BASE_CODE_PROTOCOL *Pxe;
-
+
Status = gBS->LocateProtocol (&gEfiPxeBaseCodeProtocolGuid, NULL, (VOID **)&Pxe);
if (EFI_ERROR(Status)) {
return Status;
@@ -118,7 +118,7 @@ EblSetStationIp ( {
EFI_STATUS Status;
EFI_PXE_BASE_CODE_PROTOCOL *Pxe;
-
+
Status = gBS->LocateProtocol (&gEfiPxeBaseCodeProtocolGuid, NULL, (VOID **)&Pxe);
if (EFI_ERROR(Status)) {
return Status;
@@ -128,12 +128,12 @@ EblSetStationIp ( if (EFI_ERROR(Status) && (Status != EFI_ALREADY_STARTED)) {
return Status;
}
-
+
Status = Pxe->SetStationIp (Pxe, NewStationIp, NewSubnetMask);
return Status;
}
-
+
EFI_STATUS
EFIAPI
EblMtftp (
@@ -150,12 +150,12 @@ EblMtftp ( {
EFI_STATUS Status;
EFI_PXE_BASE_CODE_PROTOCOL *Pxe;
-
+
Status = gBS->LocateProtocol (&gEfiPxeBaseCodeProtocolGuid, NULL, (VOID **)&Pxe);
if (EFI_ERROR(Status)) {
return Status;
}
-
+
Status = Pxe->Mtftp (
Pxe,
Operation,
@@ -170,4 +170,4 @@ EblMtftp ( );
return Status;
}
-
+
diff --git a/EmbeddedPkg/Library/EblNetworkLib/EblNetworkLib.inf b/EmbeddedPkg/Library/EblNetworkLib/EblNetworkLib.inf index 4d66bacb81..c9b2d31dc4 100644 --- a/EmbeddedPkg/Library/EblNetworkLib/EblNetworkLib.inf +++ b/EmbeddedPkg/Library/EblNetworkLib/EblNetworkLib.inf @@ -1,14 +1,14 @@ #/** @file
-#
+#
# Copyright (c) 2008 - 2010, Apple Inc. All rights reserved.<BR>
# This program and the accompanying materials
# are licensed and made available under the terms and conditions of the BSD License
# which accompanies this distribution. The full text of the license may be found at
# http://opensource.org/licenses/bsd-license.php
-#
+#
# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
-#
+#
#**/
[Defines]
@@ -31,4 +31,4 @@ gEfiPxeBaseCodeProtocolGuid
[Depex]
- TRUE
\ No newline at end of file + TRUE
diff --git a/EmbeddedPkg/Library/EfiFileLib/EfiFileLib.c b/EmbeddedPkg/Library/EfiFileLib/EfiFileLib.c index 83a3b7841f..448127d93f 100644 --- a/EmbeddedPkg/Library/EfiFileLib/EfiFileLib.c +++ b/EmbeddedPkg/Library/EfiFileLib/EfiFileLib.c @@ -34,19 +34,19 @@ Fv2: - EFI Firmware VOlume device 2 **/
#include <PiDxe.h>
-#include <Protocol/BlockIo.h>
-#include <Protocol/DiskIo.h>
-#include <Protocol/SimpleFileSystem.h>
-#include <Protocol/FirmwareVolume2.h>
+#include <Protocol/BlockIo.h>
+#include <Protocol/DiskIo.h>
+#include <Protocol/SimpleFileSystem.h>
+#include <Protocol/FirmwareVolume2.h>
#include <Protocol/LoadFile.h>
-#include <Protocol/FirmwareVolumeBlock.h>
+#include <Protocol/FirmwareVolumeBlock.h>
#include <Guid/FileInfo.h>
#include <Library/BaseLib.h>
#include <Library/MemoryAllocationLib.h>
#include <Library/DevicePathLib.h>
#include <Library/PrintLib.h>
#include <Library/BaseMemoryLib.h>
-#include <Library/UefiLib.h>
+#include <Library/UefiLib.h>
#include <Library/UefiBootServicesTableLib.h>
#include <Library/UefiRuntimeServicesTableLib.h>
#include <Library/DebugLib.h>
@@ -210,7 +210,7 @@ EblUpdateDeviceLists ( /**
PathName is in the form <device name>:<path> for example fs1:\ or ROOT:\.
Return TRUE if the <devce name> prefix of PathName matches a file system
-Volume Name. MatchIndex is the array index in mFsInfo[] of the match,
+Volume Name. MatchIndex is the array index in mFsInfo[] of the match,
and it can be used with mFs[] to find the handle that needs to be opened
@param PathName PathName to check
@@ -291,7 +291,7 @@ EfiGetDeviceCounts ( EFI_STATUS
ConvertIpStringToEfiIp (
- IN CHAR8 *PathName,
+ IN CHAR8 *PathName,
OUT EFI_IP_ADDRESS *ServerIp
)
{
@@ -326,7 +326,7 @@ ConvertIpStringToEfiIp ( /**
-Internal work function to extract a device number from a string skipping
+Internal work function to extract a device number from a string skipping
text. Easy way to extract numbers from strings like blk7:.
@param Str String to extract device number form
@@ -344,7 +344,7 @@ EblConvertDevStringToNumber ( UINTN Index;
- // Find the first digit
+ // Find the first digit
Max = AsciiStrLen (Str);
for (Index = 0; !((*Str >= '0') && (*Str <= '9')) && (Index < Max); Index++) {
Str++;
@@ -563,11 +563,11 @@ EblFvFileDevicePath ( do {
File->FvType = EFI_FV_FILETYPE_ALL;
GetNextFileStatus = File->Fv->GetNextFile (
- File->Fv,
+ File->Fv,
&Key,
- &File->FvType,
- &File->FvNameGuid,
- &File->FvAttributes,
+ &File->FvType,
+ &File->FvNameGuid,
+ &File->FvAttributes,
&File->Size
);
if (!EFI_ERROR (GetNextFileStatus)) {
@@ -634,17 +634,17 @@ EblFvFileDevicePath ( /**
-Open a device named by PathName. The PathName includes a device name and
+Open a device named by PathName. The PathName includes a device name and
path separated by a :. See file header for more details on the PathName
syntax. There is no checking to prevent a file from being opened more than
-one type.
+one type.
SectionType is only used to open an FV. Each file in an FV contains multiple
sections and only the SectionType section is opened.
For any file that is opened with EfiOpen() must be closed with EfiClose().
-@param PathName Path to parse to open
+@param PathName Path to parse to open
@param OpenMode Same as EFI_FILE.Open()
@param SectionType Section in FV to open.
@@ -711,7 +711,7 @@ EfiOpen ( }
if ((PathName[0] == '/') || (PathName[0] == '\\')) {
- // PathName starts in / so this means we go to the root of the device in the CWD.
+ // PathName starts in / so this means we go to the root of the device in the CWD.
CwdPlusPathName[0] = '\0';
for (FileStart = 0; gCwd[FileStart] != '\0'; FileStart++) {
CwdPlusPathName[FileStart] = gCwd[FileStart];
@@ -740,7 +740,7 @@ EfiOpen ( return File;
}
- DevNumber = EblConvertDevStringToNumber ((CHAR8 *)PathName);
+ DevNumber = EblConvertDevStringToNumber ((CHAR8 *)PathName);
}
File->DeviceName = AllocatePool (StrLen);
@@ -750,11 +750,11 @@ EfiOpen ( if (File->FileName[0] == '\0') {
// if it is just a file name use / as root
File->FileName = "\\";
- }
+ }
//
// Use best match algorithm on the dev names so we only need to look at the
- // first few charters to match the full device name. Short name forms are
+ // first few charters to match the full device name. Short name forms are
// legal from the caller.
//
Status = EFI_SUCCESS;
@@ -767,7 +767,7 @@ EfiOpen ( File->EfiHandle = mFs[DevNumber];
Status = EblFileDevicePath (File, &PathName[FileStart], OpenMode);
- } else if (PathName[1] == 'v' || PathName[1] == 'V') {
+ } else if (PathName[1] == 'v' || PathName[1] == 'V') {
if (DevNumber >= mFvCount) {
goto ErrorExit;
}
@@ -784,7 +784,7 @@ EfiOpen ( for (Index = FileStart; PathName[Index] != '\0'; Index++) {
if (PathName[Index] == ':') {
// Support fv0:\DxeCore:0x10
- // This means open the PE32 Section of the file
+ // This means open the PE32 Section of the file
ModifiedSectionType = (EFI_SECTION_TYPE)AsciiStrHexToUintn (&PathName[Index + 1]);
PathName[Index] = '\0';
}
@@ -960,7 +960,7 @@ EfiCopyFile ( if (EFI_ERROR(Status)) {
AsciiPrint("Write file error %r\n", Status);
goto Exit;
- }
+ }
}
// Any left over?
@@ -977,7 +977,7 @@ EfiCopyFile ( if (EFI_ERROR(Status)) {
AsciiPrint("Write file error\n");
goto Exit;
- }
+ }
}
Exit:
@@ -1026,16 +1026,16 @@ EfiDeviceOpenByType ( DevStr = "loadfile%d:";
break;
case EfiOpenFirmwareVolume:
- DevStr = "fv%d:";
+ DevStr = "fv%d:";
break;
case EfiOpenFileSystem:
- DevStr = "fs%d:";
+ DevStr = "fs%d:";
break;
case EfiOpenBlockIo:
- DevStr = "blk%d:";
+ DevStr = "blk%d:";
break;
case EfiOpenMemoryBuffer:
- DevStr = "a%d:";
+ DevStr = "a%d:";
break;
default:
return NULL;
@@ -1074,14 +1074,14 @@ EfiClose ( TftpBufferSize = File->Size;
Status = EblMtftp (
- EFI_PXE_BASE_CODE_TFTP_WRITE_FILE,
- File->Buffer,
- TRUE,
- &TftpBufferSize,
- NULL,
- &File->ServerIp,
- (UINT8 *)File->FileName,
- NULL,
+ EFI_PXE_BASE_CODE_TFTP_WRITE_FILE,
+ File->Buffer,
+ TRUE,
+ &TftpBufferSize,
+ NULL,
+ &File->ServerIp,
+ (UINT8 *)File->FileName,
+ NULL,
FALSE
);
if (EFI_ERROR(Status)) {
@@ -1090,7 +1090,7 @@ EfiClose ( }
}
- if ((File->Type == EfiOpenLoadFile) ||
+ if ((File->Type == EfiOpenLoadFile) ||
((File->Type == EfiOpenTftp) && (File->IsBufferValid == TRUE)) ||
((File->Type == EfiOpenFirmwareVolume) && (File->IsBufferValid == TRUE))) {
EblFreePool(File->Buffer);
@@ -1112,9 +1112,9 @@ EfiClose ( /**
-Return the size of the file represented by Stream. Also return the current
+Return the size of the file represented by Stream. Also return the current
Seek position. Opening a file will enable a valid file size to be returned.
-LoadFile is an exception as a load file size is set to zero.
+LoadFile is an exception as a load file size is set to zero.
@param Stream Open File Handle
@@ -1176,7 +1176,7 @@ EfiTell ( /**
Seek to the Offset location in the file. LoadFile and FV device types do
-not support EfiSeek(). It is not possible to grow the file size using
+not support EfiSeek(). It is not possible to grow the file size using
EfiSeek().
SeekType defines how use Offset to calculate the new file position:
@@ -1185,7 +1185,7 @@ EfiSeekCurrent: Position is Offset bytes from the current position EfiSeekEnd : Only supported if Offset is zero to seek to end of file.
@param Stream Open File Handle
-@param Offset Offset to seek too.
+@param Offset Offset to seek too.
@param SeekType Type of seek to perform
@@ -1278,14 +1278,14 @@ CacheTftpFile ( TftpBufferSize = File->Size;
Status = EblMtftp (
- EFI_PXE_BASE_CODE_TFTP_READ_FILE,
- File->Buffer,
- FALSE,
- &TftpBufferSize,
- NULL,
- &File->ServerIp,
- (UINT8 *)File->FileName,
- NULL,
+ EFI_PXE_BASE_CODE_TFTP_READ_FILE,
+ File->Buffer,
+ FALSE,
+ &TftpBufferSize,
+ NULL,
+ &File->ServerIp,
+ (UINT8 *)File->FileName,
+ NULL,
FALSE);
if (EFI_ERROR(Status)) {
AsciiPrint("TFTP error during APPLE_NSP_TFTP_READ_FILE: %r\n", Status);
@@ -1301,10 +1301,10 @@ CacheTftpFile ( /**
Read BufferSize bytes from the current location in the file. For load file,
-FV, and TFTP case you must read the entire file.
+FV, and TFTP case you must read the entire file.
@param Stream Open File Handle
-@param Buffer Caller allocated buffer.
+@param Buffer Caller allocated buffer.
@param BufferSize Size of buffer in bytes.
@@ -1345,7 +1345,7 @@ EfiRead ( case EfiOpenFirmwareVolume:
if (CompareGuid (&File->FvNameGuid, &gZeroGuid)) {
- // This is the entire FV device, so treat like a memory buffer
+ // This is the entire FV device, so treat like a memory buffer
CopyMem (Buffer, (VOID *)(UINTN)(File->FvStart + File->CurrentPosition), *BufferSize);
File->CurrentPosition += *BufferSize;
Status = EFI_SUCCESS;
@@ -1429,13 +1429,13 @@ EfiRead ( /**
Read the entire file into a buffer. This routine allocates the buffer and
-returns it to the user full of the read data.
+returns it to the user full of the read data.
This is very useful for load file where it's hard to know how big the buffer
must be.
@param Stream Open File Handle
-@param Buffer Pointer to buffer to return.
+@param Buffer Pointer to buffer to return.
@param BufferSize Pointer to Size of buffer return..
@@ -1471,10 +1471,10 @@ EfiReadAllocatePool ( /**
-Write data back to the file. For TFTP case you must write the entire file.
+Write data back to the file. For TFTP case you must write the entire file.
@param Stream Open File Handle
-@param Buffer Pointer to buffer to return.
+@param Buffer Pointer to buffer to return.
@param BufferSize Pointer to Size of buffer return..
@@ -1494,7 +1494,7 @@ EfiWrite ( {
EFI_STATUS Status;
EFI_FV_WRITE_FILE_DATA FileData;
- EFI_DISK_IO_PROTOCOL *DiskIo;
+ EFI_DISK_IO_PROTOCOL *DiskIo;
if (!FileHandleValid (File)) {
return EFI_INVALID_PARAMETER;
@@ -1592,7 +1592,7 @@ EfiWrite ( /**
-Given Cwd expand Path to remove .. and replace them with real
+Given Cwd expand Path to remove .. and replace them with real
directory names.
@param Cwd Current Working Directory
@@ -1636,9 +1636,9 @@ ExpandPath ( if (Work == NULL) {
// Remaining part of Path contains no more ..
break;
- }
+ }
- // append path prior to ..
+ // append path prior to ..
AsciiStrnCat (NewPath, Start, Work - Start);
StrLen = AsciiStrLen (NewPath);
for (i = StrLen; i >= 0; i--) {
@@ -1659,7 +1659,7 @@ ExpandPath ( }
Start = Work + 3;
- }
+ }
// Handle the path that remains after the ..
AsciiStrnCat (NewPath, Start, End - Start);
@@ -1682,7 +1682,7 @@ the path does not contain a device name, The CWD is prepended to the path. EFI_STATUS
EfiSetCwd (
IN CHAR8 *Cwd
- )
+ )
{
EFI_OPEN_FILE *File;
UINTN Len;
@@ -1700,7 +1700,7 @@ EfiSetCwd ( Path = Cwd;
if (AsciiStrStr (Cwd, "..") != NULL) {
if (gCwd == NULL) {
- // no parent
+ // no parent
return EFI_SUCCESS;
}
@@ -1754,10 +1754,10 @@ EfiSetCwd ( Set the Current Working Directory (CWD). If a call is made to EfiOpen () and
the path does not contain a device name, The CWD is prepended to the path.
The CWD buffer is only valid until a new call is made to EfiSetCwd(). After
-a call to EfiSetCwd() it is not legal to use the pointer returned by
+a call to EfiSetCwd() it is not legal to use the pointer returned by
this function.
-@param Cwd Current Working Directory
+@param Cwd Current Working Directory
@return "" No CWD set
diff --git a/EmbeddedPkg/Library/EfiFileLib/EfiFileLib.inf b/EmbeddedPkg/Library/EfiFileLib/EfiFileLib.inf index a82c264247..74360dc80b 100644 --- a/EmbeddedPkg/Library/EfiFileLib/EfiFileLib.inf +++ b/EmbeddedPkg/Library/EfiFileLib/EfiFileLib.inf @@ -20,7 +20,7 @@ FILE_GUID = d8c640db-73ba-48f5-a7ed-8e93c6012491
MODULE_TYPE = UEFI_DRIVER
VERSION_STRING = 1.0
- LIBRARY_CLASS = EfiFileLib|DXE_DRIVER UEFI_APPLICATION UEFI_DRIVER
+ LIBRARY_CLASS = EfiFileLib|DXE_DRIVER UEFI_APPLICATION UEFI_DRIVER
#
@@ -44,12 +44,12 @@ DevicePathLib
PrintLib
BaseMemoryLib
- UefiLib
+ UefiLib
UefiBootServicesTableLib
UefiRuntimeServicesTableLib
DebugLib
EblNetworkLib
-
+
[Protocols]
gEfiBlockIoProtocolGuid # PROTOCOL SOMETIMES_CONSUMED
gEfiDiskIoProtocolGuid # PROTOCOL SOMETIMES_CONSUMED
@@ -57,7 +57,7 @@ gEfiFirmwareVolume2ProtocolGuid # PROTOCOL SOMETIMES_CONSUMED
gEfiLoadFileProtocolGuid # PROTOCOL SOMETIMES_CONSUMED
gEfiFirmwareVolumeBlockProtocolGuid # PROTOCOL SOMETIMES_CONSUMED
-
+
[Guids]
gEfiFileInfoGuid
gEfiFileSystemInfoGuid
diff --git a/EmbeddedPkg/Library/FdtLib/FdtLib.inf b/EmbeddedPkg/Library/FdtLib/FdtLib.inf index aee99bd997..51b13f4af7 100644 --- a/EmbeddedPkg/Library/FdtLib/FdtLib.inf +++ b/EmbeddedPkg/Library/FdtLib/FdtLib.inf @@ -1,13 +1,13 @@ #/* @file
# Copyright (c) 2011-2012, ARM Limited. All rights reserved.
-#
-# This program and the accompanying materials
-# are licensed and made available under the terms and conditions of the BSD License
-# which accompanies this distribution. The full text of the license may be found at
-# http://opensource.org/licenses/bsd-license.php
#
-# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
-# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
+# This program and the accompanying materials
+# are licensed and made available under the terms and conditions of the BSD License
+# which accompanies this distribution. The full text of the license may be found at
+# http://opensource.org/licenses/bsd-license.php
+#
+# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
+# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
#
#*/
diff --git a/EmbeddedPkg/Library/GdbDebugAgent/Arm/ExceptionSupport.ARMv6.S b/EmbeddedPkg/Library/GdbDebugAgent/Arm/ExceptionSupport.ARMv6.S index 9c3cc3ce3c..df1543a6d2 100755 --- a/EmbeddedPkg/Library/GdbDebugAgent/Arm/ExceptionSupport.ARMv6.S +++ b/EmbeddedPkg/Library/GdbDebugAgent/Arm/ExceptionSupport.ARMv6.S @@ -1,4 +1,4 @@ -#------------------------------------------------------------------------------
+#------------------------------------------------------------------------------
#
# Use ARMv6 instruction to operate on a single stack
#
@@ -19,7 +19,7 @@ This is the stack constructed by the exception handler (low address to high address)
# R0 - IFAR is EFI_SYSTEM_CONTEXT for ARM
Reg Offset
- === ======
+ === ======
R0 0x00 # stmfd SP!,{R0-R12}
R1 0x04
R2 0x08
@@ -41,14 +41,14 @@ This is the stack constructed by the exception handler (low address to high addr DFAR 0x48
IFSR 0x4c
IFAR 0x50
-
+
LR 0x54 # SVC Link register (we need to restore it)
-
- LR 0x58 # pushed by srsfd
- CPSR 0x5c
+
+ LR 0x58 # pushed by srsfd
+ CPSR 0x5c
*/
-
+
GCC_ASM_EXPORT(ExceptionHandlersStart)
GCC_ASM_EXPORT(ExceptionHandlersEnd)
@@ -175,55 +175,55 @@ ASM_PFX(CommonExceptionEntry): ASM_PFX(ExceptionHandlersEnd):
//
-// This code runs from CpuDxe driver loaded address. It is patched into
+// This code runs from CpuDxe driver loaded address. It is patched into
// CommonExceptionEntry.
//
ASM_PFX(AsmCommonExceptionEntry):
mrc p15, 0, R1, c6, c0, 2 @ Read IFAR
- str R1, [SP, #0x50] @ Store it in EFI_SYSTEM_CONTEXT_ARM.IFAR
-
+ str R1, [SP, #0x50] @ Store it in EFI_SYSTEM_CONTEXT_ARM.IFAR
+
mrc p15, 0, R1, c5, c0, 1 @ Read IFSR
str R1, [SP, #0x4c] @ Store it in EFI_SYSTEM_CONTEXT_ARM.IFSR
-
+
mrc p15, 0, R1, c6, c0, 0 @ Read DFAR
str R1, [SP, #0x48] @ Store it in EFI_SYSTEM_CONTEXT_ARM.DFAR
-
+
mrc p15, 0, R1, c5, c0, 0 @ Read DFSR
str R1, [SP, #0x44] @ Store it in EFI_SYSTEM_CONTEXT_ARM.DFSR
-
- ldr R1, [SP, #0x5c] @ srsdb saved pre-exception CPSR on the stack
+
+ ldr R1, [SP, #0x5c] @ srsdb saved pre-exception CPSR on the stack
str R1, [SP, #0x40] @ Store it in EFI_SYSTEM_CONTEXT_ARM.CPSR
add R2, SP, #0x38 @ Make R2 point to EFI_SYSTEM_CONTEXT_ARM.LR
and R3, R1, #0x1f @ Check CPSR to see if User or System Mode
cmp R3, #0x1f @ if ((CPSR == 0x10) || (CPSR == 0x1df))
- cmpne R3, #0x10 @
+ cmpne R3, #0x10 @
stmeqed R2, {lr}^ @ save unbanked lr
- @ else
+ @ else
stmneed R2, {lr} @ save SVC lr
- ldr R5, [SP, #0x58] @ PC is the LR pushed by srsfd
+ ldr R5, [SP, #0x58] @ PC is the LR pushed by srsfd
@ Check to see if we have to adjust for Thumb entry
sub r4, r0, #1 @ if (ExceptionType == 1 || ExceptionType ==2)) {
- cmp r4, #1 @ // UND & SVC have differnt LR adjust for Thumb
+ cmp r4, #1 @ // UND & SVC have differnt LR adjust for Thumb
bhi NoAdjustNeeded
-
- tst r1, #0x20 @ if ((CPSR & T)) == T) { // Thumb Mode on entry
+
+ tst r1, #0x20 @ if ((CPSR & T)) == T) { // Thumb Mode on entry
addne R5, R5, #2 @ PC += 2@
- str R5,[SP,#0x58] @ Update LR value pused by srsfd
-
+ str R5,[SP,#0x58] @ Update LR value pused by srsfd
+
NoAdjustNeeded:
str R5, [SP, #0x3c] @ Store it in EFI_SYSTEM_CONTEXT_ARM.PC
-
- sub R1, SP, #0x60 @ We pused 0x60 bytes on the stack
+
+ sub R1, SP, #0x60 @ We pused 0x60 bytes on the stack
str R1, [SP, #0x34] @ Store it in EFI_SYSTEM_CONTEXT_ARM.SP
-
- @ R0 is ExceptionType
- mov R1,SP @ R1 is SystemContext
-/*
+ @ R0 is ExceptionType
+ mov R1,SP @ R1 is SystemContext
+
+/*
VOID
EFIAPI
GdbExceptionHandler (
@@ -231,28 +231,28 @@ GdbExceptionHandler ( IN OUT EFI_SYSTEM_CONTEXT SystemContext R1
)
-*/
+*/
blx ASM_PFX(GdbExceptionHandler) @ Call exception handler
-
+
ldr R1,[SP,#0x3c] @ EFI_SYSTEM_CONTEXT_ARM.PC
- str R1,[SP,#0x58] @ Store it back to srsfd stack slot so it can be restored
+ str R1,[SP,#0x58] @ Store it back to srsfd stack slot so it can be restored
ldr R1,[SP,#0x40] @ EFI_SYSTEM_CONTEXT_ARM.CPSR
- str R1,[SP,#0x5c] @ Store it back to srsfd stack slot so it can be restored
-
+ str R1,[SP,#0x5c] @ Store it back to srsfd stack slot so it can be restored
+
add R3, SP, #0x54 @ Make R3 point to SVC LR saved on entry
add R2, SP, #0x38 @ Make R2 point to EFI_SYSTEM_CONTEXT_ARM.LR
and R1, R1, #0x1f @ Check to see if User or System Mode
cmp R1, #0x1f @ if ((CPSR == 0x10) || (CPSR == 0x1f))
- cmpne R1, #0x10 @
+ cmpne R1, #0x10 @
ldmeqed R2, {lr}^ @ restore unbanked lr
@ else
ldmneed R3, {lr} @ restore SVC lr, via ldmfd SP!, {LR}
-
+
ldmfd SP!,{R0-R12} @ Restore general purpose registers
@ Exception handler can not change SP
-
+
add SP,SP,#0x20 @ Clear out the remaining stack space
ldmfd SP!,{LR} @ restore the link register for this context
rfefd SP! @ return from exception via srsfd stack slot
-
+
diff --git a/EmbeddedPkg/Library/GdbDebugAgent/Arm/ExceptionSupport.ARMv6.asm b/EmbeddedPkg/Library/GdbDebugAgent/Arm/ExceptionSupport.ARMv6.asm index c70fb92482..611e83d7da 100755 --- a/EmbeddedPkg/Library/GdbDebugAgent/Arm/ExceptionSupport.ARMv6.asm +++ b/EmbeddedPkg/Library/GdbDebugAgent/Arm/ExceptionSupport.ARMv6.asm @@ -1,4 +1,4 @@ -//------------------------------------------------------------------------------
+//------------------------------------------------------------------------------
//
// Use ARMv6 instruction to operate on a single stack
//
@@ -21,7 +21,7 @@ This is the stack constructed by the exception handler (low address to high address)
# R0 - IFAR is EFI_SYSTEM_CONTEXT for ARM
Reg Offset
- === ======
+ === ======
R0 0x00 # stmfd SP!,{R0-R12}
R1 0x04
R2 0x08
@@ -43,15 +43,15 @@ This is the stack constructed by the exception handler (low address to high addr DFAR 0x48
IFSR 0x4c
IFAR 0x50
-
+
LR 0x54 # SVC Link register (we need to restore it)
-
- LR 0x58 # pushed by srsfd
- CPSR 0x5c
+
+ LR 0x58 # pushed by srsfd
+ CPSR 0x5c
*/
-
-
+
+
EXPORT ExceptionHandlersStart
EXPORT ExceptionHandlersEnd
EXPORT CommonExceptionEntry
@@ -60,7 +60,7 @@ This is the stack constructed by the exception handler (low address to high addr PRESERVE8
AREA DxeExceptionHandlers, CODE, READONLY
-
+
//
// This code gets copied to the ARM vector table
// ExceptionHandlersStart - ExceptionHandlersEnd gets copied
@@ -101,7 +101,7 @@ UndefinedInstructionEntry stmfd SP!,{R0-R12} ; Store the register state
mov R0,#1 ; ExceptionType
- ldr R1,CommonExceptionEntry;
+ ldr R1,CommonExceptionEntry;
bx R1
SoftwareInterruptEntry
@@ -173,55 +173,55 @@ CommonExceptionEntry ExceptionHandlersEnd
//
-// This code runs from CpuDxe driver loaded address. It is patched into
+// This code runs from CpuDxe driver loaded address. It is patched into
// CommonExceptionEntry.
//
AsmCommonExceptionEntry
mrc p15, 0, R1, c6, c0, 2 ; Read IFAR
- str R1, [SP, #0x50] ; Store it in EFI_SYSTEM_CONTEXT_ARM.IFAR
-
+ str R1, [SP, #0x50] ; Store it in EFI_SYSTEM_CONTEXT_ARM.IFAR
+
mrc p15, 0, R1, c5, c0, 1 ; Read IFSR
str R1, [SP, #0x4c] ; Store it in EFI_SYSTEM_CONTEXT_ARM.IFSR
-
+
mrc p15, 0, R1, c6, c0, 0 ; Read DFAR
str R1, [SP, #0x48] ; Store it in EFI_SYSTEM_CONTEXT_ARM.DFAR
-
+
mrc p15, 0, R1, c5, c0, 0 ; Read DFSR
str R1, [SP, #0x44] ; Store it in EFI_SYSTEM_CONTEXT_ARM.DFSR
-
- ldr R1, [SP, #0x5c] ; srsfd saved pre-exception CPSR on the stack
+
+ ldr R1, [SP, #0x5c] ; srsfd saved pre-exception CPSR on the stack
str R1, [SP, #0x40] ; Store it in EFI_SYSTEM_CONTEXT_ARM.CPSR
add R2, SP, #0x38 ; Make R2 point to EFI_SYSTEM_CONTEXT_ARM.LR
and R3, R1, #0x1f ; Check CPSR to see if User or System Mode
cmp R3, #0x1f ; if ((CPSR == 0x10) || (CPSR == 0x1df))
- cmpne R3, #0x10 ;
+ cmpne R3, #0x10 ;
stmeqed R2, {lr}^ ; save unbanked lr
- ; else
+ ; else
stmneed R2, {lr} ; save SVC lr
- ldr R5, [SP, #0x58] ; PC is the LR pushed by srsfd
+ ldr R5, [SP, #0x58] ; PC is the LR pushed by srsfd
; Check to see if we have to adjust for Thumb entry
sub r4, r0, #1 ; if (ExceptionType == 1 || ExceptionType ==2)) {
- cmp r4, #1 ; // UND & SVC have differnt LR adjust for Thumb
+ cmp r4, #1 ; // UND & SVC have differnt LR adjust for Thumb
bhi NoAdjustNeeded
-
- tst r1, #0x20 ; if ((CPSR & T)) == T) { // Thumb Mode on entry
+
+ tst r1, #0x20 ; if ((CPSR & T)) == T) { // Thumb Mode on entry
addne R5, R5, #2 ; PC += 2;
- str R5,[SP,#0x58] ; Update LR value pused by srsfd
-
+ str R5,[SP,#0x58] ; Update LR value pused by srsfd
+
NoAdjustNeeded
str R5, [SP, #0x3c] ; Store it in EFI_SYSTEM_CONTEXT_ARM.PC
-
- sub R1, SP, #0x60 ; We pused 0x60 bytes on the stack
+
+ sub R1, SP, #0x60 ; We pused 0x60 bytes on the stack
str R1, [SP, #0x34] ; Store it in EFI_SYSTEM_CONTEXT_ARM.SP
-
- ; R0 is ExceptionType
- mov R1,SP ; R1 is SystemContext
-/*
+ ; R0 is ExceptionType
+ mov R1,SP ; R1 is SystemContext
+
+/*
VOID
EFIAPI
GdbExceptionHandler (
@@ -231,29 +231,29 @@ GdbExceptionHandler ( */
blx GdbExceptionHandler ; Call exception handler
-
+
ldr R1,[SP,#0x3c] ; EFI_SYSTEM_CONTEXT_ARM.PC
- str R1,[SP,#0x58] ; Store it back to srsfd stack slot so it can be restored
+ str R1,[SP,#0x58] ; Store it back to srsfd stack slot so it can be restored
ldr R1,[SP,#0x40] ; EFI_SYSTEM_CONTEXT_ARM.CPSR
- str R1,[SP,#0x5c] ; Store it back to srsfd stack slot so it can be restored
-
+ str R1,[SP,#0x5c] ; Store it back to srsfd stack slot so it can be restored
+
add R3, SP, #0x54 ; Make R3 point to SVC LR saved on entry
add R2, SP, #0x38 ; Make R2 point to EFI_SYSTEM_CONTEXT_ARM.LR
and R1, R1, #0x1f ; Check to see if User or System Mode
cmp R1, #0x1f ; if ((CPSR == 0x10) || (CPSR == 0x1f))
- cmpne R1, #0x10 ;
+ cmpne R1, #0x10 ;
ldmeqed R2, {lr}^ ; restore unbanked lr
; else
ldmneed R3, {lr} ; restore SVC lr, via ldmfd SP!, {LR}
-
+
ldmfd SP!,{R0-R12} ; Restore general purpose registers
; Exception handler can not change SP
-
+
add SP,SP,#0x20 ; Clear out the remaining stack space
ldmfd SP!,{LR} ; restore the link register for this context
rfefd SP! ; return from exception via srsfd stack slot
-
+
END
diff --git a/EmbeddedPkg/Library/GdbDebugAgent/Arm/Processor.c b/EmbeddedPkg/Library/GdbDebugAgent/Arm/Processor.c index f22a19dded..61c6184fae 100755 --- a/EmbeddedPkg/Library/GdbDebugAgent/Arm/Processor.c +++ b/EmbeddedPkg/Library/GdbDebugAgent/Arm/Processor.c @@ -2,7 +2,7 @@ Processor specific parts of the GDB stub
Copyright (c) 2008 - 2010, Apple Inc. All rights reserved.<BR>
-
+
This program and the accompanying materials
are licensed and made available under the terms and conditions of the BSD License
which accompanies this distribution. The full text of the license may be found at
@@ -48,8 +48,8 @@ AsmCommonExceptionEntry ( //
EFI_EXCEPTION_TYPE_ENTRY gExceptionType[] = {
{ EXCEPT_ARM_SOFTWARE_INTERRUPT, GDB_SIGTRAP },
- { EXCEPT_ARM_UNDEFINED_INSTRUCTION, GDB_SIGTRAP },
- { EXCEPT_ARM_PREFETCH_ABORT, GDB_SIGTRAP },
+ { EXCEPT_ARM_UNDEFINED_INSTRUCTION, GDB_SIGTRAP },
+ { EXCEPT_ARM_PREFETCH_ABORT, GDB_SIGTRAP },
{ EXCEPT_ARM_DATA_ABORT, GDB_SIGTRAP }, // GDB_SIGEMT
{ EXCEPT_ARM_RESERVED, GDB_SIGTRAP }, // GDB_SIGILL
{ EXCEPT_ARM_FIQ, GDB_SIGINT } // Used for ctrl-c
@@ -113,8 +113,8 @@ UINTN gRegisterOffsets[] = { /**
Return the number of entries in the gExceptionType[]
-
- @retval UINTN, the number of entries in the gExceptionType[] array.
+
+ @retval UINTN, the number of entries in the gExceptionType[] array.
**/
UINTN
MaxEfiException (
@@ -128,10 +128,10 @@ MaxEfiException ( /**
- Check to see if the ISA is supported.
+ Check to see if the ISA is supported.
ISA = Instruction Set Architecture
- @retval TRUE if Isa is supported
+ @retval TRUE if Isa is supported
**/
BOOLEAN
@@ -150,14 +150,14 @@ CheckIsa ( /**
This takes in the register number and the System Context, and returns a pointer to the RegNumber-th register in gdb ordering
It is, by default, set to find the register pointer of the ARM member
- @param SystemContext Register content at time of the exception
+ @param SystemContext Register content at time of the exception
@param RegNumber The register to which we want to find a pointer
@retval the pointer to the RegNumber-th pointer
- **/
+ **/
UINTN *
FindPointerToRegister(
IN EFI_SYSTEM_CONTEXT SystemContext,
- IN UINTN RegNumber
+ IN UINTN RegNumber
)
{
UINT8 *TempPtr;
@@ -183,7 +183,7 @@ BasicReadRegister ( {
UINTN RegSize;
CHAR8 Char;
-
+
if (gRegisterOffsets[RegNumber] > 0xF00) {
AsciiSPrint(OutBufPtr, 9, "00000000");
OutBufPtr += 8;
@@ -197,13 +197,13 @@ BasicReadRegister ( Char = Char - 'A' + 'a';
}
*OutBufPtr++ = Char;
-
+
Char = mHexToStr[(UINT8)((*FindPointerToRegister(SystemContext, RegNumber) >> RegSize) & 0xf)];
if ((Char >= 'A') && (Char <= 'F')) {
Char = Char - 'A' + 'a';
}
*OutBufPtr++ = Char;
-
+
RegSize = RegSize + 8;
}
return OutBufPtr;
@@ -211,7 +211,7 @@ BasicReadRegister ( /**
- Reads the n-th register's value into an output buffer and sends it as a packet
+ Reads the n-th register's value into an output buffer and sends it as a packet
@param SystemContext Register content at time of the exception
@param InBuffer Pointer to the input buffer received from gdb server
**/
@@ -224,29 +224,29 @@ ReadNthRegister ( UINTN RegNumber;
CHAR8 OutBuffer[9]; // 1 reg=8 hex chars, and the end '\0' (escape seq)
CHAR8 *OutBufPtr; // pointer to the output buffer
-
+
RegNumber = AsciiStrHexToUintn (&InBuffer[1]);
-
+
if (RegNumber >= (sizeof (gRegisterOffsets)/sizeof (UINTN))) {
- SendError (GDB_EINVALIDREGNUM);
+ SendError (GDB_EINVALIDREGNUM);
return;
}
-
+
OutBufPtr = OutBuffer;
OutBufPtr = BasicReadRegister (SystemContext, RegNumber, OutBufPtr);
-
+
*OutBufPtr = '\0'; // the end of the buffer
SendPacket(OutBuffer);
}
/**
- Reads the general registers into an output buffer and sends it as a packet
+ Reads the general registers into an output buffer and sends it as a packet
@param SystemContext Register content at time of the exception
**/
VOID
EFIAPI
-ReadGeneralRegisters (
+ReadGeneralRegisters (
IN EFI_SYSTEM_CONTEXT SystemContext
)
{
@@ -254,13 +254,13 @@ ReadGeneralRegisters ( // a UINT32 takes 8 ascii characters
CHAR8 OutBuffer[(sizeof (gRegisterOffsets) * 2) + 1];
CHAR8 *OutBufPtr;
-
+
// It is not safe to allocate pool here....
OutBufPtr = OutBuffer;
for (Index = 0; Index < (sizeof (gRegisterOffsets)/sizeof (UINTN)); Index++) {
OutBufPtr = BasicReadRegister (SystemContext, Index, OutBufPtr);
}
-
+
*OutBufPtr = '\0';
SendPacket(OutBuffer);
}
@@ -283,7 +283,7 @@ BasicWriteRegister ( UINTN RegSize;
UINTN TempValue; // the value transferred from a hex char
UINT32 NewValue; // the new value of the RegNumber-th Register
-
+
if (gRegisterOffsets[RegNumber] > 0xF00) {
return InBufPtr + 8;
}
@@ -292,21 +292,21 @@ BasicWriteRegister ( RegSize = 0;
while (RegSize < 32) {
TempValue = HexCharToInt(*InBufPtr++);
-
+
if ((INTN)TempValue < 0) {
- SendError (GDB_EBADMEMDATA);
+ SendError (GDB_EBADMEMDATA);
return NULL;
}
-
+
NewValue += (TempValue << (RegSize+4));
TempValue = HexCharToInt(*InBufPtr++);
-
+
if ((INTN)TempValue < 0) {
- SendError (GDB_EBADMEMDATA);
+ SendError (GDB_EBADMEMDATA);
return NULL;
}
-
- NewValue += (TempValue << RegSize);
+
+ NewValue += (TempValue << RegSize);
RegSize = RegSize + 8;
}
*(FindPointerToRegister(SystemContext, RegNumber)) = NewValue;
@@ -329,19 +329,19 @@ WriteNthRegister ( CHAR8 RegNumBuffer[MAX_REG_NUM_BUF_SIZE]; // put the 'n..' part of the message into this array
CHAR8 *RegNumBufPtr;
CHAR8 *InBufPtr; // pointer to the input buffer
-
+
// find the register number to write
InBufPtr = &InBuffer[1];
RegNumBufPtr = RegNumBuffer;
while (*InBufPtr != '=') {
*RegNumBufPtr++ = *InBufPtr++;
- }
+ }
*RegNumBufPtr = '\0';
- RegNumber = AsciiStrHexToUintn (RegNumBuffer);
-
+ RegNumber = AsciiStrHexToUintn (RegNumBuffer);
+
// check if this is a valid Register Number
if (RegNumber >= (sizeof (gRegisterOffsets)/sizeof (UINTN))) {
- SendError (GDB_EINVALIDREGNUM);
+ SendError (GDB_EINVALIDREGNUM);
return;
}
InBufPtr++; // skips the '=' character
@@ -369,21 +369,21 @@ WriteGeneralRegisters ( UINTN RegisterCount = (sizeof (gRegisterOffsets)/sizeof (UINTN));
MinLength = (RegisterCount * 8) + 1; // 'G' plus the registers in ASCII format
-
+
if (AsciiStrLen(InBuffer) < MinLength) {
- //Bad message. Message is not the right length
- SendError (GDB_EBADBUFSIZE);
+ //Bad message. Message is not the right length
+ SendError (GDB_EBADBUFSIZE);
return;
}
-
+
InBufPtr = &InBuffer[1];
-
+
// Read the new values for the registers from the input buffer to an array, NewValueArray.
// The values in the array are in the gdb ordering
for(i = 0; i < RegisterCount; i++) {
InBufPtr = BasicWriteRegister (SystemContext, i, InBufPtr);
}
-
+
SendSuccess ();
}
@@ -391,10 +391,10 @@ WriteGeneralRegisters ( /**
- Continue. addr is Address to resume. If addr is omitted, resume at current
+ Continue. addr is Address to resume. If addr is omitted, resume at current
Address.
-
- @param SystemContext Register content at time of the exception
+
+ @param SystemContext Register content at time of the exception
**/
VOID
EFIAPI
@@ -405,15 +405,15 @@ ContinueAtAddress ( {
if (PacketData[1] != '\0') {
SystemContext.SystemContextArm->PC = AsciiStrHexToUintn(&PacketData[1]);
- }
+ }
}
/** ‘s [addr ]’
- Single step. addr is the Address at which to resume. If addr is omitted, resume
+ Single step. addr is the Address at which to resume. If addr is omitted, resume
at same Address.
-
- @param SystemContext Register content at time of the exception
+
+ @param SystemContext Register content at time of the exception
**/
VOID
EFIAPI
@@ -448,9 +448,9 @@ RemoveBreakPoint ( /**
- Send the T signal with the given exception type (in gdb order) and possibly
+ Send the T signal with the given exception type (in gdb order) and possibly
with n:r pairs related to the watchpoints
-
+
@param SystemContext Register content at time of the exception
@param GdbExceptionType GDB exception type
**/
@@ -467,13 +467,13 @@ ProcessorSendTSignal ( /**
FIQ state is only changed by FIQ exception. We don't want to take FIQ
- ticks in the GDB stub. The stub disables FIQ on entry, but this is the
+ ticks in the GDB stub. The stub disables FIQ on entry, but this is the
third instruction that executes in the execption handler. Thus we have
a crack we need to test for.
@param PC PC of execption
- @return TRUE We are in the GDB stub exception preamble
+ @return TRUE We are in the GDB stub exception preamble
@return FALSE We are not in GDB stub code
**/
BOOLEAN
@@ -495,21 +495,21 @@ InFiqCrack ( /**
Check to see if this exception is related to ctrl-c handling.
- In this scheme we dedicate FIQ to the ctrl-c handler so it is
- independent of the rest of the system.
-
- SaveAndSetDebugTimerInterrupt () can be used to
+ In this scheme we dedicate FIQ to the ctrl-c handler so it is
+ independent of the rest of the system.
+
+ SaveAndSetDebugTimerInterrupt () can be used to
@param ExceptionType Exception that is being processed
- @param SystemContext Register content at time of the exception
+ @param SystemContext Register content at time of the exception
@return TRUE This was a ctrl-c check that did not find a ctrl-c
@return FALSE This was not a ctrl-c check or some one hit ctrl-c
**/
BOOLEAN
-ProcessorControlC (
- IN EFI_EXCEPTION_TYPE ExceptionType,
- IN OUT EFI_SYSTEM_CONTEXT SystemContext
+ProcessorControlC (
+ IN EFI_EXCEPTION_TYPE ExceptionType,
+ IN OUT EFI_SYSTEM_CONTEXT SystemContext
)
{
CHAR8 Char;
@@ -534,7 +534,7 @@ ProcessorControlC ( Return = TRUE;
break;
}
-
+
Char = GdbGetChar ();
if (Char == 0x03) {
//
@@ -622,7 +622,7 @@ InitializeDebugAgent ( IN VOID *Context, OPTIONAL
IN DEBUG_AGENT_CONTINUE Function OPTIONAL
)
-{
+{
UINTN Offset;
UINTN Length;
BOOLEAN IrqEnabled;
@@ -647,7 +647,7 @@ InitializeDebugAgent ( VectorBase = (UINT32 *)(UINTN)PcdGet32 (PcdCpuVectorBaseAddress);
- // Copy our assembly code into the page that contains the exception vectors.
+ // Copy our assembly code into the page that contains the exception vectors.
CopyMem ((VOID *)VectorBase, (VOID *)ExceptionHandlersStart, Length);
//
diff --git a/EmbeddedPkg/Library/GdbDebugAgent/GdbDebugAgent.c b/EmbeddedPkg/Library/GdbDebugAgent/GdbDebugAgent.c index eb4b66c3ad..c8984291d9 100755 --- a/EmbeddedPkg/Library/GdbDebugAgent/GdbDebugAgent.c +++ b/EmbeddedPkg/Library/GdbDebugAgent/GdbDebugAgent.c @@ -34,7 +34,7 @@ CHAR8 gXferLibraryBuffer[2000]; GLOBAL_REMOVE_IF_UNREFERENCED CONST CHAR8 mHexToStr[] = {'0','1','2','3','4','5','6','7','8','9','A','B','C','D','E','F'};
-// add-symbol-file c:/work/edk2/Build/BeagleBoard/DEBUG_ARMGCC/ARM/BeagleBoardPkg/Sec/Sec/DEBUG/BeagleBoardSec.dll 0x80008360
+// add-symbol-file c:/work/edk2/Build/BeagleBoard/DEBUG_ARMGCC/ARM/BeagleBoardPkg/Sec/Sec/DEBUG/BeagleBoardSec.dll 0x80008360
CHAR8 *qXferHack = "<library name=\"c:/work/edk2/Build/BeagleBoard/DEBUG_ARMGCC/ARM/BeagleBoardPkg/Sec/Sec/DEBUG/BeagleBoardSec.dll\"><segment address=\"0x80008360\"/></library>";
UINTN
@@ -52,7 +52,7 @@ gXferObjectReadResponse ( *OutBufPtr++ = Type;
Count = 1;
- // Binary data encoding
+ // Binary data encoding
OutBufPtr = gOutBuffer;
while (*Str != '\0') {
Char = *Str++;
@@ -68,42 +68,42 @@ gXferObjectReadResponse ( *OutBufPtr = '\0' ; // the end of the buffer
SendPacket (gOutBuffer);
-
+
return Count;
}
-/**
+/**
Process "qXfer:object:read:annex:offset,length" request.
-
- Returns an XML document that contains loaded libraries. In our case it is
+
+ Returns an XML document that contains loaded libraries. In our case it is
infomration in the EFI Debug Inmage Table converted into an XML document.
-
- GDB will call with an arbitrary length (it can't know the real length and
- will reply with chunks of XML that are easy for us to deal with. Gdb will
+
+ GDB will call with an arbitrary length (it can't know the real length and
+ will reply with chunks of XML that are easy for us to deal with. Gdb will
keep calling until we say we are done. XML doc looks like:
-
+
<library-list>
<library name="/a/a/c/d.dSYM"><segment address="0x10000000"/></library>
<library name="/a/m/e/e.pdb"><segment address="0x20000000"/></library>
<library name="/a/l/f/f.dll"><segment address="0x30000000"/></library>
</library-list>
-
- Since we can not allocate memory in interupt context this module has
+
+ Since we can not allocate memory in interupt context this module has
assumptions about how it will get called:
1) Length will generally be max remote packet size (big enough)
2) First Offset of an XML document read needs to be 0
3) This code will return back small chunks of the XML document on every read.
Each subseqent call will ask for the next availble part of the document.
-
+
Note: The only variable size element in the XML is:
- " <library name=\"%s\"><segment address=\"%p\"/></library>\n" and it is
+ " <library name=\"%s\"><segment address=\"%p\"/></library>\n" and it is
based on the file path and name of the symbol file. If the symbol file name
is bigger than the max gdb remote packet size we could update this code
to respond back in chunks.
@param Offset offset into special data area
- @param Length number of bytes to read starting at Offset
-
+ @param Length number of bytes to read starting at Offset
+
**/
VOID
QxferLibrary (
@@ -134,13 +134,13 @@ TransferFromInBufToMem ( {
CHAR8 c1;
CHAR8 c2;
-
+
while (Length-- > 0) {
c1 = (CHAR8)HexCharToInt (*NewData++);
c2 = (CHAR8)HexCharToInt (*NewData++);
if ((c1 < 0) || (c2 < 0)) {
- SendError (GDB_EBADMEMDATA);
+ SendError (GDB_EBADMEMDATA);
return;
}
*Address++ = (UINT8)((c1 << 4) + c2);
@@ -171,7 +171,7 @@ TransferFromMemToOutBufAndSend ( OutBufPtr = OutBuffer;
while (Length > 0) {
-
+
Char = mHexToStr[*Address >> 4];
if ((Char >= 'A') && (Char <= 'F')) {
Char = Char - 'A' + 'a';
@@ -196,16 +196,16 @@ TransferFromMemToOutBufAndSend ( /**
Send a GDB Remote Serial Protocol Packet
-
- $PacketData#checksum PacketData is passed in and this function adds the packet prefix '$',
+
+ $PacketData#checksum PacketData is passed in and this function adds the packet prefix '$',
the packet teminating character '#' and the two digit checksum.
-
- If an ack '+' is not sent resend the packet, but timeout eventually so we don't end up
+
+ If an ack '+' is not sent resend the packet, but timeout eventually so we don't end up
in an infinit loop. This is so if you unplug the debugger code just keeps running
- @param PacketData Payload data for the packet
+ @param PacketData Payload data for the packet
+
-
@retval Number of bytes of packet data sent.
**/
@@ -219,7 +219,7 @@ SendPacket ( CHAR8 *Ptr;
CHAR8 TestChar;
UINTN Count;
-
+
Timeout = PcdGet32 (PcdGdbMaxPacketRetryCount);
Count = 0;
@@ -231,38 +231,38 @@ SendPacket ( // Only try a finite number of times so we don't get stuck in the loop
return Count;
}
-
+
// Packet prefix
GdbPutChar ('$');
-
+
for (CheckSum = 0, Count =0 ; *Ptr != '\0'; Ptr++, Count++) {
GdbPutChar (*Ptr);
CheckSum = CheckSum + *Ptr;
}
-
- // Packet terminating character and checksum
+
+ // Packet terminating character and checksum
GdbPutChar ('#');
GdbPutChar (mHexToStr[CheckSum >> 4]);
GdbPutChar (mHexToStr[CheckSum & 0x0F]);
-
+
TestChar = GdbGetChar ();
} while (TestChar != '+');
-
+
return Count;
}
/**
Receive a GDB Remote Serial Protocol Packet
-
- $PacketData#checksum PacketData is passed in and this function adds the packet prefix '$',
+
+ $PacketData#checksum PacketData is passed in and this function adds the packet prefix '$',
the packet teminating character '#' and the two digit checksum.
-
+
If host re-starts sending a packet without ending the previous packet, only the last valid packet is proccessed.
(In other words, if received packet is '$12345$12345$123456#checksum', only '$123456#checksum' will be processed.)
-
+
If an ack '+' is not sent resend the packet
- @param PacketData Payload data for the packet
+ @param PacketData Payload data for the packet
@retval Number of bytes of packet data received.
@@ -278,16 +278,16 @@ ReceivePacket ( CHAR8 Char;
CHAR8 SumString[3];
CHAR8 TestChar;
-
+
ZeroMem (PacketData, PacketDataSize);
-
+
for (;;) {
// wait for the start of a packet
TestChar = GdbGetChar ();
while (TestChar != '$') {
TestChar = GdbGetChar ();
};
-
+
retry:
for (Index = 0, CheckSum = 0; Index < (PacketDataSize - 1); Index++) {
Char = GdbGetChar ();
@@ -307,14 +307,14 @@ ReceivePacket ( continue;
}
- SumString[0] = GdbGetChar ();
+ SumString[0] = GdbGetChar ();
SumString[1] = GdbGetChar ();
SumString[2] = '\0';
-
+
if (AsciiStrHexToUintn (SumString) == CheckSum) {
// Ack: Success
GdbPutChar ('+');
-
+
// Null terminate the callers string
PacketData[Index] = '\0';
return Index;
@@ -323,27 +323,27 @@ ReceivePacket ( GdbPutChar ('-');
}
}
-
+
//return 0;
}
/**
- Empties the given buffer
+ Empties the given buffer
@param Buf pointer to the first element in buffer to be emptied
**/
VOID
-EmptyBuffer (
+EmptyBuffer (
IN CHAR8 *Buf
)
-{
+{
*Buf = '\0';
}
/**
Converts an 8-bit Hex Char into a INTN.
-
+
@param Char the hex character to be converted into UINTN
@retval a INTN, from 0 to 15, that corressponds to Char
-1 if Char is not a hex character
@@ -360,7 +360,7 @@ HexCharToInt ( } else if ((Char >= '0') && (Char <= '9')) {
return Char - '0';
} else { // if not a hex value, return a negative value
- return -1;
+ return -1;
}
}
@@ -371,7 +371,7 @@ CHAR8 *gError = "E__"; Send an error with the given error number after converting to hex.
The error number is put into the buffer in hex. '255' is the biggest errno we can send.
ex: 162 will be sent as A2.
-
+
@param errno the error number that will be sent
**/
VOID
@@ -385,7 +385,7 @@ SendError ( //
gError[1] = mHexToStr [ErrorNum >> 4];
gError[2] = mHexToStr [ErrorNum & 0x0f];
-
+
SendPacket (gError); // send buffer
}
@@ -398,7 +398,7 @@ VOID EFIAPI
SendSuccess (
VOID
- )
+ )
{
SendPacket ("OK"); // send buffer
}
@@ -407,12 +407,12 @@ SendSuccess ( /**
Send empty packet to specify that particular command/functionality is not supported.
**/
-VOID
-EFIAPI
+VOID
+EFIAPI
SendNotSupported (
- VOID
- )
-{
+ VOID
+ )
+{
SendPacket ("");
}
@@ -422,17 +422,17 @@ SendNotSupported ( /**
Translates the EFI mapping to GDB mapping
-
+
@param EFIExceptionType EFI Exception that is being processed
@retval UINTN that corresponds to EFIExceptionType's GDB exception type number
**/
UINT8
-ConvertEFItoGDBtype (
+ConvertEFItoGDBtype (
IN EFI_EXCEPTION_TYPE EFIExceptionType
)
-{
+{
UINTN i;
-
+
for (i=0; i < MaxEfiException() ; i++) {
if (gExceptionType[i].Exception == EFIExceptionType) {
return gExceptionType[i].SignalNo;
@@ -443,8 +443,8 @@ ConvertEFItoGDBtype ( /** "m addr,length"
- Find the Length of the area to read and the start addres. Finally, pass them to
- another function, TransferFromMemToOutBufAndSend, that will read from that memory space and
+ Find the Length of the area to read and the start addres. Finally, pass them to
+ another function, TransferFromMemToOutBufAndSend, that will read from that memory space and
send it as a packet.
**/
@@ -459,37 +459,37 @@ ReadFromMemory ( CHAR8 AddressBuffer[MAX_ADDR_SIZE]; // the buffer that will hold the address in hex chars
CHAR8 *AddrBufPtr; // pointer to the address buffer
CHAR8 *InBufPtr; /// pointer to the input buffer
-
+
AddrBufPtr = AddressBuffer;
InBufPtr = &PacketData[1];
while (*InBufPtr != ',') {
*AddrBufPtr++ = *InBufPtr++;
}
*AddrBufPtr = '\0';
-
+
InBufPtr++; // this skips ',' in the buffer
-
+
/* Error checking */
if (AsciiStrLen(AddressBuffer) >= MAX_ADDR_SIZE) {
- SendError (GDB_EBADMEMADDRBUFSIZE);
+ SendError (GDB_EBADMEMADDRBUFSIZE);
return;
}
-
+
// 2 = 'm' + ','
if (AsciiStrLen(PacketData) - AsciiStrLen(AddressBuffer) - 2 >= MAX_LENGTH_SIZE) {
- SendError (GDB_EBADMEMLENGTH);
+ SendError (GDB_EBADMEMLENGTH);
return;
}
-
+
Address = AsciiStrHexToUintn (AddressBuffer);
Length = AsciiStrHexToUintn (InBufPtr);
-
+
TransferFromMemToOutBufAndSend (Length, (unsigned char *)Address);
}
/** "M addr,length :XX..."
- Find the Length of the area in bytes to write and the start addres. Finally, pass them to
+ Find the Length of the area in bytes to write and the start addres. Finally, pass them to
another function, TransferFromInBufToMem, that will write to that memory space the info in
the input buffer.
**/
@@ -507,48 +507,48 @@ WriteToMemory ( CHAR8 *AddrBufPtr; // pointer to the Address buffer
CHAR8 *LengthBufPtr; // pointer to the Length buffer
CHAR8 *InBufPtr; /// pointer to the input buffer
-
+
AddrBufPtr = AddressBuffer;
LengthBufPtr = LengthBuffer;
InBufPtr = &PacketData[1];
-
+
while (*InBufPtr != ',') {
*AddrBufPtr++ = *InBufPtr++;
}
*AddrBufPtr = '\0';
-
+
InBufPtr++; // this skips ',' in the buffer
-
+
while (*InBufPtr != ':') {
*LengthBufPtr++ = *InBufPtr++;
}
*LengthBufPtr = '\0';
-
+
InBufPtr++; // this skips ':' in the buffer
-
+
Address = AsciiStrHexToUintn (AddressBuffer);
Length = AsciiStrHexToUintn (LengthBuffer);
-
+
/* Error checking */
-
+
//Check if Address is not too long.
if (AsciiStrLen(AddressBuffer) >= MAX_ADDR_SIZE) {
- SendError (GDB_EBADMEMADDRBUFSIZE);
+ SendError (GDB_EBADMEMADDRBUFSIZE);
return;
}
-
+
//Check if message length is not too long
if (AsciiStrLen(LengthBuffer) >= MAX_LENGTH_SIZE) {
- SendError (GDB_EBADMEMLENGBUFSIZE);
+ SendError (GDB_EBADMEMLENGBUFSIZE);
return;
}
-
+
// Check if Message is not too long/short.
// 3 = 'M' + ',' + ':'
MessageLength = (AsciiStrLen(PacketData) - AsciiStrLen(AddressBuffer) - AsciiStrLen(LengthBuffer) - 3);
if (MessageLength != (2*Length)) {
//Message too long/short. New data is not the right size.
- SendError (GDB_EBADMEMDATASIZE);
+ SendError (GDB_EBADMEMDATASIZE);
return;
}
TransferFromInBufToMem (Length, (unsigned char *)Address, InBufPtr);
@@ -623,7 +623,7 @@ ParseBreakpointPacket ( /**
Send the T signal with the given exception type (in gdb order) and possibly with n:r pairs related to the watchpoints
-
+
@param SystemContext Register content at time of the exception
@param GdbExceptionType GDB exception type
**/
@@ -644,12 +644,12 @@ GdbSendTSignal ( //
// replace _, or previous value, with Exception type
//
- *TSignalPtr++ = mHexToStr [GdbExceptionType >> 4];
+ *TSignalPtr++ = mHexToStr [GdbExceptionType >> 4];
*TSignalPtr++ = mHexToStr [GdbExceptionType & 0x0f];
-
+
ProcessorSendTSignal (SystemContext, GdbExceptionType, TSignalPtr, sizeof (TSignalBuffer) - 2);
- SendPacket (TSignalBuffer);
+ SendPacket (TSignalBuffer);
}
VOID
@@ -666,7 +666,7 @@ GdbFWrite ( for( ; ; ) {
ReceivePacket (gInBuffer, MAX_BUF_SIZE);
-
+
switch (gInBuffer[0]) {
case 'm':
ReadFromMemory (gInBuffer);
@@ -697,20 +697,20 @@ GdbFPutString ( /**
Exception Hanldler for GDB. It will be called for all exceptions
registered via the gExceptionType[] array.
-
+
@param ExceptionType Exception that is being processed
- @param SystemContext Register content at time of the exception
+ @param SystemContext Register content at time of the exception
**/
VOID
EFIAPI
-GdbExceptionHandler (
- IN EFI_EXCEPTION_TYPE ExceptionType,
- IN OUT EFI_SYSTEM_CONTEXT SystemContext
+GdbExceptionHandler (
+ IN EFI_EXCEPTION_TYPE ExceptionType,
+ IN OUT EFI_SYSTEM_CONTEXT SystemContext
)
{
UINT8 GdbExceptionType;
CHAR8 *Ptr;
-
+
if (ProcessorControlC (ExceptionType, SystemContext)) {
// We tried to process a control C handler and there is nothing to do
return;
@@ -718,37 +718,37 @@ GdbExceptionHandler ( GdbExceptionType = ConvertEFItoGDBtype (ExceptionType);
GdbSendTSignal (SystemContext, GdbExceptionType);
-
+
for( ; ; ) {
ReceivePacket (gInBuffer, MAX_BUF_SIZE);
-
+
switch (gInBuffer[0]) {
case '?':
GdbSendTSignal (SystemContext, GdbExceptionType);
break;
-
+
case 'c':
- ContinueAtAddress (SystemContext, gInBuffer);
+ ContinueAtAddress (SystemContext, gInBuffer);
return;
case 'D':
- // gdb wants to disconnect so return "OK" packet since.
+ // gdb wants to disconnect so return "OK" packet since.
SendSuccess ();
return;
case 'g':
ReadGeneralRegisters (SystemContext);
break;
-
+
case 'G':
WriteGeneralRegisters (SystemContext, gInBuffer);
break;
-
+
case 'H':
- //Return "OK" packet since we don't have more than one thread.
+ //Return "OK" packet since we don't have more than one thread.
SendSuccess ();
break;
-
+
case 'm':
ReadFromMemory (gInBuffer);
break;
@@ -764,7 +764,7 @@ GdbExceptionHandler ( //
// Still debugging this code. Not used in Darwin
//
- case 'q':
+ case 'q':
// General Query Packets
if (AsciiStrnCmp (gInBuffer, "qSupported", 10) == 0) {
// return what we currently support, we don't parse what gdb suports
@@ -774,7 +774,7 @@ GdbExceptionHandler ( // ‘qXfer:libraries:read::offset,length
// gInBuffer[22] is offset string, ++Ptr is length string’
for (Ptr = &gInBuffer[22]; *Ptr != ','; Ptr++);
-
+
// Not sure if multi-radix support is required. Currently only support decimal
QxferLibrary (AsciiStrHexToUintn (&gInBuffer[22]), AsciiStrHexToUintn (++Ptr));
} else if (AsciiStrnCmp (gInBuffer, "qOffsets", 8) == 0) {
@@ -790,18 +790,18 @@ GdbExceptionHandler ( break;
case 's':
- SingleStep (SystemContext, gInBuffer);
+ SingleStep (SystemContext, gInBuffer);
return;
-
+
case 'z':
RemoveBreakPoint (SystemContext, gInBuffer);
break;
-
+
case 'Z':
InsertBreakPoint (SystemContext, gInBuffer);
break;
-
- default:
+
+ default:
//Send empty packet
SendNotSupported ();
break;
diff --git a/EmbeddedPkg/Library/GdbDebugAgent/GdbDebugAgent.h b/EmbeddedPkg/Library/GdbDebugAgent/GdbDebugAgent.h index 44c82f3472..85328486d3 100755 --- a/EmbeddedPkg/Library/GdbDebugAgent/GdbDebugAgent.h +++ b/EmbeddedPkg/Library/GdbDebugAgent/GdbDebugAgent.h @@ -34,7 +34,7 @@ extern CONST CHAR8 mHexToStr[];
// maximum size of input and output buffers
-// This value came from the show remote command of the gdb we tested against
+// This value came from the show remote command of the gdb we tested against
#define MAX_BUF_SIZE 2000
// maximum size of address buffer
@@ -57,11 +57,11 @@ extern CONST CHAR8 mHexToStr[]; // GDB Signal definitions - generic names for interrupts
//
#define GDB_SIGINT 2 // Interrupt process via ctrl-c
-#define GDB_SIGILL 4 // Illegal instruction
+#define GDB_SIGILL 4 // Illegal instruction
#define GDB_SIGTRAP 5 // Trace Trap (Breakpoint and SingleStep)
#define GDB_SIGEMT 7 // Emulator Trap
#define GDB_SIGFPE 8 // Floating point exception
-#define GDB_SIGSEGV 11 // Setgment violation, page fault
+#define GDB_SIGSEGV 11 // Setgment violation, page fault
//
@@ -69,9 +69,9 @@ extern CONST CHAR8 mHexToStr[]; // Includes all general GDB Unix like error values
//
#define GDB_EBADMEMADDRBUFSIZE 11 // the buffer that stores memory Address to be read from/written to is not the right size
-#define GDB_EBADMEMLENGBUFSIZE 12 // the buffer that stores Length is not the right size
+#define GDB_EBADMEMLENGBUFSIZE 12 // the buffer that stores Length is not the right size
#define GDB_EBADMEMLENGTH 13 // Length, the given number of bytes to read or write, is not the right size
-#define GDB_EBADMEMDATA 14 // one of the bytes or nibbles of the memory is leess than 0
+#define GDB_EBADMEMDATA 14 // one of the bytes or nibbles of the memory is leess than 0
#define GDB_EBADMEMDATASIZE 15 // the memory data, 'XX..', is too short or too long
#define GDB_EBADBUFSIZE 21 // the buffer created is not the correct size
#define GDB_EINVALIDARG 31 // argument is invalid
@@ -91,7 +91,7 @@ extern CONST CHAR8 mHexToStr[]; //
//Define Register size for different architectures
//
-#if defined (MDE_CPU_IA32)
+#if defined (MDE_CPU_IA32)
#define REG_SIZE 32
#elif defined (MDE_CPU_X64)
#define REG_SIZE 64
@@ -119,7 +119,7 @@ typedef union { UINT32 B1:1; // Breakpoint condition detected
UINT32 B2:1; // Breakpoint condition detected
UINT32 B3:1; // Breakpoint condition detected
- UINT32 Reserved_1:9; // Reserved
+ UINT32 Reserved_1:9; // Reserved
UINT32 BD:1; // Debug register access detected
UINT32 BS:1; // Single step
UINT32 BT:1; // Task switch
@@ -186,8 +186,8 @@ extern BOOLEAN gProcessingFPacket; /**
Return the number of entries in the gExceptionType[]
-
- @retval UINTN, the number of entries in the gExceptionType[] array.
+
+ @retval UINTN, the number of entries in the gExceptionType[] array.
**/
UINTN
MaxEfiException (
@@ -196,9 +196,9 @@ MaxEfiException ( /**
- Check to see if the ISA is supported.
+ Check to see if the ISA is supported.
ISA = Instruction Set Architecture
-
+
@retval TRUE if Isa is supported,
FALSE otherwise.
**/
@@ -210,7 +210,7 @@ CheckIsa ( /**
Send the T signal with the given exception type (in gdb order) and possibly with n:r pairs related to the watchpoints
-
+
@param SystemContext Register content at time of the exception
@param GdbExceptionType GDB exception type
**/
@@ -224,29 +224,29 @@ GdbSendTSignal ( /**
Translates the EFI mapping to GDB mapping
-
+
@param EFIExceptionType EFI Exception that is being processed
@retval UINTN that corresponds to EFIExceptionType's GDB exception type number
**/
UINT8
-ConvertEFItoGDBtype (
+ConvertEFItoGDBtype (
IN EFI_EXCEPTION_TYPE EFIExceptionType
);
/**
- Empties the given buffer
+ Empties the given buffer
@param *Buf pointer to the first element in buffer to be emptied
**/
VOID
-EmptyBuffer (
+EmptyBuffer (
IN CHAR8 *Buf
);
/**
Converts an 8-bit Hex Char into a INTN.
-
+
@param Char - the hex character to be converted into UINTN
@retval a INTN, from 0 to 15, that corressponds to Char
-1 if Char is not a hex character
@@ -261,7 +261,7 @@ HexCharToInt ( Send an error with the given error number after converting to hex.
The error number is put into the buffer in hex. '255' is the biggest errno we can send.
ex: 162 will be sent as A2.
-
+
@param errno the error number that will be sent
**/
VOID
@@ -288,8 +288,8 @@ SendNotSupported ( VOID
);
-/** ‘p n’
- Reads the n-th register's value into an output buffer and sends it as a packet
+/** ‘p n’
+ Reads the n-th register's value into an output buffer and sends it as a packet
@param SystemContext Register content at time of the exception
@param InBuffer This is the input buffer received from gdb server
**/
@@ -300,12 +300,12 @@ ReadNthRegister ( );
-/** ‘g’
- Reads the general registers into an output buffer and sends it as a packet
+/** ‘g’
+ Reads the general registers into an output buffer and sends it as a packet
@param SystemContext Register content at time of the exception
**/
VOID
-ReadGeneralRegisters (
+ReadGeneralRegisters (
IN EFI_SYSTEM_CONTEXT SystemContext
);
@@ -336,10 +336,10 @@ WriteGeneralRegisters ( /** ‘m addr,length ’
- Find the Length of the area to read and the start addres. Finally, pass them to
- another function, TransferFromMemToOutBufAndSend, that will read from that memory space and
+ Find the Length of the area to read and the start addres. Finally, pass them to
+ another function, TransferFromMemToOutBufAndSend, that will read from that memory space and
send it as a packet.
-
+
@param *PacketData Pointer to Payload data for the packet
**/
VOID
@@ -349,10 +349,10 @@ ReadFromMemory ( /** ‘M addr,length :XX...’
- Find the Length of the area in bytes to write and the start addres. Finally, pass them to
+ Find the Length of the area in bytes to write and the start addres. Finally, pass them to
another function, TransferFromInBufToMem, that will write to that memory space the info in
the input buffer.
-
+
@param PacketData Pointer to Payload data for the packet
**/
VOID
@@ -361,11 +361,11 @@ WriteToMemory ( );
-/** ‘c [addr ]’
- Continue. addr is Address to resume. If addr is omitted, resume at current
+/** ‘c [addr ]’
+ Continue. addr is Address to resume. If addr is omitted, resume at current
Address.
-
- @param SystemContext Register content at time of the exception
+
+ @param SystemContext Register content at time of the exception
@param *PacketData Pointer to PacketData
**/
@@ -377,9 +377,9 @@ ContinueAtAddress ( /** ‘s [addr ]’
- Single step. addr is the Address at which to resume. If addr is omitted, resume
+ Single step. addr is the Address at which to resume. If addr is omitted, resume
at same Address.
-
+
@param SystemContext Register content at time of the exception
@param PacketData Pointer to Payload data for the packet
**/
@@ -389,27 +389,27 @@ SingleStep ( IN CHAR8 *PacketData
);
-/**
+/**
Insert Single Step in the SystemContext
-
+
@param SystemContext Register content at time of the exception
**/
VOID
AddSingleStep (
IN EFI_SYSTEM_CONTEXT SystemContext
);
-
-/**
+
+/**
Remove Single Step in the SystemContext
-
+
@param SystemContext Register content at time of the exception
**/
VOID
RemoveSingleStep (
IN EFI_SYSTEM_CONTEXT SystemContext
);
-
-
+
+
/**
‘Z1, [addr], [length]’
‘Z2, [addr], [length]’
@@ -453,36 +453,36 @@ RemoveBreakPoint( /**
Exception Hanldler for GDB. It will be called for all exceptions
registered via the gExceptionType[] array.
-
+
@param ExceptionType Exception that is being processed
- @param SystemContext Register content at time of the exception
-
+ @param SystemContext Register content at time of the exception
+
**/
VOID
EFIAPI
-GdbExceptionHandler (
- IN EFI_EXCEPTION_TYPE ExceptionType,
- IN OUT EFI_SYSTEM_CONTEXT SystemContext
+GdbExceptionHandler (
+ IN EFI_EXCEPTION_TYPE ExceptionType,
+ IN OUT EFI_SYSTEM_CONTEXT SystemContext
);
/**
- Periodic callback for GDB. This function is used to catch a ctrl-c or other
+ Periodic callback for GDB. This function is used to catch a ctrl-c or other
break in type command from GDB.
-
+
@param SystemContext Register content at time of the call
-
+
**/
VOID
EFIAPI
-GdbPeriodicCallBack (
- IN OUT EFI_SYSTEM_CONTEXT SystemContext
+GdbPeriodicCallBack (
+ IN OUT EFI_SYSTEM_CONTEXT SystemContext
);
/**
Make two serail consoles: 1) StdIn and StdOut via GDB. 2) StdErr via GDB.
-
+
These console show up on the remote system running GDB
**/
@@ -495,15 +495,15 @@ GdbInitializeSerialConsole ( /**
Send a GDB Remote Serial Protocol Packet
-
- $PacketData#checksum PacketData is passed in and this function adds the packet prefix '$',
+
+ $PacketData#checksum PacketData is passed in and this function adds the packet prefix '$',
the packet teminating character '#' and the two digit checksum.
-
- If an ack '+' is not sent resend the packet, but timeout eventually so we don't end up
+
+ If an ack '+' is not sent resend the packet, but timeout eventually so we don't end up
in an infinit loop. This is so if you unplug the debugger code just keeps running
- @param PacketData Payload data for the packet
-
+ @param PacketData Payload data for the packet
+
@retval Number of bytes of packet data sent.
**/
@@ -511,21 +511,21 @@ UINTN SendPacket (
IN CHAR8 *PacketData
);
-
+
/**
Receive a GDB Remote Serial Protocol Packet
-
- $PacketData#checksum PacketData is passed in and this function adds the packet prefix '$',
+
+ $PacketData#checksum PacketData is passed in and this function adds the packet prefix '$',
the packet teminating character '#' and the two digit checksum.
-
+
If host re-starts sending a packet without ending the previous packet, only the last valid packet is proccessed.
(In other words, if received packet is '$12345$12345$123456#checksum', only '$123456#checksum' will be processed.)
-
+
If an ack '+' is not sent resend the packet
-
- @param PacketData Payload data for the packet
-
+
+ @param PacketData Payload data for the packet
+
@retval Number of bytes of packet data received.
**/
@@ -534,15 +534,15 @@ ReceivePacket ( OUT CHAR8 *PacketData,
IN UINTN PacketDataSize
);
-
+
/**
- Read data from a FileDescriptor. On success number of bytes read is returned. Zero indicates
+ Read data from a FileDescriptor. On success number of bytes read is returned. Zero indicates
the end of a file. On error -1 is returned. If count is zero, GdbRead returns zero.
@param FileDescriptor Device to talk to.
@param Buffer Buffer to hold Count bytes that were read
- @param Count Number of bytes to transfer.
+ @param Count Number of bytes to transfer.
@retval -1 Error
@retval {other} Number of bytes read.
@@ -554,15 +554,15 @@ GdbRead ( OUT VOID *Buffer,
IN UINTN Count
);
-
+
/**
- Write data to a FileDescriptor. On success number of bytes written is returned. Zero indicates
- nothing was written. On error -1 is returned.
+ Write data to a FileDescriptor. On success number of bytes written is returned. Zero indicates
+ nothing was written. On error -1 is returned.
@param FileDescriptor Device to talk to.
@param Buffer Buffer to hold Count bytes that are to be written
- @param Count Number of bytes to transfer.
+ @param Count Number of bytes to transfer.
@retval -1 Error
@retval {other} Number of bytes written.
@@ -575,13 +575,13 @@ GdbWrite ( IN UINTN Count
);
-UINTN *
+UINTN *
FindPointerToRegister (
IN EFI_SYSTEM_CONTEXT SystemContext,
- IN UINTN RegNumber
+ IN UINTN RegNumber
);
-CHAR8 *
+CHAR8 *
BasicReadRegister (
IN EFI_SYSTEM_CONTEXT SystemContext,
IN UINTN RegNumber,
@@ -608,7 +608,7 @@ BasicWriteRegister ( IN CHAR8 *InBufPtr
);
-VOID
+VOID
PrintReg (
EFI_SYSTEM_CONTEXT SystemContext
);
@@ -624,7 +624,7 @@ ParseBreakpointPacket ( UINTN
GetBreakpointDataAddress (
IN EFI_SYSTEM_CONTEXT SystemContext,
- IN UINTN BreakpointNumber
+ IN UINTN BreakpointNumber
);
UINTN
@@ -635,7 +635,7 @@ GetBreakpointDetected ( BREAK_TYPE
GetBreakpointType (
IN EFI_SYSTEM_CONTEXT SystemContext,
- IN UINTN BreakpointNumber
+ IN UINTN BreakpointNumber
);
UINTN
@@ -680,7 +680,7 @@ InitializeProcessor ( /**
Send the T signal with the given exception type (in gdb order) and possibly with n:r pairs related to the watchpoints
-
+
@param SystemContext Register content at time of the exception
@param GdbExceptionType GDB exception type
**/
@@ -694,17 +694,17 @@ ProcessorSendTSignal ( /**
Check to see if this exception is related to ctrl-c handling.
-
+
@param ExceptionType Exception that is being processed
- @param SystemContext Register content at time of the exception
+ @param SystemContext Register content at time of the exception
@return TRUE This was a ctrl-c check that did not find a ctrl-c
@return FALSE This was not a ctrl-c check or some one hit ctrl-c
**/
BOOLEAN
-ProcessorControlC (
- IN EFI_EXCEPTION_TYPE ExceptionType,
- IN OUT EFI_SYSTEM_CONTEXT SystemContext
+ProcessorControlC (
+ IN EFI_EXCEPTION_TYPE ExceptionType,
+ IN OUT EFI_SYSTEM_CONTEXT SystemContext
);
diff --git a/EmbeddedPkg/Library/GdbDebugAgent/GdbDebugAgent.inf b/EmbeddedPkg/Library/GdbDebugAgent/GdbDebugAgent.inf index 1111ba35c0..02f80579b1 100755 --- a/EmbeddedPkg/Library/GdbDebugAgent/GdbDebugAgent.inf +++ b/EmbeddedPkg/Library/GdbDebugAgent/GdbDebugAgent.inf @@ -51,10 +51,10 @@ ArmPkg/ArmPkg.dec
[LibraryClasses]
- BaseLib
- DebugLib
- BaseMemoryLib
- PcdLib
+ BaseLib
+ DebugLib
+ BaseMemoryLib
+ PcdLib
GdbSerialLib
CacheMaintenanceLib
DebugAgentTimerLib
diff --git a/EmbeddedPkg/Library/GdbDebugAgent/Ia32/Processor.c b/EmbeddedPkg/Library/GdbDebugAgent/Ia32/Processor.c index 4e4350a0f2..c5a421c69e 100755 --- a/EmbeddedPkg/Library/GdbDebugAgent/Ia32/Processor.c +++ b/EmbeddedPkg/Library/GdbDebugAgent/Ia32/Processor.c @@ -2,7 +2,7 @@ Processor specific parts of the GDB stub
Copyright (c) 2008 - 2009, Apple Inc. All rights reserved.<BR>
-
+
This program and the accompanying materials
are licensed and made available under the terms and conditions of the BSD License
which accompanies this distribution. The full text of the license may be found at
@@ -20,7 +20,7 @@ // {EFI mapping, GDB mapping}
//
EFI_EXCEPTION_TYPE_ENTRY gExceptionType[] = {
- { EXCEPT_IA32_DIVIDE_ERROR, GDB_SIGFPE },
+ { EXCEPT_IA32_DIVIDE_ERROR, GDB_SIGFPE },
{ EXCEPT_IA32_DEBUG, GDB_SIGTRAP },
{ EXCEPT_IA32_NMI, GDB_SIGEMT },
{ EXCEPT_IA32_BREAKPOINT, GDB_SIGTRAP },
@@ -62,7 +62,7 @@ UINTN gRegisterOffsets[] = { //Debug only..
-VOID
+VOID
PrintReg (
IN EFI_SYSTEM_CONTEXT SystemContext
)
@@ -80,7 +80,7 @@ PrintReg ( }
//Debug only..
-VOID
+VOID
PrintDRreg (
IN EFI_SYSTEM_CONTEXT SystemContext
)
@@ -96,8 +96,8 @@ PrintDRreg ( /**
Return the number of entries in the gExceptionType[]
-
- @retval UINTN, the number of entries in the gExceptionType[] array.
+
+ @retval UINTN, the number of entries in the gExceptionType[] array.
**/
UINTN
MaxEfiException (
@@ -109,9 +109,9 @@ MaxEfiException ( /**
- Check to see if the ISA is supported.
+ Check to see if the ISA is supported.
ISA = Instruction Set Architecture
-
+
@retval TRUE if Isa is supported,
FALSE otherwise.
**/
@@ -128,14 +128,14 @@ CheckIsa ( This takes in the register number and the System Context, and returns a pointer to the RegNumber-th register in gdb ordering
It is, by default, set to find the register pointer of the IA32 member
- @param SystemContext Register content at time of the exception
+ @param SystemContext Register content at time of the exception
@param RegNumber The register to which we want to find a pointer
@retval the pointer to the RegNumber-th pointer
**/
UINTN *
FindPointerToRegister(
IN EFI_SYSTEM_CONTEXT SystemContext,
- IN UINTN RegNumber
+ IN UINTN RegNumber
)
{
UINT8 *TempPtr;
@@ -160,7 +160,7 @@ BasicReadRegister ( )
{
UINTN RegSize;
-
+
RegSize = 0;
while (RegSize < REG_SIZE) {
*OutBufPtr++ = mHexToStr[((*FindPointerToRegister(SystemContext, RegNumber) >> (RegSize+4)) & 0xf)];
@@ -171,8 +171,8 @@ BasicReadRegister ( }
-/** ‘p n’
- Reads the n-th register's value into an output buffer and sends it as a packet
+/** ‘p n’
+ Reads the n-th register's value into an output buffer and sends it as a packet
@param SystemContext Register content at time of the exception
@param InBuffer Pointer to the input buffer received from gdb server
@@ -187,7 +187,7 @@ ReadNthRegister ( UINTN RegNumber;
CHAR8 OutBuffer[9]; // 1 reg=8 hex chars, and the end '\0' (escape seq)
CHAR8 *OutBufPtr; // pointer to the output buffer
-
+
RegNumber = AsciiStrHexToUintn (&InBuffer[1]);
if ((RegNumber < 0) || (RegNumber >= sizeof (gRegisterOffsets)/sizeof (UINTN))) {
@@ -203,14 +203,14 @@ ReadNthRegister ( }
-/** ‘g’
- Reads the general registers into an output buffer and sends it as a packet
+/** ‘g’
+ Reads the general registers into an output buffer and sends it as a packet
@param SystemContext Register content at time of the exception
**/
VOID
EFIAPI
-ReadGeneralRegisters (
+ReadGeneralRegisters (
IN EFI_SYSTEM_CONTEXT SystemContext
)
{
@@ -219,7 +219,7 @@ ReadGeneralRegisters ( CHAR8 *OutBufPtr; // pointer to the output buffer
OutBufPtr = OutBuffer;
- for(i = 0 ; i < sizeof (gRegisterOffsets)/sizeof (UINTN) ; i++) { // there are only 16 registers to read
+ for(i = 0 ; i < sizeof (gRegisterOffsets)/sizeof (UINTN) ; i++) { // there are only 16 registers to read
OutBufPtr = BasicReadRegister(SystemContext, i, OutBufPtr);
}
@@ -246,26 +246,26 @@ BasicWriteRegister ( UINTN RegSize;
UINTN TempValue; // the value transferred from a hex char
UINT32 NewValue; // the new value of the RegNumber-th Register
-
+
NewValue = 0;
RegSize = 0;
while (RegSize < REG_SIZE) {
TempValue = HexCharToInt(*InBufPtr++);
-
+
if (TempValue < 0) {
- SendError (GDB_EBADMEMDATA);
+ SendError (GDB_EBADMEMDATA);
return NULL;
}
NewValue += (TempValue << (RegSize+4));
TempValue = HexCharToInt(*InBufPtr++);
-
+
if (TempValue < 0) {
- SendError (GDB_EBADMEMDATA);
+ SendError (GDB_EBADMEMDATA);
return NULL;
}
-
- NewValue += (TempValue << RegSize);
+
+ NewValue += (TempValue << RegSize);
RegSize = RegSize + 8;
}
*(FindPointerToRegister(SystemContext, RegNumber)) = NewValue;
@@ -290,19 +290,19 @@ WriteNthRegister ( CHAR8 RegNumBuffer[MAX_REG_NUM_BUF_SIZE]; // put the 'n..' part of the message into this array
CHAR8 *RegNumBufPtr;
CHAR8 *InBufPtr; // pointer to the input buffer
-
+
// find the register number to write
InBufPtr = &InBuffer[1];
RegNumBufPtr = RegNumBuffer;
while (*InBufPtr != '=') {
*RegNumBufPtr++ = *InBufPtr++;
- }
+ }
*RegNumBufPtr = '\0';
- RegNumber = AsciiStrHexToUintn (RegNumBuffer);
+ RegNumber = AsciiStrHexToUintn (RegNumBuffer);
// check if this is a valid Register Number
if ((RegNumber < 0) || (RegNumber >= sizeof (gRegisterOffsets)/sizeof (UINTN))) {
- SendError (GDB_EINVALIDREGNUM);
+ SendError (GDB_EINVALIDREGNUM);
return;
}
InBufPtr++; // skips the '=' character
@@ -327,16 +327,16 @@ WriteGeneralRegisters ( UINTN i;
CHAR8 *InBufPtr; /// pointer to the input buffer
- // check to see if the buffer is the right size which is
- // 1 (for 'G') + 16 (for 16 registers) * 8 ( for 8 hex chars each) = 129
+ // check to see if the buffer is the right size which is
+ // 1 (for 'G') + 16 (for 16 registers) * 8 ( for 8 hex chars each) = 129
if (AsciiStrLen(InBuffer) != 129) { // 16 regs, 8 hex chars each, and the end '\0' (escape seq)
- //Bad message. Message is not the right length
- SendError (GDB_EBADBUFSIZE);
+ //Bad message. Message is not the right length
+ SendError (GDB_EBADBUFSIZE);
return;
}
InBufPtr = &InBuffer[1];
-
+
// Read the new values for the registers from the input buffer to an array, NewValueArray.
// The values in the array are in the gdb ordering
for(i=0; i < sizeof (gRegisterOffsets)/sizeof (UINTN); i++) { // there are only 16 registers to write
@@ -346,11 +346,11 @@ WriteGeneralRegisters ( SendSuccess();
}
-/** ‘c [addr ]’
- Continue. addr is Address to resume. If addr is omitted, resume at current
+/** ‘c [addr ]’
+ Continue. addr is Address to resume. If addr is omitted, resume at current
Address.
-
- @param SystemContext Register content at time of the exception
+
+ @param SystemContext Register content at time of the exception
**/
VOID
EFIAPI
@@ -361,15 +361,15 @@ ContinueAtAddress ( {
if (PacketData[1] != '\0') {
SystemContext.SystemContextIa32->Eip = AsciiStrHexToUintn (&PacketData[1]);
- }
+ }
}
/** ‘s [addr ]’
- Single step. addr is the Address at which to resume. If addr is omitted, resume
+ Single step. addr is the Address at which to resume. If addr is omitted, resume
at same Address.
-
- @param SystemContext Register content at time of the exception
+
+ @param SystemContext Register content at time of the exception
**/
VOID
EFIAPI
@@ -421,9 +421,9 @@ GetBreakpointDataAddress ( @param SystemContext Register content at time of the exception
- @retval {1-4} Currently detected breakpoint value
+ @retval {1-4} Currently detected breakpoint value
@retval 0 No breakpoint detected.
-
+
**/
UINTN
GetBreakpointDetected (
@@ -444,7 +444,7 @@ GetBreakpointDetected ( } else if (Dr6.Bits.B3 == 1) {
BreakpointNumber = 4;
} else {
- BreakpointNumber = 0; //No breakpoint detected
+ BreakpointNumber = 0; //No breakpoint detected
}
return BreakpointNumber;
@@ -454,13 +454,13 @@ GetBreakpointDetected ( /**
Returns Breakpoint type (InstructionExecution, DataWrite, DataRead or DataReadWrite)
based on the Breakpoint number
-
+
@param SystemContext Register content at time of the exception
@param BreakpointNumber Breakpoint number
-
+
@retval BREAK_TYPE Breakpoint type value read from register DR7 RWn field
For unknown value, it returns NotSupported.
-
+
**/
BREAK_TYPE
GetBreakpointType (
@@ -474,22 +474,22 @@ GetBreakpointType ( Dr7.UintN = SystemContext.SystemContextIa32->Dr7;
if (BreakpointNumber == 1) {
- Type = (BREAK_TYPE) Dr7.Bits.RW0;
+ Type = (BREAK_TYPE) Dr7.Bits.RW0;
} else if (BreakpointNumber == 2) {
- Type = (BREAK_TYPE) Dr7.Bits.RW1;
+ Type = (BREAK_TYPE) Dr7.Bits.RW1;
} else if (BreakpointNumber == 3) {
- Type = (BREAK_TYPE) Dr7.Bits.RW2;
+ Type = (BREAK_TYPE) Dr7.Bits.RW2;
} else if (BreakpointNumber == 4) {
- Type = (BREAK_TYPE) Dr7.Bits.RW3;
+ Type = (BREAK_TYPE) Dr7.Bits.RW3;
}
return Type;
}
-/**
+/**
Parses Length and returns the length which DR7 LENn field accepts.
- For example: If we receive 1-Byte length then we should return 0.
+ For example: If we receive 1-Byte length then we should return 0.
Zero gets written to DR7 LENn field.
@param Length Breakpoint length in Bytes (1 byte, 2 byte, 4 byte)
@@ -502,7 +502,7 @@ ConvertLengthData ( IN UINTN Length
)
{
- if (Length == 1) { //1-Byte length
+ if (Length == 1) { //1-Byte length
return 0;
} else if (Length == 2) { //2-Byte length
return 1;
@@ -515,8 +515,8 @@ ConvertLengthData ( /**
- Finds the next free debug register. If all the registers are occupied then
- EFI_OUT_OF_RESOURCES is returned.
+ Finds the next free debug register. If all the registers are occupied then
+ EFI_OUT_OF_RESOURCES is returned.
@param SystemContext Register content at time of the exception
@param Register Register value (0 - 3 for the first free debug register)
@@ -553,11 +553,11 @@ FindNextFreeDebugRegister ( /**
Enables the debug register. Writes Address value to appropriate DR0-3 register.
Sets LENn, Gn, RWn bits in DR7 register.
-
+
@param SystemContext Register content at time of the exception
- @param Register Register value (0 - 3)
+ @param Register Register value (0 - 3)
@param Address Breakpoint address value
- @param Type Breakpoint type (Instruction, Data write, Data read
+ @param Type Breakpoint type (Instruction, Data write, Data read
or write etc.)
@retval EFI_STATUS Appropriate status value.
@@ -577,15 +577,15 @@ EnableDebugRegister ( //Convert length data
Length = ConvertLengthData (Length);
- //For Instruction execution, length should be 0
+ //For Instruction execution, length should be 0
//(Ref. Intel reference manual 18.2.4)
if ((Type == 0) && (Length != 0)) {
return EFI_INVALID_PARAMETER;
}
-
+
//Hardware doesn't support ReadWatch (z3 packet) type. GDB can handle
//software breakpoint. We should send empty packet in both these cases.
- if ((Type == (BREAK_TYPE)DataRead) ||
+ if ((Type == (BREAK_TYPE)DataRead) ||
(Type == (BREAK_TYPE)SoftwareBreakpoint)) {
return EFI_UNSUPPORTED;
}
@@ -617,7 +617,7 @@ EnableDebugRegister ( return EFI_INVALID_PARAMETER;
}
- //Update Dr7 with appropriate Gn, RWn and LENn bits
+ //Update Dr7 with appropriate Gn, RWn and LENn bits
SystemContext.SystemContextIa32->Dr7 = Dr7.UintN;
return EFI_SUCCESS;
@@ -633,7 +633,7 @@ EnableDebugRegister ( @param SystemContext Register content at time of the exception
@param Address Breakpoint address value
@param Length Breakpoint length value
- @param Type Breakpoint type (Instruction, Data write,
+ @param Type Breakpoint type (Instruction, Data write,
Data read or write etc.)
@param Register Register value to be returned
@@ -653,7 +653,7 @@ FindMatchingDebugRegister ( //Hardware doesn't support ReadWatch (z3 packet) type. GDB can handle
//software breakpoint. We should send empty packet in both these cases.
- if ((Type == (BREAK_TYPE)DataRead) ||
+ if ((Type == (BREAK_TYPE)DataRead) ||
(Type == (BREAK_TYPE)SoftwareBreakpoint)) {
return EFI_UNSUPPORTED;
}
@@ -663,24 +663,24 @@ FindMatchingDebugRegister ( Dr7.UintN = SystemContext.SystemContextIa32->Dr7;
- if ((Dr7.Bits.G0 == 1) &&
+ if ((Dr7.Bits.G0 == 1) &&
(Dr7.Bits.LEN0 == Length) &&
- (Dr7.Bits.RW0 == Type) &&
+ (Dr7.Bits.RW0 == Type) &&
(Address == SystemContext.SystemContextIa32->Dr0)) {
*Register = 0;
- } else if ((Dr7.Bits.G1 == 1) &&
+ } else if ((Dr7.Bits.G1 == 1) &&
(Dr7.Bits.LEN1 == Length) &&
- (Dr7.Bits.RW1 == Type) &&
+ (Dr7.Bits.RW1 == Type) &&
(Address == SystemContext.SystemContextIa32->Dr1)) {
*Register = 1;
- } else if ((Dr7.Bits.G2 == 1) &&
+ } else if ((Dr7.Bits.G2 == 1) &&
(Dr7.Bits.LEN2 == Length) &&
- (Dr7.Bits.RW2 == Type) &&
+ (Dr7.Bits.RW2 == Type) &&
(Address == SystemContext.SystemContextIa32->Dr2)) {
*Register = 2;
- } else if ((Dr7.Bits.G3 == 1) &&
+ } else if ((Dr7.Bits.G3 == 1) &&
(Dr7.Bits.LEN3 == Length) &&
- (Dr7.Bits.RW3 == Type) &&
+ (Dr7.Bits.RW3 == Type) &&
(Address == SystemContext.SystemContextIa32->Dr3)) {
*Register = 3;
} else {
@@ -704,12 +704,12 @@ FindMatchingDebugRegister ( EFI_STATUS
DisableDebugRegister (
IN EFI_SYSTEM_CONTEXT SystemContext,
- IN UINTN Register
+ IN UINTN Register
)
{
IA32_DR7 Dr7;
UINTN Address = 0;
-
+
//Read DR7 register so appropriate Gn, RWn and LENn bits can be turned off.
Dr7.UintN = SystemContext.SystemContextIa32->Dr7;
@@ -863,15 +863,15 @@ RemoveBreakPoint ( }
switch (Type) {
-
+
case 0: //Software breakpoint
BreakType = SoftwareBreakpoint;
break;
-
+
case 1: //Hardware breakpoint
BreakType = InstructionExecution;
break;
-
+
case 2: //Write watchpoint
BreakType = DataWrite;
break;
diff --git a/EmbeddedPkg/Library/GdbDebugAgent/X64/Processor.c b/EmbeddedPkg/Library/GdbDebugAgent/X64/Processor.c index 5d13c937ee..8a39c4828f 100755 --- a/EmbeddedPkg/Library/GdbDebugAgent/X64/Processor.c +++ b/EmbeddedPkg/Library/GdbDebugAgent/X64/Processor.c @@ -2,7 +2,7 @@ Processor specific parts of the GDB stub
Copyright (c) 2008 - 2009, Apple Inc. All rights reserved.<BR>
-
+
This program and the accompanying materials
are licensed and made available under the terms and conditions of the BSD License
which accompanies this distribution. The full text of the license may be found at
@@ -19,7 +19,7 @@ // Array of exception types that need to be hooked by the debugger
//
EFI_EXCEPTION_TYPE_ENTRY gExceptionType[] = {
- { EXCEPT_X64_DIVIDE_ERROR, GDB_SIGFPE },
+ { EXCEPT_X64_DIVIDE_ERROR, GDB_SIGFPE },
{ EXCEPT_X64_DEBUG, GDB_SIGTRAP },
{ EXCEPT_X64_NMI, GDB_SIGEMT },
{ EXCEPT_X64_BREAKPOINT, GDB_SIGTRAP },
@@ -37,7 +37,7 @@ EFI_EXCEPTION_TYPE_ENTRY gExceptionType[] = { // The offsets of registers SystemContextX64.
-// The fields in the array are in the gdb ordering.
+// The fields in the array are in the gdb ordering.
// HAVE TO DOUBLE-CHECK THE ORDER of the 24 regs
//
UINTN gRegisterOffsets[] = {
@@ -70,8 +70,8 @@ UINTN gRegisterOffsets[] = { /**
Return the number of entries in the gExceptionType[]
-
- @retval UINTN, the number of entries in the gExceptionType[] array.
+
+ @retval UINTN, the number of entries in the gExceptionType[] array.
**/
UINTN
MaxEfiException (
@@ -84,8 +84,8 @@ MaxEfiException ( /**
Return the number of entries in the gRegisters[]
-
- @retval UINTN, the number of entries (registers) in the gRegisters[] array.
+
+ @retval UINTN, the number of entries (registers) in the gRegisters[] array.
**/
UINTN
MaxRegisterCount (
@@ -95,9 +95,9 @@ MaxRegisterCount ( return sizeof (gRegisterOffsets)/sizeof (UINTN);
}
-
+
/**
- Check to see if the ISA is supported.
+ Check to see if the ISA is supported.
ISA = Instruction Set Architecture
@retval TRUE if Isa is supported
@@ -114,14 +114,14 @@ CheckIsa ( /**
This takes in the register number and the System Context, and returns a pointer to the RegNumber-th register in gdb ordering
It is, by default, set to find the register pointer of the X64 member
- @param SystemContext Register content at time of the exception
+ @param SystemContext Register content at time of the exception
@param RegNumber The register to which we want to find a pointer
@retval the pointer to the RegNumber-th pointer
**/
UINTN *
FindPointerToRegister(
IN EFI_SYSTEM_CONTEXT SystemContext,
- IN UINTN RegNumber
+ IN UINTN RegNumber
)
{
UINT8 *TempPtr;
@@ -145,7 +145,7 @@ BasicReadRegister ( )
{
UINTN RegSize;
-
+
RegSize = 0;
while (RegSize < 64) {
*OutBufPtr++ = mHexToStr[((*FindPointerToRegister(SystemContext, RegNumber) >> (RegSize+4)) & 0xf)];
@@ -156,8 +156,8 @@ BasicReadRegister ( }
-/** ‘p n’
- Reads the n-th register's value into an output buffer and sends it as a packet
+/** ‘p n’
+ Reads the n-th register's value into an output buffer and sends it as a packet
@param SystemContext Register content at time of the exception
@param InBuffer Pointer to the input buffer received from gdb server
**/
@@ -170,42 +170,42 @@ ReadNthRegister ( UINTN RegNumber;
CHAR8 OutBuffer[17]; // 1 reg=16 hex chars, and the end '\0' (escape seq)
CHAR8 *OutBufPtr; // pointer to the output buffer
-
+
RegNumber = AsciiStrHexToUintn (&InBuffer[1]);
-
+
if ((RegNumber < 0) || (RegNumber >= MaxRegisterCount())) {
- SendError (GDB_EINVALIDREGNUM);
+ SendError (GDB_EINVALIDREGNUM);
return;
}
-
+
OutBufPtr = OutBuffer;
OutBufPtr = BasicReadRegister(SystemContext, RegNumber, OutBufPtr);
-
+
*OutBufPtr = '\0'; // the end of the buffer
SendPacket (OutBuffer);
}
-/** ‘g’
- Reads the general registers into an output buffer and sends it as a packet
+/** ‘g’
+ Reads the general registers into an output buffer and sends it as a packet
@param SystemContext Register content at time of the exception
**/
VOID
EFIAPI
-ReadGeneralRegisters (
+ReadGeneralRegisters (
IN EFI_SYSTEM_CONTEXT SystemContext
)
{
UINTN i;
CHAR8 OutBuffer[385]; // 24 regs, 16 hex chars each, and the end '\0' (escape seq)
CHAR8 *OutBufPtr; // pointer to the output buffer
-
+
OutBufPtr = OutBuffer;
- for(i = 0 ; i < MaxRegisterCount() ; i++) { // there are only 24 registers to read
+ for(i = 0 ; i < MaxRegisterCount() ; i++) { // there are only 24 registers to read
OutBufPtr = BasicReadRegister(SystemContext, i, OutBufPtr);
}
-
+
*OutBufPtr = '\0'; // the end of the buffer
SendPacket (OutBuffer);
}
@@ -229,26 +229,26 @@ BasicWriteRegister ( UINTN RegSize;
UINTN TempValue; // the value transferred from a hex char
UINT64 NewValue; // the new value of the RegNumber-th Register
-
+
NewValue = 0;
RegSize = 0;
while (RegSize < 64) {
TempValue = HexCharToInt(*InBufPtr++);
-
+
if (TempValue < 0) {
- SendError (GDB_EBADMEMDATA);
+ SendError (GDB_EBADMEMDATA);
return NULL;
}
-
+
NewValue += (TempValue << (RegSize+4));
TempValue = HexCharToInt(*InBufPtr++);
-
+
if (TempValue < 0) {
- SendError (GDB_EBADMEMDATA);
+ SendError (GDB_EBADMEMDATA);
return NULL;
}
-
- NewValue += (TempValue << RegSize);
+
+ NewValue += (TempValue << RegSize);
RegSize = RegSize + 8;
}
*(FindPointerToRegister(SystemContext, RegNumber)) = NewValue;
@@ -273,19 +273,19 @@ WriteNthRegister ( CHAR8 RegNumBuffer[MAX_REG_NUM_BUF_SIZE]; // put the 'n..' part of the message into this array
CHAR8 *RegNumBufPtr;
CHAR8 *InBufPtr; // pointer to the input buffer
-
+
// find the register number to write
InBufPtr = &InBuffer[1];
RegNumBufPtr = RegNumBuffer;
while (*InBufPtr != '=') {
*RegNumBufPtr++ = *InBufPtr++;
- }
+ }
*RegNumBufPtr = '\0';
- RegNumber = AsciiStrHexToUintn (RegNumBuffer);
+ RegNumber = AsciiStrHexToUintn (RegNumBuffer);
// check if this is a valid Register Number
if ((RegNumber < 0) || (RegNumber >= MaxRegisterCount())) {
- SendError (GDB_EINVALIDREGNUM);
+ SendError (GDB_EINVALIDREGNUM);
return;
}
InBufPtr++; // skips the '=' character
@@ -309,30 +309,30 @@ WriteGeneralRegisters ( {
UINTN i;
CHAR8 *InBufPtr; /// pointer to the input buffer
-
- // check to see if the buffer is the right size which is
- // 1 (for 'G') + 16 (for 16 registers) * 8 ( for 8 hex chars each) = 385
+
+ // check to see if the buffer is the right size which is
+ // 1 (for 'G') + 16 (for 16 registers) * 8 ( for 8 hex chars each) = 385
if (AsciiStrLen(InBuffer) != 385) { // 24 regs, 16 hex chars each, and the end '\0' (escape seq)
- //Bad message. Message is not the right length
- SendError (GDB_EBADBUFSIZE);
+ //Bad message. Message is not the right length
+ SendError (GDB_EBADBUFSIZE);
return;
}
-
+
InBufPtr = &InBuffer[1];
-
+
// Read the new values for the registers from the input buffer to an array, NewValueArray.
// The values in the array are in the gdb ordering
for(i=0; i < MaxRegisterCount(); i++) { // there are only 16 registers to write
InBufPtr = BasicWriteRegister(SystemContext, i, InBufPtr);
}
-
+
SendSuccess();
}
- /**
+ /**
Insert Single Step in the SystemContext
-
+
@param SystemContext Register content at time of the exception
**/
VOID
@@ -343,11 +343,11 @@ AddSingleStep ( SystemContext.SystemContextX64->Rflags |= TF_BIT; //Setting the TF bit.
}
-
-
-/**
+
+
+/**
Remove Single Step in the SystemContext
-
+
@param SystemContext Register content at time of the exception
**/
VOID
@@ -360,11 +360,11 @@ RemoveSingleStep ( -/** ‘c [addr ]’
- Continue. addr is Address to resume. If addr is omitted, resume at current
+/** ‘c [addr ]’
+ Continue. addr is Address to resume. If addr is omitted, resume at current
Address.
-
- @param SystemContext Register content at time of the exception
+
+ @param SystemContext Register content at time of the exception
**/
VOID
EFIAPI
@@ -375,15 +375,15 @@ ContinueAtAddress ( {
if (PacketData[1] != '\0') {
SystemContext.SystemContextX64->Rip = AsciiStrHexToUintn(&PacketData[1]);
- }
+ }
}
/** ‘s [addr ]’
- Single step. addr is the Address at which to resume. If addr is omitted, resume
+ Single step. addr is the Address at which to resume. If addr is omitted, resume
at same Address.
-
- @param SystemContext Register content at time of the exception
+
+ @param SystemContext Register content at time of the exception
**/
VOID
EFIAPI
@@ -395,19 +395,19 @@ SingleStep ( if (PacketData[1] != '\0') {
SystemContext.SystemContextX64->Rip = AsciiStrHexToUintn (&PacketData[1]);
}
-
+
AddSingleStep (SystemContext);
}
/**
- Returns breakpoint data address from DR0-DR3 based on the input breakpoint
+ Returns breakpoint data address from DR0-DR3 based on the input breakpoint
number
@param SystemContext Register content at time of the exception
@param BreakpointNumber Breakpoint number
- @retval Address Data address from DR0-DR3 based on the
+ @retval Address Data address from DR0-DR3 based on the
breakpoint number.
**/
@@ -435,7 +435,7 @@ GetBreakpointDataAddress ( }
/**
- Returns currently detected breakpoint value based on the register
+ Returns currently detected breakpoint value based on the register
DR6 B0-B3 field.
If no breakpoint is detected then it returns 0.
@@ -471,13 +471,13 @@ GetBreakpointDetected ( }
/**
- Returns Breakpoint type (InstructionExecution, DataWrite, DataRead
+ Returns Breakpoint type (InstructionExecution, DataWrite, DataRead
or DataReadWrite) based on the Breakpoint number
@param SystemContext Register content at time of the exception
@param BreakpointNumber Breakpoint number
- @retval BREAK_TYPE Breakpoint type value read from register DR7 RWn
+ @retval BREAK_TYPE Breakpoint type value read from register DR7 RWn
field. For unknown value, it returns NotSupported.
**/
@@ -506,9 +506,9 @@ GetBreakpointType ( }
-/**
+/**
Parses Length and returns the length which DR7 LENn field accepts.
- For example: If we receive 1-Byte length then we should return 0.
+ For example: If we receive 1-Byte length then we should return 0.
Zero gets written to DR7 LENn field.
@param Length Breakpoint length in Bytes (1 byte, 2 byte, 4 byte)
@@ -521,7 +521,7 @@ ConvertLengthData ( IN UINTN Length
)
{
- if (Length == 1) { //1-Byte length
+ if (Length == 1) { //1-Byte length
return 0;
} else if (Length == 2) { //2-Byte length
return 1;
@@ -576,7 +576,7 @@ FindNextFreeDebugRegister ( @param SystemContext Register content at time of the exception
@param Register Register value (0 - 3)
@param Address Breakpoint address value
- @param Type Breakpoint type (Instruction, Data write,
+ @param Type Breakpoint type (Instruction, Data write,
Data read or write etc.)
@retval EFI_STATUS Appropriate status value.
@@ -596,7 +596,7 @@ EnableDebugRegister ( //Convert length data
Length = ConvertLengthData (Length);
- //For Instruction execution, length should be 0
+ //For Instruction execution, length should be 0
//(Ref. Intel reference manual 18.2.4)
if ((Type == 0) && (Length != 0)) {
return EFI_INVALID_PARAMETER;
@@ -604,7 +604,7 @@ EnableDebugRegister ( //Hardware doesn't support ReadWatch (z3 packet) type. GDB can handle
//software breakpoint. We should send empty packet in both these cases.
- if ((Type == (BREAK_TYPE)DataRead) ||
+ if ((Type == (BREAK_TYPE)DataRead) ||
(Type == (BREAK_TYPE)SoftwareBreakpoint)) {
return EFI_UNSUPPORTED;
}
@@ -643,14 +643,14 @@ EnableDebugRegister ( }
-/**
- Returns register number 0 - 3 for the maching debug register.
- This function compares incoming Address, Type, Length and
+/**
+ Returns register number 0 - 3 for the maching debug register.
+ This function compares incoming Address, Type, Length and
if there is a match then it returns the appropriate register number.
In case of mismatch, function returns EFI_NOT_FOUND message.
@param SystemContext Register content at time of the exception
- @param Address Breakpoint address value
+ @param Address Breakpoint address value
@param Length Breakpoint length value
@param Type Breakpoint type (Instruction, Data write, Data read
or write etc.)
@@ -672,7 +672,7 @@ FindMatchingDebugRegister ( //Hardware doesn't support ReadWatch (z3 packet) type. GDB can handle
//software breakpoint. We should send empty packet in both these cases.
- if ((Type == (BREAK_TYPE)DataRead) ||
+ if ((Type == (BREAK_TYPE)DataRead) ||
(Type == (BREAK_TYPE)SoftwareBreakpoint)) {
return EFI_UNSUPPORTED;
}
@@ -682,24 +682,24 @@ FindMatchingDebugRegister ( Dr7.UintN = SystemContext.SystemContextIa32->Dr7;
- if ((Dr7.Bits.G0 == 1) &&
+ if ((Dr7.Bits.G0 == 1) &&
(Dr7.Bits.LEN0 == Length) &&
- (Dr7.Bits.RW0 == Type) &&
+ (Dr7.Bits.RW0 == Type) &&
(Address == SystemContext.SystemContextIa32->Dr0)) {
*Register = 0;
- } else if ((Dr7.Bits.G1 == 1) &&
+ } else if ((Dr7.Bits.G1 == 1) &&
(Dr7.Bits.LEN1 == Length) &&
- (Dr7.Bits.RW1 == Type) &&
+ (Dr7.Bits.RW1 == Type) &&
(Address == SystemContext.SystemContextIa32->Dr1)) {
*Register = 1;
- } else if ((Dr7.Bits.G2 == 1) &&
+ } else if ((Dr7.Bits.G2 == 1) &&
(Dr7.Bits.LEN2 == Length) &&
- (Dr7.Bits.RW2 == Type) &&
+ (Dr7.Bits.RW2 == Type) &&
(Address == SystemContext.SystemContextIa32->Dr2)) {
*Register = 2;
- } else if ((Dr7.Bits.G3 == 1) &&
+ } else if ((Dr7.Bits.G3 == 1) &&
(Dr7.Bits.LEN3 == Length) &&
- (Dr7.Bits.RW3 == Type) &&
+ (Dr7.Bits.RW3 == Type) &&
(Address == SystemContext.SystemContextIa32->Dr3)) {
*Register = 3;
} else {
@@ -884,15 +884,15 @@ RemoveBreakPoint ( }
switch (Type) {
-
+
case 0: //Software breakpoint
BreakType = SoftwareBreakpoint;
break;
-
+
case 1: //Hardware breakpoint
BreakType = InstructionExecution;
break;
-
+
case 2: //Write watchpoint
BreakType = DataWrite;
break;
@@ -954,8 +954,8 @@ ValidateAddress ( BOOLEAN
ValidateException (
- IN EFI_EXCEPTION_TYPE ExceptionType,
- IN OUT EFI_SYSTEM_CONTEXT SystemContext
+ IN EFI_EXCEPTION_TYPE ExceptionType,
+ IN OUT EFI_SYSTEM_CONTEXT SystemContext
)
{
return TRUE;
diff --git a/EmbeddedPkg/Library/GdbSerialDebugPortLib/GdbSerialDebugPortLib.c b/EmbeddedPkg/Library/GdbSerialDebugPortLib/GdbSerialDebugPortLib.c index cceb80dbf0..e3d1b47cc4 100644 --- a/EmbeddedPkg/Library/GdbSerialDebugPortLib/GdbSerialDebugPortLib.c +++ b/EmbeddedPkg/Library/GdbSerialDebugPortLib/GdbSerialDebugPortLib.c @@ -2,7 +2,7 @@ Basic serial IO abstaction for GDB
Copyright (c) 2008 - 2009, Apple Inc. All rights reserved.<BR>
-
+
This program and the accompanying materials
are licensed and made available under the terms and conditions of the BSD License
which accompanies this distribution. The full text of the license may be found at
@@ -28,10 +28,10 @@ UINTN gTimeOut = 0; /**
The constructor function initializes the UART.
-
+
@param ImageHandle The firmware allocated handle for the EFI image.
@param SystemTable A pointer to the EFI System Table.
-
+
@retval EFI_SUCCESS The constructor always returns EFI_SUCCESS.
**/
@@ -43,20 +43,20 @@ GdbSerialLibDebugPortConstructor ( )
{
EFI_STATUS Status;
-
+
Status = gBS->LocateProtocol (&gEfiDebugPortProtocolGuid, NULL, (VOID **)&gDebugPort);
if (!EFI_ERROR (Status)) {
gTimeOut = PcdGet32 (PcdGdbMaxPacketRetryCount);
gDebugPort->Reset (gDebugPort);
}
-
+
return Status;
}
/**
- Sets the baud rate, receive FIFO depth, transmit/receice time out, parity,
+ Sets the baud rate, receive FIFO depth, transmit/receice time out, parity,
data buts, and stop bits on a serial device. This call is optional as the serial
port will be set up with defaults base on PCD values.
@@ -77,14 +77,14 @@ GdbSerialLibDebugPortConstructor ( RETURN_STATUS
EFIAPI
GdbSerialInit (
- IN UINT64 BaudRate,
- IN UINT8 Parity,
- IN UINT8 DataBits,
- IN UINT8 StopBits
+ IN UINT64 BaudRate,
+ IN UINT8 Parity,
+ IN UINT8 DataBits,
+ IN UINT8 StopBits
)
{
EFI_STATUS Status;
-
+
Status = gDebugPort->Reset (gDebugPort);
return Status;
}
@@ -96,18 +96,18 @@ GdbSerialInit ( @return TRUE - Character availible
@return FALSE - Character not availible
-
+
**/
BOOLEAN
EFIAPI
GdbIsCharAvailable (
VOID
- )
+ )
{
EFI_STATUS Status;
-
+
Status = gDebugPort->Poll (gDebugPort);
-
+
return (Status == EFI_SUCCESS ? TRUE : FALSE);
}
@@ -116,7 +116,7 @@ GdbIsCharAvailable ( Get a character from GDB. This function must be able to run in interrupt context.
@return A character from GDB
-
+
**/
CHAR8
EFIAPI
@@ -127,12 +127,12 @@ GdbGetChar ( EFI_STATUS Status;
CHAR8 Char;
UINTN BufferSize;
-
+
do {
BufferSize = sizeof (Char);
Status = gDebugPort->Read (gDebugPort, gTimeOut, &BufferSize, &Char);
} while (EFI_ERROR (Status) || BufferSize != sizeof (Char));
-
+
return Char;
}
@@ -153,12 +153,12 @@ GdbPutChar ( {
EFI_STATUS Status;
UINTN BufferSize;
-
+
do {
BufferSize = sizeof (Char);
Status = gDebugPort->Write (gDebugPort, gTimeOut, &BufferSize, &Char);
} while (EFI_ERROR (Status) || BufferSize != sizeof (Char));
-
+
return;
}
diff --git a/EmbeddedPkg/Library/GdbSerialDebugPortLib/GdbSerialDebugPortLib.inf b/EmbeddedPkg/Library/GdbSerialDebugPortLib/GdbSerialDebugPortLib.inf index 888f10db1b..b7c289c5a3 100644 --- a/EmbeddedPkg/Library/GdbSerialDebugPortLib/GdbSerialDebugPortLib.inf +++ b/EmbeddedPkg/Library/GdbSerialDebugPortLib/GdbSerialDebugPortLib.inf @@ -40,7 +40,7 @@ [Protocols.common]
gEfiDebugPortProtocolGuid
-
+
[FixedPcd.common]
gEmbeddedTokenSpaceGuid.PcdGdbBaudRate|115200
gEmbeddedTokenSpaceGuid.PcdGdbDataBits|8
diff --git a/EmbeddedPkg/Library/GdbSerialLib/GdbSerialLib.c b/EmbeddedPkg/Library/GdbSerialLib/GdbSerialLib.c index a1515626a2..7ea976ff9d 100644 --- a/EmbeddedPkg/Library/GdbSerialLib/GdbSerialLib.c +++ b/EmbeddedPkg/Library/GdbSerialLib/GdbSerialLib.c @@ -2,7 +2,7 @@ Basic serial IO abstaction for GDB
Copyright (c) 2008 - 2009, Apple Inc. All rights reserved.<BR>
-
+
This program and the accompanying materials
are licensed and made available under the terms and conditions of the BSD License
which accompanies this distribution. The full text of the license may be found at
@@ -54,10 +54,10 @@ UINTN gPort; /**
The constructor function initializes the UART.
-
+
@param ImageHandle The firmware allocated handle for the EFI image.
@param SystemTable A pointer to the EFI System Table.
-
+
@retval EFI_SUCCESS The constructor always returns EFI_SUCCESS.
**/
@@ -72,9 +72,9 @@ GdbSerialLibConstructor ( UINT8 DataBits;
UINT8 Parity;
UINT8 StopBits;
-
+
gPort = (UINTN)PcdGet32 (PcdGdbUartPort);
-
+
BaudRate = PcdGet64 (PcdGdbBaudRate);
Parity = PcdGet8 (PcdGdbParity);
DataBits = PcdGet8 (PcdGdbDataBits);
@@ -86,7 +86,7 @@ GdbSerialLibConstructor ( /**
- Sets the baud rate, receive FIFO depth, transmit/receice time out, parity,
+ Sets the baud rate, receive FIFO depth, transmit/receice time out, parity,
data buts, and stop bits on a serial device. This call is optional as the serial
port will be set up with defaults base on PCD values.
@@ -107,10 +107,10 @@ GdbSerialLibConstructor ( RETURN_STATUS
EFIAPI
GdbSerialInit (
- IN UINT64 BaudRate,
- IN UINT8 Parity,
- IN UINT8 DataBits,
- IN UINT8 StopBits
+ IN UINT64 BaudRate,
+ IN UINT8 Parity,
+ IN UINT8 DataBits,
+ IN UINT8 StopBits
)
{
UINTN Divisor;
@@ -121,7 +121,7 @@ GdbSerialInit ( //
// We assume the UART has been turned on to decode gPort address range
//
-
+
//
// Map 5..8 to 0..3
//
@@ -130,8 +130,8 @@ GdbSerialInit ( //
// Calculate divisor for baud generator
//
- Divisor = 115200/(UINTN)BaudRate;
-
+ Divisor = 115200/(UINTN)BaudRate;
+
//
// Set communications format
//
@@ -167,18 +167,18 @@ GdbSerialInit ( @return TRUE - Character availible
@return FALSE - Character not availible
-
+
**/
BOOLEAN
EFIAPI
GdbIsCharAvailable (
VOID
- )
+ )
{
UINT8 Data;
-
+
Data = IoRead8 (gPort + LSR_OFFSET);
-
+
return ((Data & LSR_RXDA) == LSR_RXDA);
}
@@ -187,7 +187,7 @@ GdbIsCharAvailable ( Get a character from GDB. This function must be able to run in interrupt context.
@return A character from GDB
-
+
**/
CHAR8
EFIAPI
@@ -204,7 +204,7 @@ GdbGetChar ( } while ((Data & LSR_RXDA) == 0);
Char = IoRead8 (gPort);
-
+
// Make this an EFI_D_INFO after we get everything debugged.
DEBUG ((EFI_D_ERROR, "<%c<", Char));
return Char;
@@ -226,15 +226,15 @@ GdbPutChar ( )
{
UINT8 Data;
-
+
// Make this an EFI_D_INFO after we get everything debugged.
DEBUG ((EFI_D_ERROR, ">%c>", Char));
-
+
// Wait for the serial port to be ready
do {
Data = IoRead8 (gPort + LSR_OFFSET);
} while ((Data & LSR_TXRDY) == 0);
-
+
IoWrite8 (gPort, Char);
}
diff --git a/EmbeddedPkg/Library/HalRuntimeServicesExampleLib/Capsule.c b/EmbeddedPkg/Library/HalRuntimeServicesExampleLib/Capsule.c index 3764bd5670..ec89cfdeec 100644 --- a/EmbeddedPkg/Library/HalRuntimeServicesExampleLib/Capsule.c +++ b/EmbeddedPkg/Library/HalRuntimeServicesExampleLib/Capsule.c @@ -2,7 +2,7 @@ Generic Capsule services
Copyright (c) 2008 - 2009, Apple Inc. All rights reserved.<BR>
-
+
This program and the accompanying materials
are licensed and made available under the terms and conditions of the BSD License
which accompanies this distribution. The full text of the license may be found at
@@ -19,7 +19,7 @@ //
//Max size capsule services support are platform policy,to populate capsules we just need
//memory to maintain them across reset,it is not a problem. And to special capsules ,for
-//example,update flash,it is mostly decided by the platform. Here is a sample size for
+//example,update flash,it is mostly decided by the platform. Here is a sample size for
//different type capsules.
//
#define MAX_SIZE_POPULATE (0)
@@ -34,8 +34,8 @@ SupportUpdateCapsuleRest ( )
{
//
- //If the platform has a way to guarantee the memory integrity across a system reset, return
- //TRUE, else FALSE.
+ //If the platform has a way to guarantee the memory integrity across a system reset, return
+ //TRUE, else FALSE.
//
return FALSE;
}
@@ -54,7 +54,7 @@ SupportCapsuleSize ( //
*MaxSizePopulate = MAX_SIZE_POPULATE;
*MaxSizeNonPopulate = MAX_SIZE_NON_POPULATE;
- return;
+ return;
}
@@ -77,7 +77,7 @@ Arguments: CapsuleHeaderArray A array of pointers to capsule headers passed in
CapsuleCount The number of capsule
ScatterGatherList Physical address of datablock list points to capsule
-
+
Returns:
EFI STATUS
@@ -85,8 +85,8 @@ Returns: not set, the capsule has been successfully processed by the firmware.
If it set, the ScattlerGatherList is successfully to be set.
EFI_INVALID_PARAMETER CapsuleCount is less than 1,CapsuleGuid is not supported.
- EFI_DEVICE_ERROR Failed to SetVariable or AllocatePool or ProcessFirmwareVolume.
-
+ EFI_DEVICE_ERROR Failed to SetVariable or AllocatePool or ProcessFirmwareVolume.
+
--*/
{
UINTN CapsuleSize;
@@ -110,17 +110,17 @@ Returns: for (ArrayNumber = 0; ArrayNumber < CapsuleCount; ArrayNumber++) {
CapsuleHeader = CapsuleHeaderArray[ArrayNumber];
if ((CapsuleHeader->Flags & (CAPSULE_FLAGS_PERSIST_ACROSS_RESET | CAPSULE_FLAGS_POPULATE_SYSTEM_TABLE)) == CAPSULE_FLAGS_POPULATE_SYSTEM_TABLE) {
- return EFI_INVALID_PARAMETER;
+ return EFI_INVALID_PARAMETER;
}
if (!CompareGuid (&CapsuleHeader->CapsuleGuid, &gEfiCapsuleGuid)) {
if ((CapsuleHeader->Flags & CAPSULE_FLAGS_POPULATE_SYSTEM_TABLE) == 0) {
return EFI_UNSUPPORTED;
- }
- }
+ }
+ }
}
//
- //Assume that capsules have the same flags on reseting or not.
+ //Assume that capsules have the same flags on reseting or not.
//
CapsuleHeader = CapsuleHeaderArray[0];
@@ -131,28 +131,28 @@ Returns: if (!SupportUpdateCapsuleRest()) {
return EFI_UNSUPPORTED;
}
-
+
if (ScatterGatherList == 0) {
return EFI_INVALID_PARAMETER;
} else {
Status = EfiSetVariable (
- EFI_CAPSULE_VARIABLE_NAME,
- &gEfiCapsuleVendorGuid,
- EFI_VARIABLE_NON_VOLATILE | EFI_VARIABLE_RUNTIME_ACCESS | EFI_VARIABLE_BOOTSERVICE_ACCESS,
- sizeof (UINTN),
- (VOID *) &ScatterGatherList
+ EFI_CAPSULE_VARIABLE_NAME,
+ &gEfiCapsuleVendorGuid,
+ EFI_VARIABLE_NON_VOLATILE | EFI_VARIABLE_RUNTIME_ACCESS | EFI_VARIABLE_BOOTSERVICE_ACCESS,
+ sizeof (UINTN),
+ (VOID *) &ScatterGatherList
);
- if (Status != EFI_SUCCESS) {
+ if (Status != EFI_SUCCESS) {
return EFI_DEVICE_ERROR;
}
}
return EFI_SUCCESS;
}
-
+
//
//The rest occurs in the condition of non-reset mode
//
- if (EfiAtRuntime ()) {
+ if (EfiAtRuntime ()) {
return EFI_INVALID_PARAMETER;
}
@@ -169,7 +169,7 @@ Returns: gBS->CopyMem (BufferPtr, (UINT8*)CapsuleHeader+ CapsuleHeader->HeaderSize, CapsuleSize);
//
- //Call DXE service ProcessFirmwareVolume to process immediatelly
+ //Call DXE service ProcessFirmwareVolume to process immediatelly
//
Status = gDS->ProcessFirmwareVolume (BufferPtr, CapsuleSize, &FvHandle);
if (Status != EFI_SUCCESS) {
@@ -184,7 +184,7 @@ Returns: Done:
if (BufferPtr != NULL) {
gBS->FreePool (BufferPtr);
- }
+ }
return EFI_DEVICE_ERROR;
}
@@ -231,10 +231,10 @@ Returns: if ((MaxiumCapsuleSize == NULL) ||(ResetType == NULL)) {
return EFI_INVALID_PARAMETER;
- }
+ }
CapsuleHeader = NULL;
-
+
//
//Compare GUIDs with EFI_CAPSULE_GUID, if capsule header contains CAPSULE_FLAGS_PERSIST_ACROSS_RESET
//and CAPSULE_FLAGS_POPULATE_SYSTEM_TABLE flags,whatever the GUID is ,the service supports.
@@ -242,20 +242,20 @@ Returns: for (ArrayNumber = 0; ArrayNumber < CapsuleCount; ArrayNumber++) {
CapsuleHeader = CapsuleHeaderArray[ArrayNumber];
if ((CapsuleHeader->Flags & (CAPSULE_FLAGS_PERSIST_ACROSS_RESET | CAPSULE_FLAGS_POPULATE_SYSTEM_TABLE)) == CAPSULE_FLAGS_POPULATE_SYSTEM_TABLE) {
- return EFI_INVALID_PARAMETER;
+ return EFI_INVALID_PARAMETER;
}
if (!CompareGuid (&CapsuleHeader->CapsuleGuid, &gEfiCapsuleGuid)) {
if ((CapsuleHeader->Flags & CAPSULE_FLAGS_POPULATE_SYSTEM_TABLE) == 0) {
return EFI_UNSUPPORTED;
}
- }
+ }
}
SupportCapsuleSize(&MaxSizePopulate,&MaxSizeNonPopulate);
//
- //Assume that capsules have the same flags on reseting or not.
+ //Assume that capsules have the same flags on reseting or not.
//
- CapsuleHeader = CapsuleHeaderArray[0];
+ CapsuleHeader = CapsuleHeaderArray[0];
if ((CapsuleHeader->Flags & CAPSULE_FLAGS_PERSIST_ACROSS_RESET) != 0) {
//
//Check if the platform supports update capsule across a system reset
@@ -264,11 +264,11 @@ Returns: return EFI_UNSUPPORTED;
}
*ResetType = EfiResetWarm;
- *MaxiumCapsuleSize = MaxSizePopulate;
+ *MaxiumCapsuleSize = MaxSizePopulate;
} else {
*ResetType = EfiResetCold;
*MaxiumCapsuleSize = MaxSizeNonPopulate;
- }
+ }
return EFI_SUCCESS;
}
diff --git a/EmbeddedPkg/Library/HalRuntimeServicesExampleLib/Mtc.c b/EmbeddedPkg/Library/HalRuntimeServicesExampleLib/Mtc.c index a3f3c13def..2b60d07203 100644 --- a/EmbeddedPkg/Library/HalRuntimeServicesExampleLib/Mtc.c +++ b/EmbeddedPkg/Library/HalRuntimeServicesExampleLib/Mtc.c @@ -63,7 +63,7 @@ Arguments: Returns:
- EFI_SUCCESS The event has been handled properly
+ EFI_SUCCESS The event has been handled properly
EFI_NOT_FOUND An error occurred updating the variable.
--*/
@@ -106,7 +106,7 @@ LibMtcGetNextHighMonotonicCount ( *HighCount = (UINT32) RShiftU64 (mEfiMtc, 32) + 1;
mEfiMtc = LShiftU64 (*HighCount, 32);
-
+
if (!EfiAtRuntime ()) {
gBS->RestoreTPL (OldTpl);
}
diff --git a/EmbeddedPkg/Library/HalRuntimeServicesExampleLib/ReportStatusCode.c b/EmbeddedPkg/Library/HalRuntimeServicesExampleLib/ReportStatusCode.c index aaae407284..e2d5500ae0 100644 --- a/EmbeddedPkg/Library/HalRuntimeServicesExampleLib/ReportStatusCode.c +++ b/EmbeddedPkg/Library/HalRuntimeServicesExampleLib/ReportStatusCode.c @@ -2,7 +2,7 @@ Report status code lib on top of either SerialLib and/or EFI Serial Protocol.
Based on PcdStatusCodeUseEfiSerial & PcdStatusCodeUseHardSerial settings
- There is just a single runtime memory buffer that contans all the data.
+ There is just a single runtime memory buffer that contans all the data.
Copyright (c) 2007, Intel Corporation. All rights reserved.<BR>
Portions copyright (c) 2008 - 2009, Apple Inc. All rights reserved.<BR>
@@ -77,12 +77,12 @@ LibReportStatusCode ( // Print DEBUG() information into output buffer.
//
CharCount = AsciiVSPrint (
- Buffer,
- EFI_STATUS_CODE_DATA_MAX_SIZE,
- Format,
+ Buffer,
+ EFI_STATUS_CODE_DATA_MAX_SIZE,
+ Format,
Marker
);
- } else if (Data != NULL &&
+ } else if (Data != NULL &&
CompareGuid (&Data->Type, &gEfiStatusCodeSpecificDataGuid) &&
(CodeType & EFI_STATUS_CODE_TYPE_MASK) == EFI_DEBUG_CODE) {
//
@@ -98,19 +98,19 @@ LibReportStatusCode ( // Print ERROR information into output buffer.
//
CharCount = AsciiSPrint (
- Buffer,
- EFI_STATUS_CODE_DATA_MAX_SIZE,
- "ERROR: C%x:V%x I%x",
- CodeType,
- Value,
+ Buffer,
+ EFI_STATUS_CODE_DATA_MAX_SIZE,
+ "ERROR: C%x:V%x I%x",
+ CodeType,
+ Value,
Instance
);
//
- // Make sure we don't try to print values that weren't
+ // Make sure we don't try to print values that weren't
// intended to be printed, especially NULL GUID pointers.
//
-
+
if (CallerId != NULL) {
CharCount += AsciiSPrint (
&Buffer[CharCount - 1],
@@ -136,19 +136,19 @@ LibReportStatusCode ( );
} else if ((CodeType & EFI_STATUS_CODE_TYPE_MASK) == EFI_PROGRESS_CODE) {
CharCount = AsciiSPrint (
- Buffer,
- EFI_STATUS_CODE_DATA_MAX_SIZE,
- "PROGRESS CODE: V%x I%x\n\r",
- Value,
+ Buffer,
+ EFI_STATUS_CODE_DATA_MAX_SIZE,
+ "PROGRESS CODE: V%x I%x\n\r",
+ Value,
Instance
);
} else {
CharCount = AsciiSPrint (
- Buffer,
- EFI_STATUS_CODE_DATA_MAX_SIZE,
- "Undefined: C%x:V%x I%x\n\r",
- CodeType,
- Value,
+ Buffer,
+ EFI_STATUS_CODE_DATA_MAX_SIZE,
+ "Undefined: C%x:V%x I%x\n\r",
+ CodeType,
+ Value,
Instance
);
}
@@ -165,7 +165,7 @@ LibReportStatusCode ( gBS->LocateProtocol (&gEfiSerialIoProtocolGuid, NULL, (VOID **) &mSerialIoProtocol);
}
- if (mSerialIoProtocol == NULL) {
+ if (mSerialIoProtocol == NULL) {
mSerialIoProtocol->Write (
mSerialIoProtocol,
&CharCount,
diff --git a/EmbeddedPkg/Library/HalRuntimeServicesExampleLib/Reset.c b/EmbeddedPkg/Library/HalRuntimeServicesExampleLib/Reset.c index 65a0a166b3..c6ae1f0c32 100644 --- a/EmbeddedPkg/Library/HalRuntimeServicesExampleLib/Reset.c +++ b/EmbeddedPkg/Library/HalRuntimeServicesExampleLib/Reset.c @@ -3,7 +3,7 @@ Copyright (c) 2007, Intel Corporation. All rights reserved.<BR>
Portions copyright (c) 2008 - 2009, Apple Inc. All rights reserved.<BR>
-
+
This program and the accompanying materials
are licensed and made available under the terms and conditions of the BSD License
which accompanies this distribution. The full text of the license may be found at
@@ -14,7 +14,7 @@ **/
-
+
VOID
diff --git a/EmbeddedPkg/Library/HalRuntimeServicesExampleLib/Rtc.c b/EmbeddedPkg/Library/HalRuntimeServicesExampleLib/Rtc.c index 59c8cd16b0..6fd6516bf2 100644 --- a/EmbeddedPkg/Library/HalRuntimeServicesExampleLib/Rtc.c +++ b/EmbeddedPkg/Library/HalRuntimeServicesExampleLib/Rtc.c @@ -14,7 +14,7 @@ **/
-
+
typedef struct {
@@ -255,8 +255,8 @@ RtcTimeFieldsValid ( Routine Description:
Arguments:
-
- Returns:
+
+ Returns:
--*/
// TODO: Time - add argument and description to function comment
// TODO: EFI_INVALID_PARAMETER - add return value to function comment
diff --git a/EmbeddedPkg/Library/HalRuntimeServicesExampleLib/Variable.c b/EmbeddedPkg/Library/HalRuntimeServicesExampleLib/Variable.c index 4d06666887..0c1b76a4bb 100644 --- a/EmbeddedPkg/Library/HalRuntimeServicesExampleLib/Variable.c +++ b/EmbeddedPkg/Library/HalRuntimeServicesExampleLib/Variable.c @@ -1,11 +1,11 @@ /** @file
Variable services implemented from system memory
- There is just a single runtime memory buffer that contans all the data.
+ There is just a single runtime memory buffer that contans all the data.
Copyright (c) 2007, Intel Corporation. All rights reserved.<BR>
Portions copyright (c) 2008 - 2009, Apple Inc. All rights reserved.<BR>
-
+
This program and the accompanying materials
are licensed and made available under the terms and conditions of the BSD License
which accompanies this distribution. The full text of the license may be found at
@@ -50,7 +50,7 @@ AddEntry ( EFI_TPL CurrentTpl;
- SizeOfString = StrSize (VariableName);
+ SizeOfString = StrSize (VariableName);
Size = SizeOfString + sizeof (VARIABLE_ARRAY_ENTRY) + DataSize;
if ((VARIABLE_ARRAY_ENTRY *)(((UINT8 *)mVariableArrayNextFree) + Size) > mVariableArrayEnd) {
// ran out of space
@@ -70,7 +70,7 @@ AddEntry ( mVariableArrayNextFree = (VARIABLE_ARRAY_ENTRY *)(((UINT8 *)mVariableArrayNextFree) + SizeOfString);
CopyMem (mVariableArrayNextFree, Data, DataSize);
mVariableArrayNextFree = (VARIABLE_ARRAY_ENTRY *)(((UINT8 *)mVariableArrayNextFree) + DataSize);
-
+
if (!EfiAtRuntime ()) {
// Exit Critical section
gBS->RestoreTPL (CurrentTpl);
@@ -78,7 +78,7 @@ AddEntry ( return Entry;
}
-
+
VOID
DeleteEntry (
IN VARIABLE_ARRAY_ENTRY *Entry
@@ -199,22 +199,22 @@ LibGetNextVariableName ( if (Entry == NULL) {
return EFI_NOT_FOUND;
}
-
+
// If we are at runtime skip variables that do not have the Runitme attribute set.
Done = (EfiAtRuntime () && ((Entry->Attribute & EFI_VARIABLE_RUNTIME_ACCESS) == 0)) ? FALSE : TRUE;
- }
+ }
StringSize = StrSize ((CHAR16 *)(Entry + 1));
Entry = (VARIABLE_ARRAY_ENTRY *)(((UINT8 *)Entry) + (StringSize + sizeof (VARIABLE_ARRAY_ENTRY) + Entry->DataSize));
if (Entry >= mVariableArrayEnd) {
return EFI_NOT_FOUND;
}
-
+
if (*VariableNameSize < StringSize) {
*VariableNameSize = StringSize;
return EFI_BUFFER_TOO_SMALL;
}
-
+
*VariableNameSize = StringSize;
CopyMem (VariableName, (CHAR16 *)(Entry + 1), StringSize);
CopyMem (VendorGuid, &Entry->VendorGuid, sizeof (EFI_GUID));
@@ -298,9 +298,9 @@ LibVariableInitialize (VOID) ASSERT (mVariableArray != NULL);
mVariableArrayEnd = (VARIABLE_ARRAY_ENTRY *)(((UINT8 *)mVariableArray) + Size);
-
+
mMaximumVariableStorageSize = Size - sizeof (VARIABLE_ARRAY_ENTRY);
mRemainingVariableStorageSize = mMaximumVariableStorageSize;
mMaximumVariableSize = mMaximumVariableStorageSize;
}
-
+
diff --git a/EmbeddedPkg/Library/LzmaHobCustomDecompressLib/LzmaHobCustomDecompressLib.c b/EmbeddedPkg/Library/LzmaHobCustomDecompressLib/LzmaHobCustomDecompressLib.c index 8cd483dede..2a91a98ba8 100644 --- a/EmbeddedPkg/Library/LzmaHobCustomDecompressLib/LzmaHobCustomDecompressLib.c +++ b/EmbeddedPkg/Library/LzmaHobCustomDecompressLib/LzmaHobCustomDecompressLib.c @@ -34,17 +34,17 @@ LzmaDecompressLibConstructor ( )
{
EXTRACT_SECTION_HOB *Hob;
-
+
Hob = GetFirstGuidHob (&gLzmaCustomDecompressGuid);
if (Hob == NULL) {
return EFI_NOT_FOUND;
}
-
- // Locate Guided Hob
+
+ // Locate Guided Hob
return ExtractGuidedSectionRegisterHandlers (
&gLzmaCustomDecompressGuid,
Hob->Data.SectionGetInfo,
Hob->Data.SectionExtraction
- );
+ );
}
diff --git a/EmbeddedPkg/Library/LzmaHobCustomDecompressLib/LzmaHobCustomDecompressLib.inf b/EmbeddedPkg/Library/LzmaHobCustomDecompressLib/LzmaHobCustomDecompressLib.inf index d88fb377f3..1ec967b016 100644 --- a/EmbeddedPkg/Library/LzmaHobCustomDecompressLib/LzmaHobCustomDecompressLib.inf +++ b/EmbeddedPkg/Library/LzmaHobCustomDecompressLib/LzmaHobCustomDecompressLib.inf @@ -2,7 +2,7 @@ # LzmaCustomDecompressLib produces LZMA custom decompression algorithm.
#
# It is based on the LZMA SDK 4.65.
-# LZMA SDK 4.65 was placed in the public domain on 2009-02-03.
+# LZMA SDK 4.65 was placed in the public domain on 2009-02-03.
# It was released on the http://www.7-zip.org/sdk.html website.
#
# Copyright (c) 2009, Intel Corporation. All rights reserved.<BR>
diff --git a/EmbeddedPkg/Library/NullDmaLib/NullDmaLib.c b/EmbeddedPkg/Library/NullDmaLib/NullDmaLib.c index 74386dfa28..a0bb57541d 100755 --- a/EmbeddedPkg/Library/NullDmaLib/NullDmaLib.c +++ b/EmbeddedPkg/Library/NullDmaLib/NullDmaLib.c @@ -2,7 +2,7 @@ Generic ARM implementation of DmaLib.h
Copyright (c) 2008 - 2010, Apple Inc. All rights reserved.<BR>
-
+
This program and the accompanying materials
are licensed and made available under the terms and conditions of the BSD License
which accompanies this distribution. The full text of the license may be found at
@@ -20,25 +20,25 @@ -/**
+/**
Provides the DMA controller-specific addresses needed to access system memory.
-
+
Operation is relative to the DMA bus master.
-
+
@param Operation Indicates if the bus master is going to read or write to system memory.
@param HostAddress The system memory address to map to the DMA controller.
@param NumberOfBytes On input the number of bytes to map. On output the number of bytes
- that were mapped.
+ that were mapped.
@param DeviceAddress The resulting map address for the bus master controller to use to
- access the hosts HostAddress.
+ access the hosts HostAddress.
@param Mapping A resulting value to pass to Unmap().
-
+
@retval EFI_SUCCESS The range was mapped for the returned NumberOfBytes.
- @retval EFI_UNSUPPORTED The HostAddress cannot be mapped as a common buffer.
+ @retval EFI_UNSUPPORTED The HostAddress cannot be mapped as a common buffer.
@retval EFI_INVALID_PARAMETER One or more parameters are invalid.
@retval EFI_OUT_OF_RESOURCES The request could not be completed due to a lack of resources.
@retval EFI_DEVICE_ERROR The system hardware could not map the requested address.
-
+
**/
EFI_STATUS
EFIAPI
@@ -56,15 +56,15 @@ DmaMap ( }
-/**
+/**
Completes the DmaMapBusMasterRead(), DmaMapBusMasterWrite(), or DmaMapBusMasterCommonBuffer()
operation and releases any corresponding resources.
-
+
@param Mapping The mapping value returned from DmaMap*().
-
+
@retval EFI_SUCCESS The range was unmapped.
@retval EFI_DEVICE_ERROR The data was not committed to the target system memory.
-
+
**/
EFI_STATUS
EFIAPI
@@ -75,22 +75,22 @@ DmaUnmap ( return EFI_SUCCESS;
}
-/**
+/**
Allocates pages that are suitable for an DmaMap() of type MapOperationBusMasterCommonBuffer.
- mapping.
-
+ mapping.
+
@param MemoryType The type of memory to allocate, EfiBootServicesData or
- EfiRuntimeServicesData.
- @param Pages The number of pages to allocate.
+ EfiRuntimeServicesData.
+ @param Pages The number of pages to allocate.
@param HostAddress A pointer to store the base system memory address of the
- allocated range.
+ allocated range.
@retval EFI_SUCCESS The requested memory pages were allocated.
@retval EFI_UNSUPPORTED Attributes is unsupported. The only legal attribute bits are
- MEMORY_WRITE_COMBINE and MEMORY_CACHED.
+ MEMORY_WRITE_COMBINE and MEMORY_CACHED.
@retval EFI_INVALID_PARAMETER One or more parameters are invalid.
- @retval EFI_OUT_OF_RESOURCES The memory pages could not be allocated.
-
+ @retval EFI_OUT_OF_RESOURCES The memory pages could not be allocated.
+
**/
EFI_STATUS
EFIAPI
@@ -121,16 +121,16 @@ DmaAllocateBuffer ( }
-/**
+/**
Frees memory that was allocated with DmaAllocateBuffer().
-
- @param Pages The number of pages to free.
- @param HostAddress The base system memory address of the allocated range.
-
+
+ @param Pages The number of pages to free.
+ @param HostAddress The base system memory address of the allocated range.
+
@retval EFI_SUCCESS The requested memory pages were freed.
@retval EFI_INVALID_PARAMETER The memory range specified by HostAddress and Pages
was not allocated with DmaAllocateBuffer().
-
+
**/
EFI_STATUS
EFIAPI
@@ -141,8 +141,8 @@ DmaFreeBuffer ( {
if (HostAddress == NULL) {
return EFI_INVALID_PARAMETER;
- }
-
+ }
+
FreePages (HostAddress, Pages);
return EFI_SUCCESS;
}
diff --git a/EmbeddedPkg/Library/NullDmaLib/NullDmaLib.inf b/EmbeddedPkg/Library/NullDmaLib/NullDmaLib.inf index 8e8ccaee38..38261d5ede 100755 --- a/EmbeddedPkg/Library/NullDmaLib/NullDmaLib.inf +++ b/EmbeddedPkg/Library/NullDmaLib/NullDmaLib.inf @@ -1,14 +1,14 @@ #/** @file
-#
+#
# Copyright (c) 2008 - 2010, Apple Inc. All rights reserved.<BR>
# This program and the accompanying materials
# are licensed and made available under the terms and conditions of the BSD License
# which accompanies this distribution. The full text of the license may be found at
# http://opensource.org/licenses/bsd-license.php
-#
+#
# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
-#
+#
#**/
[Defines]
@@ -17,7 +17,7 @@ FILE_GUID = 0F2A0816-D319-4ee7-A6B8-D58524E4428F
MODULE_TYPE = BASE
VERSION_STRING = 1.0
- LIBRARY_CLASS = DmaLib
+ LIBRARY_CLASS = DmaLib
[Sources.common]
NullDmaLib.c
@@ -29,13 +29,13 @@ [LibraryClasses]
DebugLib
MemoryAllocationLib
-
-
+
+
[Protocols]
-
+
[Guids]
-
+
[Pcd]
[Depex]
- TRUE
\ No newline at end of file + TRUE
diff --git a/EmbeddedPkg/Library/PrePiExtractGuidedSectionLib/PrePiExtractGuidedSectionLib.c b/EmbeddedPkg/Library/PrePiExtractGuidedSectionLib/PrePiExtractGuidedSectionLib.c index 38de686a44..cee15c4be2 100644 --- a/EmbeddedPkg/Library/PrePiExtractGuidedSectionLib/PrePiExtractGuidedSectionLib.c +++ b/EmbeddedPkg/Library/PrePiExtractGuidedSectionLib/PrePiExtractGuidedSectionLib.c @@ -1,7 +1,7 @@ /** @file
Copyright (c) 2008 - 2009, Apple Inc. All rights reserved.<BR>
-
+
This program and the accompanying materials
are licensed and made available under the terms and conditions of the BSD License
which accompanies this distribution. The full text of the license may be found at
@@ -38,7 +38,7 @@ GetSavedData ( GuidHob = GetFirstGuidHob(&SavedDataGuid);
GuidHob++;
-
+
return (PRE_PI_EXTRACT_GUIDED_SECTION_DATA *)GuidHob;
}
@@ -78,21 +78,21 @@ ExtractGuidedSectionRegisterHandlers ( SavedData->ExtractGetInfoHandlerTable [Index] = GetInfoHandler;
return RETURN_SUCCESS;
}
-
+
//
// Check the global table is enough to contain new Handler.
//
if (SavedData->NumberOfExtractHandler >= PcdGet32 (PcdMaximumGuidedExtractHandler)) {
return RETURN_OUT_OF_RESOURCES;
}
-
+
//
// Register new Handler and guid value.
//
CopyGuid (&SavedData->ExtractHandlerGuidTable [SavedData->NumberOfExtractHandler], SectionGuid);
SavedData->ExtractDecodeHandlerTable [SavedData->NumberOfExtractHandler] = DecodeHandler;
SavedData->ExtractGetInfoHandlerTable [SavedData->NumberOfExtractHandler++] = GetInfoHandler;
-
+
return RETURN_SUCCESS;
}
@@ -105,9 +105,9 @@ ExtractGuidedSectionGetGuidList ( PRE_PI_EXTRACT_GUIDED_SECTION_DATA *SavedData;
ASSERT(ExtractHandlerGuidTable != NULL);
-
+
SavedData = GetSavedData();
-
+
*ExtractHandlerGuidTable = SavedData->ExtractHandlerGuidTable;
return SavedData->NumberOfExtractHandler;
}
@@ -118,20 +118,20 @@ ExtractGuidedSectionGetInfo ( IN CONST VOID *InputSection,
OUT UINT32 *OutputBufferSize,
OUT UINT32 *ScratchBufferSize,
- OUT UINT16 *SectionAttribute
+ OUT UINT16 *SectionAttribute
)
{
PRE_PI_EXTRACT_GUIDED_SECTION_DATA *SavedData;
UINT32 Index;
-
+
if (InputSection == NULL) {
return RETURN_INVALID_PARAMETER;
}
-
+
ASSERT (OutputBufferSize != NULL);
ASSERT (ScratchBufferSize != NULL);
ASSERT (SectionAttribute != NULL);
-
+
SavedData = GetSavedData();
//
@@ -144,7 +144,7 @@ ExtractGuidedSectionGetInfo ( }
//
- // Not found, the input guided section is not supported.
+ // Not found, the input guided section is not supported.
//
if (Index == SavedData->NumberOfExtractHandler) {
return RETURN_INVALID_PARAMETER;
@@ -167,16 +167,16 @@ ExtractGuidedSectionDecode ( IN CONST VOID *InputSection,
OUT VOID **OutputBuffer,
OUT VOID *ScratchBuffer, OPTIONAL
- OUT UINT32 *AuthenticationStatus
+ OUT UINT32 *AuthenticationStatus
)
{
PRE_PI_EXTRACT_GUIDED_SECTION_DATA *SavedData;
UINT32 Index;
-
+
if (InputSection == NULL) {
return RETURN_INVALID_PARAMETER;
}
-
+
ASSERT (OutputBuffer != NULL);
ASSERT (AuthenticationStatus != NULL);
@@ -192,7 +192,7 @@ ExtractGuidedSectionDecode ( }
//
- // Not found, the input guided section is not supported.
+ // Not found, the input guided section is not supported.
//
if (Index == SavedData->NumberOfExtractHandler) {
return RETURN_INVALID_PARAMETER;
@@ -225,7 +225,7 @@ ExtractGuidedSectionLibConstructor ( if (SavedData.ExtractHandlerGuidTable == NULL) {
return RETURN_OUT_OF_RESOURCES;
}
-
+
SavedData.ExtractDecodeHandlerTable = (EXTRACT_GUIDED_SECTION_DECODE_HANDLER *)AllocatePool(PcdGet32(PcdMaximumGuidedExtractHandler) * sizeof(EXTRACT_GUIDED_SECTION_DECODE_HANDLER));
if (SavedData.ExtractDecodeHandlerTable == NULL) {
return RETURN_OUT_OF_RESOURCES;
@@ -235,13 +235,13 @@ ExtractGuidedSectionLibConstructor ( if (SavedData.ExtractGetInfoHandlerTable == NULL) {
return RETURN_OUT_OF_RESOURCES;
}
-
+
//
// the initialized number is Zero.
//
SavedData.NumberOfExtractHandler = 0;
-
+
BuildGuidDataHob(&HobGuid, &SavedData, sizeof(SavedData));
-
+
return RETURN_SUCCESS;
}
diff --git a/EmbeddedPkg/Library/PrePiExtractGuidedSectionLib/PrePiExtractGuidedSectionLib.inf b/EmbeddedPkg/Library/PrePiExtractGuidedSectionLib/PrePiExtractGuidedSectionLib.inf index 6389f70a3d..ba74c26268 100644 --- a/EmbeddedPkg/Library/PrePiExtractGuidedSectionLib/PrePiExtractGuidedSectionLib.inf +++ b/EmbeddedPkg/Library/PrePiExtractGuidedSectionLib/PrePiExtractGuidedSectionLib.inf @@ -1,14 +1,14 @@ #/** @file
-#
+#
# Copyright (c) 2008 - 2010, Apple Inc. All rights reserved.<BR>
# This program and the accompanying materials
# are licensed and made available under the terms and conditions of the BSD License
# which accompanies this distribution. The full text of the license may be found at
# http://opensource.org/licenses/bsd-license.php
-#
+#
# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
-#
+#
#**/
[Defines]
@@ -33,4 +33,4 @@ DebugLib
[FixedPcd.common]
- gEfiMdePkgTokenSpaceGuid.PcdMaximumGuidedExtractHandler
+ gEfiMdePkgTokenSpaceGuid.PcdMaximumGuidedExtractHandler
diff --git a/EmbeddedPkg/Library/PrePiHobLib/Hob.c b/EmbeddedPkg/Library/PrePiHobLib/Hob.c index 320dddfc25..aff532259e 100644 --- a/EmbeddedPkg/Library/PrePiHobLib/Hob.c +++ b/EmbeddedPkg/Library/PrePiHobLib/Hob.c @@ -1,7 +1,7 @@ /** @file
Copyright (c) 2010, Apple Inc. All rights reserved.<BR>
-
+
This program and the accompanying materials
are licensed and made available under the terms and conditions of the BSD License
which accompanies this distribution. The full text of the license may be found at
@@ -193,7 +193,7 @@ CreateHobList ( SetHobList (Hob);
BuildCpuHob (PcdGet8 (PcdPrePiCpuMemorySize), PcdGet8 (PcdPrePiCpuIoSize));
-
+
Attributes =(
EFI_RESOURCE_ATTRIBUTE_PRESENT |
EFI_RESOURCE_ATTRIBUTE_INITIALIZED |
@@ -209,25 +209,25 @@ CreateHobList ( BuildStackHob ((EFI_PHYSICAL_ADDRESS)(UINTN)StackBase, ((UINTN)MemoryBegin + MemoryLength) - (UINTN)StackBase);
if (FeaturePcdGet (PcdPrePiProduceMemoryTypeInformationHob)) {
- // Optional feature that helps prevent EFI memory map fragmentation.
+ // Optional feature that helps prevent EFI memory map fragmentation.
BuildMemoryTypeInformationHob ();
}
-}
-
+}
+
VOID
EFIAPI
-BuildFvHobs (
+BuildFvHobs (
IN EFI_PHYSICAL_ADDRESS PhysicalStart,
IN UINT64 NumberOfBytes,
IN EFI_RESOURCE_ATTRIBUTE_TYPE *ResourceAttribute
- )
+ )
{
EFI_RESOURCE_ATTRIBUTE_TYPE Resource;
-
+
BuildFvHob (PhysicalStart, NumberOfBytes);
-
+
if (ResourceAttribute == NULL) {
Resource = (EFI_RESOURCE_ATTRIBUTE_PRESENT |
EFI_RESOURCE_ATTRIBUTE_INITIALIZED |
@@ -236,14 +236,14 @@ BuildFvHobs ( } else {
Resource = *ResourceAttribute;
}
-
+
BuildResourceDescriptorHob (EFI_RESOURCE_FIRMWARE_DEVICE, Resource, PhysicalStart, NumberOfBytes);
}
/**
Returns the next instance of a HOB type from the starting HOB.
- This function searches the first instance of a HOB type from the starting HOB pointer.
+ This function searches the first instance of a HOB type from the starting HOB pointer.
If there does not exist such HOB type from the starting HOB pointer, it will return NULL.
In contrast with macro GET_NEXT_HOB(), this function does not skip the starting HOB pointer
unconditionally: it returns HobStart back if HobStart itself meets the requirement;
@@ -266,7 +266,7 @@ GetNextHob ( EFI_PEI_HOB_POINTERS Hob;
ASSERT (HobStart != NULL);
-
+
Hob.Raw = (UINT8 *) HobStart;
//
// Parse the HOB list until end of list or matching type is found.
@@ -279,14 +279,14 @@ GetNextHob ( }
return NULL;
}
-
-
+
+
/**
Returns the first instance of a HOB type among the whole HOB list.
- This function searches the first instance of a HOB type among the whole HOB list.
- If there does not exist such HOB type in the HOB list, it will return NULL.
+ This function searches the first instance of a HOB type among the whole HOB list.
+ If there does not exist such HOB type in the HOB list, it will return NULL.
@param Type The HOB type to return.
@@ -307,10 +307,10 @@ GetFirstHob ( /**
- This function searches the first instance of a HOB from the starting HOB pointer.
- Such HOB should satisfy two conditions:
- its HOB type is EFI_HOB_TYPE_GUID_EXTENSION and its GUID Name equals to the input Guid.
- If there does not exist such HOB from the starting HOB pointer, it will return NULL.
+ This function searches the first instance of a HOB from the starting HOB pointer.
+ Such HOB should satisfy two conditions:
+ its HOB type is EFI_HOB_TYPE_GUID_EXTENSION and its GUID Name equals to the input Guid.
+ If there does not exist such HOB from the starting HOB pointer, it will return NULL.
Caller is required to apply GET_GUID_HOB_DATA () and GET_GUID_HOB_DATA_SIZE ()
to extract the data section and its size info respectively.
In contrast with macro GET_NEXT_HOB(), this function does not skip the starting HOB pointer
@@ -345,7 +345,7 @@ GetNextGuidHob ( /**
- This function searches the first instance of a HOB among the whole HOB list.
+ This function searches the first instance of a HOB among the whole HOB list.
Such HOB should satisfy two conditions:
its HOB type is EFI_HOB_TYPE_GUID_EXTENSION and its GUID Name equals to the input Guid.
If there does not exist such HOB from the starting HOB pointer, it will return NULL.
@@ -374,7 +374,7 @@ GetFirstGuidHob ( /**
Get the Boot Mode from the HOB list.
- This function returns the system boot mode information from the
+ This function returns the system boot mode information from the
PHIT HOB in HOB list.
@param VOID
@@ -398,7 +398,7 @@ GetBootMode ( /**
Get the Boot Mode from the HOB list.
- This function returns the system boot mode information from the
+ This function returns the system boot mode information from the
PHIT HOB in HOB list.
@param VOID
@@ -459,7 +459,7 @@ BuildModuleHob ( // Zero the reserved space to match HOB spec
//
ZeroMem (Hob->MemoryAllocationHeader.Reserved, sizeof (Hob->MemoryAllocationHeader.Reserved));
-
+
CopyGuid (&Hob->ModuleName, ModuleName);
Hob->EntryPoint = EntryPoint;
}
@@ -467,8 +467,8 @@ BuildModuleHob ( /**
Builds a GUID HOB with a certain data length.
- This function builds a customized HOB tagged with a GUID for identification
- and returns the start address of GUID HOB data so that caller can fill the customized data.
+ This function builds a customized HOB tagged with a GUID for identification
+ and returns the start address of GUID HOB data so that caller can fill the customized data.
The HOB Header and Name field is already stripped.
It can only be invoked during PEI phase;
for DXE phase, it will ASSERT() since PEI HOB is read-only for DXE phase.
@@ -580,7 +580,7 @@ BuildFvHob ( @param Length The size of the Firmware Volume in bytes.
@param FvName The name of the Firmware Volume.
@param FileName The name of the file.
-
+
**/
VOID
EFIAPI
@@ -655,7 +655,7 @@ BuildCpuHob ( //
// Zero the reserved space to match HOB spec
//
- ZeroMem (Hob->Reserved, sizeof (Hob->Reserved));
+ ZeroMem (Hob->Reserved, sizeof (Hob->Reserved));
}
@@ -762,9 +762,9 @@ BuildMemoryAllocationHob ( ASSERT (((BaseAddress & (EFI_PAGE_SIZE - 1)) == 0) &&
((Length & (EFI_PAGE_SIZE - 1)) == 0));
-
+
Hob = CreateHob (EFI_HOB_TYPE_MEMORY_ALLOCATION, sizeof (EFI_HOB_MEMORY_ALLOCATION));
-
+
ZeroMem (&(Hob->AllocDescriptor.Name), sizeof (EFI_GUID));
Hob->AllocDescriptor.MemoryBaseAddress = BaseAddress;
Hob->AllocDescriptor.MemoryLength = Length;
@@ -786,7 +786,7 @@ BuildExtractSectionHob ( )
{
EXTRACT_SECTION_DATA Data;
-
+
Data.SectionGetInfo = SectionGetInfo;
Data.SectionExtraction = SectionExtraction;
BuildGuidDataHob (Guid, &Data, sizeof (Data));
@@ -809,10 +809,10 @@ BuildPeCoffLoaderHob ( VOID
)
{
- VOID *Ptr;
-
+ VOID *Ptr;
+
Ptr = &gPeCoffProtocol;
- BuildGuidDataHob (&gPeCoffLoaderProtocolGuid, &Ptr, sizeof (VOID *));
+ BuildGuidDataHob (&gPeCoffLoaderProtocolGuid, &Ptr, sizeof (VOID *));
}
// May want to put this into a library so you only need the PCD setings if you are using the feature?
diff --git a/EmbeddedPkg/Library/PrePiHobLib/PrePiHobLib.inf b/EmbeddedPkg/Library/PrePiHobLib/PrePiHobLib.inf index ca73e6a203..19e5a298f3 100644 --- a/EmbeddedPkg/Library/PrePiHobLib/PrePiHobLib.inf +++ b/EmbeddedPkg/Library/PrePiHobLib/PrePiHobLib.inf @@ -19,7 +19,7 @@ FILE_GUID = 1F3A3278-82EB-4C0D-86F1-5BCDA5846CB2
MODULE_TYPE = BASE
VERSION_STRING = 1.0
- LIBRARY_CLASS = HobLib
+ LIBRARY_CLASS = HobLib
#
@@ -40,7 +40,7 @@ BaseMemoryLib
DebugLib
PrePiHobListPointerLib
-
+
[Guids]
gEfiHobMemoryAllocModuleGuid
gEfiHobMemoryAllocStackGuid
diff --git a/EmbeddedPkg/Library/PrePiHobListPointerLib/PrePiHobListPointer.c b/EmbeddedPkg/Library/PrePiHobListPointerLib/PrePiHobListPointer.c index bf4f80f4e4..9065b1132f 100644 --- a/EmbeddedPkg/Library/PrePiHobListPointerLib/PrePiHobListPointer.c +++ b/EmbeddedPkg/Library/PrePiHobListPointerLib/PrePiHobListPointer.c @@ -1,14 +1,14 @@ /** @file
*
* Copyright (c) 2011, ARM Limited. All rights reserved.
-*
-* This program and the accompanying materials
-* are licensed and made available under the terms and conditions of the BSD License
-* which accompanies this distribution. The full text of the license may be found at
-* http://opensource.org/licenses/bsd-license.php
*
-* THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
-* WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
+* This program and the accompanying materials
+* are licensed and made available under the terms and conditions of the BSD License
+* which accompanies this distribution. The full text of the license may be found at
+* http://opensource.org/licenses/bsd-license.php
+*
+* THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
+* WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
*
**/
@@ -52,7 +52,7 @@ PrePeiGetHobList ( Updates the pointer to the HOB list.
@param HobList Hob list pointer to store
-
+
**/
EFI_STATUS
EFIAPI
@@ -61,7 +61,7 @@ PrePeiSetHobList ( )
{
gHobList = HobList;
-
+
//
// If this code is running from ROM this could fail
//
diff --git a/EmbeddedPkg/Library/PrePiHobListPointerLib/PrePiHobListPointerLib.inf b/EmbeddedPkg/Library/PrePiHobListPointerLib/PrePiHobListPointerLib.inf index fea8f43687..bfd3c209a1 100644 --- a/EmbeddedPkg/Library/PrePiHobListPointerLib/PrePiHobListPointerLib.inf +++ b/EmbeddedPkg/Library/PrePiHobListPointerLib/PrePiHobListPointerLib.inf @@ -1,14 +1,14 @@ #/** @file
#
# Copyright (c) 2011, ARM Limited. All rights reserved.
-#
-# This program and the accompanying materials
-# are licensed and made available under the terms and conditions of the BSD License
-# which accompanies this distribution. The full text of the license may be found at
-# http://opensource.org/licenses/bsd-license.php
#
-# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
-# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
+# This program and the accompanying materials
+# are licensed and made available under the terms and conditions of the BSD License
+# which accompanies this distribution. The full text of the license may be found at
+# http://opensource.org/licenses/bsd-license.php
+#
+# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
+# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
#
#**/
@@ -33,7 +33,6 @@ [LibraryClasses]
#DebugLib
-
+
[FixedPcd.common]
gEmbeddedTokenSpaceGuid.PcdPrePiHobBase
-
\ No newline at end of file diff --git a/EmbeddedPkg/Library/PrePiLib/FwVol.c b/EmbeddedPkg/Library/PrePiLib/FwVol.c index 0dec29efe9..34ae0f59ac 100644 --- a/EmbeddedPkg/Library/PrePiLib/FwVol.c +++ b/EmbeddedPkg/Library/PrePiLib/FwVol.c @@ -1,10 +1,10 @@ /** @file
Implementation of the 6 PEI Ffs (FV) APIs in library form.
-
+
This code only knows about a FV if it has a EFI_HOB_TYPE_FV entry in the HOB list
Copyright (c) 2008 - 2009, Apple Inc. All rights reserved.<BR>
-
+
This program and the accompanying materials
are licensed and made available under the terms and conditions of the BSD License
which accompanies this distribution. The full text of the license may be found at
@@ -25,11 +25,11 @@ /**
Returns the highest bit set of the State field
-
+
@param ErasePolarity Erase Polarity as defined by EFI_FVB2_ERASE_POLARITY
in the Attributes field.
@param FfsHeader Pointer to FFS File Header
-
+
@retval the highest bit in the State field
@@ -56,15 +56,15 @@ GetFileState( }
return HighestBit;
-}
+}
/**
Calculates the checksum of the header of a file.
The header is a zero byte checksum, so zero means header is good
-
+
@param FfsHeader Pointer to FFS File Header
-
+
@retval Checksum of the header
**/
@@ -77,7 +77,7 @@ CalculateHeaderChecksum ( UINT8 *Ptr;
UINTN Index;
UINT8 Sum;
-
+
Sum = 0;
Ptr = (UINT8 *)FileHeader;
@@ -91,9 +91,9 @@ CalculateHeaderChecksum ( for (; Index < sizeof(EFI_FFS_FILE_HEADER); Index++) {
Sum = (UINT8)(Sum + Ptr[Index]);
}
-
+
//
- // State field (since this indicates the different state of file).
+ // State field (since this indicates the different state of file).
//
Sum = (UINT8)(Sum - FileHeader->State);
//
@@ -107,10 +107,10 @@ CalculateHeaderChecksum ( /**
Given a FileHandle return the VolumeHandle
-
+
@param FileHandle File handle to look up
@param VolumeHandle Match for FileHandle
-
+
@retval TRUE VolumeHandle is valid
**/
@@ -129,7 +129,7 @@ FileHandleToVolume ( if (Hob.Raw == NULL) {
return FALSE;
}
-
+
do {
Hob.Raw = GetNextHob (EFI_HOB_TYPE_FV, Hob.Raw);
if (Hob.Raw != NULL) {
@@ -143,7 +143,7 @@ FileHandleToVolume ( Hob.Raw = GetNextHob (EFI_HOB_TYPE_FV, GET_NEXT_HOB (Hob));
}
} while (Hob.Raw != NULL);
-
+
return FALSE;
}
@@ -153,10 +153,10 @@ FileHandleToVolume ( Given the input file pointer, search for the next matching file in the
FFS volume as defined by SearchType. The search starts from FileHeader inside
the Firmware Volume defined by FwVolHeader.
-
+
@param FileHandle File handle to look up
@param VolumeHandle Match for FileHandle
-
+
**/
EFI_STATUS
@@ -208,13 +208,13 @@ FindFileEx ( FileOccupiedSize = GET_OCCUPIED_SIZE (FileLength, 8);
FfsFileHeader = (EFI_FFS_FILE_HEADER *)((UINT8 *)*FileHeader + FileOccupiedSize);
}
-
+
FileOffset = (UINT32) ((UINT8 *)FfsFileHeader - (UINT8 *)FwVolHeader);
ASSERT (FileOffset <= 0xFFFFFFFF);
while (FileOffset < (FvLength - sizeof (EFI_FFS_FILE_HEADER))) {
//
- // Get FileState which is the highest bit of the State
+ // Get FileState which is the highest bit of the State
//
FileState = GetFileState (ErasePolarity, FfsFileHeader);
@@ -224,7 +224,7 @@ FindFileEx ( FileOffset += sizeof(EFI_FFS_FILE_HEADER);
FfsFileHeader = (EFI_FFS_FILE_HEADER *)((UINT8 *)FfsFileHeader + sizeof(EFI_FFS_FILE_HEADER));
break;
-
+
case EFI_FILE_DATA_VALID:
case EFI_FILE_MARKED_FOR_UPDATE:
if (CalculateHeaderChecksum (FfsFileHeader) != 0) {
@@ -241,16 +241,16 @@ FindFileEx ( *FileHeader = FfsFileHeader;
return EFI_SUCCESS;
}
- } else if (((SearchType == FfsFileHeader->Type) || (SearchType == EFI_FV_FILETYPE_ALL)) &&
- (FfsFileHeader->Type != EFI_FV_FILETYPE_FFS_PAD)) {
+ } else if (((SearchType == FfsFileHeader->Type) || (SearchType == EFI_FV_FILETYPE_ALL)) &&
+ (FfsFileHeader->Type != EFI_FV_FILETYPE_FFS_PAD)) {
*FileHeader = FfsFileHeader;
return EFI_SUCCESS;
}
- FileOffset += FileOccupiedSize;
+ FileOffset += FileOccupiedSize;
FfsFileHeader = (EFI_FFS_FILE_HEADER *)((UINT8 *)FfsFileHeader + FileOccupiedSize);
break;
-
+
case EFI_FILE_DELETED:
FileLength = *(UINT32 *)(FfsFileHeader->Size) & 0x00FFFFFF;
FileOccupiedSize = GET_OCCUPIED_SIZE(FileLength, 8);
@@ -261,24 +261,24 @@ FindFileEx ( default:
*FileHeader = NULL;
return EFI_NOT_FOUND;
- }
+ }
}
-
+
*FileHeader = NULL;
- return EFI_NOT_FOUND;
+ return EFI_NOT_FOUND;
}
/**
Go through the file to search SectionType section,
- when meeting an encapsuled section.
-
+ when meeting an encapsuled section.
+
@param SectionType - Filter to find only section of this type.
@param Section - From where to search.
@param SectionSize - The file size to search.
@param OutputBuffer - Pointer to the section to search.
-
+
@retval EFI_SUCCESS
**/
EFI_STATUS
@@ -310,11 +310,11 @@ FfsProcessSection ( return EFI_SUCCESS;
} else if ((Section->Type == EFI_SECTION_COMPRESSION) || (Section->Type == EFI_SECTION_GUID_DEFINED)) {
-
+
if (Section->Type == EFI_SECTION_COMPRESSION) {
CompressionSection = (EFI_COMPRESSION_SECTION *) Section;
SectionLength = *(UINT32 *)Section->Size & 0x00FFFFFF;
-
+
if (CompressionSection->CompressionType != EFI_STANDARD_COMPRESSION) {
return EFI_UNSUPPORTED;
}
@@ -333,7 +333,7 @@ FfsProcessSection ( &SectionAttribute
);
}
-
+
if (EFI_ERROR (Status)) {
//
// GetInfo failed
@@ -349,7 +349,7 @@ FfsProcessSection ( return EFI_OUT_OF_RESOURCES;
}
//
- // Allocate destination buffer, extra one page for adjustment
+ // Allocate destination buffer, extra one page for adjustment
//
DstBuffer = (VOID *)(UINTN)AllocatePages (EFI_SIZE_TO_PAGES (DstBufferSize) + 1);
if (DstBuffer == NULL) {
@@ -377,7 +377,7 @@ FfsProcessSection ( &AuthenticationStatus
);
}
-
+
if (EFI_ERROR (Status)) {
//
// Decompress failed
@@ -386,16 +386,16 @@ FfsProcessSection ( return EFI_NOT_FOUND;
} else {
return FfsProcessSection (
- SectionType,
- DstBuffer,
- DstBufferSize,
- OutputBuffer
+ SectionType,
+ DstBuffer,
+ DstBufferSize,
+ OutputBuffer
);
- }
+ }
}
//
- // Size is 24 bits wide so mask upper 8 bits.
+ // Size is 24 bits wide so mask upper 8 bits.
// SectionLength is adjusted it is 4 byte aligned.
// Go to the next section
//
@@ -405,7 +405,7 @@ FfsProcessSection ( ParsedLength += SectionLength;
Section = (EFI_COMMON_SECTION_HEADER *)((UINT8 *)Section + SectionLength);
}
-
+
return EFI_NOT_FOUND;
}
@@ -438,7 +438,7 @@ FfsFindSectionData ( FfsFileHeader = (EFI_FFS_FILE_HEADER *)(FileHandle);
//
- // Size is 24 bits wide so mask upper 8 bits.
+ // Size is 24 bits wide so mask upper 8 bits.
// Does not include FfsFileHeader header size
// FileSize is adjusted to FileOccupiedSize as it is 8 byte aligned.
//
@@ -447,9 +447,9 @@ FfsFindSectionData ( FileSize -= sizeof (EFI_FFS_FILE_HEADER);
return FfsProcessSection (
- SectionType,
- Section,
- FileSize,
+ SectionType,
+ Section,
+ FileSize,
SectionData
);
}
@@ -503,13 +503,13 @@ FfsFindNextVolume ( )
{
EFI_PEI_HOB_POINTERS Hob;
-
+
Hob.Raw = GetHobList ();
if (Hob.Raw == NULL) {
return EFI_NOT_FOUND;
}
-
+
do {
Hob.Raw = GetNextHob (EFI_HOB_TYPE_FV, Hob.Raw);
if (Hob.Raw != NULL) {
@@ -521,7 +521,7 @@ FfsFindNextVolume ( Hob.Raw = GetNextHob (EFI_HOB_TYPE_FV, GET_NEXT_HOB (Hob));
}
} while (Hob.Raw != NULL);
-
+
return EFI_NOT_FOUND;
}
@@ -529,7 +529,7 @@ FfsFindNextVolume ( /**
Find a file in the volume by name
-
+
@param FileName A pointer to the name of the file to
find within the firmware volume.
@@ -546,7 +546,7 @@ FfsFindNextVolume ( **/
EFI_STATUS
-EFIAPI
+EFIAPI
FfsFindFileByName (
IN CONST EFI_GUID *FileName,
IN EFI_PEI_FV_HANDLE VolumeHandle,
@@ -576,15 +576,15 @@ FfsFindFileByName ( information.
@retval EFI_SUCCESS File information returned.
-
+
@retval EFI_INVALID_PARAMETER If FileHandle does not
represent a valid file.
-
+
@retval EFI_INVALID_PARAMETER If FileInfo is NULL.
-
+
**/
EFI_STATUS
-EFIAPI
+EFIAPI
FfsGetFileInfo (
IN EFI_PEI_FILE_HANDLE FileHandle,
OUT EFI_FV_FILE_INFO *FileInfo
@@ -614,14 +614,14 @@ FfsGetFileInfo ( }
//
- // Get FileState which is the highest bit of the State
+ // Get FileState which is the highest bit of the State
//
FileState = GetFileState (ErasePolarity, (EFI_FFS_FILE_HEADER*)FileHandle);
switch (FileState) {
case EFI_FILE_DATA_VALID:
case EFI_FILE_MARKED_FOR_UPDATE:
- break;
+ break;
default:
return EFI_INVALID_PARAMETER;
}
@@ -645,15 +645,15 @@ FfsGetFileInfo ( information.
@retval EFI_SUCCESS File information returned.
-
+
@retval EFI_INVALID_PARAMETER If FileHandle does not
represent a valid file.
-
+
@retval EFI_INVALID_PARAMETER If FileInfo is NULL.
**/
EFI_STATUS
-EFIAPI
+EFIAPI
FfsGetVolumeInfo (
IN EFI_PEI_FV_HANDLE VolumeHandle,
OUT EFI_FV_INFO *VolumeInfo
@@ -665,10 +665,10 @@ FfsGetVolumeInfo ( if (VolumeInfo == NULL) {
return EFI_INVALID_PARAMETER;
}
-
+
//
- // VolumeHandle may not align at 8 byte,
- // but FvLength is UINT64 type, which requires FvHeader align at least 8 byte.
+ // VolumeHandle may not align at 8 byte,
+ // but FvLength is UINT64 type, which requires FvHeader align at least 8 byte.
// So, Copy FvHeader into the local FvHeader structure.
//
CopyMem (&FwVolHeader, VolumeHandle, sizeof (EFI_FIRMWARE_VOLUME_HEADER));
@@ -698,7 +698,7 @@ FfsGetVolumeInfo ( @param FileType File handle of a Fv type file.
@param Volumehandle On succes Volume Handle of the match
@param FileHandle On success File Handle of the match
-
+
@retval EFI_NOT_FOUND FV image can't be found.
@retval EFI_SUCCESS Successfully found FileType
@@ -734,7 +734,7 @@ FfsAnyFvFindFirstFile ( break;
}
}
-
+
return Status;
}
@@ -788,14 +788,14 @@ FfsProcessFvFile ( if (EFI_ERROR (Status)) {
return Status;
}
-
+
//
// Collect FvImage Info.
//
ZeroMem (&FvImageInfo, sizeof (FvImageInfo));
Status = FfsGetVolumeInfo (FvImageHandle, &FvImageInfo);
ASSERT_EFI_ERROR (Status);
-
+
//
// FvAlignment must be more than 8 bytes required by FvHeader structure.
//
@@ -803,7 +803,7 @@ FfsProcessFvFile ( if (FvAlignment < 8) {
FvAlignment = 8;
}
-
+
//
// Check FvImage
//
@@ -824,7 +824,7 @@ FfsProcessFvFile ( // Inform HOB consumer phase, i.e. DXE core, the existance of this FV
//
BuildFvHob ((EFI_PHYSICAL_ADDRESS) (UINTN) FvImageInfo.FvStart, FvImageInfo.FvSize);
-
+
//
// Makes the encapsulated volume show up in DXE phase to skip processing of
// encapsulated file again.
diff --git a/EmbeddedPkg/Library/PrePiLib/PrePi.h b/EmbeddedPkg/Library/PrePiLib/PrePi.h index d637277d2a..607561cd24 100644 --- a/EmbeddedPkg/Library/PrePiLib/PrePi.h +++ b/EmbeddedPkg/Library/PrePiLib/PrePi.h @@ -38,7 +38,7 @@ #define END_OF_HOB_LIST(Hob) (GET_HOB_TYPE (Hob) == EFI_HOB_TYPE_END_OF_HOB_LIST)
//
-// Get the data and data size field of GUID
+// Get the data and data size field of GUID
//
#define GET_GUID_HOB_DATA(GuidHob) ((VOID *) (((UINT8 *) &((GuidHob)->Name)) + sizeof (EFI_GUID)))
#define GET_GUID_HOB_DATA_SIZE(GuidHob) (((GuidHob)->Header).HobLength - sizeof (EFI_HOB_GUID_TYPE))
diff --git a/EmbeddedPkg/Library/PrePiLib/PrePiLib.c b/EmbeddedPkg/Library/PrePiLib/PrePiLib.c index 4cc974f1a9..9a1ef344df 100644 --- a/EmbeddedPkg/Library/PrePiLib/PrePiLib.c +++ b/EmbeddedPkg/Library/PrePiLib/PrePiLib.c @@ -1,7 +1,7 @@ /** @file
Copyright (c) 2008 - 2009, Apple Inc. All rights reserved.<BR>
-
+
This program and the accompanying materials
are licensed and made available under the terms and conditions of the BSD License
which accompanies this distribution. The full text of the license may be found at
@@ -43,13 +43,13 @@ LoadPeCoffImage ( VOID *Buffer;
ZeroMem (&ImageContext, sizeof (ImageContext));
-
+
ImageContext.Handle = PeCoffImage;
ImageContext.ImageRead = PeCoffLoaderImageReadFromMemory;
Status = PeCoffLoaderGetImageInfo (&ImageContext);
ASSERT_EFI_ERROR (Status);
-
+
//
// Allocate Memory for the image
@@ -88,7 +88,7 @@ LoadPeCoffImage ( -typedef
+typedef
VOID
(EFIAPI *DXE_CORE_ENTRY_POINT) (
IN VOID *HobStart
@@ -116,7 +116,7 @@ LoadDxeCoreFromFfsFile ( return Status;
}
-
+
Status = LoadPeCoffImage (PeCoffImage, &ImageAddress, &ImageSize, &EntryPoint);
// For NT32 Debug Status = SecWinNtPeiLoadFile (PeCoffImage, &ImageAddress, &ImageSize, &EntryPoint);
ASSERT_EFI_ERROR (Status);
@@ -128,22 +128,22 @@ LoadDxeCoreFromFfsFile ( ASSERT_EFI_ERROR (Status);
BuildModuleHob (&FvFileInfo.FileName, (EFI_PHYSICAL_ADDRESS)(UINTN)ImageAddress, EFI_SIZE_TO_PAGES ((UINT32) ImageSize) * EFI_PAGE_SIZE, EntryPoint);
-
+
DEBUG ((EFI_D_INFO | EFI_D_LOAD, "Loading DxeCore at 0x%10p EntryPoint=0x%10p\n", (VOID *)(UINTN)ImageAddress, (VOID *)(UINTN)EntryPoint));
Hob = GetHobList ();
if (StackSize == 0) {
// User the current stack
-
+
((DXE_CORE_ENTRY_POINT)(UINTN)EntryPoint) (Hob);
} else {
-
+
//
// Allocate 128KB for the Stack
//
BaseOfStack = AllocatePages (EFI_SIZE_TO_PAGES (StackSize));
ASSERT (BaseOfStack != NULL);
-
+
//
// Compute the top of the stack we were allocated. Pre-allocate a UINTN
// for safety.
@@ -153,7 +153,7 @@ LoadDxeCoreFromFfsFile ( //
// Update the contents of BSP stack HOB to reflect the real stack info passed to DxeCore.
- //
+ //
UpdateStackHob ((EFI_PHYSICAL_ADDRESS)(UINTN) BaseOfStack, StackSize);
SwitchStack (
@@ -164,11 +164,11 @@ LoadDxeCoreFromFfsFile ( );
}
-
+
// Should never get here as DXE Core does not return
DEBUG ((EFI_D_ERROR, "DxeCore returned\n"));
ASSERT (FALSE);
-
+
return EFI_DEVICE_ERROR;
}
@@ -199,9 +199,9 @@ LoadDxeCoreFromFv ( if (!EFI_ERROR (Status)) {
return LoadDxeCoreFromFfsFile (FileHandle, StackSize);
- }
-
- return Status;
+ }
+
+ return Status;
}
@@ -219,7 +219,7 @@ DecompressFirstFv ( if (!EFI_ERROR (Status)) {
Status = FfsProcessFvFile (FileHandle);
}
-
+
return Status;
}
diff --git a/EmbeddedPkg/Library/PrePiLib/PrePiLib.inf b/EmbeddedPkg/Library/PrePiLib/PrePiLib.inf index 449e57d1af..b27b0441d5 100644 --- a/EmbeddedPkg/Library/PrePiLib/PrePiLib.inf +++ b/EmbeddedPkg/Library/PrePiLib/PrePiLib.inf @@ -1,9 +1,9 @@ #/** @file
# Component description file for Apple Pre PI Library
#
-# LIbrary helps you build a platform that skips PEI and loads DXE Core
+# LIbrary helps you build a platform that skips PEI and loads DXE Core
# directly. Helps building HOBs, reading data from the FV, and doing
-# decompression.
+# decompression.
#
# Copyright (c) 2008, Apple Inc. All rights reserved.<BR>
#
@@ -23,7 +23,7 @@ FILE_GUID = 1F3A3278-82EB-4C0D-86F1-5BCDA5846CB2
MODULE_TYPE = BASE
VERSION_STRING = 1.0
- LIBRARY_CLASS = PrePiLib
+ LIBRARY_CLASS = PrePiLib
#
@@ -65,7 +65,7 @@ [Protocols]
gEfiStatusCodeRuntimeProtocolGuid
gPeCoffLoaderProtocolGuid
-
+
[FixedPcd.common]
gEmbeddedTokenSpaceGuid.PcdPrePiCpuMemorySize
diff --git a/EmbeddedPkg/Library/PrePiLib/ReportStatusCode.c b/EmbeddedPkg/Library/PrePiLib/ReportStatusCode.c index 747acac766..7a0b90a1e6 100644 --- a/EmbeddedPkg/Library/PrePiLib/ReportStatusCode.c +++ b/EmbeddedPkg/Library/PrePiLib/ReportStatusCode.c @@ -2,7 +2,7 @@ Library that helps implement monolithic PEI
Copyright (c) 2008 - 2009, Apple Inc. All rights reserved.<BR>
-
+
This program and the accompanying materials
are licensed and made available under the terms and conditions of the BSD License
which accompanies this distribution. The full text of the license may be found at
@@ -34,8 +34,8 @@ SerialReportStatusCode ( );
-EFI_STATUS_CODE_PROTOCOL gStatusCode = {
- (EFI_REPORT_STATUS_CODE)SerialReportStatusCode
+EFI_STATUS_CODE_PROTOCOL gStatusCode = {
+ (EFI_REPORT_STATUS_CODE)SerialReportStatusCode
};
/**
@@ -221,7 +221,7 @@ SerialReportStatusCode ( } else if (Data != NULL &&
ReportStatusCodeExtractDebugInfo (Data, &ErrorLevel, &Marker, &Format)) {
-
+
//
// Print DEBUG() information into output buffer.
//
diff --git a/EmbeddedPkg/Library/PrePiMemoryAllocationLib/MemoryAllocationLib.c b/EmbeddedPkg/Library/PrePiMemoryAllocationLib/MemoryAllocationLib.c index c22682a918..0e75e23933 100644 --- a/EmbeddedPkg/Library/PrePiMemoryAllocationLib/MemoryAllocationLib.c +++ b/EmbeddedPkg/Library/PrePiMemoryAllocationLib/MemoryAllocationLib.c @@ -2,7 +2,7 @@ Implementation of the 6 PEI Ffs (FV) APIs in library form.
Copyright (c) 2008 - 2009, Apple Inc. All rights reserved.<BR>
-
+
This program and the accompanying materials
are licensed and made available under the terms and conditions of the BSD License
which accompanies this distribution. The full text of the license may be found at
@@ -180,7 +180,7 @@ AllocatePool ( Hob = GetHobList ();
-
+
//
// Verify that there is sufficient memory to satisfy the allocation
//
diff --git a/EmbeddedPkg/Library/PrePiMemoryAllocationLib/PrePiMemoryAllocationLib.inf b/EmbeddedPkg/Library/PrePiMemoryAllocationLib/PrePiMemoryAllocationLib.inf index 2addc5a5a8..21f6eb1e14 100644 --- a/EmbeddedPkg/Library/PrePiMemoryAllocationLib/PrePiMemoryAllocationLib.inf +++ b/EmbeddedPkg/Library/PrePiMemoryAllocationLib/PrePiMemoryAllocationLib.inf @@ -1,14 +1,14 @@ #/** @file
-#
+#
# Copyright (c) 2011, ARM Ltd. All rights reserved.<BR>
# This program and the accompanying materials
# are licensed and made available under the terms and conditions of the BSD License
# which accompanies this distribution. The full text of the license may be found at
# http://opensource.org/licenses/bsd-license.php
-#
+#
# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
-#
+#
#**/
[Defines]
diff --git a/EmbeddedPkg/Library/TemplateRealTimeClockLib/RealTimeClockLib.c b/EmbeddedPkg/Library/TemplateRealTimeClockLib/RealTimeClockLib.c index 129d4e06ef..8e4ee9b919 100644 --- a/EmbeddedPkg/Library/TemplateRealTimeClockLib/RealTimeClockLib.c +++ b/EmbeddedPkg/Library/TemplateRealTimeClockLib/RealTimeClockLib.c @@ -1,10 +1,10 @@ /** @file
Implement EFI RealTimeClock runtime services via RTC Lib.
-
+
Currently this driver does not support runtime virtual calling.
Copyright (c) 2008 - 2009, Apple Inc. All rights reserved.<BR>
-
+
This program and the accompanying materials
are licensed and made available under the terms and conditions of the BSD License
which accompanies this distribution. The full text of the license may be found at
@@ -164,7 +164,7 @@ LibRtcVirtualNotifyEvent ( {
//
// Only needed if you are going to support the OS calling RTC functions in virtual mode.
- // You will need to call EfiConvertPointer (). To convert any stored physical addresses
+ // You will need to call EfiConvertPointer (). To convert any stored physical addresses
// to virtual address. After the OS transistions to calling in virtual mode, all future
// runtime calls will be made in virtual mode.
//
diff --git a/EmbeddedPkg/Library/TemplateRealTimeClockLib/TemplateRealTimeClockLib.inf b/EmbeddedPkg/Library/TemplateRealTimeClockLib/TemplateRealTimeClockLib.inf index ce0d13257c..ebc3729aae 100644 --- a/EmbeddedPkg/Library/TemplateRealTimeClockLib/TemplateRealTimeClockLib.inf +++ b/EmbeddedPkg/Library/TemplateRealTimeClockLib/TemplateRealTimeClockLib.inf @@ -34,4 +34,3 @@ [LibraryClasses]
IoLib
DebugLib
-
\ No newline at end of file diff --git a/EmbeddedPkg/Library/TemplateResetSystemLib/ResetSystemLib.c b/EmbeddedPkg/Library/TemplateResetSystemLib/ResetSystemLib.c index 5c482a29f7..328bcbcf16 100644 --- a/EmbeddedPkg/Library/TemplateResetSystemLib/ResetSystemLib.c +++ b/EmbeddedPkg/Library/TemplateResetSystemLib/ResetSystemLib.c @@ -1,11 +1,11 @@ /** @file
Template library implementation to support ResetSystem Runtime call.
-
+
Fill in the templates with what ever makes you system reset.
Copyright (c) 2008 - 2009, Apple Inc. All rights reserved.<BR>
-
+
This program and the accompanying materials
are licensed and made available under the terms and conditions of the BSD License
which accompanies this distribution. The full text of the license may be found at
@@ -46,30 +46,30 @@ LibResetSystem ( {
UINTN Address;
UINT8 Data;
-
-
+
+
switch (ResetType) {
case EfiResetCold:
// system power cycle
-
+
// Example using IoLib functions to do IO.
Address = 0x12345678;
Data = MmioRead8 (Address);
MmioWrite8 (Address, Data | 0x01);
-
+
// Note this is a bad example asa MmioOr8 (Address, 0x01) does the same thing
break;
-
+
case EfiResetWarm:
- // not a full power cycle, maybe memory stays around.
+ // not a full power cycle, maybe memory stays around.
// if not support do the same thing as EfiResetCold.
break;
-
+
case EfiResetShutdown:
// turn off the system.
// if not support do the same thing as EfiResetCold.
break;
-
+
default:
return EFI_INVALID_PARAMETER;
}
@@ -79,7 +79,7 @@ LibResetSystem ( //
return EFI_DEVICE_ERROR;
}
-
+
/**
@@ -87,7 +87,7 @@ LibResetSystem ( @param ImageHandle The firmware allocated handle for the EFI image.
@param SystemTable A pointer to the EFI System Table.
-
+
@retval EFI_SUCCESS The constructor always returns EFI_SUCCESS.
**/
diff --git a/EmbeddedPkg/Library/TemplateSerialPortExtLib/TemplateSerialPortExtLib.c b/EmbeddedPkg/Library/TemplateSerialPortExtLib/TemplateSerialPortExtLib.c index f993cbf5c0..2c2b4382d2 100644 --- a/EmbeddedPkg/Library/TemplateSerialPortExtLib/TemplateSerialPortExtLib.c +++ b/EmbeddedPkg/Library/TemplateSerialPortExtLib/TemplateSerialPortExtLib.c @@ -2,7 +2,7 @@ Extended Serial I/O Port library functions
Copyright (c) 2012, ARM Ltd. All rights reserved.
-
+
This program and the accompanying materials
are licensed and made available under the terms and conditions of the BSD License
which accompanies this distribution. The full text of the license may be found at
diff --git a/EmbeddedPkg/Library/TemplateSerialPortLib/TemplateSerialPortLib.c b/EmbeddedPkg/Library/TemplateSerialPortLib/TemplateSerialPortLib.c index 5d9bb073c7..c3f8bd1298 100644 --- a/EmbeddedPkg/Library/TemplateSerialPortLib/TemplateSerialPortLib.c +++ b/EmbeddedPkg/Library/TemplateSerialPortLib/TemplateSerialPortLib.c @@ -3,7 +3,7 @@ Copyright (c) 2008 - 2009, Apple Inc. All rights reserved.<BR>
Copyright (c) 2012, ARM Ltd. All rights reserved.
-
+
This program and the accompanying materials
are licensed and made available under the terms and conditions of the BSD License
which accompanies this distribution. The full text of the license may be found at
@@ -82,7 +82,7 @@ SerialPortRead ( Poll the serial device to see if there is any data waiting.
If there is data waiting to be read from the serial port, then return
- TRUE. If there is no data waiting to be read from the serial port, then
+ TRUE. If there is no data waiting to be read from the serial port, then
return FALSE.
@retval TRUE Data is waiting to be read.
diff --git a/EmbeddedPkg/MetronomeDxe/MetronomeDxe.inf b/EmbeddedPkg/MetronomeDxe/MetronomeDxe.inf index 37aea8571a..bb5bf0ee95 100644 --- a/EmbeddedPkg/MetronomeDxe/MetronomeDxe.inf +++ b/EmbeddedPkg/MetronomeDxe/MetronomeDxe.inf @@ -1,5 +1,5 @@ #/** @file
-#
+#
# Component description file for Bds module
#
# Copyright (c) 2008, Apple Inc. All rights reserved.
@@ -9,10 +9,10 @@ # are licensed and made available under the terms and conditions of the BSD License
# which accompanies this distribution. The full text of the license may be found at
# http://opensource.org/licenses/bsd-license.php
-#
+#
# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
-#
+#
#**/
[Defines]
@@ -42,9 +42,9 @@ [FixedPcd]
gEmbeddedTokenSpaceGuid.PcdMetronomeTickPeriod
-
+
[Protocols]
- gEfiMetronomeArchProtocolGuid
+ gEfiMetronomeArchProtocolGuid
[depex]
TRUE
diff --git a/EmbeddedPkg/RealTimeClockRuntimeDxe/RealTimeClock.c b/EmbeddedPkg/RealTimeClockRuntimeDxe/RealTimeClock.c index 9564cf55ee..80af8cf824 100644 --- a/EmbeddedPkg/RealTimeClockRuntimeDxe/RealTimeClock.c +++ b/EmbeddedPkg/RealTimeClockRuntimeDxe/RealTimeClock.c @@ -1,11 +1,11 @@ /** @file
Implement EFI RealTimeClock runtime services via RTC Lib.
-
+
Currently this driver does not support runtime virtual calling.
Copyright (c) 2008 - 2009, Apple Inc. All rights reserved.<BR>
-
+
This program and the accompanying materials
are licensed and made available under the terms and conditions of the BSD License
which accompanies this distribution. The full text of the license may be found at
@@ -16,7 +16,7 @@ **/
-#include <PiDxe.h>
+#include <PiDxe.h>
#include <Library/UefiLib.h>
#include <Library/UefiBootServicesTableLib.h>
#include <Library/RealTimeClockLib.h>
diff --git a/EmbeddedPkg/RealTimeClockRuntimeDxe/RealTimeClockRuntimeDxe.inf b/EmbeddedPkg/RealTimeClockRuntimeDxe/RealTimeClockRuntimeDxe.inf index 14bf26f532..186d4610bd 100644 --- a/EmbeddedPkg/RealTimeClockRuntimeDxe/RealTimeClockRuntimeDxe.inf +++ b/EmbeddedPkg/RealTimeClockRuntimeDxe/RealTimeClockRuntimeDxe.inf @@ -37,7 +37,7 @@ RealTimeClockLib
[Protocols]
- gEfiRealTimeClockArchProtocolGuid
+ gEfiRealTimeClockArchProtocolGuid
[Depex]
TRUE
diff --git a/EmbeddedPkg/ResetRuntimeDxe/reset.c b/EmbeddedPkg/ResetRuntimeDxe/reset.c index 1708447e1e..3b9129ed29 100644 --- a/EmbeddedPkg/ResetRuntimeDxe/reset.c +++ b/EmbeddedPkg/ResetRuntimeDxe/reset.c @@ -1,7 +1,7 @@ /** @file
Copyright (c) 2008 - 2009, Apple Inc. All rights reserved.<BR>
-
+
This program and the accompanying materials
are licensed and made available under the terms and conditions of the BSD License
which accompanies this distribution. The full text of the license may be found at
@@ -57,7 +57,7 @@ InitializeReset ( EFI_HANDLE Handle;
LibInitializeResetSystem (ImageHandle, SystemTable);
-
+
SystemTable->RuntimeServices->ResetSystem = ResetSystemViaLib;
Handle = NULL;
diff --git a/EmbeddedPkg/SerialDxe/SerialDxe.inf b/EmbeddedPkg/SerialDxe/SerialDxe.inf index ed7f377351..aed458df63 100644 --- a/EmbeddedPkg/SerialDxe/SerialDxe.inf +++ b/EmbeddedPkg/SerialDxe/SerialDxe.inf @@ -1,16 +1,16 @@ #/** @file
-#
+#
# Convert SerialLib into SerialIo protocol
-#
+#
# Copyright (c) 2008, Intel Corporation. All rights reserved.<BR>
# This program and the accompanying materials
# are licensed and made available under the terms and conditions of the BSD License
# which accompanies this distribution. The full text of the license may be found at
# http://opensource.org/licenses/bsd-license.php
-#
+#
# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
-#
+#
#**/
[Defines]
@@ -42,7 +42,7 @@ SerialPortExtLib
[Protocols]
- gEfiSerialIoProtocolGuid
+ gEfiSerialIoProtocolGuid
gEfiDevicePathProtocolGuid
[FixedPcd]
@@ -51,5 +51,5 @@ gEfiMdePkgTokenSpaceGuid.PcdUartDefaultParity
gEfiMdePkgTokenSpaceGuid.PcdUartDefaultStopBits
-[Depex]
+[Depex]
TRUE
diff --git a/EmbeddedPkg/SerialDxe/SerialIo.c b/EmbeddedPkg/SerialDxe/SerialIo.c index 0bdf4b9f63..7a849b7a01 100644 --- a/EmbeddedPkg/SerialDxe/SerialIo.c +++ b/EmbeddedPkg/SerialDxe/SerialIo.c @@ -1,9 +1,9 @@ /** @file
- Serial IO Abstraction for GDB stub. This allows an EFI consoles that shows up on the system
+ Serial IO Abstraction for GDB stub. This allows an EFI consoles that shows up on the system
running GDB. One console for error information and another console for user input/output.
Basic packet format is $packet-data#checksum. So every command has 4 bytes of overhead: $,
- #, 0, 0. The 0 and 0 are the ascii characters for the checksum.
+ #, 0, 0. The 0 and 0 are the ascii characters for the checksum.
Copyright (c) 2008 - 2009, Apple Inc. All rights reserved.<BR>
Copyright (c) 2013-2014, ARM Ltd. All rights reserved.<BR>
@@ -56,7 +56,7 @@ EFI_HANDLE gHandle = NULL; Reset the serial device.
@param This Protocol instance pointer.
-
+
@retval EFI_SUCCESS The device was reset.
@retval EFI_DEVICE_ERROR The serial device could not be reset.
@@ -247,7 +247,7 @@ SerialSetControl ( @param This Protocol instance pointer.
@param Control A pointer to return the current Control signals from the serial device.
-
+
@retval EFI_SUCCESS The control bits were read from the serial device.
@retval EFI_DEVICE_ERROR The serial device is not functioning correctly.
@@ -285,7 +285,7 @@ SerialWrite ( )
{
UINTN Count;
-
+
Count = SerialPortWrite (Buffer, *BufferSize);
if (Count != *BufferSize) {
@@ -332,7 +332,7 @@ SerialRead ( return EFI_SUCCESS;
}
-//
+//
// Template used to initialize the GDB Serial IO protocols
//
EFI_SERIAL_IO_MODE gSerialIoMode = {
@@ -379,13 +379,13 @@ SerialDxeInitialize ( // Make a new handle with Serial IO protocol and its device path on it.
Status = gBS->InstallMultipleProtocolInterfaces (
- &gHandle,
+ &gHandle,
&gEfiSerialIoProtocolGuid, &gSerialIoTemplate,
- &gEfiDevicePathProtocolGuid, &mDevicePath,
+ &gEfiDevicePathProtocolGuid, &mDevicePath,
NULL
);
ASSERT_EFI_ERROR (Status);
-
+
return Status;
}
diff --git a/EmbeddedPkg/SimpleTextInOutSerial/SimpleTextInOut.c b/EmbeddedPkg/SimpleTextInOutSerial/SimpleTextInOut.c index 5905a108b1..8df58fce22 100644 --- a/EmbeddedPkg/SimpleTextInOutSerial/SimpleTextInOut.c +++ b/EmbeddedPkg/SimpleTextInOutSerial/SimpleTextInOut.c @@ -1,8 +1,8 @@ /** @file
- Simple Console that sits on a SerialLib.
+ Simple Console that sits on a SerialLib.
Copyright (c) 2008 - 2009, Apple Inc. All rights reserved.<BR>
-
+
This program and the accompanying materials
are licensed and made available under the terms and conditions of the BSD License
which accompanies this distribution. The full text of the license may be found at
@@ -13,7 +13,7 @@ **/
-/*
+/*
Symbols used in table below
===========================
ESC = 0x1B
@@ -295,17 +295,17 @@ ReadKeyStroke ( )
{
CHAR8 Char;
-
+
if (!SerialPortPoll ()) {
return EFI_NOT_READY;
}
-
+
SerialPortRead ((UINT8 *)&Char, 1);
-
+
//
// Check for ESC sequence. This code is not techincally correct VT100 code.
// An illegal ESC sequence represents an ESC and the characters that follow.
- // This code will eat one or two chars after an escape. This is done to
+ // This code will eat one or two chars after an escape. This is done to
// prevent some complex FIFOing of the data. It is good enough to get
// the arrow and delete keys working
//
@@ -332,7 +332,7 @@ ReadKeyStroke ( Key->ScanCode = SCAN_HOME;
break;
case 'K':
- case 'F': // PC ANSI
+ case 'F': // PC ANSI
Key->ScanCode = SCAN_END;
break;
case '@':
@@ -340,7 +340,7 @@ ReadKeyStroke ( Key->ScanCode = SCAN_INSERT;
break;
case 'P':
- case 'X': // PC ANSI
+ case 'X': // PC ANSI
Key->ScanCode = SCAN_DELETE;
break;
case 'U':
@@ -419,12 +419,12 @@ ReadKeyStroke ( }
}
} else if (Char < ' ') {
- if ((Char == CHAR_BACKSPACE) ||
- (Char == CHAR_TAB) ||
- (Char == CHAR_LINEFEED) ||
+ if ((Char == CHAR_BACKSPACE) ||
+ (Char == CHAR_TAB) ||
+ (Char == CHAR_LINEFEED) ||
(Char == CHAR_CARRIAGE_RETURN)) {
// Only let through EFI required control characters
- Key->UnicodeChar = (CHAR16)Char;
+ Key->UnicodeChar = (CHAR16)Char;
}
} else if (Char == 0x7f) {
Key->ScanCode = SCAN_DELETE;
@@ -523,13 +523,13 @@ OutputString ( EFI_SIMPLE_TEXT_OUTPUT_MODE *Mode;
UINTN MaxColumn;
UINTN MaxRow;
-
+
Size = StrLen(String) + 1;
OutputString = AllocatePool(Size);
//If there is any non-ascii characters in String buffer then replace it with '?'
//Eventually, UnicodeStrToAsciiStr API should be fixed.
- SafeUnicodeStrToAsciiStr(String, OutputString);
+ SafeUnicodeStrToAsciiStr(String, OutputString);
SerialPortWrite ((UINT8 *)OutputString, Size - 1);
//
@@ -693,7 +693,7 @@ SetCursorPosition ( This,
Mode->Mode,
&MaxColumn,
- &MaxRow
+ &MaxRow
);
if (EFI_ERROR(Status)) {
return EFI_UNSUPPORTED;
@@ -742,7 +742,7 @@ SimpleTextInOutEntryPoint ( &mSimpleTextIn.WaitForKey
);
ASSERT_EFI_ERROR (Status);
-
+
Status = gBS->InstallMultipleProtocolInterfaces(
&mInstallHandle,
&gEfiSimpleTextInProtocolGuid, &mSimpleTextIn,
@@ -754,6 +754,6 @@ SimpleTextInOutEntryPoint ( gST->ConOut = &mSimpleTextOut;
gST->ConIn = &mSimpleTextIn;
}
-
+
return Status;
}
diff --git a/EmbeddedPkg/SimpleTextInOutSerial/SimpleTextInOutSerial.inf b/EmbeddedPkg/SimpleTextInOutSerial/SimpleTextInOutSerial.inf index e1c5ea6fb6..4b45f83889 100644 --- a/EmbeddedPkg/SimpleTextInOutSerial/SimpleTextInOutSerial.inf +++ b/EmbeddedPkg/SimpleTextInOutSerial/SimpleTextInOutSerial.inf @@ -1,16 +1,16 @@ #/** @file
-#
+#
# Component description file for Bds module
-#
+#
# Copyright (c) 2008, Intel Corporation. All rights reserved.<BR>
# This program and the accompanying materials
# are licensed and made available under the terms and conditions of the BSD License
# which accompanies this distribution. The full text of the license may be found at
# http://opensource.org/licenses/bsd-license.php
-#
+#
# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
-#
+#
#**/
[Defines]
@@ -43,12 +43,12 @@ SerialPortLib
[Guids]
-
+
[Protocols]
- gEfiSimpleTextInProtocolGuid
- gEfiSimpleTextOutProtocolGuid
- gEfiSerialIoProtocolGuid
+ gEfiSimpleTextInProtocolGuid
+ gEfiSimpleTextOutProtocolGuid
+ gEfiSerialIoProtocolGuid
gEfiDevicePathProtocolGuid
[FixedPcd]
diff --git a/EmbeddedPkg/TemplateSec/TemplateSec.c b/EmbeddedPkg/TemplateSec/TemplateSec.c index b43bb13e40..c63adbb6f9 100644 --- a/EmbeddedPkg/TemplateSec/TemplateSec.c +++ b/EmbeddedPkg/TemplateSec/TemplateSec.c @@ -1,7 +1,7 @@ /** @file
Copyright (c) 2008 - 2009, Apple Inc. All rights reserved.<BR>
-
+
This program and the accompanying materials
are licensed and made available under the terms and conditions of the BSD License
which accompanies this distribution. The full text of the license may be found at
@@ -46,30 +46,30 @@ CEntryPoint ( MemoryLength = (UINT64)MemorySize;
HobBase = (VOID *)(UINTN)(FixedPcdGet32(PcdEmbeddedFdBaseAddress) + FixedPcdGet32(PcdEmbeddedFdSize));
CreateHobList (MemoryBase, MemorySize, HobBase, StackBase);
-
+
MemoryBegin = (EFI_PHYSICAL_ADDRESS)(UINTN)StackBase;
MemoryLength = (UINT64)StackSize;
UpdateStackHob (MemoryBegin, MemoryLength);
DEBUG ((DEBUG_ERROR, "CEntryPoint (%x,%x,%x,%x)\n", MemoryBase, MemorySize, StackBase, StackSize));
-
+
//
// Add your C code stuff here....
//
-
-
+
+
//
// Load the DXE Core and transfer control to it
//
-
- // Give the DXE Core access to our DEBUG and ASSERT infrastructure so this will work prior
+
+ // Give the DXE Core access to our DEBUG and ASSERT infrastructure so this will work prior
// to the DXE version being loaded. Thus we close the debugging gap between phases.
AddDxeCoreReportStatusCodeCallback ();
-
+
//BuildFvHobs (PcdBfvBase, PcdBfvSize, NULL);
-
+
LoadDxeCoreFromFv (NULL, 0);
-
+
// DXE Core should always load and never return
ASSERT (FALSE);
}
diff --git a/EmbeddedPkg/TemplateSec/TemplateSec.inf b/EmbeddedPkg/TemplateSec/TemplateSec.inf index 81f4ac761b..3a63e59294 100644 --- a/EmbeddedPkg/TemplateSec/TemplateSec.inf +++ b/EmbeddedPkg/TemplateSec/TemplateSec.inf @@ -1,18 +1,18 @@ #/** @file
-#
+#
# Component description file for DxeIpl module
-#
+#
# The responsibility of this module is to load the DXE Core from a Firmware Volume. This implementation i used to load a 32-bit DXE Core.
-#
+#
# Copyright (c) 2006 - 2008, Intel Corporation. All rights reserved.<BR>
# This program and the accompanying materials
# are licensed and made available under the terms and conditions of the BSD License
# which accompanies this distribution. The full text of the license may be found at
# http://opensource.org/licenses/bsd-license.php
-#
+#
# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
-#
+#
#**/
[Defines]
@@ -48,7 +48,7 @@ MdePkg/MdePkg.dec
MdeModulePkg/MdeModulePkg.dec
EmbeddedPkg/EmbeddedPkg.dec
-
+
[LibraryClasses]
BaseLib
@@ -58,7 +58,7 @@ PeCoffLib
CacheMaintenanceLib
PrePiLib
-
+
[Pcd]
gEmbeddedTokenSpaceGuid.PcdEmbeddedFdBaseAddress
gEmbeddedTokenSpaceGuid.PcdEmbeddedFdSize
diff --git a/EmbeddedPkg/Universal/MmcDxe/ComponentName.c b/EmbeddedPkg/Universal/MmcDxe/ComponentName.c index 030a54f72b..0161f56d91 100644 --- a/EmbeddedPkg/Universal/MmcDxe/ComponentName.c +++ b/EmbeddedPkg/Universal/MmcDxe/ComponentName.c @@ -2,14 +2,14 @@ Component Name Protocol implementation for the MMC DXE driver
Copyright (c) 2011, ARM Limited. All rights reserved.
-
- This program and the accompanying materials
- are licensed and made available under the terms and conditions of the BSD License
- which accompanies this distribution. The full text of the license may be found at
- http://opensource.org/licenses/bsd-license.php
-
- THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
- WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
+
+ This program and the accompanying materials
+ are licensed and made available under the terms and conditions of the BSD License
+ which accompanies this distribution. The full text of the license may be found at
+ http://opensource.org/licenses/bsd-license.php
+
+ THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
+ WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
**/
diff --git a/EmbeddedPkg/Universal/MmcDxe/Diagnostics.c b/EmbeddedPkg/Universal/MmcDxe/Diagnostics.c index 310b7cc820..783e548d2a 100644 --- a/EmbeddedPkg/Universal/MmcDxe/Diagnostics.c +++ b/EmbeddedPkg/Universal/MmcDxe/Diagnostics.c @@ -2,14 +2,14 @@ Diagnostics Protocol implementation for the MMC DXE driver
Copyright (c) 2011-2014, ARM Limited. All rights reserved.
-
- This program and the accompanying materials
- are licensed and made available under the terms and conditions of the BSD License
- which accompanies this distribution. The full text of the license may be found at
- http://opensource.org/licenses/bsd-license.php
-
- THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
- WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
+
+ This program and the accompanying materials
+ are licensed and made available under the terms and conditions of the BSD License
+ which accompanies this distribution. The full text of the license may be found at
+ http://opensource.org/licenses/bsd-license.php
+
+ THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
+ WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
**/
diff --git a/EmbeddedPkg/Universal/MmcDxe/Mmc.c b/EmbeddedPkg/Universal/MmcDxe/Mmc.c index 9327bd6337..570e1d2e43 100644 --- a/EmbeddedPkg/Universal/MmcDxe/Mmc.c +++ b/EmbeddedPkg/Universal/MmcDxe/Mmc.c @@ -2,14 +2,14 @@ Main file of the MMC Dxe driver. The driver entrypoint is defined into this file.
Copyright (c) 2011-2013, ARM Limited. All rights reserved.
-
- This program and the accompanying materials
- are licensed and made available under the terms and conditions of the BSD License
- which accompanies this distribution. The full text of the license may be found at
- http://opensource.org/licenses/bsd-license.php
- THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
- WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
+ This program and the accompanying materials
+ are licensed and made available under the terms and conditions of the BSD License
+ which accompanies this distribution. The full text of the license may be found at
+ http://opensource.org/licenses/bsd-license.php
+
+ THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
+ WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
**/
@@ -246,7 +246,7 @@ MmcDriverBindingSupported ( }
/**
-
+
**/
EFI_STATUS
EFIAPI
@@ -306,7 +306,7 @@ MmcDriverBindingStart ( }
/**
-
+
**/
EFI_STATUS
EFIAPI
@@ -398,7 +398,7 @@ EFI_DRIVER_BINDING_PROTOCOL gMmcDriverBinding = { };
/**
-
+
**/
EFI_STATUS
EFIAPI
@@ -442,8 +442,8 @@ MmcDxeInitialize ( CheckCardsCallback,
NULL,
&gCheckCardsEvent);
- ASSERT_EFI_ERROR (Status);
-
+ ASSERT_EFI_ERROR (Status);
+
Status = gBS->SetTimer(
gCheckCardsEvent,
TimerPeriodic,
diff --git a/EmbeddedPkg/Universal/MmcDxe/Mmc.h b/EmbeddedPkg/Universal/MmcDxe/Mmc.h index e84c3c1cdf..301561a282 100644 --- a/EmbeddedPkg/Universal/MmcDxe/Mmc.h +++ b/EmbeddedPkg/Universal/MmcDxe/Mmc.h @@ -2,14 +2,14 @@ Main Header file for the MMC DXE driver
Copyright (c) 2011-2014, ARM Limited. All rights reserved.
-
- This program and the accompanying materials
- are licensed and made available under the terms and conditions of the BSD License
- which accompanies this distribution. The full text of the license may be found at
- http://opensource.org/licenses/bsd-license.php
- THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
- WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
+ This program and the accompanying materials
+ are licensed and made available under the terms and conditions of the BSD License
+ which accompanies this distribution. The full text of the license may be found at
+ http://opensource.org/licenses/bsd-license.php
+
+ THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
+ WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
**/
@@ -65,12 +65,12 @@ typedef enum { } CARD_TYPE;
typedef struct {
- UINT32 Reserved0: 7; // 0
+ UINT32 Reserved0: 7; // 0
UINT32 V170_V195: 1; // 1.70V - 1.95V
UINT32 V200_V260: 7; // 2.00V - 2.60V
UINT32 V270_V360: 9; // 2.70V - 3.60V
UINT32 RESERVED_1: 5; // Reserved
- UINT32 AccessMode: 2; // 00b (byte mode), 10b (sector mode)
+ UINT32 AccessMode: 2; // 00b (byte mode), 10b (sector mode)
UINT32 PowerUp: 1; // This bit is set to LOW if the card has not finished the power up routine
} OCR;
@@ -96,14 +96,14 @@ typedef struct { UINT8 PERM_WRITE_PROTECT: 1; // Permanent write protection [13:13]
UINT8 COPY: 1; // Copy flag (OTP) [14:14]
UINT8 FILE_FORMAT_GRP: 1; // File format group [15:15]
-
+
UINT16 RESERVED_2: 5; // Reserved [20:16]
UINT16 WRITE_BL_PARTIAL: 1; // Partial blocks for write allowed [21:21]
UINT16 WRITE_BL_LEN: 4; // Max. write data block length [25:22]
UINT16 R2W_FACTOR: 3; // Write speed factor [28:26]
UINT16 RESERVED_3: 2; // Reserved [30:29]
UINT16 WP_GRP_ENABLE: 1; // Write protect group enable [31:31]
-
+
UINT32 WP_GRP_SIZE: 7; // Write protect group size [38:32]
UINT32 SECTOR_SIZE: 7; // Erase sector size [45:39]
UINT32 ERASE_BLK_EN: 1; // Erase single block enable [46:46]
@@ -113,7 +113,7 @@ typedef struct { UINT32 VDD_R_CURR_MAX: 3; // Max. read current @ VDD max [58:56]
UINT32 VDD_R_CURR_MIN: 3; // Max. read current @ VDD min [61:59]
UINT32 C_SIZELow2: 2; // Device size [63:62]
-
+
UINT32 C_SIZEHigh10: 10;// Device size [73:64]
UINT32 RESERVED_4: 2; // Reserved [75:74]
UINT32 DSR_IMP: 1; // DSR implemented [76:76]
@@ -126,7 +126,7 @@ typedef struct { UINT8 TRAN_SPEED ; // Max. bus clock frequency [103:96]
UINT8 NSAC ; // Data read access-time 2 in CLK cycles (NSAC*100) [111:104]
UINT8 TAAC ; // Data read access-time 1 [119:112]
-
+
UINT8 RESERVED_5: 6; // Reserved [125:120]
UINT8 CSD_STRUCTURE: 2; // CSD structure [127:126]
} CSD;
@@ -149,7 +149,7 @@ typedef struct _MMC_HOST_INSTANCE { EFI_BLOCK_IO_PROTOCOL BlockIo;
CARD_INFO CardInfo;
EFI_MMC_HOST_PROTOCOL *MmcHost;
-
+
BOOLEAN Initialized;
} MMC_HOST_INSTANCE;
@@ -186,7 +186,7 @@ extern LIST_ENTRY mMmcHostPool; /**
Reset the block device.
- This function implements EFI_BLOCK_IO_PROTOCOL.Reset().
+ This function implements EFI_BLOCK_IO_PROTOCOL.Reset().
It resets the block device hardware.
ExtendedVerification is ignored in this implementation.
@@ -208,7 +208,7 @@ MmcReset ( /**
Reads the requested number of blocks from the device.
- This function implements EFI_BLOCK_IO_PROTOCOL.ReadBlocks().
+ This function implements EFI_BLOCK_IO_PROTOCOL.ReadBlocks().
It reads the requested number of blocks from the device.
All the blocks are read, or an error is returned.
@@ -242,7 +242,7 @@ MmcReadBlocks ( /**
Writes a specified number of blocks to the device.
- This function implements EFI_BLOCK_IO_PROTOCOL.WriteBlocks().
+ This function implements EFI_BLOCK_IO_PROTOCOL.WriteBlocks().
It writes a specified number of blocks to the device.
All blocks are written, or an error is returned.
diff --git a/EmbeddedPkg/Universal/MmcDxe/MmcDxe.inf b/EmbeddedPkg/Universal/MmcDxe/MmcDxe.inf index 5a05ed8be4..f9a2b9c703 100644 --- a/EmbeddedPkg/Universal/MmcDxe/MmcDxe.inf +++ b/EmbeddedPkg/Universal/MmcDxe/MmcDxe.inf @@ -2,14 +2,14 @@ # Build file for the MMC DXE driver
#
# Copyright (c) 2011-2014, ARM Limited. All rights reserved.
-#
-# This program and the accompanying materials
-# are licensed and made available under the terms and conditions of the BSD License
-# which accompanies this distribution. The full text of the license may be found at
-# http://opensource.org/licenses/bsd-license.php
#
-# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
-# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
+# This program and the accompanying materials
+# are licensed and made available under the terms and conditions of the BSD License
+# which accompanies this distribution. The full text of the license may be found at
+# http://opensource.org/licenses/bsd-license.php
+#
+# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
+# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
#
#**/
@@ -47,6 +47,6 @@ gEfiDevicePathProtocolGuid
gEfiMmcHostProtocolGuid
gEfiDriverDiagnostics2ProtocolGuid
-
+
[Depex]
TRUE
diff --git a/Omap35xxPkg/Flash/Flash.c b/Omap35xxPkg/Flash/Flash.c index b33c9badf7..b8de109d87 100644 --- a/Omap35xxPkg/Flash/Flash.c +++ b/Omap35xxPkg/Flash/Flash.c @@ -1,7 +1,7 @@ /** @file
Copyright (c) 2008 - 2009, Apple Inc. All rights reserved.<BR>
-
+
This program and the accompanying materials
are licensed and made available under the terms and conditions of the BSD License
which accompanies this distribution. The full text of the license may be found at
@@ -227,7 +227,7 @@ NandConfigureEcc ( MmioWrite32 (GPMC_ECC_SIZE_CONFIG, (ECCSIZE0_512BYTES | ECCSIZE1_512BYTES));
}
-VOID
+VOID
NandEnableEcc (
VOID
)
@@ -268,7 +268,7 @@ NandCalculateEcc ( EccResult = MmioRead32 (EccResultRegister);
//Calculate ECC code from 32-bit ECC result value.
- //NOTE: Following calculation is not part of TRM. We got this information
+ //NOTE: Following calculation is not part of TRM. We got this information
//from Beagleboard mailing list.
gEccCode[Index * 3] = EccResult & 0xFF;
gEccCode[(Index * 3) + 1] = (EccResult >> 16) & 0xFF;
@@ -380,7 +380,7 @@ NandWritePage ( MmioWrite16(GPMC_NAND_DATA_0, *MainAreaWordBuffer++);
//After each write access, device has to wait to accept data.
- //Currently we may not be programming proper timing parameters to
+ //Currently we may not be programming proper timing parameters to
//the GPMC_CONFIGi_0 registers and we would need to figure that out.
//Without following delay, page programming fails.
gBS->Stall(1);
@@ -544,7 +544,7 @@ NandFlashReset ( //Send RESET command to device.
NandSendCommand(RESET_CMD);
-
+
//Wait for 1ms before we check status register.
gBS->Stall(1000);
@@ -562,7 +562,7 @@ NandFlashReset ( ResetBusyTimeout--;
}
}
-
+
return EFI_SUCCESS;
}
@@ -585,12 +585,12 @@ NandFlashReadBlocks ( Status = EFI_INVALID_PARAMETER;
goto exit;
}
-
+
if (Lba > LAST_BLOCK) {
Status = EFI_INVALID_PARAMETER;
goto exit;
}
-
+
if ((BufferSize % gNandFlashInfo->BlockSize) != 0) {
Status = EFI_BAD_BUFFER_SIZE;
goto exit;
@@ -640,12 +640,12 @@ NandFlashWriteBlocks ( Status = EFI_INVALID_PARAMETER;
goto exit;
}
-
+
if (Lba > LAST_BLOCK) {
Status = EFI_INVALID_PARAMETER;
goto exit;
}
-
+
if ((BufferSize % gNandFlashInfo->BlockSize) != 0) {
Status = EFI_BAD_BUFFER_SIZE;
goto exit;
@@ -668,7 +668,7 @@ NandFlashWriteBlocks ( goto exit;
}
}
-
+
// Program data
Status = NandWriteBlock((UINTN)Lba, EndBlockIndex, Buffer, SpareBuffer);
if (EFI_ERROR(Status)) {
@@ -708,7 +708,7 @@ EFI_BLOCK_IO_MEDIA gNandFlashMedia = { 0 // LastBlock
};
-EFI_BLOCK_IO_PROTOCOL BlockIo =
+EFI_BLOCK_IO_PROTOCOL BlockIo =
{
EFI_BLOCK_IO_INTERFACE_REVISION, // Revision
&gNandFlashMedia, // *Media
@@ -725,7 +725,7 @@ NandFlashInitialize ( )
{
EFI_STATUS Status;
-
+
gNandFlashInfo = (NAND_FLASH_INFO *)AllocateZeroPool (sizeof(NAND_FLASH_INFO));
//Initialize GPMC module.
@@ -764,9 +764,9 @@ NandFlashInitialize ( //Publish BlockIO.
Status = gBS->InstallMultipleProtocolInterfaces (
- &ImageHandle,
+ &ImageHandle,
&gEfiBlockIoProtocolGuid, &BlockIo,
- &gEfiDevicePathProtocolGuid, &gDevicePath,
+ &gEfiDevicePathProtocolGuid, &gDevicePath,
NULL
);
return Status;
diff --git a/Omap35xxPkg/Flash/Flash.inf b/Omap35xxPkg/Flash/Flash.inf index 4f12a27485..36e6fe45eb 100644 --- a/Omap35xxPkg/Flash/Flash.inf +++ b/Omap35xxPkg/Flash/Flash.inf @@ -1,14 +1,14 @@ #/** @file
-#
+#
# Copyright (c) 2008 - 2010, Apple Inc. All rights reserved.<BR>
# This program and the accompanying materials
# are licensed and made available under the terms and conditions of the BSD License
# which accompanies this distribution. The full text of the license may be found at
# http://opensource.org/licenses/bsd-license.php
-#
+#
# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
-#
+#
#**/
[Defines]
@@ -36,7 +36,7 @@ IoLib
[Guids]
-
+
[Protocols]
gEfiBlockIoProtocolGuid
gEfiCpuArchProtocolGuid
@@ -45,4 +45,4 @@ gOmap35xxTokenSpaceGuid.PcdOmap35xxGpmcOffset
[depex]
- TRUE
\ No newline at end of file + TRUE
diff --git a/Omap35xxPkg/Gpio/Gpio.c b/Omap35xxPkg/Gpio/Gpio.c index c64e6be7bb..4d713f7bf5 100644 --- a/Omap35xxPkg/Gpio/Gpio.c +++ b/Omap35xxPkg/Gpio/Gpio.c @@ -1,7 +1,7 @@ /** @file
Copyright (c) 2008 - 2009, Apple Inc. All rights reserved.<BR>
-
+
This program and the accompanying materials
are licensed and made available under the terms and conditions of the BSD License
which accompanies this distribution. The full text of the license may be found at
@@ -129,7 +129,7 @@ GpioInitialize ( )
{
EFI_STATUS Status;
-
+
Status = gBS->InstallMultipleProtocolInterfaces(&ImageHandle, &gEmbeddedGpioProtocolGuid, &Gpio, NULL);
return Status;
}
diff --git a/Omap35xxPkg/Gpio/Gpio.inf b/Omap35xxPkg/Gpio/Gpio.inf index 2069d2d734..a8ffb2e966 100644 --- a/Omap35xxPkg/Gpio/Gpio.inf +++ b/Omap35xxPkg/Gpio/Gpio.inf @@ -1,14 +1,14 @@ #/** @file
-#
+#
# Copyright (c) 2008 - 2010, Apple Inc. All rights reserved.<BR>
# This program and the accompanying materials
# are licensed and made available under the terms and conditions of the BSD License
# which accompanies this distribution. The full text of the license may be found at
# http://opensource.org/licenses/bsd-license.php
-#
+#
# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
-#
+#
#**/
[Defines]
@@ -35,11 +35,11 @@ OmapLib
[Guids]
-
+
[Protocols]
gEmbeddedGpioProtocolGuid
[Pcd]
[depex]
- TRUE
\ No newline at end of file + TRUE
diff --git a/Omap35xxPkg/Include/Library/OmapDmaLib.h b/Omap35xxPkg/Include/Library/OmapDmaLib.h index f13b733796..dfac36f07e 100755 --- a/Omap35xxPkg/Include/Library/OmapDmaLib.h +++ b/Omap35xxPkg/Include/Library/OmapDmaLib.h @@ -1,7 +1,7 @@ /** @file
- Abstractions for simple OMAP DMA.
- OMAP_DMA4 structure elements are described in the OMAP35xx TRM.
+ Abstractions for simple OMAP DMA.
+ OMAP_DMA4 structure elements are described in the OMAP35xx TRM.
Copyright (c) 2008 - 2010, Apple Inc. All rights reserved.<BR>
@@ -46,16 +46,16 @@ typedef struct { } OMAP_DMA4;
-/**
+/**
Configure OMAP DMA Channel
-
+
@param Channel DMA Channel to configure
- @param Dma4 Pointer to structure used to initialize DMA registers for the Channel
-
+ @param Dma4 Pointer to structure used to initialize DMA registers for the Channel
+
@retval EFI_SUCCESS The range was mapped for the returned NumberOfBytes.
@retval EFI_INVALID_PARAMETER Channel is not valid
@retval EFI_DEVICE_ERROR The system hardware could not map the requested information.
-
+
**/
EFI_STATUS
EFIAPI
@@ -64,17 +64,17 @@ EnableDmaChannel ( IN OMAP_DMA4 *Dma4
);
-/**
+/**
Turn of DMA channel configured by EnableDma().
-
+
@param Channel DMA Channel to configure
@param SuccesMask Bits in DMA4_CSR register indicate EFI_SUCCESS
@param ErrorMask Bits in DMA4_CSR register indicate EFI_DEVICE_ERROR
-
+
@retval EFI_SUCCESS DMA hardware disabled
@retval EFI_INVALID_PARAMETER Channel is not valid
@retval EFI_DEVICE_ERROR The system hardware could not map the requested information.
-
+
**/
EFI_STATUS
EFIAPI
@@ -86,5 +86,5 @@ DisableDmaChannel ( -#endif
+#endif
diff --git a/Omap35xxPkg/Include/Library/OmapLib.h b/Omap35xxPkg/Include/Library/OmapLib.h index 80e5e0d2cb..ec14603ccd 100644 --- a/Omap35xxPkg/Include/Library/OmapLib.h +++ b/Omap35xxPkg/Include/Library/OmapLib.h @@ -15,13 +15,13 @@ #ifndef __OMAPLIB_H__
#define __OMAPLIB_H__
-UINT32
+UINT32
EFIAPI
GpioBase (
IN UINTN Port
);
-UINT32
+UINT32
EFIAPI
TimerBase (
IN UINTN Timer
diff --git a/Omap35xxPkg/Include/Omap3530/Omap3530Dma.h b/Omap35xxPkg/Include/Omap3530/Omap3530Dma.h index 5db9a07972..a6e070dda3 100755 --- a/Omap35xxPkg/Include/Omap3530/Omap3530Dma.h +++ b/Omap35xxPkg/Include/Omap3530/Omap3530Dma.h @@ -56,9 +56,9 @@ #define DMA4_CSDP_BURST_EN32 (0x2 << 14)
#define DMA4_CSDP_BURST_EN64 (0x3 << 14)
-#define DMA4_CSDP_WRITE_MODE_NONE_POSTED (0x0 << 16)
+#define DMA4_CSDP_WRITE_MODE_NONE_POSTED (0x0 << 16)
#define DMA4_CSDP_WRITE_MODE_POSTED (0x1 << 16)
-#define DMA4_CSDP_WRITE_MODE_LAST_NON_POSTED (0x2 << 16)
+#define DMA4_CSDP_WRITE_MODE_LAST_NON_POSTED (0x2 << 16)
#define DMA4_CSDP_DST_ENDIAN_LOCK_LOCK BIT18
#define DMA4_CSDP_DST_ENDIAN_LOCK_ADAPT 0
@@ -72,7 +72,7 @@ #define DMA4_CSDP_SRC_ENDIAN_BIG BIT21
#define DMA4_CSDP_SRC_ENDIAN_LITTLE 0
-// Channel Control
+// Channel Control
#define DMA4_CCR_SYNCHRO_CONTROL_MASK 0x1f
#define DMA4_CCR_FS_ELEMENT (0 | 0)
@@ -104,7 +104,7 @@ #define DMA4_CCR_CONST_FILL_ENABLE BIT16
#define DMA4_CCR_TRANSPARENT_COPY_ENABLE BIT17
-
+
#define DMA4_CCR_SEL_SRC_DEST_SYNC_SOURCE BIT24
#define DMA4_CSR_DROP BIT1
@@ -126,5 +126,5 @@ #define DMA4_CICR_ENABLE_ALL 0x1FBE
-#endif
+#endif
diff --git a/Omap35xxPkg/Include/Omap3530/Omap3530MMCHS.h b/Omap35xxPkg/Include/Omap3530/Omap3530MMCHS.h index 5bebe6c509..88b43de480 100644 --- a/Omap35xxPkg/Include/Omap3530/Omap3530MMCHS.h +++ b/Omap35xxPkg/Include/Omap3530/Omap3530MMCHS.h @@ -66,7 +66,7 @@ #define RSP_TYPE_48BITS (0x2UL << 16)
#define CCCE_ENABLE BIT19
#define CICE_ENABLE BIT20
-#define DP_ENABLE BIT21
+#define DP_ENABLE BIT21
#define INDX(CMD_INDX) ((CMD_INDX & 0x3F) << 24)
#define MMCHS_RSP10 (MMCHS1BASE + 0x110)
diff --git a/Omap35xxPkg/Include/Omap3530/Omap3530Prcm.h b/Omap35xxPkg/Include/Omap3530/Omap3530Prcm.h index 3a297d0a98..1871dbb122 100644 --- a/Omap35xxPkg/Include/Omap3530/Omap3530Prcm.h +++ b/Omap35xxPkg/Include/Omap3530/Omap3530Prcm.h @@ -69,7 +69,7 @@ #define CM_CLKSEL_PLL_MULT(x) (((x) & 0x07FF) << 8)
#define CM_CLKSEL_PLL_DIV(x) ((((x) - 1) & 0x7F) << 0)
-
+
#define CM_CLKSEL_DIV_120M(x) (((x) & 0x1F) << 0)
#define CM_FCLKEN_USBHOST_EN_USBHOST2_MASK BIT1
diff --git a/Omap35xxPkg/Include/TPS65950.h b/Omap35xxPkg/Include/TPS65950.h index 20df2319e1..1db8b6db46 100644 --- a/Omap35xxPkg/Include/TPS65950.h +++ b/Omap35xxPkg/Include/TPS65950.h @@ -30,7 +30,7 @@ #define VMMC1_DEV_GRP 0x82
#define DEV_GRP_P1 BIT5
-#define VMMC1_DEDICATED_REG 0x85
+#define VMMC1_DEDICATED_REG 0x85
#define VSEL_1_85V 0x0
#define VSEL_2_85V 0x1
#define VSEL_3_00V 0x2
diff --git a/Omap35xxPkg/InterruptDxe/HardwareInterrupt.c b/Omap35xxPkg/InterruptDxe/HardwareInterrupt.c index 5040c4b152..e9d84aeabb 100644 --- a/Omap35xxPkg/InterruptDxe/HardwareInterrupt.c +++ b/Omap35xxPkg/InterruptDxe/HardwareInterrupt.c @@ -1,8 +1,8 @@ /** @file
- Handle OMAP35xx interrupt controller
+ Handle OMAP35xx interrupt controller
Copyright (c) 2008 - 2010, Apple Inc. All rights reserved.<BR>
-
+
This program and the accompanying materials
are licensed and made available under the terms and conditions of the BSD License
which accompanies this distribution. The full text of the license may be found at
@@ -38,7 +38,7 @@ HARDWARE_INTERRUPT_HANDLER gRegisteredInterruptHandlers[INT_NROF_VECTORS]; /**
Shutdown our hardware
-
+
DXE Core will disable interrupts and turn off the timer and disable interrupts
after all the event handlers have run.
@@ -83,16 +83,16 @@ RegisterInterruptSource ( if (Source > MAX_VECTOR) {
ASSERT(FALSE);
return EFI_UNSUPPORTED;
- }
-
+ }
+
if ((MmioRead32 (INTCPS_ILR(Source)) & INTCPS_ILR_FIQ) == INTCPS_ILR_FIQ) {
// This vector has been programmed as FIQ so we can't use it for IRQ
- // EFI does not use FIQ, but the debugger can use it to check for
+ // EFI does not use FIQ, but the debugger can use it to check for
// ctrl-c. So this ASSERT means you have a conflict with the debug agent
ASSERT (FALSE);
return EFI_UNSUPPORTED;
}
-
+
if ((Handler == NULL) && (gRegisteredInterruptHandlers[Source] == NULL)) {
return EFI_INVALID_PARAMETER;
}
@@ -125,17 +125,17 @@ EnableInterruptSource ( {
UINTN Bank;
UINTN Bit;
-
+
if (Source > MAX_VECTOR) {
ASSERT(FALSE);
return EFI_UNSUPPORTED;
}
-
+
Bank = Source / 32;
Bit = 1UL << (Source % 32);
-
+
MmioWrite32 (INTCPS_MIR_CLEAR(Bank), Bit);
-
+
return EFI_SUCCESS;
}
@@ -159,17 +159,17 @@ DisableInterruptSource ( {
UINTN Bank;
UINTN Bit;
-
+
if (Source > MAX_VECTOR) {
ASSERT(FALSE);
return EFI_UNSUPPORTED;
}
-
+
Bank = Source / 32;
Bit = 1UL << (Source % 32);
-
+
MmioWrite32 (INTCPS_MIR_SET(Bank), Bit);
-
+
return EFI_SUCCESS;
}
@@ -196,11 +196,11 @@ GetInterruptSourceState ( {
UINTN Bank;
UINTN Bit;
-
+
if (InterruptState == NULL) {
return EFI_INVALID_PARAMETER;
}
-
+
if (Source > MAX_VECTOR) {
ASSERT(FALSE);
return EFI_UNSUPPORTED;
@@ -208,18 +208,18 @@ GetInterruptSourceState ( Bank = Source / 32;
Bit = 1UL << (Source % 32);
-
+
if ((MmioRead32(INTCPS_MIR(Bank)) & Bit) == Bit) {
*InterruptState = FALSE;
} else {
*InterruptState = TRUE;
}
-
+
return EFI_SUCCESS;
}
/**
- Signal to the hardware that the End Of Intrrupt state
+ Signal to the hardware that the End Of Intrrupt state
has been reached.
@param This Instance pointer for this protocol
@@ -262,19 +262,19 @@ IrqInterruptHandler ( {
UINT32 Vector;
HARDWARE_INTERRUPT_HANDLER InterruptHandler;
-
+
Vector = MmioRead32 (INTCPS_SIR_IRQ) & INTCPS_SIR_IRQ_MASK;
// Needed to prevent infinite nesting when Time Driver lowers TPL
MmioWrite32 (INTCPS_CONTROL, INTCPS_CONTROL_NEWIRQAGR);
ArmDataSyncronizationBarrier ();
-
+
InterruptHandler = gRegisteredInterruptHandlers[Vector];
if (InterruptHandler != NULL) {
// Call the registered interrupt handler.
InterruptHandler (Vector, SystemContext);
}
-
+
// Needed to clear after running the handler
MmioWrite32 (INTCPS_CONTROL, INTCPS_CONTROL_NEWIRQAGR);
ArmDataSyncronizationBarrier ();
@@ -324,12 +324,12 @@ InterruptDxeInitialize ( MmioWrite32 (INTCPS_MIR(1), 0xFFFFFFFF);
MmioWrite32 (INTCPS_MIR(2), 0xFFFFFFFF);
MmioOr32 (INTCPS_CONTROL, INTCPS_CONTROL_NEWIRQAGR);
-
+
Status = gBS->InstallMultipleProtocolInterfaces(&gHardwareInterruptHandle,
&gHardwareInterruptProtocolGuid, &gHardwareInterruptProtocol,
NULL);
ASSERT_EFI_ERROR(Status);
-
+
//
// Get the CPU protocol that this driver requires.
//
diff --git a/Omap35xxPkg/InterruptDxe/InterruptDxe.inf b/Omap35xxPkg/InterruptDxe/InterruptDxe.inf index 7ecb32e654..6deb8c3f67 100644 --- a/Omap35xxPkg/InterruptDxe/InterruptDxe.inf +++ b/Omap35xxPkg/InterruptDxe/InterruptDxe.inf @@ -1,16 +1,16 @@ #/** @file
-#
+#
# Interrupt DXE driver
-#
+#
# Copyright (c) 2008 - 2010, Apple Inc. All rights reserved.<BR>
# This program and the accompanying materials
# are licensed and made available under the terms and conditions of the BSD License
# which accompanies this distribution. The full text of the license may be found at
# http://opensource.org/licenses/bsd-license.php
-#
+#
# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
-#
+#
#**/
[Defines]
@@ -46,7 +46,7 @@ [Protocols]
gHardwareInterruptProtocolGuid
gEfiCpuArchProtocolGuid
-
+
[FixedPcd.common]
gEmbeddedTokenSpaceGuid.PcdInterruptBaseAddress
diff --git a/Omap35xxPkg/LcdGraphicsOutputDxe/LcdGraphicsOutputBlt.c b/Omap35xxPkg/LcdGraphicsOutputDxe/LcdGraphicsOutputBlt.c index 9541e7e902..4e2e4de7db 100644 --- a/Omap35xxPkg/LcdGraphicsOutputDxe/LcdGraphicsOutputBlt.c +++ b/Omap35xxPkg/LcdGraphicsOutputDxe/LcdGraphicsOutputBlt.c @@ -334,7 +334,7 @@ BltBufferToVideo ( );
}
}
-
+
return Status;
}
@@ -416,7 +416,7 @@ LcdGraphicsBlt ( if (!mDisplayInitialized) {
InitializeDisplay (Instance);
}
-
+
switch (BltOperation) {
case EfiBltVideoFill:
Status = BltVideoFill (This, BltBuffer, SourceX, SourceY, DestinationX, DestinationY, Width, Height, Delta);
diff --git a/Omap35xxPkg/LcdGraphicsOutputDxe/LcdGraphicsOutputDxe.c b/Omap35xxPkg/LcdGraphicsOutputDxe/LcdGraphicsOutputDxe.c index f7d247865d..bfd9f3be43 100644 --- a/Omap35xxPkg/LcdGraphicsOutputDxe/LcdGraphicsOutputDxe.c +++ b/Omap35xxPkg/LcdGraphicsOutputDxe/LcdGraphicsOutputDxe.c @@ -142,14 +142,14 @@ DssSetMode ( )
{
// Make sure the interface clock is running
- MmioWrite32 (CM_ICLKEN_DSS, EN_DSS);
+ MmioWrite32 (CM_ICLKEN_DSS, EN_DSS);
// Stop the functional clocks
MmioAnd32 (CM_FCLKEN_DSS, ~(EN_DSS1 | EN_DSS2 | EN_TV));
// Program the DSS clock divisor
MmioWrite32 (CM_CLKSEL_DSS, 0x1000 | (LcdModes[ModeNumber].DssDivisor));
-
+
// Start the functional clocks
MmioOr32 (CM_FCLKEN_DSS, (EN_DSS1 | EN_DSS2 | EN_TV));
@@ -159,10 +159,10 @@ DssSetMode ( // Reset the subsystem
MmioWrite32(DSS_SYSCONFIG, DSS_SOFTRESET);
while (!(MmioRead32 (DSS_SYSSTATUS) & DSS_RESETDONE));
-
+
// Configure LCD parameters
MmioWrite32 (DISPC_SIZE_LCD,
- ((LcdModes[ModeNumber].HorizontalResolution - 1)
+ ((LcdModes[ModeNumber].HorizontalResolution - 1)
| ((LcdModes[ModeNumber].VerticalResolution - 1) << 16))
);
MmioWrite32 (DISPC_TIMING_H,
@@ -187,7 +187,7 @@ DssSetMode ( MmioWrite32 (DISPC_GFX_PRELD, 0x2D8);
MmioWrite32 (DISPC_GFX_BA0, VramBaseAddress);
MmioWrite32 (DISPC_GFX_SIZE,
- ((LcdModes[ModeNumber].HorizontalResolution - 1)
+ ((LcdModes[ModeNumber].HorizontalResolution - 1)
| ((LcdModes[ModeNumber].VerticalResolution - 1) << 16))
);
@@ -213,7 +213,7 @@ HwInitializeDisplay ( // Enable power lines used by TFP410
Status = gBS->LocateProtocol (&gEmbeddedExternalDeviceProtocolGuid, NULL, (VOID **)&gTPS65950);
- ASSERT_EFI_ERROR (Status);
+ ASSERT_EFI_ERROR (Status);
OldTpl = gBS->RaiseTPL(TPL_NOTIFY);
Data = VAUX_DEV_GRP_P1;
@@ -222,7 +222,7 @@ HwInitializeDisplay ( Data = VAUX_DEDICATED_18V;
Status = gTPS65950->Write (gTPS65950, EXTERNAL_DEVICE_REGISTER(I2C_ADDR_GRP_ID4, VPLL2_DEDICATED), 1, &Data);
- ASSERT_EFI_ERROR (Status);
+ ASSERT_EFI_ERROR (Status);
// Power up TFP410 (set GPIO2 on TPS - for BeagleBoard-xM)
Status = gTPS65950->Read (gTPS65950, EXTERNAL_DEVICE_REGISTER(I2C_ADDR_GRP_ID2, GPIODATADIR1), 1, &Data);
@@ -239,7 +239,7 @@ HwInitializeDisplay ( // Power up TFP410 (set GPIO 170 - for older BeagleBoards)
MmioAnd32 (GPIO6_BASE + GPIO_OE, ~BIT10);
- MmioOr32 (GPIO6_BASE + GPIO_SETDATAOUT, BIT10);
+ MmioOr32 (GPIO6_BASE + GPIO_SETDATAOUT, BIT10);
return EFI_SUCCESS;
}
@@ -249,7 +249,7 @@ InitializeDisplay ( IN LCD_INSTANCE* Instance
)
{
- EFI_STATUS Status;
+ EFI_STATUS Status;
UINTN VramSize;
EFI_PHYSICAL_ADDRESS VramBaseAddress;
diff --git a/Omap35xxPkg/LcdGraphicsOutputDxe/LcdGraphicsOutputDxe.h b/Omap35xxPkg/LcdGraphicsOutputDxe/LcdGraphicsOutputDxe.h index 520e28e670..8b27f3d558 100644 --- a/Omap35xxPkg/LcdGraphicsOutputDxe/LcdGraphicsOutputDxe.h +++ b/Omap35xxPkg/LcdGraphicsOutputDxe/LcdGraphicsOutputDxe.h @@ -144,7 +144,7 @@ LcdGraphicsBlt ( #define LCDENABLE BIT0
#define ACTIVEMATRIX BIT3
#define GOLCD BIT5
-#define DATALINES24 (BIT8 | BIT9)
+#define DATALINES24 (BIT8 | BIT9)
#define LCDENABLESIGNAL BIT28
#define GFXENABLE BIT0
diff --git a/Omap35xxPkg/LcdGraphicsOutputDxe/LcdGraphicsOutputDxe.inf b/Omap35xxPkg/LcdGraphicsOutputDxe/LcdGraphicsOutputDxe.inf index ac026f4356..86fbef42c0 100644 --- a/Omap35xxPkg/LcdGraphicsOutputDxe/LcdGraphicsOutputDxe.inf +++ b/Omap35xxPkg/LcdGraphicsOutputDxe/LcdGraphicsOutputDxe.inf @@ -1,14 +1,14 @@ #/** @file
-#
+#
# Copyright (c) 2011, ARM Ltd. All rights reserved.<BR>
# This program and the accompanying materials
# are licensed and made available under the terms and conditions of the BSD License
# which accompanies this distribution. The full text of the license may be found at
# http://opensource.org/licenses/bsd-license.php
-#
+#
# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
-#
+#
#**/
[Defines]
diff --git a/Omap35xxPkg/Library/DebugAgentTimerLib/DebugAgentTimerLib.c b/Omap35xxPkg/Library/DebugAgentTimerLib/DebugAgentTimerLib.c index b3da7366a9..de849d4fd6 100755 --- a/Omap35xxPkg/Library/DebugAgentTimerLib/DebugAgentTimerLib.c +++ b/Omap35xxPkg/Library/DebugAgentTimerLib/DebugAgentTimerLib.c @@ -2,7 +2,7 @@ Debug Agent timer lib for OMAP 35xx.
Copyright (c) 2008 - 2010, Apple Inc. All rights reserved.<BR>
-
+
This program and the accompanying materials
are licensed and made available under the terms and conditions of the BSD License
which accompanies this distribution. The full text of the license may be found at
@@ -44,7 +44,7 @@ EnableInterruptSource ( Bank = gVector / 32;
Bit = 1UL << (gVector % 32);
-
+
MmioWrite32 (INTCPS_MIR_CLEAR(Bank), Bit);
}
@@ -55,9 +55,9 @@ DisableInterruptSource ( {
UINTN Bank;
UINTN Bit;
-
+
Bank = gVector / 32;
- Bit = 1UL << (gVector % 32);
+ Bit = 1UL << (gVector % 32);
MmioWrite32 (INTCPS_MIR_SET(Bank), Bit);
}
@@ -96,17 +96,17 @@ DebugAgentTimerIntialize ( CpuDeadLoop ();
}
// Set source clock for GPT2 - GPT9 to SYS_CLK
- MmioOr32 (CM_CLKSEL_PER, 1 << (TimerNumber - 2));
+ MmioOr32 (CM_CLKSEL_PER, 1 << (TimerNumber - 2));
}
-
-
+
+
/**
Set the period for the debug agent timer. Zero means disable the timer.
@param[in] TimerPeriodMilliseconds Frequency of the debug agent timer.
-**/
+**/
VOID
EFIAPI
DebugAgentTimerSetPeriod (
@@ -115,13 +115,13 @@ DebugAgentTimerSetPeriod ( {
UINT64 TimerCount;
INT32 LoadValue;
-
+
if (TimerPeriodMilliseconds == 0) {
// Turn off GPTIMER3
MmioWrite32 (gTCLR, TCLR_ST_OFF);
-
+
DisableInterruptSource ();
- } else {
+ } else {
// Calculate required timer count
TimerCount = DivU64x32(TimerPeriodMilliseconds * 1000000, PcdGet32(PcdDebugAgentTimerFreqNanoSeconds));
@@ -139,13 +139,13 @@ DebugAgentTimerSetPeriod ( EnableInterruptSource ();
}
}
-
+
/**
- Perform End Of Interrupt for the debug agent timer. This is called in the
- interrupt handler after the interrupt has been processed.
+ Perform End Of Interrupt for the debug agent timer. This is called in the
+ interrupt handler after the interrupt has been processed.
-**/
+**/
VOID
EFIAPI
DebugAgentTimerEndOfInterrupt (
@@ -153,7 +153,7 @@ DebugAgentTimerEndOfInterrupt ( )
{
// Clear all timer interrupts
- MmioWrite32 (gTISR, TISR_CLEAR_ALL);
+ MmioWrite32 (gTISR, TISR_CLEAR_ALL);
// Poll interrupt status bits to ensure clearing
while ((MmioRead32 (gTISR) & TISR_ALL_INTERRUPT_MASK) != TISR_NO_INTERRUPTS_PENDING);
@@ -163,4 +163,3 @@ DebugAgentTimerEndOfInterrupt ( }
-
\ No newline at end of file diff --git a/Omap35xxPkg/Library/DebugAgentTimerLib/DebugAgentTimerLib.inf b/Omap35xxPkg/Library/DebugAgentTimerLib/DebugAgentTimerLib.inf index 551aee5385..07810d9afd 100755 --- a/Omap35xxPkg/Library/DebugAgentTimerLib/DebugAgentTimerLib.inf +++ b/Omap35xxPkg/Library/DebugAgentTimerLib/DebugAgentTimerLib.inf @@ -33,7 +33,7 @@ EmbeddedPkg/EmbeddedPkg.dec
Omap35xxPkg/Omap35xxPkg.dec
ArmPkg/ArmPkg.dec
-
+
[LibraryClasses]
BaseLib
@@ -44,4 +44,3 @@ [Pcd]
gOmap35xxTokenSpaceGuid.PcdOmap35xxDebugAgentTimer
gOmap35xxTokenSpaceGuid.PcdDebugAgentTimerFreqNanoSeconds
-
\ No newline at end of file diff --git a/Omap35xxPkg/Library/EblCmdLib/EblCmdLib.c b/Omap35xxPkg/Library/EblCmdLib/EblCmdLib.c index c59f75b5be..47161755de 100644 --- a/Omap35xxPkg/Library/EblCmdLib/EblCmdLib.c +++ b/Omap35xxPkg/Library/EblCmdLib/EblCmdLib.c @@ -2,7 +2,7 @@ Add custom commands for BeagleBoard development.
Copyright (c) 2008 - 2009, Apple Inc. All rights reserved.<BR>
-
+
This program and the accompanying materials
are licensed and made available under the terms and conditions of the BSD License
which accompanies this distribution. The full text of the license may be found at
@@ -35,7 +35,7 @@ Argv[0] - "%CommandName%"
@param Argc Number of command arguments in Argv
- @param Argv Array of strings that represent the parsed command line.
+ @param Argv Array of strings that represent the parsed command line.
Argv[0] is the command name
@return EFI_SUCCESS
diff --git a/Omap35xxPkg/Library/EblCmdLib/EblCmdLib.inf b/Omap35xxPkg/Library/EblCmdLib/EblCmdLib.inf index 396444719f..dd7a13cf66 100644 --- a/Omap35xxPkg/Library/EblCmdLib/EblCmdLib.inf +++ b/Omap35xxPkg/Library/EblCmdLib/EblCmdLib.inf @@ -20,7 +20,7 @@ FILE_GUID = ea62bdc3-1063-425f-8851-98cb47f213a8
MODULE_TYPE = UEFI_DRIVER
VERSION_STRING = 1.0
- LIBRARY_CLASS = EblCmdLib|DXE_DRIVER UEFI_APPLICATION UEFI_DRIVER
+ LIBRARY_CLASS = EblCmdLib|DXE_DRIVER UEFI_APPLICATION UEFI_DRIVER
#
@@ -40,9 +40,9 @@ [LibraryClasses]
BaseLib
DebugLib
-
+
[Protocols]
-
+
[Guids]
-
+
[Pcd]
diff --git a/Omap35xxPkg/Library/GdbSerialLib/GdbSerialLib.c b/Omap35xxPkg/Library/GdbSerialLib/GdbSerialLib.c index 54247e42e6..dcc518244a 100644 --- a/Omap35xxPkg/Library/GdbSerialLib/GdbSerialLib.c +++ b/Omap35xxPkg/Library/GdbSerialLib/GdbSerialLib.c @@ -2,7 +2,7 @@ Basic serial IO abstaction for GDB
Copyright (c) 2008 - 2009, Apple Inc. All rights reserved.<BR>
-
+
This program and the accompanying materials
are licensed and made available under the terms and conditions of the BSD License
which accompanies this distribution. The full text of the license may be found at
@@ -33,10 +33,10 @@ GdbSerialLibConstructor ( RETURN_STATUS
EFIAPI
GdbSerialInit (
- IN UINT64 BaudRate,
- IN UINT8 Parity,
- IN UINT8 DataBits,
- IN UINT8 StopBits
+ IN UINT64 BaudRate,
+ IN UINT8 Parity,
+ IN UINT8 DataBits,
+ IN UINT8 StopBits
)
{
return RETURN_SUCCESS;
@@ -46,7 +46,7 @@ BOOLEAN EFIAPI
GdbIsCharAvailable (
VOID
- )
+ )
{
UINT32 LSR = UartBase(PcdGet32(PcdOmap35xxConsoleUart)) + UART_LSR_REG;
@@ -66,7 +66,7 @@ GdbGetChar ( UINT32 LSR = UartBase(PcdGet32(PcdOmap35xxConsoleUart)) + UART_LSR_REG;
UINT32 RBR = UartBase(PcdGet32(PcdOmap35xxConsoleUart)) + UART_RBR_REG;
CHAR8 Char;
-
+
while ((MmioRead8(LSR) & UART_LSR_RX_FIFO_E_MASK) == UART_LSR_RX_FIFO_E_EMPTY);
Char = MmioRead8(RBR);
@@ -81,7 +81,7 @@ GdbPutChar ( {
UINT32 LSR = UartBase(PcdGet32(PcdOmap35xxConsoleUart)) + UART_LSR_REG;
UINT32 THR = UartBase(PcdGet32(PcdOmap35xxConsoleUart)) + UART_THR_REG;
-
+
while ((MmioRead8(LSR) & UART_LSR_TX_FIFO_E_MASK) == UART_LSR_TX_FIFO_E_NOT_EMPTY);
MmioWrite8(THR, Char);
}
diff --git a/Omap35xxPkg/Library/GdbSerialLib/GdbSerialLib.inf b/Omap35xxPkg/Library/GdbSerialLib/GdbSerialLib.inf index 3ab26bb90d..e7aa6c0af0 100644 --- a/Omap35xxPkg/Library/GdbSerialLib/GdbSerialLib.inf +++ b/Omap35xxPkg/Library/GdbSerialLib/GdbSerialLib.inf @@ -1,14 +1,14 @@ #/** @file
-#
+#
# Copyright (c) 2008 - 2010, Apple Inc. All rights reserved.<BR>
# This program and the accompanying materials
# are licensed and made available under the terms and conditions of the BSD License
# which accompanies this distribution. The full text of the license may be found at
# http://opensource.org/licenses/bsd-license.php
-#
+#
# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
-#
+#
#**/
[Defines]
@@ -34,7 +34,7 @@ [LibraryClasses]
DebugLib
IoLib
- OmapLib
+ OmapLib
[FixedPcd]
gOmap35xxTokenSpaceGuid.PcdOmap35xxConsoleUart
diff --git a/Omap35xxPkg/Library/Omap35xxTimerLib/Omap35xxTimerLib.inf b/Omap35xxPkg/Library/Omap35xxTimerLib/Omap35xxTimerLib.inf index 3afeeae53c..35086b1045 100644 --- a/Omap35xxPkg/Library/Omap35xxTimerLib/Omap35xxTimerLib.inf +++ b/Omap35xxPkg/Library/Omap35xxTimerLib/Omap35xxTimerLib.inf @@ -23,7 +23,7 @@ FILE_GUID = fe1d7183-9abb-42ce-9a3b-36d7c6a8959f
MODULE_TYPE = BASE
VERSION_STRING = 1.0
- LIBRARY_CLASS = TimerLib
+ LIBRARY_CLASS = TimerLib
[Sources.common]
TimerLib.c
diff --git a/Omap35xxPkg/Library/Omap35xxTimerLib/TimerLib.c b/Omap35xxPkg/Library/Omap35xxTimerLib/TimerLib.c index 0b61020805..652c47b6f6 100644 --- a/Omap35xxPkg/Library/Omap35xxTimerLib/TimerLib.c +++ b/Omap35xxPkg/Library/Omap35xxTimerLib/TimerLib.c @@ -1,7 +1,7 @@ /** @file
Copyright (c) 2008 - 2009, Apple Inc. All rights reserved.<BR>
-
+
This program and the accompanying materials
are licensed and made available under the terms and conditions of the BSD License
which accompanies this distribution. The full text of the license may be found at
@@ -61,10 +61,10 @@ MicroSecondDelay ( )
{
UINT64 NanoSeconds;
-
+
NanoSeconds = MultU64x32(MicroSeconds, 1000);
- while (NanoSeconds > (UINTN)-1) {
+ while (NanoSeconds > (UINTN)-1) {
NanoSecondDelay((UINTN)-1);
NanoSeconds -= (UINTN)-1;
}
@@ -87,12 +87,12 @@ NanoSecondDelay ( UINT32 TimerCountRegister;
Delay = (NanoSeconds / PcdGet32(PcdEmbeddedPerformanceCounterPeriodInNanoseconds)) + 1;
-
+
TimerCountRegister = TimerBase(PcdGet32(PcdOmap35xxFreeTimer)) + GPTIMER_TCRR;
StartTime = MmioRead32 (TimerCountRegister);
- do
+ do
{
CurrentTime = MmioRead32 (TimerCountRegister);
ElapsedTime = CurrentTime - StartTime;
@@ -108,7 +108,7 @@ EFIAPI GetPerformanceCounter (
VOID
)
-{
+{
return (UINT64)MmioRead32 (TimerBase(PcdGet32(PcdOmap35xxFreeTimer)) + GPTIMER_TCRR);
}
@@ -123,11 +123,11 @@ GetPerformanceCounterProperties ( // Timer starts with the reload value
*StartValue = (UINT64)MmioRead32 (TimerBase(PcdGet32(PcdOmap35xxFreeTimer)) + GPTIMER_TLDR);
}
-
+
if (EndValue != NULL) {
// Timer counts up to 0xFFFFFFFF
*EndValue = 0xFFFFFFFF;
}
-
+
return PcdGet64(PcdEmbeddedPerformanceCounterFrequencyInHz);
}
diff --git a/Omap35xxPkg/Library/OmapDmaLib/OmapDmaLib.c b/Omap35xxPkg/Library/OmapDmaLib/OmapDmaLib.c index d1183129a6..41cfefbebc 100755 --- a/Omap35xxPkg/Library/OmapDmaLib/OmapDmaLib.c +++ b/Omap35xxPkg/Library/OmapDmaLib/OmapDmaLib.c @@ -1,9 +1,9 @@ /** @file
Abstractions for simple OMAP DMA channel.
-
+
Copyright (c) 2008 - 2010, Apple Inc. All rights reserved.<BR>
-
+
This program and the accompanying materials
are licensed and made available under the terms and conditions of the BSD License
which accompanies this distribution. The full text of the license may be found at
@@ -22,16 +22,16 @@ #include <Omap3530/Omap3530.h>
-/**
+/**
Configure OMAP DMA Channel
-
+
@param Channel DMA Channel to configure
- @param Dma4 Pointer to structure used to initialize DMA registers for the Channel
-
+ @param Dma4 Pointer to structure used to initialize DMA registers for the Channel
+
@retval EFI_SUCCESS The range was mapped for the returned NumberOfBytes.
@retval EFI_INVALID_PARAMETER Channel is not valid
@retval EFI_DEVICE_ERROR The system hardware could not map the requested information.
-
+
**/
EFI_STATUS
EFIAPI
@@ -50,13 +50,13 @@ EnableDmaChannel ( /* 1) Configure the transfer parameters in the logical DMA registers */
/*-------------------------------------------------------------------*/
- /* a) Set the data type CSDP[1:0], the Read/Write Port access type
- CSDP[8:7]/[15:14], the Source/dest endianism CSDP[21]/CSDP[19],
+ /* a) Set the data type CSDP[1:0], the Read/Write Port access type
+ CSDP[8:7]/[15:14], the Source/dest endianism CSDP[21]/CSDP[19],
write mode CSDP[17:16], source/dest packed or nonpacked CSDP[6]/CSDP[13] */
-
+
// Read CSDP
RegVal = MmioRead32 (DMA4_CSDP (Channel));
-
+
// Build reg
RegVal = ((RegVal & ~ 0x3) | DMA4->DataType );
RegVal = ((RegVal & ~(0x3 << 7)) | (DMA4->ReadPortAccessType << 7));
@@ -68,23 +68,23 @@ EnableDmaChannel ( RegVal = ((RegVal & ~(0x1 << 13)) | (DMA4->DestinationPacked << 13));
// Write CSDP
MmioWrite32 (DMA4_CSDP (Channel), RegVal);
-
+
/* b) Set the number of element per frame CEN[23:0]*/
MmioWrite32 (DMA4_CEN (Channel), DMA4->NumberOfElementPerFrame);
-
+
/* c) Set the number of frame per block CFN[15:0]*/
MmioWrite32 (DMA4_CFN (Channel), DMA4->NumberOfFramePerTransferBlock);
-
+
/* d) Set the Source/dest start address index CSSA[31:0]/CDSA[31:0]*/
MmioWrite32 (DMA4_CSSA (Channel), DMA4->SourceStartAddress);
MmioWrite32 (DMA4_CDSA (Channel), DMA4->DestinationStartAddress);
-
+
/* e) Set the Read Port addressing mode CCR[13:12], the Write Port addressing mode CCR[15:14],
read/write priority CCR[6]/CCR[26]
- I changed LCH CCR[20:19]=00 and CCR[4:0]=00000 to
+ I changed LCH CCR[20:19]=00 and CCR[4:0]=00000 to
LCH CCR[20:19]= DMA4->WriteRequestNumber and CCR[4:0]=DMA4->ReadRequestNumber
*/
-
+
// Read CCR
RegVal = MmioRead32 (DMA4_CCR (Channel));
@@ -95,13 +95,13 @@ EnableDmaChannel ( RegVal = ((RegVal & ~(0x3 << 14)) | (DMA4->WritePortAccessMode << 14));
RegVal = ((RegVal & ~(0x1 << 6)) | (DMA4->ReadPriority << 6));
RegVal = ((RegVal & ~(0x1 << 26)) | (DMA4->WritePriority << 26));
-
+
// Write CCR
MmioWrite32 (DMA4_CCR (Channel), RegVal);
-
+
/* f)- Set the source element index CSEI[15:0]*/
MmioWrite32 (DMA4_CSEI (Channel), DMA4->SourceElementIndex);
-
+
/* - Set the source frame index CSFI[15:0]*/
MmioWrite32 (DMA4_CSFI (Channel), DMA4->SourceFrameIndex);
@@ -111,7 +111,7 @@ EnableDmaChannel ( /* - Set the destination frame index CDFI[31:0]*/
MmioWrite32 (DMA4_CDFI (Channel), DMA4->DestinationFrameIndex);
-
+
MmioWrite32 (DMA4_CDFI (Channel), DMA4->DestinationFrameIndex);
// Enable all the status bits since we are polling
@@ -126,17 +126,17 @@ EnableDmaChannel ( return EFI_SUCCESS;
}
-/**
+/**
Turn of DMA channel configured by EnableDma().
-
+
@param Channel DMA Channel to configure
@param SuccesMask Bits in DMA4_CSR register indicate EFI_SUCCESS
@param ErrorMask Bits in DMA4_CSR register indicate EFI_DEVICE_ERROR
-
+
@retval EFI_SUCCESS DMA hardware disabled
@retval EFI_INVALID_PARAMETER Channel is not valid
@retval EFI_DEVICE_ERROR The system hardware could not map the requested information.
-
+
**/
EFI_STATUS
EFIAPI
@@ -168,7 +168,7 @@ DisableDmaChannel ( MmioWrite32 (DMA4_CICR (Channel), 0);
MmioWrite32 (DMA4_CSR (Channel), DMA4_CSR_RESET);
- MmioAnd32 (DMA4_CCR(0), ~(DMA4_CCR_ENABLE | DMA4_CCR_RD_ACTIVE | DMA4_CCR_WR_ACTIVE));
+ MmioAnd32 (DMA4_CCR(0), ~(DMA4_CCR_ENABLE | DMA4_CCR_RD_ACTIVE | DMA4_CCR_WR_ACTIVE));
return Status;
}
diff --git a/Omap35xxPkg/Library/OmapDmaLib/OmapDmaLib.inf b/Omap35xxPkg/Library/OmapDmaLib/OmapDmaLib.inf index d94ddf9867..b569cfbdef 100755 --- a/Omap35xxPkg/Library/OmapDmaLib/OmapDmaLib.inf +++ b/Omap35xxPkg/Library/OmapDmaLib/OmapDmaLib.inf @@ -1,14 +1,14 @@ #/** @file
-#
+#
# Copyright (c) 2008 - 2010, Apple Inc. All rights reserved.<BR>
# This program and the accompanying materials
# are licensed and made available under the terms and conditions of the BSD License
# which accompanies this distribution. The full text of the license may be found at
# http://opensource.org/licenses/bsd-license.php
-#
+#
# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
-#
+#
#**/
[Defines]
@@ -17,7 +17,7 @@ FILE_GUID = 09B17D99-BB07-49a8-B0D2-06D6AFCBE3AB
MODULE_TYPE = UEFI_DRIVER
VERSION_STRING = 1.0
- LIBRARY_CLASS = OmapDmaLib
+ LIBRARY_CLASS = OmapDmaLib
[Sources.common]
@@ -37,14 +37,14 @@ IoLib
BaseMemoryLib
ArmLib
-
-
+
+
[Protocols]
gEfiCpuArchProtocolGuid
-
+
[Guids]
-
+
[Pcd]
[Depex]
- gEfiCpuArchProtocolGuid
\ No newline at end of file + gEfiCpuArchProtocolGuid
diff --git a/Omap35xxPkg/Library/OmapLib/OmapLib.c b/Omap35xxPkg/Library/OmapLib/OmapLib.c index 4a6bc65d16..29645ee55a 100644 --- a/Omap35xxPkg/Library/OmapLib/OmapLib.c +++ b/Omap35xxPkg/Library/OmapLib/OmapLib.c @@ -1,7 +1,7 @@ /** @file
Copyright (c) 2008 - 2009, Apple Inc. All rights reserved.<BR>
-
+
This program and the accompanying materials
are licensed and made available under the terms and conditions of the BSD License
which accompanies this distribution. The full text of the license may be found at
@@ -17,7 +17,7 @@ #include <Library/OmapLib.h>
#include <Omap3530/Omap3530.h>
-UINT32
+UINT32
GpioBase (
IN UINTN Port
)
diff --git a/Omap35xxPkg/Library/OmapLib/OmapLib.inf b/Omap35xxPkg/Library/OmapLib/OmapLib.inf index 6de796910e..96eee09ab4 100644 --- a/Omap35xxPkg/Library/OmapLib/OmapLib.inf +++ b/Omap35xxPkg/Library/OmapLib/OmapLib.inf @@ -1,14 +1,14 @@ #/** @file
-#
+#
# Copyright (c) 2008 - 2010, Apple Inc. All rights reserved.<BR>
# This program and the accompanying materials
# are licensed and made available under the terms and conditions of the BSD License
# which accompanies this distribution. The full text of the license may be found at
# http://opensource.org/licenses/bsd-license.php
-#
+#
# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
-#
+#
#**/
[Defines]
@@ -17,7 +17,7 @@ FILE_GUID = d035f5c2-1b92-4746-9f6c-5ff6202970df
MODULE_TYPE = UEFI_DRIVER
VERSION_STRING = 1.0
- LIBRARY_CLASS = OmapLib
+ LIBRARY_CLASS = OmapLib
[Sources.common]
OmapLib.c
@@ -29,9 +29,9 @@ [LibraryClasses]
DebugLib
-
+
[Protocols]
-
+
[Guids]
-
+
[Pcd]
diff --git a/Omap35xxPkg/Library/RealTimeClockLib/RealTimeClockLib.c b/Omap35xxPkg/Library/RealTimeClockLib/RealTimeClockLib.c index 0b9c70bc57..0ae452ebd7 100755 --- a/Omap35xxPkg/Library/RealTimeClockLib/RealTimeClockLib.c +++ b/Omap35xxPkg/Library/RealTimeClockLib/RealTimeClockLib.c @@ -1,14 +1,14 @@ /** @file
*
* Copyright (c) 2011, ARM Limited. All rights reserved.
-*
-* This program and the accompanying materials
-* are licensed and made available under the terms and conditions of the BSD License
-* which accompanies this distribution. The full text of the license may be found at
-* http://opensource.org/licenses/bsd-license.php
*
-* THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
-* WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
+* This program and the accompanying materials
+* are licensed and made available under the terms and conditions of the BSD License
+* which accompanies this distribution. The full text of the license may be found at
+* http://opensource.org/licenses/bsd-license.php
+*
+* THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
+* WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
*
**/
diff --git a/Omap35xxPkg/Library/RealTimeClockLib/RealTimeClockLib.inf b/Omap35xxPkg/Library/RealTimeClockLib/RealTimeClockLib.inf index 7c4911c385..8b49638c23 100755 --- a/Omap35xxPkg/Library/RealTimeClockLib/RealTimeClockLib.inf +++ b/Omap35xxPkg/Library/RealTimeClockLib/RealTimeClockLib.inf @@ -1,17 +1,17 @@ # Copyright (c) 2011, ARM Limited. All rights reserved.
-#
-# This program and the accompanying materials
-# are licensed and made available under the terms and conditions of the BSD License
-# which accompanies this distribution. The full text of the license may be found at
-# http://opensource.org/licenses/bsd-license.php
#
-# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
-# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
+# This program and the accompanying materials
+# are licensed and made available under the terms and conditions of the BSD License
+# which accompanies this distribution. The full text of the license may be found at
+# http://opensource.org/licenses/bsd-license.php
+#
+# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
+# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
#
[Defines]
INF_VERSION = 0x00010005
- BASE_NAME = RealTimeClockLib
+ BASE_NAME = RealTimeClockLib
FILE_GUID = EC1713DB-7DB5-4c99-8FE2-6F52F95A1132
MODULE_TYPE = BASE
VERSION_STRING = 1.0
@@ -24,7 +24,7 @@ MdePkg/MdePkg.dec
EmbeddedPkg/EmbeddedPkg.dec
Omap35xxPkg/Omap35xxPkg.dec
-
+
[LibraryClasses]
IoLib
UefiLib
diff --git a/Omap35xxPkg/Library/ResetSystemLib/ResetSystemLib.c b/Omap35xxPkg/Library/ResetSystemLib/ResetSystemLib.c index 42a73f2b18..82f04eaad1 100644 --- a/Omap35xxPkg/Library/ResetSystemLib/ResetSystemLib.c +++ b/Omap35xxPkg/Library/ResetSystemLib/ResetSystemLib.c @@ -1,11 +1,11 @@ /** @file
Template library implementation to support ResetSystem Runtime call.
-
+
Fill in the templates with what ever makes you system reset.
Copyright (c) 2008 - 2009, Apple Inc. All rights reserved.<BR>
-
+
This program and the accompanying materials
are licensed and made available under the terms and conditions of the BSD License
which accompanies this distribution. The full text of the license may be found at
@@ -66,7 +66,7 @@ LibResetSystem ( ASSERT (FALSE);
return EFI_DEVICE_ERROR;
}
-
+
/**
@@ -74,7 +74,7 @@ LibResetSystem ( @param ImageHandle The firmware allocated handle for the EFI image.
@param SystemTable A pointer to the EFI System Table.
-
+
@retval EFI_SUCCESS The constructor always returns EFI_SUCCESS.
**/
diff --git a/Omap35xxPkg/Library/ResetSystemLib/ResetSystemLib.inf b/Omap35xxPkg/Library/ResetSystemLib/ResetSystemLib.inf index 8f1c79f17d..3ca5c51820 100644 --- a/Omap35xxPkg/Library/ResetSystemLib/ResetSystemLib.inf +++ b/Omap35xxPkg/Library/ResetSystemLib/ResetSystemLib.inf @@ -34,7 +34,7 @@ [Pcd.common]
gArmTokenSpaceGuid.PcdCpuResetAddress
gEmbeddedTokenSpaceGuid.PcdEmbeddedFdBaseAddress
-
+
[LibraryClasses]
DebugLib
BeagleBoardSystemLib
diff --git a/Omap35xxPkg/Library/SerialPortLib/SerialPortLib.c b/Omap35xxPkg/Library/SerialPortLib/SerialPortLib.c index 2f93140e4c..58f70d5512 100644 --- a/Omap35xxPkg/Library/SerialPortLib/SerialPortLib.c +++ b/Omap35xxPkg/Library/SerialPortLib/SerialPortLib.c @@ -3,7 +3,7 @@ Copyright (c) 2008 - 2009, Apple Inc. All rights reserved.<BR>
-
+
This program and the accompanying materials
are licensed and made available under the terms and conditions of the BSD License
which accompanies this distribution. The full text of the license may be found at
@@ -59,7 +59,7 @@ SerialPortWrite ( UINT32 LSR = UartBase(PcdGet32(PcdOmap35xxConsoleUart)) + UART_LSR_REG;
UINT32 THR = UartBase(PcdGet32(PcdOmap35xxConsoleUart)) + UART_THR_REG;
UINTN Count;
-
+
for (Count = 0; Count < NumberOfBytes; Count++, Buffer++) {
while ((MmioRead8(LSR) & UART_LSR_TX_FIFO_E_MASK) == UART_LSR_TX_FIFO_E_NOT_EMPTY);
MmioWrite8(THR, *Buffer);
@@ -89,7 +89,7 @@ SerialPortRead ( UINT32 LSR = UartBase(PcdGet32(PcdOmap35xxConsoleUart)) + UART_LSR_REG;
UINT32 RBR = UartBase(PcdGet32(PcdOmap35xxConsoleUart)) + UART_RBR_REG;
UINTN Count;
-
+
for (Count = 0; Count < NumberOfBytes; Count++, Buffer++) {
while ((MmioRead8(LSR) & UART_LSR_RX_FIFO_E_MASK) == UART_LSR_RX_FIFO_E_EMPTY);
*Buffer = MmioRead8(RBR);
diff --git a/Omap35xxPkg/Library/SerialPortLib/SerialPortLib.inf b/Omap35xxPkg/Library/SerialPortLib/SerialPortLib.inf index 340f4a6a4d..45402e4006 100644 --- a/Omap35xxPkg/Library/SerialPortLib/SerialPortLib.inf +++ b/Omap35xxPkg/Library/SerialPortLib/SerialPortLib.inf @@ -38,7 +38,7 @@ EmbeddedPkg/EmbeddedPkg.dec
MdePkg/MdePkg.dec
Omap35xxPkg/Omap35xxPkg.dec
-
+
[FixedPcd]
gOmap35xxTokenSpaceGuid.PcdOmap35xxConsoleUart
diff --git a/Omap35xxPkg/MMCHSDxe/MMCHS.c b/Omap35xxPkg/MMCHSDxe/MMCHS.c index 3d0a7c6067..9f0ebe0f65 100644 --- a/Omap35xxPkg/MMCHSDxe/MMCHS.c +++ b/Omap35xxPkg/MMCHSDxe/MMCHS.c @@ -2,15 +2,15 @@ MMC/SD Card driver for OMAP 35xx (SDIO not supported)
This driver always produces a BlockIo protocol but it starts off with no Media
- present. A TimerCallBack detects when media is inserted or removed and after
- a media change event a call to BlockIo ReadBlocks/WriteBlocks will cause the
+ present. A TimerCallBack detects when media is inserted or removed and after
+ a media change event a call to BlockIo ReadBlocks/WriteBlocks will cause the
media to be detected (or removed) and the BlockIo Media structure will get
updated. No MMC/SD Card harward registers are updated until the first BlockIo
- ReadBlocks/WriteBlocks after media has been insterted (booting with a card
- plugged in counts as an insertion event).
+ ReadBlocks/WriteBlocks after media has been insterted (booting with a card
+ plugged in counts as an insertion event).
Copyright (c) 2008 - 2009, Apple Inc. All rights reserved.<BR>
-
+
This program and the accompanying materials
are licensed and made available under the terms and conditions of the BSD License
which accompanies this distribution. The full text of the license may be found at
@@ -47,7 +47,7 @@ MMCHS_DEVICE_PATH gMmcHsDevicePath = { HW_VENDOR_DP,
(UINT8)(sizeof(VENDOR_DEVICE_PATH)),
(UINT8)((sizeof(VENDOR_DEVICE_PATH)) >> 8),
- 0xb615f1f5, 0x5088, 0x43cd, 0x80, 0x9c, 0xa1, 0x6e, 0x52, 0x48, 0x7d, 0x00
+ 0xb615f1f5, 0x5088, 0x43cd, 0x80, 0x9c, 0xa1, 0x6e, 0x52, 0x48, 0x7d, 0x00
},
{
END_DEVICE_PATH_TYPE,
@@ -68,8 +68,8 @@ BOOLEAN gMediaChange = FALSE; VOID
ParseCardCIDData (
- UINT32 Response0,
- UINT32 Response1,
+ UINT32 Response0,
+ UINT32 Response1,
UINT32 Response2,
UINT32 Response3
)
@@ -96,7 +96,7 @@ UpdateMMCHSClkFrequency ( MmioAnd32 (MMCHS_SYSCTL, ~CEN);
//Set new clock frequency.
- MmioAndThenOr32 (MMCHS_SYSCTL, ~CLKD_MASK, NewCLKD << 6);
+ MmioAndThenOr32 (MMCHS_SYSCTL, ~CLKD_MASK, NewCLKD << 6);
//Poll till Internal Clock Stable
while ((MmioRead32 (MMCHS_SYSCTL) & ICS_MASK) != ICS);
@@ -359,7 +359,7 @@ InitializeMMCHS ( Data = VSEL_3_00V;
Status = gTPS65950->Write (gTPS65950, EXTERNAL_DEVICE_REGISTER(I2C_ADDR_GRP_ID4, VMMC1_DEDICATED_REG), 1, &Data);
ASSERT_EFI_ERROR(Status);
-
+
//After ramping up voltage, set VDDS stable bit to indicate that voltage level is stable.
MmioOr32 (CONTROL_PBIAS_LITE, (PBIASLITEVMODE0 | PBIASLITEPWRDNZ0 | PBIASSPEEDCTRL0 | PBIASLITEVMODE1 | PBIASLITEWRDNZ1));
@@ -424,13 +424,13 @@ PerformCardIdenfication ( DEBUG ((EFI_D_INFO, "CMD0 response: %x\n", MmioRead32 (MMCHS_RSP10)));
- //Send CMD5 command.
+ //Send CMD5 command.
Status = SendCmd (CMD5, CMD5_INT_EN, CmdArgument);
if (Status == EFI_SUCCESS) {
DEBUG ((EFI_D_ERROR, "CMD5 Success. SDIO card. Follow SDIO card specification.\n"));
DEBUG ((EFI_D_INFO, "CMD5 response: %x\n", MmioRead32 (MMCHS_RSP10)));
//NOTE: Returning unsupported error for now. Need to implement SDIO specification.
- return EFI_UNSUPPORTED;
+ return EFI_UNSUPPORTED;
} else {
DEBUG ((EFI_D_INFO, "CMD5 fails. Not an SDIO card.\n"));
}
@@ -462,7 +462,7 @@ PerformCardIdenfication ( //Poll till card is busy
while (RetryCount < MAX_RETRY_COUNT) {
- //Send CMD55 command.
+ //Send CMD55 command.
CmdArgument = 0;
Status = SendCmd (CMD55, CMD55_INT_EN, CmdArgument);
if (Status == EFI_SUCCESS) {
@@ -616,7 +616,7 @@ PerformCardConfiguration ( if ((gCardInfo.CardType != UNKNOWN_CARD) && (gCardInfo.CardType != MMC_CARD)) {
// We could read SCR register, but SD Card Phys spec stats any SD Card shall
// set SCR.SD_BUS_WIDTHS to support 4-bit mode, so why bother?
-
+
// Send ACMD6 (application specific commands must be prefixed with CMD55)
Status = SendCmd (CMD55, CMD55_INT_EN, CmdArgument);
if (!EFI_ERROR (Status)) {
@@ -759,11 +759,11 @@ CpuDeadLoop (); }
ZeroMem (&DmaOperation, sizeof (DMA_MAP_OPERATION));
-
+
Dma4.DataType = 2; // DMA4_CSDPi[1:0] 32-bit elements from MMCHS_DATA
- Dma4.SourceEndiansim = 0; // DMA4_CSDPi[21]
+ Dma4.SourceEndiansim = 0; // DMA4_CSDPi[21]
Dma4.DestinationEndianism = 0; // DMA4_CSDPi[19]
@@ -771,11 +771,11 @@ CpuDeadLoop (); Dma4.DestinationPacked = 0; // DMA4_CSDPi[13]
- Dma4.NumberOfElementPerFrame = This->Media->BlockSize/4; // DMA4_CENi (TRM 4K is optimum value)
+ Dma4.NumberOfElementPerFrame = This->Media->BlockSize/4; // DMA4_CENi (TRM 4K is optimum value)
- Dma4.NumberOfFramePerTransferBlock = BlockCount; // DMA4_CFNi
+ Dma4.NumberOfFramePerTransferBlock = BlockCount; // DMA4_CFNi
- Dma4.ReadPriority = 0; // DMA4_CCRi[6] Low priority read
+ Dma4.ReadPriority = 0; // DMA4_CCRi[6] Low priority read
Dma4.WritePriority = 0; // DMA4_CCRi[23] Prefetech disabled
@@ -792,7 +792,7 @@ CpuDeadLoop (); Dma4.WriteMode = 1; // DMA4_CSDPi[17:16] Write posted
-
+
Dma4.SourceStartAddress = MMCHS_DATA; // DMA4_CSSAi
@@ -812,11 +812,11 @@ CpuDeadLoop (); Dma4.WritePortAccessMode = 1; // DMA4_CCRi[15:14] Post increment memory address
- Dma4.ReadRequestNumber = 0x1e; // DMA4_CCRi[4:0] Syncro with MMCA_DMA_RX (61)
+ Dma4.ReadRequestNumber = 0x1e; // DMA4_CCRi[4:0] Syncro with MMCA_DMA_RX (61)
Dma4.WriteRequestNumber = 1; // DMA4_CCRi[20:19] Syncro upper 0x3e == 62 (one based)
- } else if (OperationType == WRITE) {
+ } else if (OperationType == WRITE) {
Cmd = CMD25; //Multiple block write
CmdInterruptEnable = CMD25_INT_EN;
DmaOperation = MapOperationBusMasterRead;
@@ -827,7 +827,7 @@ CpuDeadLoop (); Dma4.WriteMode = 1; // DMA4_CSDPi[17:16] Write posted ???
-
+
Dma4.SourceStartAddress = (UINT32)BufferAddress; // DMA4_CSSAi
@@ -847,7 +847,7 @@ CpuDeadLoop (); Dma4.WritePortAccessMode = 0; // DMA4_CCRi[15:14] Always write MMCHS_DATA
- Dma4.ReadRequestNumber = 0x1d; // DMA4_CCRi[4:0] Syncro with MMCA_DMA_TX (60)
+ Dma4.ReadRequestNumber = 0x1d; // DMA4_CCRi[4:0] Syncro with MMCA_DMA_TX (60)
Dma4.WriteRequestNumber = 1; // DMA4_CCRi[20:19] Syncro upper 0x3d == 61 (one based)
@@ -857,7 +857,7 @@ CpuDeadLoop (); EnableDmaChannel (2, &Dma4);
-
+
//Set command argument based on the card access mode (Byte mode or Block mode)
if (gCardInfo.OCRData.AccessMode & BIT1) {
@@ -899,7 +899,7 @@ CpuDeadLoop (); }
}
RetryCount++;
- }
+ }
DisableDmaChannel (2, DMA4_CSR_BLOCK, DMA4_CSR_ERR);
Status = DmaUnmap (BufferMap);
@@ -933,7 +933,7 @@ TransferBlock ( if (OperationType == READ) {
Cmd = CMD17; //Single block read
CmdInterruptEnable = CMD18_INT_EN;
- } else if (OperationType == WRITE) {
+ } else if (OperationType == WRITE) {
Cmd = CMD24; //Single block write
CmdInterruptEnable = CMD24_INT_EN;
}
@@ -991,7 +991,7 @@ TransferBlock ( }
}
RetryCount++;
- }
+ }
if (RetryCount == MAX_RETRY_COUNT) {
DEBUG ((EFI_D_ERROR, "TransferBlockData timed out.\n"));
@@ -1083,13 +1083,13 @@ DetectCard ( DEBUG ((EFI_D_ERROR, "No MMC/SD card detected.\n"));
return Status;
}
-
+
//Get CSD (Card specific data) for the detected card.
Status = GetCardSpecificData();
if (EFI_ERROR(Status)) {
return Status;
}
-
+
//Configure the card in data transfer mode.
Status = PerformCardConfiguration();
if (EFI_ERROR(Status)) {
@@ -1100,8 +1100,8 @@ DetectCard ( gMMCHSMedia.LastBlock = (gCardInfo.NumBlocks - 1);
gMMCHSMedia.BlockSize = gCardInfo.BlockSize;
gMMCHSMedia.ReadOnly = (MmioRead32 (GPIO1_BASE + GPIO_DATAIN) & BIT23) == BIT23;
- gMMCHSMedia.MediaPresent = TRUE;
- gMMCHSMedia.MediaId++;
+ gMMCHSMedia.MediaPresent = TRUE;
+ gMMCHSMedia.MediaId++;
DEBUG ((EFI_D_INFO, "SD Card Media Change on Handle 0x%08x\n", gImageHandle));
@@ -1113,8 +1113,8 @@ DetectCard ( EFI_STATUS
SdReadWrite (
IN EFI_BLOCK_IO_PROTOCOL *This,
- IN UINTN Lba,
- OUT VOID *Buffer,
+ IN UINTN Lba,
+ OUT VOID *Buffer,
IN UINTN BufferSize,
IN OPERATION_TYPE OperationType
)
@@ -1129,7 +1129,7 @@ SdReadWrite ( BOOLEAN Update;
-
+
Update = FALSE;
if (gMediaChange) {
@@ -1140,7 +1140,7 @@ SdReadWrite ( gMMCHSMedia.MediaPresent = FALSE;
gMMCHSMedia.LastBlock = 0;
gMMCHSMedia.BlockSize = 512; // Should be zero but there is a bug in DiskIo
- gMMCHSMedia.ReadOnly = FALSE;
+ gMMCHSMedia.ReadOnly = FALSE;
}
gMediaChange = FALSE;
} else if (!gMMCHSMedia.MediaPresent) {
@@ -1172,7 +1172,7 @@ SdReadWrite ( Status = EFI_INVALID_PARAMETER;
goto Done;
}
-
+
if ((BufferSize % This->Media->BlockSize) != 0) {
Status = EFI_BAD_BUFFER_SIZE;
goto Done;
@@ -1258,7 +1258,7 @@ MMCHSReset ( IN BOOLEAN ExtendedVerification
)
{
- return EFI_SUCCESS;
+ return EFI_SUCCESS;
}
@@ -1292,7 +1292,7 @@ MMCHSReset ( @retval EFI_BAD_BUFFER_SIZE The Buffer was not a multiple of the block size of the device.
- @retval EFI_INVALID_PARAMETER The read request contains LBAs that are not valid,
+ @retval EFI_INVALID_PARAMETER The read request contains LBAs that are not valid,
or the buffer is not on proper alignment.
@@ -1351,7 +1351,7 @@ MMCHSReadBlocks ( @retval EFI_BAD_BUFFER_SIZE The Buffer was not a multiple of the block size of the device.
- @retval EFI_INVALID_PARAMETER The write request contains LBAs that are not valid,
+ @retval EFI_INVALID_PARAMETER The write request contains LBAs that are not valid,
or the buffer is not on proper alignment.
@@ -1422,7 +1422,7 @@ EFI_BLOCK_IO_PROTOCOL gBlockIo = { Timer callback to convert card present hardware into a boolean that indicates
- a media change event has happened. If you just check the GPIO you could see
+ a media change event has happened. If you just check the GPIO you could see
card 1 and then check again after card 1 was removed and card 2 was inserted
@@ -1457,7 +1457,7 @@ TimerCallback ( }
} else {
if (Present && !gMediaChange) {
- gMediaChange = TRUE;
+ gMediaChange = TRUE;
}
}
}
@@ -1479,14 +1479,14 @@ MMCHSInitialize ( Status = gBS->CreateEvent (EVT_TIMER | EVT_NOTIFY_SIGNAL, TPL_CALLBACK, TimerCallback, NULL, &gTimerEvent);
ASSERT_EFI_ERROR (Status);
-
- Status = gBS->SetTimer (gTimerEvent, TimerPeriodic, FixedPcdGet32 (PcdMmchsTimerFreq100NanoSeconds));
+
+ Status = gBS->SetTimer (gTimerEvent, TimerPeriodic, FixedPcdGet32 (PcdMmchsTimerFreq100NanoSeconds));
ASSERT_EFI_ERROR (Status);
//Publish BlockIO.
Status = gBS->InstallMultipleProtocolInterfaces (
- &ImageHandle,
- &gEfiBlockIoProtocolGuid, &gBlockIo,
+ &ImageHandle,
+ &gEfiBlockIoProtocolGuid, &gBlockIo,
&gEfiDevicePathProtocolGuid, &gMmcHsDevicePath,
NULL
);
diff --git a/Omap35xxPkg/MMCHSDxe/MMCHS.h b/Omap35xxPkg/MMCHSDxe/MMCHS.h index e19607bae0..06960a3bd6 100644 --- a/Omap35xxPkg/MMCHSDxe/MMCHS.h +++ b/Omap35xxPkg/MMCHSDxe/MMCHS.h @@ -40,12 +40,12 @@ #define HCS BIT30 //Host capacity support/1 = Supporting high capacity
#define CCS BIT30 //Card capacity status/1 = High capacity card
typedef struct {
- UINT32 Reserved0: 7; // 0
+ UINT32 Reserved0: 7; // 0
UINT32 V170_V195: 1; // 1.70V - 1.95V
UINT32 V200_V260: 7; // 2.00V - 2.60V
UINT32 V270_V360: 9; // 2.70V - 3.60V
UINT32 RESERVED_1: 5; // Reserved
- UINT32 AccessMode: 2; // 00b (byte mode), 10b (sector mode)
+ UINT32 AccessMode: 2; // 00b (byte mode), 10b (sector mode)
UINT32 Busy: 1; // This bit is set to LOW if the card has not finished the power up routine
}OCR;
@@ -71,14 +71,14 @@ typedef struct { UINT8 PERM_WRITE_PROTECT: 1; // Permanent write protection [13:13]
UINT8 COPY: 1; // Copy flag (OTP) [14:14]
UINT8 FILE_FORMAT_GRP: 1; // File format group [15:15]
-
+
UINT16 RESERVED_2: 5; // Reserved [20:16]
UINT16 WRITE_BL_PARTIAL: 1; // Partial blocks for write allowed [21:21]
UINT16 WRITE_BL_LEN: 4; // Max. write data block length [25:22]
UINT16 R2W_FACTOR: 3; // Write speed factor [28:26]
UINT16 RESERVED_3: 2; // Reserved [30:29]
UINT16 WP_GRP_ENABLE: 1; // Write protect group enable [31:31]
-
+
UINT32 WP_GRP_SIZE: 7; // Write protect group size [38:32]
UINT32 SECTOR_SIZE: 7; // Erase sector size [45:39]
UINT32 ERASE_BLK_EN: 1; // Erase single block enable [46:46]
@@ -88,7 +88,7 @@ typedef struct { UINT32 VDD_R_CURR_MAX: 3; // Max. read current @ VDD max [58:56]
UINT32 VDD_R_CURR_MIN: 3; // Max. read current @ VDD min [61:59]
UINT32 C_SIZELow2: 2; // Device size [63:62]
-
+
UINT32 C_SIZEHigh10: 10;// Device size [73:64]
UINT32 RESERVED_4: 2; // Reserved [75:74]
UINT32 DSR_IMP: 1; // DSR implemented [76:76]
@@ -101,7 +101,7 @@ typedef struct { UINT8 TRAN_SPEED ; // Max. bus clock frequency [103:96]
UINT8 NSAC ; // Data read access-time 2 in CLK cycles (NSAC*100) [111:104]
UINT8 TAAC ; // Data read access-time 1 [119:112]
-
+
UINT8 RESERVED_5: 6; // Reserved [125:120]
UINT8 CSD_STRUCTURE: 2; // CSD structure [127:126]
}CSD;
diff --git a/Omap35xxPkg/MMCHSDxe/MMCHS.inf b/Omap35xxPkg/MMCHSDxe/MMCHS.inf index cc753c2a21..02f5e8844f 100644 --- a/Omap35xxPkg/MMCHSDxe/MMCHS.inf +++ b/Omap35xxPkg/MMCHSDxe/MMCHS.inf @@ -1,14 +1,14 @@ #/** @file
-#
+#
# Copyright (c) 2008 - 2010, Apple Inc. All rights reserved.<BR>
# This program and the accompanying materials
# are licensed and made available under the terms and conditions of the BSD License
# which accompanies this distribution. The full text of the license may be found at
# http://opensource.org/licenses/bsd-license.php
-#
+#
# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
-#
+#
#**/
[Defines]
@@ -39,7 +39,7 @@ DmaLib
[Guids]
-
+
[Protocols]
gEfiBlockIoProtocolGuid
gEfiCpuArchProtocolGuid
diff --git a/Omap35xxPkg/MmcHostDxe/MmcHostDxe.c b/Omap35xxPkg/MmcHostDxe/MmcHostDxe.c index dab932999f..ad922a18e3 100755 --- a/Omap35xxPkg/MmcHostDxe/MmcHostDxe.c +++ b/Omap35xxPkg/MmcHostDxe/MmcHostDxe.c @@ -236,7 +236,7 @@ UpdateMMCHSClkFrequency ( MmioAnd32 (MMCHS_SYSCTL, ~CEN);
// Set new clock frequency.
- MmioAndThenOr32 (MMCHS_SYSCTL, ~CLKD_MASK, NewCLKD << 6);
+ MmioAndThenOr32 (MMCHS_SYSCTL, ~CLKD_MASK, NewCLKD << 6);
// Poll till Internal Clock Stable
while ((MmioRead32 (MMCHS_SYSCTL) & ICS_MASK) != ICS);
@@ -264,7 +264,7 @@ InitializeMMCHS ( Data = VSEL_3_00V;
Status = gTPS65950->Write (gTPS65950, EXTERNAL_DEVICE_REGISTER(I2C_ADDR_GRP_ID4, VMMC1_DEDICATED_REG), 1, &Data);
ASSERT_EFI_ERROR(Status);
-
+
// After ramping up voltage, set VDDS stable bit to indicate that voltage level is stable.
MmioOr32 (CONTROL_PBIAS_LITE, (PBIASLITEVMODE0 | PBIASLITEPWRDNZ0 | PBIASSPEEDCTRL0 | PBIASLITEVMODE1 | PBIASLITEWRDNZ1));
@@ -303,10 +303,10 @@ MMCIsReadOnly ( )
{
/* Note:
- * On our BeagleBoard the SD card WP pin is always read as TRUE.
+ * On our BeagleBoard the SD card WP pin is always read as TRUE.
* Probably something wrong with GPIO configuration.
* BeagleBoard-xM uses microSD cards so there is no write protect at all.
- * Hence commenting out SD card WP pin read status.
+ * Hence commenting out SD card WP pin read status.
*/
//return (MmioRead32 (GPIO1_BASE + GPIO_DATAIN) & BIT23) == BIT23;
return 0;
@@ -667,7 +667,7 @@ MMCInitialize ( ASSERT_EFI_ERROR(Status);
Status = gBS->InstallMultipleProtocolInterfaces (
- &Handle,
+ &Handle,
&gEfiMmcHostProtocolGuid, &gMMCHost,
NULL
);
diff --git a/Omap35xxPkg/MmcHostDxe/MmcHostDxe.h b/Omap35xxPkg/MmcHostDxe/MmcHostDxe.h index ec55234db2..0748ddfa47 100755 --- a/Omap35xxPkg/MmcHostDxe/MmcHostDxe.h +++ b/Omap35xxPkg/MmcHostDxe/MmcHostDxe.h @@ -1,14 +1,14 @@ /** @file
*
* Copyright (c) 2011, ARM Limited. All rights reserved.
-*
-* This program and the accompanying materials
-* are licensed and made available under the terms and conditions of the BSD License
-* which accompanies this distribution. The full text of the license may be found at
-* http://opensource.org/licenses/bsd-license.php
*
-* THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
-* WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
+* This program and the accompanying materials
+* are licensed and made available under the terms and conditions of the BSD License
+* which accompanies this distribution. The full text of the license may be found at
+* http://opensource.org/licenses/bsd-license.php
+*
+* THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
+* WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
*
**/
diff --git a/Omap35xxPkg/MmcHostDxe/MmcHostDxe.inf b/Omap35xxPkg/MmcHostDxe/MmcHostDxe.inf index 8c95c0f2d9..7d406ecd82 100755 --- a/Omap35xxPkg/MmcHostDxe/MmcHostDxe.inf +++ b/Omap35xxPkg/MmcHostDxe/MmcHostDxe.inf @@ -1,12 +1,12 @@ # Copyright (c) 2011, ARM Limited. All rights reserved.
-#
-# This program and the accompanying materials
-# are licensed and made available under the terms and conditions of the BSD License
-# which accompanies this distribution. The full text of the license may be found at
-# http://opensource.org/licenses/bsd-license.php
#
-# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
-# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
+# This program and the accompanying materials
+# are licensed and made available under the terms and conditions of the BSD License
+# which accompanies this distribution. The full text of the license may be found at
+# http://opensource.org/licenses/bsd-license.php
+#
+# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
+# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
#
[Defines]
@@ -37,7 +37,7 @@ DmaLib
[Guids]
-
+
[Protocols]
gEfiBlockIoProtocolGuid
gEfiCpuArchProtocolGuid
diff --git a/Omap35xxPkg/Omap35xxPkg.dec b/Omap35xxPkg/Omap35xxPkg.dec index 3503517978..8924e2ac47 100644 --- a/Omap35xxPkg/Omap35xxPkg.dec +++ b/Omap35xxPkg/Omap35xxPkg.dec @@ -35,14 +35,14 @@ ## @libraryclass Abstract location of basic OMAP components
##
OmapLib|Include/Library/OmapLib.h
-
+
## @libraryclass Abstract OMAP and ARM DMA, modeled after PCI IO protocol
##
OmapDmaLib|Include/Library/OmapDmaLib.h
[Guids.common]
- gOmap35xxTokenSpaceGuid = { 0x24b09abe, 0x4e47, 0x481c, { 0xa9, 0xad, 0xce, 0xf1, 0x2c, 0x39, 0x23, 0x27} }
+ gOmap35xxTokenSpaceGuid = { 0x24b09abe, 0x4e47, 0x481c, { 0xa9, 0xad, 0xce, 0xf1, 0x2c, 0x39, 0x23, 0x27} }
[PcdsFeatureFlag.common]
@@ -55,4 +55,4 @@ gOmap35xxTokenSpaceGuid.PcdOmap35xxDebugAgentTimer|5|UINT32|0x00000207
gOmap35xxTokenSpaceGuid.PcdDebugAgentTimerFreqNanoSeconds|77|UINT32|0x00000208
gOmap35xxTokenSpaceGuid.PcdMmchsTimerFreq100NanoSeconds|1000000|UINT32|0x00000209
-
+
diff --git a/Omap35xxPkg/Omap35xxPkg.dsc b/Omap35xxPkg/Omap35xxPkg.dsc index 075dd6ae99..8d8f52104b 100644 --- a/Omap35xxPkg/Omap35xxPkg.dsc +++ b/Omap35xxPkg/Omap35xxPkg.dsc @@ -35,23 +35,23 @@ ArmLib|ArmPkg/Library/ArmLib/ArmV7/ArmV7Lib.inf
MemoryAllocationLib|MdePkg/Library/UefiMemoryAllocationLib/UefiMemoryAllocationLib.inf
-
+
BaseLib|MdePkg/Library/BaseLib/BaseLib.inf
BaseMemoryLib|MdePkg/Library/BaseMemoryLib/BaseMemoryLib.inf
PrintLib|MdePkg/Library/BasePrintLib/BasePrintLib.inf
-
+
CacheMaintenanceLib|ArmPkg/Library/ArmCacheMaintenanceLib/ArmCacheMaintenanceLib.inf
DefaultExceptioHandlerLib|ArmPkg/Library/DefaultExceptionHandlerLib/DefaultExceptionHandlerLib.inf
CpuExceptionHandlerLib|MdeModulePkg/Library/CpuExceptionHandlerLibNull/CpuExceptionHandlerLibNull.inf
PrePiLib|EmbeddedPkg/Library/PrePiLib/PrePiLib.inf
-
+
RealTimeClockLib|EmbeddedPkg/Library/TemplateRealTimeClockLib/TemplateRealTimeClockLib.inf
IoLib|MdePkg/Library/BaseIoLibIntrinsic/BaseIoLibIntrinsic.inf
OmapLib|Omap35xxPkg/Library/OmapLib/OmapLib.inf
OmapDmaLib|Omap35xxPkg/Library/OmapDmaLib/OmapDmaLib.inf
-
+
MemoryAllocationLib|MdePkg/Library/UefiMemoryAllocationLib/UefiMemoryAllocationLib.inf
UefiLib|MdePkg/Library/UefiLib/UefiLib.inf
UefiRuntimeServicesTableLib|MdePkg/Library/UefiRuntimeServicesTableLib/UefiRuntimeServicesTableLib.inf
@@ -69,7 +69,7 @@ PcdLib|MdePkg/Library/BasePcdLibNull/BasePcdLibNull.inf
UefiRuntimeLib|MdePkg/Library/UefiRuntimeLib/UefiRuntimeLib.inf
-
+
# UncachedMemoryAllocationLib|ArmPkg/Library/UncachedMemoryAllocationLib/UncachedMemoryAllocationLib.inf
UncachedMemoryAllocationLib|ArmPkg/Library/DebugUncachedMemoryAllocationLib/DebugUncachedMemoryAllocationLib.inf
@@ -82,7 +82,7 @@ [LibraryClasses.ARM]
#
- # Note: This NULL library feature is not yet in the edk2/BaseTools, but it is checked in to
+ # Note: This NULL library feature is not yet in the edk2/BaseTools, but it is checked in to
# the BaseTools project. So you need to build with the BaseTools project util this feature gets synced.
#
NULL|ArmPkg/Library/CompilerIntrinsicsLib/CompilerIntrinsicsLib.inf
@@ -98,7 +98,7 @@ RVCT:*_*_ARM_ARCHCC_FLAGS == --cpu 7-A
RVCT:*_*_ARM_ARCHASM_FLAGS == --cpu 7-A
-
+
################################################################################
#
@@ -106,7 +106,7 @@ #
################################################################################
-
+
[PcdsFixedAtBuild.common]
# DEBUG_ASSERT_ENABLED 0x01
@@ -136,7 +136,7 @@ gEfiMdePkgTokenSpaceGuid.PcdDebugPrintErrorLevel|0x80000004
gEfiMdePkgTokenSpaceGuid.PcdReportStatusCodePropertyMask|0x07
-
+
gEmbeddedTokenSpaceGuid.PcdPrePiTempMemorySize|0
gEmbeddedTokenSpaceGuid.PcdPrePiBfvBaseAddress|0
gEmbeddedTokenSpaceGuid.PcdPrePiBfvSize|0
@@ -147,20 +147,20 @@ gEmbeddedTokenSpaceGuid.PcdPrePiStackSize|0x20000 # 128K stack
gArmTokenSpaceGuid.PcdCpuVectorBaseAddress|0x80000000
gArmTokenSpaceGuid.PcdCpuResetAddress|0x80008000
-
+
gOmap35xxTokenSpaceGuid.PcdOmap35xxGpmcOffset|0x6E000000
gOmap35xxTokenSpaceGuid.PcdOmap35xxMMCHS1Base|0x4809C000
- # Console
+ # Console
gOmap35xxTokenSpaceGuid.PcdOmap35xxConsoleUart|3
-
+
# Timers
gOmap35xxTokenSpaceGuid.PcdOmap35xxArchTimer|3
gOmap35xxTokenSpaceGuid.PcdOmap35xxFreeTimer|4
gEmbeddedTokenSpaceGuid.PcdTimerPeriod|100000
gEmbeddedTokenSpaceGuid.PcdEmbeddedPerformanceCounterPeriodInNanoseconds|77
gEmbeddedTokenSpaceGuid.PcdEmbeddedPerformanceCounterFrequencyInHz|13000000
-
+
#
# ARM Pcds
#
@@ -172,17 +172,17 @@ #
################################################################################
[Components.common]
- Omap35xxPkg/Library/Omap35xxTimerLib/Omap35xxTimerLib.inf
+ Omap35xxPkg/Library/Omap35xxTimerLib/Omap35xxTimerLib.inf
Omap35xxPkg/Library/OmapLib/OmapLib.inf
Omap35xxPkg/Library/OmapDmaLib/OmapDmaLib.inf
-
+
Omap35xxPkg/Flash/Flash.inf
Omap35xxPkg/MMCHSDxe/MMCHS.inf
Omap35xxPkg/SmbusDxe/Smbus.inf
Omap35xxPkg/Gpio/Gpio.inf
Omap35xxPkg/InterruptDxe/InterruptDxe.inf
- Omap35xxPkg/TimerDxe/TimerDxe.inf
+ Omap35xxPkg/TimerDxe/TimerDxe.inf
Omap35xxPkg/TPS65950Dxe/TPS65950.inf
-
-
+
+
diff --git a/Omap35xxPkg/PciEmulation/PciEmulation.c b/Omap35xxPkg/PciEmulation/PciEmulation.c index afa64193a2..5af8849c4a 100644 --- a/Omap35xxPkg/PciEmulation/PciEmulation.c +++ b/Omap35xxPkg/PciEmulation/PciEmulation.c @@ -1,7 +1,7 @@ /** @file
Copyright (c) 2008 - 2009, Apple Inc. All rights reserved.<BR>
-
+
This program and the accompanying materials
are licensed and made available under the terms and conditions of the BSD License
which accompanies this distribution. The full text of the license may be found at
@@ -36,7 +36,7 @@ typedef struct { #define EFI_PCI_IO_PRIVATE_DATA_SIGNATURE SIGNATURE_32('p', 'c', 'i', 'o')
#define EFI_PCI_IO_PRIVATE_DATA_FROM_THIS(a) CR(a, EFI_PCI_IO_PRIVATE_DATA, PciIoProtocol, EFI_PCI_IO_PRIVATE_DATA_SIGNATURE)
-EFI_PCI_IO_DEVICE_PATH PciIoDevicePathTemplate =
+EFI_PCI_IO_DEVICE_PATH PciIoDevicePathTemplate =
{
{
{ ACPI_DEVICE_PATH, ACPI_DP, { sizeof (ACPI_HID_DEVICE_PATH), 0 } },
@@ -82,7 +82,7 @@ ConfigureUSBHost ( // Get the Power IC protocol
Status = gBS->LocateProtocol (&gEmbeddedExternalDeviceProtocolGuid, NULL, (VOID **)&gTPS65950);
- ASSERT_EFI_ERROR (Status);
+ ASSERT_EFI_ERROR (Status);
// Power the USB PHY
Data = VAUX_DEV_GRP_P1;
@@ -91,7 +91,7 @@ ConfigureUSBHost ( Data = VAUX_DEDICATED_18V;
Status = gTPS65950->Write (gTPS65950, EXTERNAL_DEVICE_REGISTER(I2C_ADDR_GRP_ID4, VAUX2_DEDICATED), 1, &Data);
- ASSERT_EFI_ERROR (Status);
+ ASSERT_EFI_ERROR (Status);
// Enable power to the USB hub
Status = gTPS65950->Read (gTPS65950, EXTERNAL_DEVICE_REGISTER(I2C_ADDR_GRP_ID3, LEDEN), 1, &Data);
@@ -150,7 +150,7 @@ PciIoMemRead ( {
EFI_PCI_IO_PRIVATE_DATA *Private = EFI_PCI_IO_PRIVATE_DATA_FROM_THIS(This);
- return PciRootBridgeIoMemRead (&Private->RootBridge.Io,
+ return PciRootBridgeIoMemRead (&Private->RootBridge.Io,
(EFI_PCI_ROOT_BRIDGE_IO_PROTOCOL_WIDTH) Width,
Private->ConfigSpace->Device.Bar[BarIndex] + Offset,
Count,
@@ -170,7 +170,7 @@ PciIoMemWrite ( {
EFI_PCI_IO_PRIVATE_DATA *Private = EFI_PCI_IO_PRIVATE_DATA_FROM_THIS(This);
- return PciRootBridgeIoMemWrite (&Private->RootBridge.Io,
+ return PciRootBridgeIoMemWrite (&Private->RootBridge.Io,
(EFI_PCI_ROOT_BRIDGE_IO_PROTOCOL_WIDTH) Width,
Private->ConfigSpace->Device.Bar[BarIndex] + Offset,
Count,
@@ -217,11 +217,11 @@ PciIoPciRead ( {
EFI_PCI_IO_PRIVATE_DATA *Private = EFI_PCI_IO_PRIVATE_DATA_FROM_THIS(This);
- return PciRootBridgeIoMemRW ((EFI_PCI_ROOT_BRIDGE_IO_PROTOCOL_WIDTH)Width,
- Count,
- TRUE,
- (PTR)(UINTN)Buffer,
- TRUE,
+ return PciRootBridgeIoMemRW ((EFI_PCI_ROOT_BRIDGE_IO_PROTOCOL_WIDTH)Width,
+ Count,
+ TRUE,
+ (PTR)(UINTN)Buffer,
+ TRUE,
(PTR)(UINTN)(((UINT8 *)Private->ConfigSpace) + Offset)
);
}
@@ -237,11 +237,11 @@ PciIoPciWrite ( {
EFI_PCI_IO_PRIVATE_DATA *Private = EFI_PCI_IO_PRIVATE_DATA_FROM_THIS(This);
- return PciRootBridgeIoMemRW ((EFI_PCI_ROOT_BRIDGE_IO_PROTOCOL_WIDTH) Width,
- Count,
- TRUE,
- (PTR)(UINTN)(((UINT8 *)Private->ConfigSpace) + Offset),
- TRUE,
+ return PciRootBridgeIoMemRW ((EFI_PCI_ROOT_BRIDGE_IO_PROTOCOL_WIDTH) Width,
+ Count,
+ TRUE,
+ (PTR)(UINTN)(((UINT8 *)Private->ConfigSpace) + Offset),
+ TRUE,
(PTR)(UINTN)Buffer
);
}
@@ -385,7 +385,7 @@ PciIoAttributes ( case EfiPciIoAttributeOperationDisable:
// Since we are not a real PCI device no enable/set or disable operations exist.
return EFI_SUCCESS;
-
+
default:
ASSERT (FALSE);
return EFI_INVALID_PARAMETER;
@@ -418,7 +418,7 @@ PciIoSetBarAttributes ( return EFI_UNSUPPORTED;
}
-EFI_PCI_IO_PROTOCOL PciIoTemplate =
+EFI_PCI_IO_PROTOCOL PciIoTemplate =
{
PciIoPollMem,
PciIoPollIo,
@@ -463,7 +463,7 @@ PciEmulationEntryPoint ( Status = EFI_OUT_OF_RESOURCES;
return Status;
}
-
+
Private->Signature = EFI_PCI_IO_PRIVATE_DATA_SIGNATURE; // Fill in signature
Private->RootBridge.Signature = PCI_ROOT_BRIDGE_SIGNATURE; // Fake Root Bridge structure needs a signature too
Private->RootBridge.MemoryStart = USB_EHCI_HCCAPBASE; // Get the USB capability register base
@@ -504,7 +504,7 @@ PciEmulationEntryPoint ( // Unique device path.
CopyMem(&Private->DevicePath, &PciIoDevicePathTemplate, sizeof(PciIoDevicePathTemplate));
Private->DevicePath.AcpiDevicePath.UID = 0;
-
+
// Copy protocol structure
CopyMem(&Private->PciIoProtocol, &PciIoTemplate, sizeof(PciIoTemplate));
diff --git a/Omap35xxPkg/PciEmulation/PciEmulation.h b/Omap35xxPkg/PciEmulation/PciEmulation.h index 2a381f2f99..d5ee043189 100644 --- a/Omap35xxPkg/PciEmulation/PciEmulation.h +++ b/Omap35xxPkg/PciEmulation/PciEmulation.h @@ -72,7 +72,7 @@ typedef struct { EFI_HANDLE Handle;
EFI_PCI_ROOT_BRIDGE_IO_PROTOCOL Io;
EFI_PCI_ROOT_BRIDGE_DEVICE_PATH DevicePath;
-
+
UINT8 StartBus;
UINT8 EndBus;
UINT16 Type;
@@ -81,7 +81,7 @@ typedef struct { UINTN IoOffset;
UINT32 IoStart;
UINT32 IoSize;
- UINT64 PciAttributes;
+ UINT64 PciAttributes;
ACPI_CONFIG_INFO *Config;
@@ -104,7 +104,7 @@ typedef union { EFI_STATUS
EFIAPI
-PciRootBridgeIoPollMem (
+PciRootBridgeIoPollMem (
IN EFI_PCI_ROOT_BRIDGE_IO_PROTOCOL *This,
IN EFI_PCI_ROOT_BRIDGE_IO_PROTOCOL_WIDTH Width,
IN UINT64 Address,
@@ -113,10 +113,10 @@ PciRootBridgeIoPollMem ( IN UINT64 Delay,
OUT UINT64 *Result
);
-
+
EFI_STATUS
EFIAPI
-PciRootBridgeIoPollIo (
+PciRootBridgeIoPollIo (
IN EFI_PCI_ROOT_BRIDGE_IO_PROTOCOL *This,
IN EFI_PCI_ROOT_BRIDGE_IO_PROTOCOL_WIDTH Width,
IN UINT64 Address,
@@ -125,7 +125,7 @@ PciRootBridgeIoPollIo ( IN UINT64 Delay,
OUT UINT64 *Result
);
-
+
EFI_STATUS
EFIAPI
PciRootBridgeIoMemRead (
@@ -253,8 +253,8 @@ PciRootBridgeIoSetAttributes ( IN EFI_PCI_ROOT_BRIDGE_IO_PROTOCOL *This,
IN UINT64 Attributes,
IN OUT UINT64 *ResourceBase,
- IN OUT UINT64 *ResourceLength
- );
+ IN OUT UINT64 *ResourceLength
+ );
EFI_STATUS
EFIAPI
diff --git a/Omap35xxPkg/PciEmulation/PciEmulation.inf b/Omap35xxPkg/PciEmulation/PciEmulation.inf index ab37541795..2180bb4989 100644 --- a/Omap35xxPkg/PciEmulation/PciEmulation.inf +++ b/Omap35xxPkg/PciEmulation/PciEmulation.inf @@ -1,5 +1,5 @@ /** @file
-
+
Copyright (c) 2009, Apple Inc. All rights reserved.<BR>
This program and the accompanying materials
@@ -52,6 +52,5 @@ gEmbeddedExternalDeviceProtocolGuid
[Depex]
- gEfiMetronomeArchProtocolGuid AND
+ gEfiMetronomeArchProtocolGuid AND
gEmbeddedExternalDeviceProtocolGuid
-
\ No newline at end of file diff --git a/Omap35xxPkg/PciEmulation/PciRootBridgeIo.c b/Omap35xxPkg/PciEmulation/PciRootBridgeIo.c index 33d70341cc..e8635ed88d 100644 --- a/Omap35xxPkg/PciEmulation/PciRootBridgeIo.c +++ b/Omap35xxPkg/PciEmulation/PciRootBridgeIo.c @@ -1,7 +1,7 @@ /** @file
Copyright (c) 2008 - 2009, Apple Inc. All rights reserved.<BR>
-
+
This program and the accompanying materials
are licensed and made available under the terms and conditions of the BSD License
which accompanies this distribution. The full text of the license may be found at
@@ -87,20 +87,20 @@ PciRootBridgeIoPciRW ( return EFI_SUCCESS;
}
-/**
+/**
Enables a PCI driver to access PCI controller registers in the PCI root bridge memory space.
-
+
@param This A pointer to the EFI_PCI_ROOT_BRIDGE_IO_PROTOCOL.
@param Width Signifies the width of the memory operations.
- @param Address The base address of the memory operations.
+ @param Address The base address of the memory operations.
@param Count The number of memory operations to perform.
@param Buffer For read operations, the destination buffer to store the results. For write
- operations, the source buffer to write data from.
-
- @retval EFI_SUCCESS The data was read from or written to the PCI root bridge.
+ operations, the source buffer to write data from.
+
+ @retval EFI_SUCCESS The data was read from or written to the PCI root bridge.
@retval EFI_OUT_OF_RESOURCES The request could not be completed due to a lack of resources.
@retval EFI_INVALID_PARAMETER One or more parameters are invalid.
-
+
**/
EFI_STATUS
EFIAPI
@@ -120,7 +120,7 @@ PciRootBridgeIoMemRead ( if ( Buffer == NULL ) {
return EFI_INVALID_PARAMETER;
}
-
+
Private = INSTANCE_FROM_PCI_ROOT_BRIDGE_IO_THIS (This);
if (!PciRootBridgeMemAddressValid (Private, Address)) {
@@ -153,30 +153,30 @@ PciRootBridgeIoMemRead ( case EfiPciWidthFillUint32:
case EfiPciWidthFillUint64:
return PciRootBridgeIoMemRW (Width, Count, FALSE, In, TRUE, Out);
-
+
default:
break;
}
-
+
return EFI_INVALID_PARAMETER;
}
-/**
+/**
Enables a PCI driver to access PCI controller registers in the PCI root bridge memory space.
-
+
@param This A pointer to the EFI_PCI_ROOT_BRIDGE_IO_PROTOCOL.
@param Width Signifies the width of the memory operations.
- @param Address The base address of the memory operations.
+ @param Address The base address of the memory operations.
@param Count The number of memory operations to perform.
@param Buffer For read operations, the destination buffer to store the results. For write
- operations, the source buffer to write data from.
-
- @retval EFI_SUCCESS The data was read from or written to the PCI root bridge.
+ operations, the source buffer to write data from.
+
+ @retval EFI_SUCCESS The data was read from or written to the PCI root bridge.
@retval EFI_OUT_OF_RESOURCES The request could not be completed due to a lack of resources.
@retval EFI_INVALID_PARAMETER One or more parameters are invalid.
-
+
**/
EFI_STATUS
EFIAPI
@@ -196,7 +196,7 @@ PciRootBridgeIoMemWrite ( if ( Buffer == NULL ) {
return EFI_INVALID_PARAMETER;
}
-
+
Private = INSTANCE_FROM_PCI_ROOT_BRIDGE_IO_THIS (This);
if (!PciRootBridgeMemAddressValid (Private, Address)) {
@@ -217,7 +217,7 @@ PciRootBridgeIoMemWrite ( case EfiPciWidthUint32:
case EfiPciWidthUint64:
return PciRootBridgeIoMemRW (Width, Count, TRUE, In, TRUE, Out);
-
+
case EfiPciWidthFifoUint8:
case EfiPciWidthFifoUint16:
case EfiPciWidthFifoUint32:
@@ -229,7 +229,7 @@ PciRootBridgeIoMemWrite ( case EfiPciWidthFillUint32:
case EfiPciWidthFillUint64:
return PciRootBridgeIoMemRW (Width, Count, TRUE, In, FALSE, Out);
-
+
default:
break;
}
@@ -237,20 +237,20 @@ PciRootBridgeIoMemWrite ( return EFI_INVALID_PARAMETER;
}
-/**
+/**
Enables a PCI driver to access PCI controller registers in the PCI root bridge memory space.
-
+
@param This A pointer to the EFI_PCI_ROOT_BRIDGE_IO_PROTOCOL.
@param Width Signifies the width of the memory operations.
- @param Address The base address of the memory operations.
+ @param Address The base address of the memory operations.
@param Count The number of memory operations to perform.
@param Buffer For read operations, the destination buffer to store the results. For write
- operations, the source buffer to write data from.
-
- @retval EFI_SUCCESS The data was read from or written to the PCI root bridge.
+ operations, the source buffer to write data from.
+
+ @retval EFI_SUCCESS The data was read from or written to the PCI root bridge.
@retval EFI_OUT_OF_RESOURCES The request could not be completed due to a lack of resources.
@retval EFI_INVALID_PARAMETER One or more parameters are invalid.
-
+
**/
EFI_STATUS
EFIAPI
@@ -271,20 +271,20 @@ PciRootBridgeIoPciRead ( -/**
+/**
Enables a PCI driver to access PCI controller registers in the PCI root bridge memory space.
-
+
@param This A pointer to the EFI_PCI_ROOT_BRIDGE_IO_PROTOCOL.
@param Width Signifies the width of the memory operations.
- @param Address The base address of the memory operations.
+ @param Address The base address of the memory operations.
@param Count The number of memory operations to perform.
@param Buffer For read operations, the destination buffer to store the results. For write
- operations, the source buffer to write data from.
-
- @retval EFI_SUCCESS The data was read from or written to the PCI root bridge.
+ operations, the source buffer to write data from.
+
+ @retval EFI_SUCCESS The data was read from or written to the PCI root bridge.
@retval EFI_OUT_OF_RESOURCES The request could not be completed due to a lack of resources.
@retval EFI_INVALID_PARAMETER One or more parameters are invalid.
-
+
**/
EFI_STATUS
EFIAPI
@@ -299,7 +299,7 @@ PciRootBridgeIoPciWrite ( if (Buffer == NULL) {
return EFI_INVALID_PARAMETER;
}
-
+
return PciRootBridgeIoPciRW (This, TRUE, Width, Address, Count, Buffer);
}
diff --git a/Omap35xxPkg/SmbusDxe/Smbus.c b/Omap35xxPkg/SmbusDxe/Smbus.c index 3b88974ae1..f2f43e252f 100644 --- a/Omap35xxPkg/SmbusDxe/Smbus.c +++ b/Omap35xxPkg/SmbusDxe/Smbus.c @@ -1,7 +1,7 @@ /** @file
Copyright (c) 2008 - 2009, Apple Inc. All rights reserved.<BR>
-
+
This program and the accompanying materials
are licensed and made available under the terms and conditions of the BSD License
which accompanies this distribution. The full text of the license may be found at
@@ -76,8 +76,8 @@ ConfigureI2c ( //Program prescaler to obtain 12-MHz clock
MmioWrite16(I2C_PSC, 0x0000);
- //Program SCLL and SCLH
- //NOTE: Following values are the register dump after U-Boot code executed.
+ //Program SCLL and SCLH
+ //NOTE: Following values are the register dump after U-Boot code executed.
//We need to figure out how its calculated based on the I2C functional clock and I2C_PSC.
MmioWrite16(I2C_SCLL, 0x0035);
MmioWrite16(I2C_SCLH, 0x0035);
@@ -124,7 +124,7 @@ I2CReadOneByte ( STATIC
EFI_STATUS
I2CWriteOneByte (
- UINT8 Data
+ UINT8 Data
)
{
EFI_STATUS Status;
@@ -319,7 +319,7 @@ InitializeSmbus ( // Install the SMBUS interface
Status = gBS->InstallMultipleProtocolInterfaces(&Handle, &gEfiSmbusHcProtocolGuid, &SmbusProtocol, NULL);
ASSERT_EFI_ERROR(Status);
-
+
return Status;
}
diff --git a/Omap35xxPkg/SmbusDxe/Smbus.inf b/Omap35xxPkg/SmbusDxe/Smbus.inf index 5a4e43ea24..009927d73a 100644 --- a/Omap35xxPkg/SmbusDxe/Smbus.inf +++ b/Omap35xxPkg/SmbusDxe/Smbus.inf @@ -1,14 +1,14 @@ #/** @file
-#
+#
# Copyright (c) 2008 - 2010, Apple Inc. All rights reserved.<BR>
# This program and the accompanying materials
# are licensed and made available under the terms and conditions of the BSD License
# which accompanies this distribution. The full text of the license may be found at
# http://opensource.org/licenses/bsd-license.php
-#
+#
# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
-#
+#
#**/
[Defines]
@@ -35,11 +35,11 @@ IoLib
[Guids]
-
+
[Protocols]
gEfiSmbusHcProtocolGuid
[Pcd]
[depex]
- TRUE
\ No newline at end of file + TRUE
diff --git a/Omap35xxPkg/TPS65950Dxe/TPS65950.c b/Omap35xxPkg/TPS65950Dxe/TPS65950.c index ed19389d43..66f9d853ff 100644 --- a/Omap35xxPkg/TPS65950Dxe/TPS65950.c +++ b/Omap35xxPkg/TPS65950Dxe/TPS65950.c @@ -1,7 +1,7 @@ /** @file
Copyright (c) 2008 - 2009, Apple Inc. All rights reserved.<BR>
-
+
This program and the accompanying materials
are licensed and made available under the terms and conditions of the BSD License
which accompanies this distribution. The full text of the license may be found at
@@ -35,7 +35,7 @@ Read ( )
{
EFI_STATUS Status;
- EFI_SMBUS_DEVICE_ADDRESS SlaveAddress;
+ EFI_SMBUS_DEVICE_ADDRESS SlaveAddress;
UINT8 DeviceRegister;
UINTN DeviceRegisterLength = 1;
@@ -62,7 +62,7 @@ Write ( )
{
EFI_STATUS Status;
- EFI_SMBUS_DEVICE_ADDRESS SlaveAddress;
+ EFI_SMBUS_DEVICE_ADDRESS SlaveAddress;
UINT8 DeviceRegister;
UINTN DeviceBufferLength = Length + 1;
UINT8 *DeviceBuffer;
@@ -107,10 +107,10 @@ TPS65950Initialize ( )
{
EFI_STATUS Status;
-
+
Status = gBS->LocateProtocol(&gEfiSmbusHcProtocolGuid, NULL, (VOID **)&Smbus);
ASSERT_EFI_ERROR(Status);
-
+
Status = gBS->InstallMultipleProtocolInterfaces(&ImageHandle, &gEmbeddedExternalDeviceProtocolGuid, &ExternalDevice, NULL);
return Status;
}
diff --git a/Omap35xxPkg/TPS65950Dxe/TPS65950.inf b/Omap35xxPkg/TPS65950Dxe/TPS65950.inf index 5fca7a356f..6144a33c55 100644 --- a/Omap35xxPkg/TPS65950Dxe/TPS65950.inf +++ b/Omap35xxPkg/TPS65950Dxe/TPS65950.inf @@ -1,14 +1,14 @@ #/** @file
-#
+#
# Copyright (c) 2008 - 2010, Apple Inc. All rights reserved.<BR>
# This program and the accompanying materials
# are licensed and made available under the terms and conditions of the BSD License
# which accompanies this distribution. The full text of the license may be found at
# http://opensource.org/licenses/bsd-license.php
-#
+#
# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
-#
+#
#**/
[Defines]
@@ -37,7 +37,7 @@ MemoryAllocationLib
[Guids]
-
+
[Protocols]
gEfiSmbusHcProtocolGuid
gEmbeddedExternalDeviceProtocolGuid
diff --git a/Omap35xxPkg/TimerDxe/Timer.c b/Omap35xxPkg/TimerDxe/Timer.c index bc3d9b0aba..8b56d457e4 100644 --- a/Omap35xxPkg/TimerDxe/Timer.c +++ b/Omap35xxPkg/TimerDxe/Timer.c @@ -2,14 +2,14 @@ Template for Timer Architecture Protocol driver of the ARM flavor
Copyright (c) 2008 - 2009, Apple Inc. All rights reserved.<BR>
-
- This program and the accompanying materials
- are licensed and made available under the terms and conditions of the BSD License
- which accompanies this distribution. The full text of the license may be found at
- http://opensource.org/licenses/bsd-license.php
- THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
- WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
+ This program and the accompanying materials
+ are licensed and made available under the terms and conditions of the BSD License
+ which accompanies this distribution. The full text of the license may be found at
+ http://opensource.org/licenses/bsd-license.php
+
+ THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
+ WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
**/
@@ -61,7 +61,7 @@ volatile UINTN gVector; what source means.
@param SystemContext Pointer to system register context. Mostly used by debuggers and will
- update the system context after the return from the interrupt if
+ update the system context after the return from the interrupt if
modified. Don't change these values unless you know what you are doing
**/
@@ -69,7 +69,7 @@ VOID EFIAPI
TimerInterruptHandler (
IN HARDWARE_INTERRUPT_SOURCE Source,
- IN EFI_SYSTEM_CONTEXT SystemContext
+ IN EFI_SYSTEM_CONTEXT SystemContext
)
{
EFI_TPL OriginalTPL;
@@ -77,9 +77,9 @@ TimerInterruptHandler ( //
- // DXE core uses this callback for the EFI timer tick. The DXE core uses locks
+ // DXE core uses this callback for the EFI timer tick. The DXE core uses locks
// that raise to TPL_HIGH and then restore back to current level. Thus we need
- // to make sure TPL level is set to TPL_HIGH while we are handling the timer tick.
+ // to make sure TPL level is set to TPL_HIGH while we are handling the timer tick.
//
OriginalTPL = gBS->RaiseTPL (TPL_HIGH_LEVEL);
@@ -88,7 +88,7 @@ TimerInterruptHandler ( }
// Clear all timer interrupts
- MmioWrite32 (TISR, TISR_CLEAR_ALL);
+ MmioWrite32 (TISR, TISR_CLEAR_ALL);
// Poll interrupt status bits to ensure clearing
while ((MmioRead32 (TISR) & TISR_ALL_INTERRUPT_MASK) != TISR_NO_INTERRUPTS_PENDING);
@@ -97,16 +97,16 @@ TimerInterruptHandler ( }
/**
- This function registers the handler NotifyFunction so it is called every time
- the timer interrupt fires. It also passes the amount of time since the last
- handler call to the NotifyFunction. If NotifyFunction is NULL, then the
- handler is unregistered. If the handler is registered, then EFI_SUCCESS is
- returned. If the CPU does not support registering a timer interrupt handler,
- then EFI_UNSUPPORTED is returned. If an attempt is made to register a handler
- when a handler is already registered, then EFI_ALREADY_STARTED is returned.
- If an attempt is made to unregister a handler when a handler is not registered,
- then EFI_INVALID_PARAMETER is returned. If an error occurs attempting to
- register the NotifyFunction with the timer interrupt, then EFI_DEVICE_ERROR
+ This function registers the handler NotifyFunction so it is called every time
+ the timer interrupt fires. It also passes the amount of time since the last
+ handler call to the NotifyFunction. If NotifyFunction is NULL, then the
+ handler is unregistered. If the handler is registered, then EFI_SUCCESS is
+ returned. If the CPU does not support registering a timer interrupt handler,
+ then EFI_UNSUPPORTED is returned. If an attempt is made to register a handler
+ when a handler is already registered, then EFI_ALREADY_STARTED is returned.
+ If an attempt is made to unregister a handler when a handler is not registered,
+ then EFI_INVALID_PARAMETER is returned. If an error occurs attempting to
+ register the NotifyFunction with the timer interrupt, then EFI_DEVICE_ERROR
is returned.
@param This The EFI_TIMER_ARCH_PROTOCOL instance.
@@ -146,17 +146,17 @@ TimerDriverRegisterHandler ( /**
- This function adjusts the period of timer interrupts to the value specified
- by TimerPeriod. If the timer period is updated, then the selected timer
- period is stored in EFI_TIMER.TimerPeriod, and EFI_SUCCESS is returned. If
- the timer hardware is not programmable, then EFI_UNSUPPORTED is returned.
- If an error occurs while attempting to update the timer period, then the
- timer hardware will be put back in its state prior to this call, and
- EFI_DEVICE_ERROR is returned. If TimerPeriod is 0, then the timer interrupt
- is disabled. This is not the same as disabling the CPU's interrupts.
- Instead, it must either turn off the timer hardware, or it must adjust the
- interrupt controller so that a CPU interrupt is not generated when the timer
- interrupt fires.
+ This function adjusts the period of timer interrupts to the value specified
+ by TimerPeriod. If the timer period is updated, then the selected timer
+ period is stored in EFI_TIMER.TimerPeriod, and EFI_SUCCESS is returned. If
+ the timer hardware is not programmable, then EFI_UNSUPPORTED is returned.
+ If an error occurs while attempting to update the timer period, then the
+ timer hardware will be put back in its state prior to this call, and
+ EFI_DEVICE_ERROR is returned. If TimerPeriod is 0, then the timer interrupt
+ is disabled. This is not the same as disabling the CPU's interrupts.
+ Instead, it must either turn off the timer hardware, or it must adjust the
+ interrupt controller so that a CPU interrupt is not generated when the timer
+ interrupt fires.
@param This The EFI_TIMER_ARCH_PROTOCOL instance.
@param TimerPeriod The rate to program the timer interrupt in 100 nS units. If
@@ -182,13 +182,13 @@ TimerDriverSetTimerPeriod ( EFI_STATUS Status;
UINT64 TimerCount;
INT32 LoadValue;
-
+
if (TimerPeriod == 0) {
// Turn off GPTIMER3
MmioWrite32 (TCLR, TCLR_ST_OFF);
-
- Status = gInterrupt->DisableInterruptSource(gInterrupt, gVector);
- } else {
+
+ Status = gInterrupt->DisableInterruptSource(gInterrupt, gVector);
+ } else {
// Calculate required timer count
TimerCount = DivU64x32(TimerPeriod * 100, PcdGet32(PcdEmbeddedPerformanceCounterPeriodInNanoseconds));
@@ -203,7 +203,7 @@ TimerDriverSetTimerPeriod ( // Turn on GPTIMER3, it will reload at overflow
MmioWrite32 (TCLR, TCLR_AR_AUTORELOAD | TCLR_ST_ON);
- Status = gInterrupt->EnableInterruptSource(gInterrupt, gVector);
+ Status = gInterrupt->EnableInterruptSource(gInterrupt, gVector);
}
//
@@ -215,9 +215,9 @@ TimerDriverSetTimerPeriod ( /**
- This function retrieves the period of timer interrupts in 100 ns units,
- returns that value in TimerPeriod, and returns EFI_SUCCESS. If TimerPeriod
- is NULL, then EFI_INVALID_PARAMETER is returned. If a TimerPeriod of 0 is
+ This function retrieves the period of timer interrupts in 100 ns units,
+ returns that value in TimerPeriod, and returns EFI_SUCCESS. If TimerPeriod
+ is NULL, then EFI_INVALID_PARAMETER is returned. If a TimerPeriod of 0 is
returned, then the timer is currently disabled.
@param This The EFI_TIMER_ARCH_PROTOCOL instance.
@@ -245,12 +245,12 @@ TimerDriverGetTimerPeriod ( }
/**
- This function generates a soft timer interrupt. If the platform does not support soft
- timer interrupts, then EFI_UNSUPPORTED is returned. Otherwise, EFI_SUCCESS is returned.
- If a handler has been registered through the EFI_TIMER_ARCH_PROTOCOL.RegisterHandler()
- service, then a soft timer interrupt will be generated. If the timer interrupt is
- enabled when this service is called, then the registered handler will be invoked. The
- registered handler should not be able to distinguish a hardware-generated timer
+ This function generates a soft timer interrupt. If the platform does not support soft
+ timer interrupts, then EFI_UNSUPPORTED is returned. Otherwise, EFI_SUCCESS is returned.
+ If a handler has been registered through the EFI_TIMER_ARCH_PROTOCOL.RegisterHandler()
+ service, then a soft timer interrupt will be generated. If the timer interrupt is
+ enabled when this service is called, then the registered handler will be invoked. The
+ registered handler should not be able to distinguish a hardware-generated timer
interrupt from a software-generated timer interrupt.
@param This The EFI_TIMER_ARCH_PROTOCOL instance.
@@ -273,24 +273,24 @@ TimerDriverGenerateSoftInterrupt ( Interface stucture for the Timer Architectural Protocol.
@par Protocol Description:
- This protocol provides the services to initialize a periodic timer
+ This protocol provides the services to initialize a periodic timer
interrupt, and to register a handler that is called each time the timer
interrupt fires. It may also provide a service to adjust the rate of the
- periodic timer interrupt. When a timer interrupt occurs, the handler is
- passed the amount of time that has passed since the previous timer
+ periodic timer interrupt. When a timer interrupt occurs, the handler is
+ passed the amount of time that has passed since the previous timer
interrupt.
@param RegisterHandler
- Registers a handler that will be called each time the
- timer interrupt fires. TimerPeriod defines the minimum
- time between timer interrupts, so TimerPeriod will also
- be the minimum time between calls to the registered
+ Registers a handler that will be called each time the
+ timer interrupt fires. TimerPeriod defines the minimum
+ time between timer interrupts, so TimerPeriod will also
+ be the minimum time between calls to the registered
handler.
@param SetTimerPeriod
- Sets the period of the timer interrupt in 100 nS units.
- This function is optional, and may return EFI_UNSUPPORTED.
- If this function is supported, then the timer period will
+ Sets the period of the timer interrupt in 100 nS units.
+ This function is optional, and may return EFI_UNSUPPORTED.
+ If this function is supported, then the timer period will
be rounded up to the nearest supported timer period.
@@ -298,8 +298,8 @@ TimerDriverGenerateSoftInterrupt ( Retrieves the period of the timer interrupt in 100 nS units.
@param GenerateSoftInterrupt
- Generates a soft timer interrupt that simulates the firing of
- the timer interrupt. This service can be used to invoke the registered handler if the timer interrupt has been masked for
+ Generates a soft timer interrupt that simulates the firing of
+ the timer interrupt. This service can be used to invoke the registered handler if the timer interrupt has been masked for
a period of time.
**/
diff --git a/Omap35xxPkg/TimerDxe/TimerDxe.inf b/Omap35xxPkg/TimerDxe/TimerDxe.inf index 2c5a2f7a4a..b77b0a154a 100644 --- a/Omap35xxPkg/TimerDxe/TimerDxe.inf +++ b/Omap35xxPkg/TimerDxe/TimerDxe.inf @@ -1,16 +1,16 @@ #/** @file
-#
+#
# Component description file for Timer module
-#
+#
# Copyright (c) 2009, Apple Inc. All rights reserved.<BR>
# This program and the accompanying materials
# are licensed and made available under the terms and conditions of the BSD License
# which accompanies this distribution. The full text of the license may be found at
# http://opensource.org/licenses/bsd-license.php
-#
+#
# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
-#
+#
#**/
[Defines]
@@ -45,7 +45,7 @@ [Guids]
[Protocols]
- gEfiTimerArchProtocolGuid
+ gEfiTimerArchProtocolGuid
gHardwareInterruptProtocolGuid
[Pcd.common]
@@ -54,4 +54,4 @@ gOmap35xxTokenSpaceGuid.PcdOmap35xxArchTimer
[Depex]
- gHardwareInterruptProtocolGuid
\ No newline at end of file + gHardwareInterruptProtocolGuid
|