blob: 963fe092cff73ffa4a4281f0eaa268901bdaf171 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
|
/** @file
Copyright (c) 2024, Intel Corporation. All rights reserved.<BR>
SPDX-License-Identifier: BSD-2-Clause-Patent
**/
#include "PiSmmCpuCommon.h"
BOOLEAN mIsRestrictedMemoryAccess = TRUE;
BOOLEAN mIsRestrictedMemoryAccessInitialized = FALSE;
/**
Return whether access to non-SMRAM is restricted.
@retval TRUE Access to non-SMRAM is restricted.
@retval FALSE Access to non-SMRAM is not restricted.
**/
BOOLEAN
IsRestrictedMemoryAccess (
VOID
)
{
if (!mIsRestrictedMemoryAccessInitialized) {
mIsRestrictedMemoryAccess = PcdGetBool (PcdCpuSmmRestrictedMemoryAccess);
mIsRestrictedMemoryAccessInitialized = TRUE;
}
return mIsRestrictedMemoryAccess;
}
|