]> git.baikalelectronics.ru Git - kernel.git/commit
KVM: MIPS: Init timer frequency from callback
authorJames Hogan <james.hogan@imgtec.com>
Tue, 14 Mar 2017 10:15:21 +0000 (10:15 +0000)
committerJames Hogan <james.hogan@imgtec.com>
Tue, 28 Mar 2017 13:53:48 +0000 (14:53 +0100)
commitb06cb03a6e85467770b3977be5c1ef3db79985fe
tree1601c684dbbfde8c0e2a6a37c5a9151853a96242
parent5c05787bdcac070ddafd1e0cdbbbc421ba2639fc
KVM: MIPS: Init timer frequency from callback

Currently the software emulated timer is initialised to a frequency of
100MHz by kvm_mips_init_count(), but this isn't suitable for VZ where
the frequency of the guest timer matches that of the host.

Add a count_hz argument so the caller can specify the default frequency,
and move the call from kvm_arch_vcpu_create() to the implementation
specific vcpu_setup() callback, so that VZ can specify a different
frequency.

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
arch/mips/include/asm/kvm_host.h
arch/mips/kvm/emulate.c
arch/mips/kvm/mips.c
arch/mips/kvm/trap_emul.c