MIPS: Probe guest CP0_UserLocal
authorJames Hogan <james.hogan@imgtec.com>
Tue, 14 Mar 2017 10:15:10 +0000 (10:15 +0000)
committerJames Hogan <james.hogan@imgtec.com>
Tue, 28 Mar 2017 13:49:11 +0000 (14:49 +0100)
commita7c7ad6c3e0a2ae88625df4e41c1c7305aa26f04
tree9839db3c2e78e23f16b464f18cbf28e06946e959
parentf359a1115519122c7c3bc7fc4a01797dcf576709
MIPS: Probe guest CP0_UserLocal

Probe for presence of guest CP0_UserLocal register and expose via
cpu_guest_has_userlocal. This register is optional pre-r6, so this will
allow KVM to only save/restore/expose the guest CP0_UserLocal register
if it exists.

Signed-off-by: James Hogan <james.hogan@imgtec.com>
Acked-by: Ralf Baechle <ralf@linux-mips.org>
Cc: Paolo Bonzini <pbonzini@redhat.com>
Cc: "Radim Krčmář" <rkrcmar@redhat.com>
Cc: linux-mips@linux-mips.org
Cc: kvm@vger.kernel.org
arch/mips/include/asm/cpu-features.h
arch/mips/kernel/cpu-probe.c