IntelSiliconPkg IntelVTdDxe: Fix DMA does not work issue
Fix DMA does not work issue when system memory is not
greater than 4G.
Cc: Jiewen Yao <jiewen.yao@intel.com>
Contributed-under: TianoCore Contribution Agreement 1.1
Signed-off-by: Star Zeng <star.zeng@intel.com>
Reviewed-by: Jiewen Yao <jiewen.yao@intel.com>
(cherry picked from commit 1d4c17a6ef
)
This commit is contained in:
@@ -286,9 +286,13 @@ CreateSecondLevelPagingEntry (
|
|||||||
if (SecondLevelPagingEntry == NULL) {
|
if (SecondLevelPagingEntry == NULL) {
|
||||||
return NULL;
|
return NULL;
|
||||||
}
|
}
|
||||||
SecondLevelPagingEntry = CreateSecondLevelPagingEntryTable (VtdIndex, SecondLevelPagingEntry, SIZE_4GB, mAbove4GMemoryLimit, IoMmuAccess);
|
|
||||||
if (SecondLevelPagingEntry == NULL) {
|
if (mAbove4GMemoryLimit != 0) {
|
||||||
return NULL;
|
ASSERT (mAbove4GMemoryLimit > BASE_4GB);
|
||||||
|
SecondLevelPagingEntry = CreateSecondLevelPagingEntryTable (VtdIndex, SecondLevelPagingEntry, SIZE_4GB, mAbove4GMemoryLimit, IoMmuAccess);
|
||||||
|
if (SecondLevelPagingEntry == NULL) {
|
||||||
|
return NULL;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
return SecondLevelPagingEntry;
|
return SecondLevelPagingEntry;
|
||||||
|
Reference in New Issue
Block a user