]> git.baikalelectronics.ru Git - kernel.git/commit
KVM: PPC: Move vcpu_load/vcpu_put down to each ioctl case in kvm_arch_vcpu_ioctl
authorSimon Guo <wei.guo.simon@gmail.com>
Wed, 23 May 2018 07:02:09 +0000 (15:02 +0800)
committerPaul Mackerras <paulus@ozlabs.org>
Fri, 1 Jun 2018 00:30:53 +0000 (10:30 +1000)
commit9cd702fc907491c014d37f2fd8000a81c7b94c9b
treebfba142405d95d36da14b680c0705e9697ba4dbd
parent50c0f197821be7f73be9f0013581fe1ebe70c653
KVM: PPC: Move vcpu_load/vcpu_put down to each ioctl case in kvm_arch_vcpu_ioctl

Although we already have kvm_arch_vcpu_async_ioctl() which doesn't require
ioctl to load vcpu, the sync ioctl code need to be cleaned up when
CONFIG_HAVE_KVM_VCPU_ASYNC_IOCTL is not configured.

This patch moves vcpu_load/vcpu_put down to each ioctl switch case so that
each ioctl can decide to do vcpu_load/vcpu_put or not independently.

Signed-off-by: Simon Guo <wei.guo.simon@gmail.com>
Signed-off-by: Paul Mackerras <paulus@ozlabs.org>
arch/powerpc/kvm/powerpc.c