Correct 1G page table generation.

git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@12380 6f19259b-4bc3-4df7-8a09-765794883524
This commit is contained in:
jyao1 2011-09-19 13:02:05 +00:00
parent df692f024b
commit 54d3b84e3e
4 changed files with 4 additions and 8 deletions

View File

@ -299,8 +299,7 @@ S3CreateIdentityMappingPageTables (
PageMapLevel4Entry->Bits.Present = 1;
if (Page1GSupport) {
PageDirectory1GEntry = (PAGE_TABLE_1G_ENTRY *)(UINTN)S3NvsPageTableAddress;
S3NvsPageTableAddress += SIZE_4KB;
PageDirectory1GEntry = (PAGE_TABLE_1G_ENTRY *)(UINTN)PageDirectoryPointerEntry;
for (IndexOfPageDirectoryEntries = 0; IndexOfPageDirectoryEntries < 512; IndexOfPageDirectoryEntries++, PageDirectory1GEntry++, PageAddress += SIZE_1GB) {
//

View File

@ -144,8 +144,7 @@ CreateIdentityMappingPageTables (
PageMapLevel4Entry->Bits.Present = 1;
if (Page1GSupport) {
PageDirectory1GEntry = (VOID *) BigPageAddress;
BigPageAddress += SIZE_4KB;
PageDirectory1GEntry = (VOID *) PageDirectoryPointerEntry;
for (IndexOfPageDirectoryEntries = 0; IndexOfPageDirectoryEntries < 512; IndexOfPageDirectoryEntries++, PageDirectory1GEntry++, PageAddress += SIZE_1GB) {
//

View File

@ -218,8 +218,7 @@ CreateIdentityMappingPageTables (
PageMapLevel4Entry->Bits.Present = 1;
if (Page1GSupport) {
PageDirectory1GEntry = (VOID *) BigPageAddress;
BigPageAddress += SIZE_4KB;
PageDirectory1GEntry = (VOID *) PageDirectoryPointerEntry;
for (IndexOfPageDirectoryEntries = 0; IndexOfPageDirectoryEntries < 512; IndexOfPageDirectoryEntries++, PageDirectory1GEntry++, PageAddress += SIZE_1GB) {
//

View File

@ -579,8 +579,7 @@ RestoreS3PageTables (
PageMapLevel4Entry->Bits.Present = 1;
if (Page1GSupport) {
PageDirectory1GEntry = (VOID *) S3NvsPageTableAddress;
S3NvsPageTableAddress += SIZE_4KB;
PageDirectory1GEntry = (VOID *) PageDirectoryPointerEntry;
for (IndexOfPageDirectoryEntries = 0; IndexOfPageDirectoryEntries < 512; IndexOfPageDirectoryEntries++, PageDirectory1GEntry++, PageAddress += SIZE_1GB) {
//