]>
git.proxmox.com Git - mirror_edk2.git/blob - ArmPkg/Library/ArmLib/ArmLib.c
3 Copyright (c) 2008 - 2009, Apple Inc. All rights reserved.<BR>
4 Copyright (c) 2011 - 2021, ARM Ltd. All rights reserved.<BR>
6 SPDX-License-Identifier: BSD-2-Clause-Patent
12 #include <Library/ArmLib.h>
14 #include "ArmLibPrivate.h"
22 ArmWriteAuxCr (ArmReadAuxCr () | Bits
);
31 ArmWriteAuxCr (ArmReadAuxCr () & ~Bits
);
35 // Helper functions for accessing CPUACTLR
44 ArmWriteCpuActlr (ArmReadCpuActlr () | Bits
);
53 ArmWriteCpuActlr (ArmReadCpuActlr () & ~Bits
);
58 ArmDataCacheLineLength (
62 return 4 << ((ArmCacheInfo () >> 16) & 0xf); // CTR_EL0.DminLine
67 ArmInstructionCacheLineLength (
71 return 4 << (ArmCacheInfo () & 0xf); // CTR_EL0.IminLine
76 ArmCacheWritebackGranule (
82 CWG
= (ArmCacheInfo () >> 24) & 0xf; // CTR_EL0.CWG