3 Copyright (c) 2014, Intel Corporation. All rights reserved.<BR>
4 This program and the accompanying materials
5 are licensed and made available under the terms and conditions of the BSD License
6 which accompanies this distribution. The full text of the license may be found at
7 http://opensource.org/licenses/bsd-license.php.
9 THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
10 WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
18 // EFI_MEMORY_CACHE_TYPE
20 typedef INT32 EFI_MEMORY_CACHE_TYPE
;
22 #define EFI_CACHE_UNCACHEABLE 0
23 #define EFI_CACHE_WRITECOMBINING 1
24 #define EFI_CACHE_WRITETHROUGH 4
25 #define EFI_CACHE_WRITEPROTECTED 5
26 #define EFI_CACHE_WRITEBACK 6
29 Reset all the MTRRs to a known state.
31 @retval EFI_SUCCESS All MTRRs have been reset successfully.
36 ResetCacheAttributes (
41 Given the memory range and cache type, programs the MTRRs.
43 @param[in] MemoryAddress Base Address of Memory to program MTRR.
44 @param[in] MemoryLength Length of Memory to program MTRR.
45 @param[in] MemoryCacheType Cache Type.
47 @retval EFI_SUCCESS Mtrr are set successfully.
48 @retval EFI_LOAD_ERROR No empty MTRRs to use.
49 @retval EFI_INVALID_PARAMETER The input parameter is not valid.
50 @retval others An error occurs when setting MTTR.
56 IN EFI_PHYSICAL_ADDRESS MemoryAddress
,
57 IN UINT64 MemoryLength
,
58 IN EFI_MEMORY_CACHE_TYPE MemoryCacheType