]> git.proxmox.com Git - mirror_edk2.git/blame - ArmPkg/Library/ArmLib/Arm11/Arm11Lib.c
ARM Packages: Removed trailing spaces
[mirror_edk2.git] / ArmPkg / Library / ArmLib / Arm11 / Arm11Lib.c
CommitLineData
0c0e7ef4 1/** @file\r
2\r
3 Copyright (c) 2008 - 2009, Apple Inc. All rights reserved.<BR>\r
4e57d6d7 4 Copyright (c) 2011 - 2014, ARM Limited. All rights reserved.\r
3402aac7 5\r
0c0e7ef4 6 This program and the accompanying materials\r
7 are licensed and made available under the terms and conditions of the BSD License\r
8 which accompanies this distribution. The full text of the license may be found at\r
9 http://opensource.org/licenses/bsd-license.php\r
10\r
11 THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,\r
12 WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.\r
13\r
14**/\r
15\r
16#include <Chipset/ARM1176JZ-S.h>\r
17\r
18#include <Library/ArmLib.h>\r
19#include <Library/DebugLib.h>\r
20#include <Library/PcdLib.h>\r
21\r
22VOID\r
23EFIAPI\r
24ArmWriteVBar (\r
4e57d6d7 25 IN UINTN VectorBase\r
0c0e7ef4 26 )\r
27{\r
28 ASSERT(FeaturePcdGet (PcdRelocateVectorTable) == TRUE);\r
29\r
30 if (VectorBase == 0x0) {\r
31 ArmSetLowVectors ();\r
32 } else if (VectorBase == 0xFFFF0000) {\r
33 ArmSetHighVectors ();\r
34 } else {\r
35 // Feature not supported by ARM11. The Vector Table is either at 0x0 or 0xFFFF0000\r
36 ASSERT(0);\r
37 }\r
38}\r
39\r
4e57d6d7 40UINTN\r
0c0e7ef4 41EFIAPI\r
42ArmReadVBar (\r
43 VOID\r
44 )\r
45{\r
46 ASSERT((FeaturePcdGet (PcdRelocateVectorTable) == TRUE) && ((PcdGet32 (PcdCpuVectorBaseAddress) == 0x0) || (PcdGet32 (PcdCpuVectorBaseAddress) == 0xFFFF0000)));\r
47 return PcdGet32 (PcdCpuVectorBaseAddress);\r
48}\r
49\r