This maybe an error in the AMD white paper "AMD nested paging", issued on July 2008, revision 1.0
The error is about Figure 5 in the white paper.
When doing nested paging, the very first step should translate gCR3, which is a guest physical address (GPA) to system physical address (SPA) using the nested walk as shown in top of Figure 4. After that we can use the SPA and the guest virtual address[47:39] to get the entry in guest page table L4.
However, in figure 5, we can see that the first step is to combine gCR3 and gVA[47:39], which is wrong. The guest page table walk should happened after the nested page walk. So the correction should be removing the gVA in each row after nL1 such that the gVA could be combined with SPA to find the guest page table entry.
Please correct me if there is any misunderstanding.
- Hui