UefiCpuPkg/MtrrLib: Update MtrrGetFixedMtrr().
IsMtrrSupported() return true when either fixed mtrr supported or variable mtrr suppored. In this case, rather than checking whether MTRR is supported or not, we should specifically check for fixed MTRR support. Signed-off-by: Yuanhao Xie <yuanhao.xie@intel.com> Cc: Eric Dong <eric.dong@intel.com> Cc: Rahul Kumar <rahul1.kumar@intel.com> Cc: Gerd Hoffmann <kraxel@redhat.com> Cc: Ray Ni <ray.ni@intel.com> Reviewed-by: Eric Dong <eric.dong@intel.com> Reviewed-by: Ray Ni <ray.ni@intel.com>
This commit is contained in:
@@ -468,7 +468,11 @@ MtrrGetFixedMtrr (
|
||||
OUT MTRR_FIXED_SETTINGS *FixedSettings
|
||||
)
|
||||
{
|
||||
if (!IsMtrrSupported ()) {
|
||||
BOOLEAN FixedMtrrSupported;
|
||||
|
||||
MtrrLibIsMtrrSupported (&FixedMtrrSupported, NULL);
|
||||
|
||||
if (!FixedMtrrSupported) {
|
||||
return FixedSettings;
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user