diff options
author | andrewfish <andrewfish@6f19259b-4bc3-4df7-8a09-765794883524> | 2010-02-24 22:38:46 +0000 |
---|---|---|
committer | andrewfish <andrewfish@6f19259b-4bc3-4df7-8a09-765794883524> | 2010-02-24 22:38:46 +0000 |
commit | 026c3d34ee83b4df623cc80761450a53e9f7622b (patch) | |
tree | 093ad41be275694e4a107bc0775853afcc59dc70 /ArmPkg/Library/ArmLib/Arm11 | |
parent | 14e00c13be4ead51d9fd38e07af661af63ca2359 (diff) | |
download | edk2-platforms-026c3d34ee83b4df623cc80761450a53e9f7622b.tar.xz |
Updated Hardware Interrupt protocol to add an EOI member. Added ARM Data/Instruction syncronization barrier support to the ARM lib.
git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@10063 6f19259b-4bc3-4df7-8a09-765794883524
Diffstat (limited to 'ArmPkg/Library/ArmLib/Arm11')
-rw-r--r-- | ArmPkg/Library/ArmLib/Arm11/Arm11Lib.c | 31 | ||||
-rw-r--r-- | ArmPkg/Library/ArmLib/Arm11/Arm11Support.S | 20 | ||||
-rw-r--r-- | ArmPkg/Library/ArmLib/Arm11/Arm11Support.asm | 18 |
3 files changed, 69 insertions, 0 deletions
diff --git a/ArmPkg/Library/ArmLib/Arm11/Arm11Lib.c b/ArmPkg/Library/ArmLib/Arm11/Arm11Lib.c index 3736904954..6f0f599d93 100644 --- a/ArmPkg/Library/ArmLib/Arm11/Arm11Lib.c +++ b/ArmPkg/Library/ArmLib/Arm11/Arm11Lib.c @@ -116,3 +116,34 @@ ArmConfigureMmu ( ArmEnableDataCache(); ArmEnableMmu(); } + + +VOID +EFIAPI +ArmDataMemoryBarrier ( + VOID + ) +{ + // Should move to assembly with the +} + +VOID +EFIAPI +ArmDataSyncronizationBarrier ( + VOID + ) +{ +// MOV R0, #0 +// MCR P15, #0, R0, C7, C10, #4} +} + + +VOID +EFIAPI +ArmInstructionSynchronizationBarrier ( + VOID + ) +{ +} + + diff --git a/ArmPkg/Library/ArmLib/Arm11/Arm11Support.S b/ArmPkg/Library/ArmLib/Arm11/Arm11Support.S index e3b7746317..6d178b107f 100644 --- a/ArmPkg/Library/ArmLib/Arm11/Arm11Support.S +++ b/ArmPkg/Library/ArmLib/Arm11/Arm11Support.S @@ -30,6 +30,10 @@ .globl ASM_PFX(ArmDisableInstructionCache) .globl ASM_PFX(ArmEnableBranchPrediction) .globl ASM_PFX(ArmDisableBranchPrediction) +.globl ASM_PFX(ArmDataMemoryBarrier) +.globl ASM_PFX(ArmDataSyncronizationBarrier) +.globl ASM_PFX(ArmInstructionSynchronizationBarrier) + .set DC_ON, (0x1<<2) .set IC_ON, (0x1<<12) @@ -132,4 +136,20 @@ ASM_PFX(ArmDisableBranchPrediction): mcr p15, 0, r0, c1, c0, 0 bx LR +ASM_PFX(ArmDataMemoryBarrier): + mov R0, #0 + mcr P15, #0, R0, C7, C10, #5 + bx LR + +ASM_PFX(ArmDataSyncronizationBarrier): + mov R0, #0 + mcr P15, #0, R0, C7, C10, #4 + bx LR + +ASM_PFX(ArmInstructionSynchronizationBarrier): + mov R0, #0 + mcr P15, #0, R0, C7, C5, #4 + bx LR + + ASM_FUNCTION_REMOVE_IF_UNREFERENCED diff --git a/ArmPkg/Library/ArmLib/Arm11/Arm11Support.asm b/ArmPkg/Library/ArmLib/Arm11/Arm11Support.asm index a2ed2e6f2a..546503b75c 100644 --- a/ArmPkg/Library/ArmLib/Arm11/Arm11Support.asm +++ b/ArmPkg/Library/ArmLib/Arm11/Arm11Support.asm @@ -28,6 +28,9 @@ EXPORT ArmDisableInstructionCache EXPORT ArmEnableBranchPrediction EXPORT ArmDisableBranchPrediction + EXPORT ArmDataMemoryBarrier + EXPORT ArmDataSyncronizationBarrier + EXPORT ArmInstructionSynchronizationBarrier DC_ON EQU ( 0x1:SHL:2 ) @@ -136,4 +139,19 @@ ArmDisableBranchPrediction mcr p15, 0, r0, c1, c0, 0 bx LR +ASM_PFX(ArmDataMemoryBarrier): + mov R0, #0 + mcr P15, #0, R0, C7, C10, #5 + bx LR + +ASM_PFX(ArmDataSyncronizationBarrier): + mov R0, #0 + mcr P15, #0, R0, C7, C10, #4 + bx LR + +ASM_PFX(ArmInstructionSynchronizationBarrier): + MOV R0, #0 + MCR P15, #0, R0, C7, C5, #4 + bx LR + END |