Home
last modified time | relevance | path

Searched refs:vlapic (Results 1 – 10 of 10) sorted by relevance

/freebsd/sys/amd64/vmm/io/
H A Dvlapic.c62 #define x2apic(vlapic) (((vlapic)->msr_apicbase & APICBASE_X2APIC) ? 1 : 0) argument
70 #define VLAPIC_TIMER_LOCK(vlapic) mtx_lock_spin(&((vlapic)->timer_mtx)) argument
71 #define VLAPIC_TIMER_UNLOCK(vlapic) mtx_unlock_spin(&((vlapic)->timer_mtx)) argument
72 #define VLAPIC_TIMER_LOCKED(vlapic) mtx_owned(&((vlapic)->timer_mtx)) argument
81 static void vlapic_set_error(struct vlapic *, uint32_t, bool);
83 static void vlapic_reset(struct vlapic *vlapic);
86 vlapic_get_id(struct vlapic *vlapic) in vlapic_get_id() argument
89 if (x2apic(vlapic)) in vlapic_get_id()
90 return (vlapic->vcpuid); in vlapic_get_id()
92 return (vlapic->vcpuid << 24); in vlapic_get_id()
[all …]
H A Dvlapic.h36 int vlapic_write(struct vlapic *vlapic, int mmio_access, uint64_t offset,
38 int vlapic_read(struct vlapic *vlapic, int mmio_access, uint64_t offset,
51 int vlapic_pending_intr(struct vlapic *vlapic, int *vecptr);
59 void vlapic_intr_accepted(struct vlapic *vlapic, int vector);
64 int vlapic_set_intr_ready(struct vlapic *vlapic, int vector, bool level);
71 void vlapic_post_intr(struct vlapic *vlapic, int hostcpu, int ipinum);
73 void vlapic_fire_cmci(struct vlapic *vlapic);
74 int vlapic_trigger_lvt(struct vlapic *vlapic, int vector);
76 void vlapic_sync_tpr(struct vlapic *vlapic);
78 uint64_t vlapic_get_apicbase(struct vlapic *vlapic);
[all …]
H A Dvlapic_priv.h86 #define VLAPIC_CTR0(vlapic, format) \ argument
87 VCPU_CTR0((vlapic)->vm, (vlapic)->vcpuid, format)
89 #define VLAPIC_CTR1(vlapic, format, p1) \ argument
90 VCPU_CTR1((vlapic)->vm, (vlapic)->vcpuid, format, p1)
92 #define VLAPIC_CTR2(vlapic, format, p1, p2) \ argument
93 VCPU_CTR2((vlapic)->vm, (vlapic)->vcpuid, format, p1, p2)
95 #define VLAPIC_CTR3(vlapic, format, p1, p2, p3) \ argument
96 VCPU_CTR3((vlapic)->vm, (vlapic)->vcpuid, format, p1, p2, p3)
98 #define VLAPIC_CTR_IRR(vlapic, msg) \ argument
100 uint32_t *irrptr = &(vlapic)->apic_page->irr0; \
[all …]
H A Dvioapic.c240 struct vlapic *vlapic; in vioapic_update_tmr() local
245 vlapic = vm_lapic(vcpu); in vioapic_update_tmr()
252 vlapic_reset_tmr(vlapic); in vioapic_update_tmr()
271 vlapic_set_tmr_level(vlapic, dest, phys, delmode, vector); in vioapic_update_tmr()
/freebsd/sys/amd64/vmm/
H A Dvmm_lapic.c53 struct vlapic *vlapic; in lapic_set_intr() local
62 vlapic = vm_lapic(vcpu); in lapic_set_intr()
63 if (vlapic_set_intr_ready(vlapic, vector, level)) in lapic_set_intr()
71 struct vlapic *vlapic; in lapic_set_local_intr() local
79 vlapic = vm_lapic(vm_vcpu(vm, cpu)); in lapic_set_local_intr()
80 error = vlapic_trigger_lvt(vlapic, vector); in lapic_set_local_intr()
85 vlapic = vm_lapic(vcpu); in lapic_set_local_intr()
86 error = vlapic_trigger_lvt(vlapic, vector); in lapic_set_local_intr()
155 struct vlapic *vlapic; in lapic_rdmsr() local
157 vlapic = vm_lapic(vcpu); in lapic_rdmsr()
[all …]
H A Dvmm.c93 struct vlapic;
110 struct vlapic *vlapic; /* (i) APIC device model */ member
252 DEFINE_VMMOPS_IFUNC(struct vlapic *, vlapic_init, (void *vcpui))
253 DEFINE_VMMOPS_IFUNC(void, vlapic_cleanup, (struct vlapic *vlapic))
354 vmmops_vlapic_cleanup(vcpu->vlapic); in vcpu_cleanup()
389 vcpu->vlapic = vmmops_vlapic_init(vcpu->cookie); in vcpu_init()
1543 vlapic_pending_intr(vcpu->vlapic, NULL)) { in vm_handle_hlt()
2414 struct vlapic *
2417 return (vcpu->vlapic); in vm_lapic()
2653 vlapic_post_intr(vcpu->vlapic, hostcpu, in vcpu_notify_event_locked()
/freebsd/sys/amd64/vmm/intel/
H A Dvmx.c317 static void vmx_inject_pir(struct vlapic *vlapic);
1454 vmx_inject_interrupts(struct vmx_vcpu *vcpu, struct vlapic *vlapic, in vmx_inject_interrupts() argument
1536 vmx_inject_pir(vlapic); in vmx_inject_interrupts()
1553 if (!vlapic_pending_intr(vlapic, &vector)) in vmx_inject_interrupts()
1614 vlapic_intr_accepted(vlapic, vector); in vmx_inject_interrupts()
1931 struct vlapic *vlapic; in vmx_emulate_cr8_access() local
1940 vlapic = vm_lapic(vcpu->vcpu); in vmx_emulate_cr8_access()
1943 cr8 = vlapic_get_cr8(vlapic); in vmx_emulate_cr8_access()
1947 vlapic_set_cr8(vlapic, cr8); in vmx_emulate_cr8_access()
2167 vmx_handle_apic_write(struct vmx_vcpu *vcpu, struct vlapic *vlapic, in vmx_handle_apic_write() argument
[all …]
/freebsd/sys/amd64/vmm/amd/
H A Dsvm.c976 struct vlapic *vlapic; in svm_update_virqinfo() local
979 vlapic = vm_lapic(vcpu->vcpu); in svm_update_virqinfo()
983 vlapic_set_cr8(vlapic, ctrl->v_tpr); in svm_update_virqinfo()
1721 struct vlapic *vlapic) in svm_inj_interrupts() argument
1808 if (!vlapic_pending_intr(vlapic, &vector)) in svm_inj_interrupts()
1847 vlapic_intr_accepted(vlapic, vector); in svm_inj_interrupts()
1872 v_tpr = vlapic_get_cr8(vlapic); in svm_inj_interrupts()
2109 struct vlapic *vlapic; in svm_run() local
2119 vlapic = vm_lapic(vcpu->vcpu); in svm_run()
2204 svm_inj_interrupts(svm_sc, vcpu, vlapic); in svm_run()
[all …]
/freebsd/sys/amd64/include/
H A Dvmm.h158 struct vlapic;
189 typedef struct vlapic * (*vmi_vlapic_init)(void *vcpui);
190 typedef void (*vmi_vlapic_cleanup)(struct vlapic *vlapic);
289 struct vlapic *vm_lapic(struct vcpu *vcpu);
/freebsd/sys/modules/vmm/
H A DMakefile96 vlapic.c \