]> git.proxmox.com Git - mirror_edk2.git/blob - ArmPkg/Library/ArmLib/Arm/ArmV7Lib.h
ArmPkg: Fix Ecc error 8003
[mirror_edk2.git] / ArmPkg / Library / ArmLib / Arm / ArmV7Lib.h
1 /** @file
2
3 Copyright (c) 2008 - 2009, Apple Inc. All rights reserved.<BR>
4
5 SPDX-License-Identifier: BSD-2-Clause-Patent
6
7 **/
8
9 #ifndef ARM_V7_LIB_H_
10 #define ARM_V7_LIB_H_
11
12 #define ID_MMFR0_SHARELVL_SHIFT 12
13 #define ID_MMFR0_SHARELVL_MASK 0xf
14 #define ID_MMFR0_SHARELVL_ONE 0
15 #define ID_MMFR0_SHARELVL_TWO 1
16
17 #define ID_MMFR0_INNERSHR_SHIFT 28
18 #define ID_MMFR0_INNERSHR_MASK 0xf
19 #define ID_MMFR0_OUTERSHR_SHIFT 8
20 #define ID_MMFR0_OUTERSHR_MASK 0xf
21
22 #define ID_MMFR0_SHR_IMP_UNCACHED 0
23 #define ID_MMFR0_SHR_IMP_HW_COHERENT 1
24 #define ID_MMFR0_SHR_IGNORED 0xf
25
26 typedef VOID (*ARM_V7_CACHE_OPERATION)(UINT32);
27
28 VOID
29 ArmV7AllDataCachesOperation (
30 IN ARM_V7_CACHE_OPERATION DataCacheOperation
31 );
32
33 VOID
34 EFIAPI
35 ArmInvalidateDataCacheEntryBySetWay (
36 IN UINTN SetWayFormat
37 );
38
39 VOID
40 EFIAPI
41 ArmCleanDataCacheEntryBySetWay (
42 IN UINTN SetWayFormat
43 );
44
45 VOID
46 EFIAPI
47 ArmCleanInvalidateDataCacheEntryBySetWay (
48 IN UINTN SetWayFormat
49 );
50
51 /** Reads the ID_MMFR4 register.
52
53 @return The contents of the ID_MMFR4 register.
54 **/
55 UINT32
56 EFIAPI
57 ArmReadIdMmfr4 (
58 VOID
59 );
60
61 UINTN
62 EFIAPI
63 ArmReadIdPfr1 (
64 VOID
65 );
66
67 #endif // ARM_V7_LIB_H_
68