]> git.baikalelectronics.ru Git - kernel.git/commit
MIPS: KVM: Add KScratch registers
authorJames Hogan <james.hogan@imgtec.com>
Wed, 15 Jun 2016 18:29:56 +0000 (19:29 +0100)
committerPaolo Bonzini <pbonzini@redhat.com>
Wed, 15 Jun 2016 21:58:36 +0000 (23:58 +0200)
commit192178b48d6c6fa60bb117bcbe060c41c3629c0c
treeedeb52dafa9ad08820c15d4cbbc0a4e589d9914c
parentc7c6c9b0e5b9172cfefad335dd7b6491c736cfb3
MIPS: KVM: Add KScratch registers

Allow up to 6 KVM guest KScratch registers to be enabled and accessed
via the KVM guest register API and from the guest itself (the fallback
reading and writing of commpage registers is sufficient for KScratch
registers to work as expected).

User mode can expose the registers by setting the appropriate bits of
the guest Config4.KScrExist field. KScratch registers that aren't usable
won't be writeable via the KVM Ioctl API.

Signed-off-by: James 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
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
Documentation/virtual/kvm/api.txt
arch/mips/include/asm/kvm_host.h
arch/mips/kvm/emulate.c
arch/mips/kvm/mips.c
arch/mips/kvm/trace.h
arch/mips/kvm/trap_emul.c