diff options
| author | Christoffer Dall <[email protected]> | 2018-11-26 17:21:22 +0000 |
|---|---|---|
| committer | Marc Zyngier <[email protected]> | 2019-02-19 21:05:36 +0000 |
| commit | accb99bcd0ca6d3ee412557b0c3f583a3abc0eb6 (patch) | |
| tree | e997f4ed8b196b597a92bc89b22f00b70e78eee0 /include/kvm/arm_arch_timer.h | |
| parent | KVM: arm/arm64: Factor out VMID into struct kvm_vmid (diff) | |
| download | kernel-accb99bcd0ca6d3ee412557b0c3f583a3abc0eb6.tar.gz kernel-accb99bcd0ca6d3ee412557b0c3f583a3abc0eb6.zip | |
KVM: arm/arm64: Simplify bg_timer programming
Instead of calling into kvm_timer_[un]schedule from the main kvm
blocking path, test if the VCPU is on the wait queue from the load/put
path and perform the background timer setup/cancel in this path.
This has the distinct advantage that we no longer race between load/put
and schedule/unschedule and programming and canceling of the bg_timer
always happens when the timer state is not loaded.
Note that we must now remove the checks in kvm_timer_blocking that do
not schedule a background timer if one of the timers can fire, because
we no longer have a guarantee that kvm_vcpu_check_block() will be called
before kvm_timer_blocking.
Reported-by: Andre Przywara <[email protected]>
Signed-off-by: Christoffer Dall <[email protected]>
Signed-off-by: Marc Zyngier <[email protected]>
Diffstat (limited to 'include/kvm/arm_arch_timer.h')
| -rw-r--r-- | include/kvm/arm_arch_timer.h | 3 |
1 files changed, 0 insertions, 3 deletions
diff --git a/include/kvm/arm_arch_timer.h b/include/kvm/arm_arch_timer.h index 33771352dcd6..d6e6a45d1d24 100644 --- a/include/kvm/arm_arch_timer.h +++ b/include/kvm/arm_arch_timer.h @@ -76,9 +76,6 @@ int kvm_arm_timer_has_attr(struct kvm_vcpu *vcpu, struct kvm_device_attr *attr); bool kvm_timer_is_pending(struct kvm_vcpu *vcpu); -void kvm_timer_schedule(struct kvm_vcpu *vcpu); -void kvm_timer_unschedule(struct kvm_vcpu *vcpu); - u64 kvm_phys_timer_read(void); void kvm_timer_vcpu_load(struct kvm_vcpu *vcpu); |
