• Junaid Shahid's avatar
    kvm: vmx: Sync all matching EPTPs when injecting nested EPT fault · 85aa8889
    Junaid Shahid authored
    When a nested EPT violation/misconfig is injected into the guest,
    the shadow EPT PTEs associated with that address need to be synced.
    This is done by kvm_inject_emulated_page_fault() before it calls
    nested_ept_inject_page_fault(). However, that will only sync the
    shadow EPT PTE associated with the current L1 EPTP. Since the ASID
    is based on EP4TA rather than the full EPTP, so syncing the current
    EPTP is not enough. The SPTEs associated with any other L1 EPTPs
    in the prev_roots cache with the same EP4TA also need to be synced.
    Signed-off-by: default avatarJunaid Shahid <junaids@google.com>
    Message-Id: <20210806222229.1645356-1-junaids@google.com>
    Signed-off-by: default avatarPaolo Bonzini <pbonzini@redhat.com>
    85aa8889
nested.c 206 KB