• James Hogan's avatar
    KVM: MIPS: Use uaccess to read/modify guest instructions · dacc3ed1
    James Hogan authored
    Now that we have GVA page tables, use standard user accesses with page
    faults disabled to read & modify guest instructions. This should be more
    robust (than the rather dodgy method of accessing guest mapped segments
    by just directly addressing them) and will also work with Enhanced
    Virtual Addressing (EVA) host kernel configurations where dedicated
    instructions are needed for accessing user mode memory.
    
    For simplicity and speed we do this regardless of the guest segment the
    address resides in, rather than handling guest KSeg0 specially with
    kmap_atomic() as before.
    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
    dacc3ed1
kvm_host.h 28.3 KB