summaryrefslogtreecommitdiffstats
path: root/arch/s390
diff options
context:
space:
mode:
authorChristoffer Dall <christoffer.dall@linaro.org>2017-12-04 21:35:27 +0100
committerPaolo Bonzini <pbonzini@redhat.com>2017-12-14 09:26:52 +0100
commit875656fe0c8473c544860d557ca1512753d6aeef (patch)
tree5f7ca232837ea02b03ff65d6fe8b27fe0711cfd4 /arch/s390
parent1fc9b76b3dd2c57ca0fe42742043a5c3cbdc41c1 (diff)
downloadlinux-stable-875656fe0c8473c544860d557ca1512753d6aeef.tar.gz
linux-stable-875656fe0c8473c544860d557ca1512753d6aeef.tar.bz2
linux-stable-875656fe0c8473c544860d557ca1512753d6aeef.zip
KVM: Move vcpu_load to arch-specific kvm_arch_vcpu_ioctl_set_regs
Move vcpu_load() and vcpu_put() into the architecture specific implementations of kvm_arch_vcpu_ioctl_set_regs(). Signed-off-by: Christoffer Dall <christoffer.dall@linaro.org> Reviewed-by: David Hildenbrand <david@redhat.com> Reviewed-by: Cornelia Huck <cohuck@redhat.com> Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
Diffstat (limited to 'arch/s390')
-rw-r--r--arch/s390/kvm/kvm-s390.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/arch/s390/kvm/kvm-s390.c b/arch/s390/kvm/kvm-s390.c
index 44317813f498..ab08823a854b 100644
--- a/arch/s390/kvm/kvm-s390.c
+++ b/arch/s390/kvm/kvm-s390.c
@@ -2709,7 +2709,9 @@ static int kvm_arch_vcpu_ioctl_initial_reset(struct kvm_vcpu *vcpu)
int kvm_arch_vcpu_ioctl_set_regs(struct kvm_vcpu *vcpu, struct kvm_regs *regs)
{
+ vcpu_load(vcpu);
memcpy(&vcpu->run->s.regs.gprs, &regs->gprs, sizeof(regs->gprs));
+ vcpu_put(vcpu);
return 0;
}