• James Hogan's avatar
    MIPS: KVM: Add missing gfn range check · 8985d503
    James Hogan authored
    kvm_mips_handle_mapped_seg_tlb_fault() calculates the guest frame number
    based on the guest TLB EntryLo values, however it is not range checked
    to ensure it lies within the guest_pmap. If the physical memory the
    guest refers to is out of range then dump the guest TLB and emit an
    internal error.
    
    Fixes: 858dd5d4 ("KVM/MIPS32: MMU/TLB operations for the Guest.")
    Signed-off-by: default avatarJames Hogan <james.hogan@imgtec.com>
    Cc: Paolo Bonzini <pbonzini@redhat.com>
    Cc: "Radim Krčmář" <rkrcmar@redhat.com>
    Cc: Ralf Baechle <ralf@linux-mips.org>
    Cc: linux-mips@linux-mips.org
    Cc: kvm@vger.kernel.org
    Cc: <stable@vger.kernel.org> # 3.10.x-
    Signed-off-by: default avatarRadim Krčmář <rkrcmar@redhat.com>
    8985d503
mmu.c 10.5 KB