ArmPlatformPkg: Introduced 'ArmPlatformSecLib'
The function only used in Secure Firmware used to be mixed with the Non-Secure/Normal functions in ArmPlatformLib. When the Secure Firmware was not required for some platforms (eg: BeagleBoard), these functions were empty functions. This new interface has been created to clean the ArmPlatformLib interface between the SEC and PEI phases. Signed-off-by: Olivier Martin <olivier.martin@arm.com> git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@13260 6f19259b-4bc3-4df7-8a09-765794883524
This commit is contained in:
@@ -1,5 +1,5 @@
|
||||
//
|
||||
// Copyright (c) 2011, ARM Limited. All rights reserved.
|
||||
// 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
|
||||
@@ -18,7 +18,7 @@
|
||||
.align 3
|
||||
|
||||
GCC_ASM_EXPORT(ArmPlatformSecBootAction)
|
||||
GCC_ASM_EXPORT(ArmPlatformInitializeBootMemory)
|
||||
GCC_ASM_EXPORT(ArmPlatformSecBootMemoryInit)
|
||||
|
||||
/**
|
||||
Call at the beginning of the platform boot up
|
||||
@@ -42,6 +42,6 @@ ASM_PFX(ArmPlatformSecBootAction):
|
||||
pointer is not used (probably required to use assembly language)
|
||||
|
||||
**/
|
||||
ASM_PFX(ArmPlatformInitializeBootMemory):
|
||||
ASM_PFX(ArmPlatformSecBootMemoryInit):
|
||||
// The SMC does not need to be initialized for RTSM
|
||||
bx lr
|
@@ -1,5 +1,5 @@
|
||||
//
|
||||
// Copyright (c) 2011, ARM Limited. All rights reserved.
|
||||
// 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
|
||||
@@ -15,10 +15,10 @@
|
||||
#include <AutoGen.h>
|
||||
|
||||
EXPORT ArmPlatformSecBootAction
|
||||
EXPORT ArmPlatformInitializeBootMemory
|
||||
EXPORT ArmPlatformSecBootMemoryInit
|
||||
|
||||
PRESERVE8
|
||||
AREA ArmPlatformLibBoot, CODE, READONLY
|
||||
AREA ArmPlatformSecLibBoot, CODE, READONLY
|
||||
|
||||
/**
|
||||
Call at the beginning of the platform boot up
|
||||
@@ -42,6 +42,6 @@ ArmPlatformSecBootAction
|
||||
pointer is not used (probably required to use assembly language)
|
||||
|
||||
**/
|
||||
ArmPlatformInitializeBootMemory
|
||||
ArmPlatformSecBootMemoryInit
|
||||
// The SMC does not need to be initialized for RTSM
|
||||
bx lr
|
@@ -1,6 +1,6 @@
|
||||
/** @file
|
||||
*
|
||||
* Copyright (c) 2011, ARM Limited. All rights reserved.
|
||||
* 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
|
||||
@@ -24,7 +24,7 @@
|
||||
|
||||
**/
|
||||
VOID
|
||||
ArmPlatformTrustzoneInit (
|
||||
ArmPlatformSecTrustzoneInit (
|
||||
IN UINTN MpId
|
||||
)
|
||||
{
|
||||
@@ -43,12 +43,18 @@ ArmPlatformTrustzoneInit (
|
||||
For example, some L2x0 requires to be initialized in Secure World
|
||||
|
||||
**/
|
||||
VOID
|
||||
RETURN_STATUS
|
||||
ArmPlatformSecInitialize (
|
||||
VOID
|
||||
IN UINTN MpId
|
||||
)
|
||||
{
|
||||
// If it is not the primary core then there is nothing to do
|
||||
if (!IS_PRIMARY_CORE(MpId)) {
|
||||
return RETURN_SUCCESS;
|
||||
}
|
||||
|
||||
// Do nothing yet
|
||||
return RETURN_SUCCESS;
|
||||
}
|
||||
|
||||
/**
|
@@ -14,10 +14,10 @@
|
||||
[Defines]
|
||||
INF_VERSION = 0x00010005
|
||||
BASE_NAME = ArmPlatformLibSecNull
|
||||
FILE_GUID = 83333d9e-b00d-44cb-819c-e154c7efe79a
|
||||
FILE_GUID = a2cf63c6-d44f-4cd0-8af6-722a0138c021
|
||||
MODULE_TYPE = BASE
|
||||
VERSION_STRING = 1.0
|
||||
LIBRARY_CLASS = ArmPlatformLib
|
||||
LIBRARY_CLASS = ArmPlatformSecLib
|
||||
|
||||
[Packages]
|
||||
MdePkg/MdePkg.dec
|
||||
@@ -30,7 +30,6 @@
|
||||
DebugLib
|
||||
|
||||
[Sources.common]
|
||||
ArmPlatformLibNull.c
|
||||
ArmPlatformLibNullSec.c
|
||||
ArmPlatformLibNullBoot.asm | RVCT
|
||||
ArmPlatformLibNullBoot.S | GCC
|
Reference in New Issue
Block a user