aboutsummaryrefslogtreecommitdiffstats
path: root/virt/kvm
diff options
context:
space:
mode:
authorJames Morse <james.morse@arm.com>2018-07-19 11:24:25 -0400
committerMarc Zyngier <marc.zyngier@arm.com>2018-07-21 11:02:32 -0400
commitb0960b9569db6b2fe8a75967d47b9dcdeb44016b (patch)
tree465340bda85cfe34f1d816e7e746b1e638e41f90 /virt/kvm
parent539aee0edb9fdc8f465e3843c261acc88c47d8ee (diff)
KVM: arm: Add 32bit get/set events support
arm64's new use of KVMs get_events/set_events API calls isn't just or RAS, it allows an SError that has been made pending by KVM as part of its device emulation to be migrated. Wire this up for 32bit too. We only need to read/write the HCR_VA bit, and check that no esr has been provided, as we don't yet support VDFSR. Signed-off-by: James Morse <james.morse@arm.com> Reviewed-by: Dongjiu Geng <gengdongjiu@huawei.com> Signed-off-by: Marc Zyngier <marc.zyngier@arm.com>
Diffstat (limited to 'virt/kvm')
-rw-r--r--virt/kvm/arm/arm.c4
1 files changed, 0 insertions, 4 deletions
diff --git a/virt/kvm/arm/arm.c b/virt/kvm/arm/arm.c
index 14f8fad1c7ae..ac658bd63196 100644
--- a/virt/kvm/arm/arm.c
+++ b/virt/kvm/arm/arm.c
@@ -1050,7 +1050,6 @@ static int kvm_arm_vcpu_has_attr(struct kvm_vcpu *vcpu,
1050 return ret; 1050 return ret;
1051} 1051}
1052 1052
1053#ifdef __KVM_HAVE_VCPU_EVENTS /* temporary: until 32bit is wired up */
1054static int kvm_arm_vcpu_get_events(struct kvm_vcpu *vcpu, 1053static int kvm_arm_vcpu_get_events(struct kvm_vcpu *vcpu,
1055 struct kvm_vcpu_events *events) 1054 struct kvm_vcpu_events *events)
1056{ 1055{
@@ -1076,7 +1075,6 @@ static int kvm_arm_vcpu_set_events(struct kvm_vcpu *vcpu,
1076 1075
1077 return __kvm_arm_vcpu_set_events(vcpu, events); 1076 return __kvm_arm_vcpu_set_events(vcpu, events);
1078} 1077}
1079#endif /* __KVM_HAVE_VCPU_EVENTS */
1080 1078
1081long kvm_arch_vcpu_ioctl(struct file *filp, 1079long kvm_arch_vcpu_ioctl(struct file *filp,
1082 unsigned int ioctl, unsigned long arg) 1080 unsigned int ioctl, unsigned long arg)
@@ -1158,7 +1156,6 @@ long kvm_arch_vcpu_ioctl(struct file *filp,
1158 r = kvm_arm_vcpu_has_attr(vcpu, &attr); 1156 r = kvm_arm_vcpu_has_attr(vcpu, &attr);
1159 break; 1157 break;
1160 } 1158 }
1161#ifdef __KVM_HAVE_VCPU_EVENTS
1162 case KVM_GET_VCPU_EVENTS: { 1159 case KVM_GET_VCPU_EVENTS: {
1163 struct kvm_vcpu_events events; 1160 struct kvm_vcpu_events events;
1164 1161
@@ -1178,7 +1175,6 @@ long kvm_arch_vcpu_ioctl(struct file *filp,
1178 1175
1179 return kvm_arm_vcpu_set_events(vcpu, &events); 1176 return kvm_arm_vcpu_set_events(vcpu, &events);
1180 } 1177 }
1181#endif
1182 default: 1178 default:
1183 r = -EINVAL; 1179 r = -EINVAL;
1184 } 1180 }