Lines Matching refs:lapic_timer

526 	remaining = hrtimer_get_remaining(&apic->lapic_timer.timer);  in apic_get_tmcct()
530 ns = mod_64(ktime_to_ns(remaining), apic->lapic_timer.period); in apic_get_tmcct()
667 ktime_t now = apic->lapic_timer.timer.base->get_time(); in start_apic_timer()
669 apic->lapic_timer.period = (u64)apic_get_reg(apic, APIC_TMICT) * in start_apic_timer()
671 atomic_set(&apic->lapic_timer.pending, 0); in start_apic_timer()
673 if (!apic->lapic_timer.period) in start_apic_timer()
681 if (apic->lapic_timer.period < NSEC_PER_MSEC/2) in start_apic_timer()
682 apic->lapic_timer.period = NSEC_PER_MSEC/2; in start_apic_timer()
685 hrtimer_start(&apic->lapic_timer.timer, in start_apic_timer()
686 ktime_add_ns(now, apic->lapic_timer.period), in start_apic_timer()
695 apic->lapic_timer.period, in start_apic_timer()
697 apic->lapic_timer.period))); in start_apic_timer()
766 atomic_set(&apic->lapic_timer.pending, 0); in apic_reg_write()
800 hrtimer_cancel(&apic->lapic_timer.timer); in apic_reg_write()
872 hrtimer_cancel(&vcpu->arch.apic->lapic_timer.timer); in kvm_free_lapic()
948 hrtimer_cancel(&apic->lapic_timer.timer); in kvm_lapic_reset()
974 atomic_set(&apic->lapic_timer.pending, 0); in kvm_lapic_reset()
1006 lapic_timer); in lapic_is_periodic()
1015 return atomic_read(&lapic->lapic_timer.pending); in apic_has_pending_timer()
1072 hrtimer_init(&apic->lapic_timer.timer, CLOCK_MONOTONIC, in kvm_create_lapic()
1074 apic->lapic_timer.timer.function = kvm_timer_fn; in kvm_create_lapic()
1075 apic->lapic_timer.t_ops = &lapic_timer_ops; in kvm_create_lapic()
1076 apic->lapic_timer.kvm = vcpu->kvm; in kvm_create_lapic()
1077 apic->lapic_timer.vcpu = vcpu; in kvm_create_lapic()
1125 if (apic && atomic_read(&apic->lapic_timer.pending) > 0) { in kvm_inject_apic_timer_irqs()
1127 atomic_dec(&apic->lapic_timer.pending); in kvm_inject_apic_timer_irqs()
1154 hrtimer_cancel(&apic->lapic_timer.timer); in kvm_apic_post_state_restore()
1169 timer = &apic->lapic_timer.timer; in __kvm_migrate_apic_timer()