diff options
-rw-r--r-- | ArmPkg/Library/ArmLib/ArmV7/ArmV7MPCore.c | 57 | ||||
-rw-r--r-- | ArmPkg/Library/ArmLib/ArmV7/ArmV7MPCoreHelper.S | 48 | ||||
-rw-r--r-- | ArmPkg/Library/ArmLib/ArmV7/ArmV7MPCoreHelper.asm | 48 | ||||
-rw-r--r-- | ArmPkg/Library/ArmLib/ArmV7/ArmV7MPCoreLib.inf | 52 | ||||
-rw-r--r-- | ArmPkg/Library/ArmLib/ArmV7/ArmV7MPCoreLibPrePi.inf | 50 | ||||
-rw-r--r-- | ArmPkg/Library/ArmLib/ArmV7/ArmV7MPCoreLibSec.inf | 46 | ||||
-rw-r--r-- | ArmPlatformPkg/ArmRealViewEbPkg/ArmRealViewEb-RTSM-A9x2.dsc | 6 | ||||
-rw-r--r-- | ArmPlatformPkg/ArmVExpressPkg/ArmVExpress-CTA9x4.dsc | 6 | ||||
-rw-r--r-- | ArmPlatformPkg/ArmVExpressPkg/ArmVExpress-RTSM-A9x4.dsc | 6 |
9 files changed, 9 insertions, 310 deletions
diff --git a/ArmPkg/Library/ArmLib/ArmV7/ArmV7MPCore.c b/ArmPkg/Library/ArmLib/ArmV7/ArmV7MPCore.c deleted file mode 100644 index 929140774c..0000000000 --- a/ArmPkg/Library/ArmLib/ArmV7/ArmV7MPCore.c +++ /dev/null @@ -1,57 +0,0 @@ -/** @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. -* -**/ - -#include <Uefi.h> -#include <Chipset/ArmV7.h> -#include <Library/ArmLib.h> -#include <Library/BaseLib.h> -#include <Library/IoLib.h> -#include "ArmV7Lib.h" -#include "ArmLibPrivate.h" - -VOID -EFIAPI -ArmSetupSmpNonSecure ( - IN UINTN CoreId - ) -{ - INTN scu_base; - - ArmSetAuxCrBit (A9_FEATURE_SMP); - - if (CoreId == 0) { - scu_base = ArmGetScuBaseAddress(); - - // Allow NS access to SCU register - MmioOr32(scu_base + SCU_SACR_OFFSET, 0xf); - // Allow NS access to Private Peripherals - MmioOr32(scu_base + SCU_SSACR_OFFSET, 0xfff); - } -} - -VOID -EFIAPI -ArmInvalidScu ( - VOID - ) -{ - INTN scu_base; - - scu_base = ArmGetScuBaseAddress(); - - // Invalidate all: write -1 to SCU Invalidate All register - MmioWrite32(scu_base + SCU_INVALL_OFFSET, 0xffffffff); - // Enable SCU - MmioWrite32(scu_base + SCU_CONTROL_OFFSET, 0x1); -} diff --git a/ArmPkg/Library/ArmLib/ArmV7/ArmV7MPCoreHelper.S b/ArmPkg/Library/ArmLib/ArmV7/ArmV7MPCoreHelper.S deleted file mode 100644 index da35a09b1d..0000000000 --- a/ArmPkg/Library/ArmLib/ArmV7/ArmV7MPCoreHelper.S +++ /dev/null @@ -1,48 +0,0 @@ -#
-# 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.
-#
-#
-
-#include <AsmMacroIoLib.h>
-#include <Base.h>
-#include <Library/PcdLib.h>
-#include <Chipset/ArmV7.h>
-#include <AutoGen.h>
-#.include AsmMacroIoLib.inc
-
-.text
-.align 2
-
-GCC_ASM_EXPORT(ArmIsScuEnable)
-GCC_ASM_EXPORT(ArmGetScuBaseAddress)
-
-# IN None
-# OUT r0 = SCU Base Address
-ASM_PFX(ArmGetScuBaseAddress):
- # Read Configuration Base Address Register. ArmCBar cannot be called to get
- # the Configuration BAR as a stack is not necessary setup. The SCU is at the
- # offset 0x0000 from the Private Memory Region.
- mrc p15, 4, r0, c15, c0, 0
- bx lr
-
-# IN None
-# OUT r1 = SCU enabled (boolean)
-ASM_PFX(ArmIsScuEnable):
- # Read Configuration Base Address Register. ArmCBar cannot be called to get
- # the Configuration BAR as a stack is not necessary setup. The SCU is at the
- # offset 0x0000 from the Private Memory Region.
- mrc p15, 4, r0, c15, c0, 0
- add r1, r0, #SCU_CONTROL_OFFSET
- ldr r1, [r1]
- and r1, r1, #1
- bx lr
-
-ASM_FUNCTION_REMOVE_IF_UNREFERENCED
diff --git a/ArmPkg/Library/ArmLib/ArmV7/ArmV7MPCoreHelper.asm b/ArmPkg/Library/ArmLib/ArmV7/ArmV7MPCoreHelper.asm deleted file mode 100644 index 6cc17c4c6a..0000000000 --- a/ArmPkg/Library/ArmLib/ArmV7/ArmV7MPCoreHelper.asm +++ /dev/null @@ -1,48 +0,0 @@ -//
-// 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.
-//
-//
-
-#include <AsmMacroIoLib.h>
-#include <Base.h>
-#include <Library/PcdLib.h>
-#include <Chipset/ArmV7.h>
-#include <AutoGen.h>
-
- INCLUDE AsmMacroIoLib.inc
-
- EXPORT ArmIsScuEnable
- EXPORT ArmGetScuBaseAddress
-
- AREA ArmV7MPCore, CODE, READONLY
-
-// IN None
-// OUT r0 = SCU Base Address
-ArmGetScuBaseAddress
- // Read Configuration Base Address Register. ArmCBar cannot be called to get
- // the Configuration BAR as a stack is not necessary setup. The SCU is at the
- // offset 0x0000 from the Private Memory Region.
- mrc p15, 4, r0, c15, c0, 0
- bx lr
-
-// IN None
-// OUT r1 = SCU enabled (boolean)
-ArmIsScuEnable
- // Read Configuration Base Address Register. ArmCBar cannot be called to get
- // the Configuration BAR as a stack is not necessary setup. The SCU is at the
- // offset 0x0000 from the Private Memory Region.
- mrc p15, 4, r0, c15, c0, 0
- add r1, r0, #SCU_CONTROL_OFFSET
- ldr r1, [r1]
- and r1, r1, #1
- bx lr
-
- END
diff --git a/ArmPkg/Library/ArmLib/ArmV7/ArmV7MPCoreLib.inf b/ArmPkg/Library/ArmLib/ArmV7/ArmV7MPCoreLib.inf deleted file mode 100644 index 17afbaf3b5..0000000000 --- a/ArmPkg/Library/ArmLib/ArmV7/ArmV7MPCoreLib.inf +++ /dev/null @@ -1,52 +0,0 @@ -#/** @file
-# Helper Library for ARMv7 MPCore architecture
-
-# 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.
-#
-#
-#**/
-
-[Defines]
- INF_VERSION = 0x00010005
- BASE_NAME = ArmV7Lib
- FILE_GUID = 411cdfd8-f964-4b9d-a3e3-1719a9c15559
- MODULE_TYPE = DXE_DRIVER
- VERSION_STRING = 1.0
- LIBRARY_CLASS = ArmLib
-
-[Sources.common]
- ArmLibSupport.S | GCC
- ArmLibSupport.asm | RVCT
- ../Common/ArmLib.c
-
- ArmV7Support.S | GCC
- ArmV7Support.asm | RVCT
-
- ArmV7Lib.c
- ArmV7Mmu.c
-
- ArmV7MPCore.c
- ArmV7MPCoreHelper.S | GCC
- ArmV7MPCoreHelper.asm | RVCT
-
-[Packages]
- ArmPkg/ArmPkg.dec
- MdePkg/MdePkg.dec
-
-[LibraryClasses]
- IoLib
- MemoryAllocationLib
-
-[Protocols]
- gEfiCpuArchProtocolGuid
-
-[FixedPcd]
- gArmTokenSpaceGuid.PcdArmCacheOperationThreshold
diff --git a/ArmPkg/Library/ArmLib/ArmV7/ArmV7MPCoreLibPrePi.inf b/ArmPkg/Library/ArmLib/ArmV7/ArmV7MPCoreLibPrePi.inf deleted file mode 100644 index 09c16db42a..0000000000 --- a/ArmPkg/Library/ArmLib/ArmV7/ArmV7MPCoreLibPrePi.inf +++ /dev/null @@ -1,50 +0,0 @@ -#/** @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.
-#
-#**/
-
-[Defines]
- INF_VERSION = 0x00010005
- BASE_NAME = ArmV7LibPrePi
- FILE_GUID = A150FA0C-F4E8-4207-9BEB-CD6DFB430D73
- MODULE_TYPE = BASE
- VERSION_STRING = 1.0
- LIBRARY_CLASS = ArmLib
-
-[Sources.common]
- ArmLibSupport.S | GCC
- ArmLibSupport.asm | RVCT
- ../Common/ArmLib.c
-
- ArmV7Support.S | GCC
- ArmV7Support.asm | RVCT
-
- ArmV7Lib.c
- ArmV7Mmu.c
-
- ArmV7MPCore.c
- ArmV7MPCoreHelper.S | GCC
- ArmV7MPCoreHelper.asm | RVCT
-
-[Packages]
- ArmPkg/ArmPkg.dec
- MdePkg/MdePkg.dec
-
-[LibraryClasses]
- IoLib
- PrePiLib
-
-[Protocols]
- gEfiCpuArchProtocolGuid
-
-[FixedPcd]
- gArmTokenSpaceGuid.PcdArmCacheOperationThreshold
diff --git a/ArmPkg/Library/ArmLib/ArmV7/ArmV7MPCoreLibSec.inf b/ArmPkg/Library/ArmLib/ArmV7/ArmV7MPCoreLibSec.inf deleted file mode 100644 index d3afed0aff..0000000000 --- a/ArmPkg/Library/ArmLib/ArmV7/ArmV7MPCoreLibSec.inf +++ /dev/null @@ -1,46 +0,0 @@ -#/* @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.
-#
-#*/
-
-[Defines]
- INF_VERSION = 0x00010005
- BASE_NAME = ArmV7Lib
- FILE_GUID = 411cdfd8-f964-4b9d-a3e3-1719a9c15559
- MODULE_TYPE = BASE
- VERSION_STRING = 1.0
- LIBRARY_CLASS = ArmLib
-
-[Sources.common]
- ArmLibSupport.S | GCC
- ArmLibSupport.asm | RVCT
- ../Common/ArmLib.c
-
- ArmV7Support.S | GCC
- ArmV7Support.asm | RVCT
-
- ArmV7Lib.c
- ArmV7MPCore.c
- ArmV7MPCoreHelper.S | GCC
- ArmV7MPCoreHelper.asm | RVCT
-
-[Packages]
- ArmPkg/ArmPkg.dec
- MdePkg/MdePkg.dec
-
-[LibraryClasses]
- IoLib
-
-[Protocols]
- gEfiCpuArchProtocolGuid
-
-[FixedPcd]
- gArmTokenSpaceGuid.PcdArmCacheOperationThreshold
diff --git a/ArmPlatformPkg/ArmRealViewEbPkg/ArmRealViewEb-RTSM-A9x2.dsc b/ArmPlatformPkg/ArmRealViewEbPkg/ArmRealViewEb-RTSM-A9x2.dsc index b17d59e0ee..9a144ca695 100644 --- a/ArmPlatformPkg/ArmRealViewEbPkg/ArmRealViewEb-RTSM-A9x2.dsc +++ b/ArmPlatformPkg/ArmRealViewEbPkg/ArmRealViewEb-RTSM-A9x2.dsc @@ -30,7 +30,7 @@ !include ArmPlatformPkg/ArmRealViewEbPkg/ArmRealViewEb.dsc.inc
[LibraryClasses.common]
- ArmLib|ArmPkg/Library/ArmLib/ArmV7/ArmV7MPCoreLib.inf
+ ArmLib|ArmPkg/Library/ArmLib/ArmV7/ArmV7Lib.inf
ArmCpuLib|ArmPkg/Drivers/ArmCpuLib/ArmCortexA9Lib/ArmCortexA9Lib.inf
ArmPlatformLib|ArmPlatformPkg/ArmRealViewEbPkg/Library/ArmRealViewEbLibRTSM/ArmRealViewEbLib.inf
@@ -39,7 +39,7 @@ ArmGicLib|ArmPkg/Drivers/PL390Gic/PL390GicLib.inf
[LibraryClasses.common.SEC]
- ArmLib|ArmPkg/Library/ArmLib/ArmV7/ArmV7MPCoreLibSec.inf
+ ArmLib|ArmPkg/Library/ArmLib/ArmV7/ArmV7LibSec.inf
ArmPlatformLib|ArmPlatformPkg/ArmRealViewEbPkg/Library/ArmRealViewEbLibRTSM/ArmRealViewEbSecLib.inf
[BuildOptions]
@@ -158,7 +158,7 @@ ArmPlatformPkg/PrePi/PeiMPCore.inf {
<LibraryClasses>
ArmGicSecLib|ArmPkg/Drivers/PL390Gic/PL390GicLib.inf
- ArmLib|ArmPkg/Library/ArmLib/ArmV7/ArmV7MPCoreLib.inf
+ ArmLib|ArmPkg/Library/ArmLib/ArmV7/ArmV7Lib.inf
ArmPlatformLib|ArmPlatformPkg/ArmRealViewEbPkg/Library/ArmRealViewEbLibRTSM/ArmRealViewEbLib.inf
}
!else
diff --git a/ArmPlatformPkg/ArmVExpressPkg/ArmVExpress-CTA9x4.dsc b/ArmPlatformPkg/ArmVExpressPkg/ArmVExpress-CTA9x4.dsc index 1324da2cd4..7c198fb56c 100644 --- a/ArmPlatformPkg/ArmVExpressPkg/ArmVExpress-CTA9x4.dsc +++ b/ArmPlatformPkg/ArmVExpressPkg/ArmVExpress-CTA9x4.dsc @@ -34,7 +34,7 @@ !include ArmPlatformPkg/ArmVExpressPkg/ArmVExpress.dsc.inc [LibraryClasses.common] - ArmLib|ArmPkg/Library/ArmLib/ArmV7/ArmV7MPCoreLib.inf + ArmLib|ArmPkg/Library/ArmLib/ArmV7/ArmV7Lib.inf ArmCpuLib|ArmPkg/Drivers/ArmCpuLib/ArmCortexA9Lib/ArmCortexA9Lib.inf ArmPlatformLib|ArmPlatformPkg/ArmVExpressPkg/Library/ArmVExpressLibCTA9x4/ArmVExpressLib.inf ArmTrustZoneLib|ArmPkg/Library/ArmTrustZoneLib/ArmTrustZoneLib.inf @@ -53,7 +53,7 @@ LcdPlatformLib|ArmPlatformPkg/ArmVExpressPkg/Library/PL111LcdArmVExpressLib/PL111LcdArmVExpressLib.inf [LibraryClasses.common.SEC] - ArmLib|ArmPkg/Library/ArmLib/ArmV7/ArmV7MPCoreLibSec.inf + ArmLib|ArmPkg/Library/ArmLib/ArmV7/ArmV7LibSec.inf ArmPlatformLib|ArmPlatformPkg/ArmVExpressPkg/Library/ArmVExpressLibCTA9x4/ArmVExpressSecLib.inf # Uncomment to turn on GDB stub in SEC. @@ -271,7 +271,7 @@ ArmPlatformPkg/PrePi/PeiMPCore.inf { <LibraryClasses> ArmGicSecLib|ArmPkg/Drivers/PL390Gic/PL390GicLib.inf - ArmLib|ArmPkg/Library/ArmLib/ArmV7/ArmV7MPCoreLib.inf + ArmLib|ArmPkg/Library/ArmLib/ArmV7/ArmV7Lib.inf ArmPlatformLib|ArmPlatformPkg/ArmVExpressPkg/Library/ArmVExpressLibCTA9x4/ArmVExpressLib.inf ArmPlatformGlobalVariableLib|ArmPlatformPkg/Library/ArmPlatformGlobalVariableLib/PrePi/PrePiArmPlatformGlobalVariableLib.inf } diff --git a/ArmPlatformPkg/ArmVExpressPkg/ArmVExpress-RTSM-A9x4.dsc b/ArmPlatformPkg/ArmVExpressPkg/ArmVExpress-RTSM-A9x4.dsc index 5f456a2fc0..f8a83e5c4a 100644 --- a/ArmPlatformPkg/ArmVExpressPkg/ArmVExpress-RTSM-A9x4.dsc +++ b/ArmPlatformPkg/ArmVExpressPkg/ArmVExpress-RTSM-A9x4.dsc @@ -30,7 +30,7 @@ !include ArmPlatformPkg/ArmVExpressPkg/ArmVExpress.dsc.inc [LibraryClasses.common] - ArmLib|ArmPkg/Library/ArmLib/ArmV7/ArmV7MPCoreLib.inf + ArmLib|ArmPkg/Library/ArmLib/ArmV7/ArmV7Lib.inf ArmCpuLib|ArmPkg/Drivers/ArmCpuLib/ArmCortexA9Lib/ArmCortexA9Lib.inf ArmPlatformLib|ArmPlatformPkg/ArmVExpressPkg/Library/ArmVExpressLibRTSM/ArmVExpressLib.inf @@ -41,7 +41,7 @@ #DebugAgentTimerLib|ArmPlatformPkg/ArmVExpressPkg/Library/DebugAgentTimerLib/DebugAgentTimerLib.inf [LibraryClasses.common.SEC] - ArmLib|ArmPkg/Library/ArmLib/ArmV7/ArmV7MPCoreLibSec.inf + ArmLib|ArmPkg/Library/ArmLib/ArmV7/ArmV7LibSec.inf ArmPlatformLib|ArmPlatformPkg/ArmVExpressPkg/Library/ArmVExpressLibRTSM/ArmVExpressSecLib.inf # Uncomment to turn on GDB stub in SEC. @@ -191,7 +191,7 @@ ArmPlatformPkg/PrePi/PeiMPCore.inf { <LibraryClasses> ArmGicSecLib|ArmPkg/Drivers/PL390Gic/PL390GicLib.inf - ArmLib|ArmPkg/Library/ArmLib/ArmV7/ArmV7MPCoreLib.inf + ArmLib|ArmPkg/Library/ArmLib/ArmV7/ArmV7Lib.inf ArmPlatformLib|ArmPlatformPkg/ArmVExpressPkg/Library/ArmVExpressLibRTSM/ArmVExpressLib.inf ArmPlatformGlobalVariableLib|ArmPlatformPkg/Library/ArmPlatformGlobalVariableLib/PrePi/PrePiArmPlatformGlobalVariableLib.inf } |