diff options
author | oliviermartin <oliviermartin@6f19259b-4bc3-4df7-8a09-765794883524> | 2012-05-02 20:14:55 +0000 |
---|---|---|
committer | oliviermartin <oliviermartin@6f19259b-4bc3-4df7-8a09-765794883524> | 2012-05-02 20:14:55 +0000 |
commit | 9d59a88be171f74ae08ad63b3e8d1b77a87522e8 (patch) | |
tree | a4ba07b79e7c40e4b2dab5a4fdc0067a7e100cbd /ArmPkg | |
parent | e314d564db4d52a9e904f6049dad7fc5dece5cb4 (diff) | |
download | edk2-9d59a88be171f74ae08ad63b3e8d1b77a87522e8.zip edk2-9d59a88be171f74ae08ad63b3e8d1b77a87522e8.tar.gz edk2-9d59a88be171f74ae08ad63b3e8d1b77a87522e8.tar.bz2 |
ArmPkg/ArmCpuLib: Fixed SMP Cortex-A9 and Cortex-A15
Signed-off-by: Olivier Martin <olivier.martin@arm.com>
git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@13261 6f19259b-4bc3-4df7-8a09-765794883524
Diffstat (limited to 'ArmPkg')
-rw-r--r-- | ArmPkg/Drivers/ArmCpuLib/ArmCortexA15Lib/ArmCortexA15Lib.c | 11 | ||||
-rw-r--r-- | ArmPkg/Drivers/ArmCpuLib/ArmCortexA9Lib/ArmCortexA9Lib.c | 5 | ||||
-rw-r--r-- | ArmPkg/Include/Chipset/ArmCortexA15.h | 25 |
3 files changed, 33 insertions, 8 deletions
diff --git a/ArmPkg/Drivers/ArmCpuLib/ArmCortexA15Lib/ArmCortexA15Lib.c b/ArmPkg/Drivers/ArmCpuLib/ArmCortexA15Lib/ArmCortexA15Lib.c index 9b64d66..95ab073 100644 --- a/ArmPkg/Drivers/ArmCpuLib/ArmCortexA15Lib/ArmCortexA15Lib.c +++ b/ArmPkg/Drivers/ArmCpuLib/ArmCortexA15Lib/ArmCortexA15Lib.c @@ -20,7 +20,7 @@ #include <Library/IoLib.h>
#include <Library/PcdLib.h>
-#include <Chipset/ArmV7.h>
+#include <Chipset/ArmCortexA15.h>
VOID
ArmCpuSetup (
@@ -41,10 +41,11 @@ ArmCpuSetup ( // if security extensions are implemented.
ArmArchTimerSetTimerFreq (PcdGet32 (PcdArmArchTimerFreqInHz));
- /*// If MPCore then Enable the SCU
if (ArmIsMpCore()) {
- ArmEnableScu ();
- }*/
+ // Turn on SMP coherency
+ ArmSetAuxCrBit (A15_FEATURE_SMP);
+ }
+
}
@@ -53,8 +54,6 @@ ArmCpuSetupSmpNonSecure ( IN UINTN MpId
)
{
- //ArmSetAuxCrBit (A15_FEATURE_SMP);
-
/*// Make the SCU accessible in Non Secure world
if (IS_PRIMARY_CORE(MpId)) {
ScuBase = ArmGetScuBaseAddress();
diff --git a/ArmPkg/Drivers/ArmCpuLib/ArmCortexA9Lib/ArmCortexA9Lib.c b/ArmPkg/Drivers/ArmCpuLib/ArmCortexA9Lib/ArmCortexA9Lib.c index 324ddb5..8d9530c 100644 --- a/ArmPkg/Drivers/ArmCpuLib/ArmCortexA9Lib/ArmCortexA9Lib.c +++ b/ArmPkg/Drivers/ArmCpuLib/ArmCortexA9Lib/ArmCortexA9Lib.c @@ -48,6 +48,9 @@ ArmCpuSetup ( // If MPCore then Enable the SCU
if (ArmIsMpCore()) {
+ // Signals the Cortex-A9 processor is taking part in coherency
+ ArmSetAuxCrBit (A9_FEATURE_SMP);
+
ArmEnableScu ();
}
}
@@ -60,8 +63,6 @@ ArmCpuSetupSmpNonSecure ( {
INTN ScuBase;
- ArmSetAuxCrBit (A9_FEATURE_SMP);
-
// Make the SCU accessible in Non Secure world
if (IS_PRIMARY_CORE(MpId)) {
ScuBase = ArmGetScuBaseAddress();
diff --git a/ArmPkg/Include/Chipset/ArmCortexA15.h b/ArmPkg/Include/Chipset/ArmCortexA15.h new file mode 100644 index 0000000..5f71567 --- /dev/null +++ b/ArmPkg/Include/Chipset/ArmCortexA15.h @@ -0,0 +1,25 @@ +/** @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.
+
+**/
+
+#ifndef __ARM_CORTEX_A15_H__
+#define __ARM_CORTEX_A15_H__
+
+#include <Chipset/ArmV7.h>
+
+//
+// Cortex A15 feature bit definitions
+//
+#define A15_FEATURE_SMP (1<<6)
+
+#endif
|