Changeset View
Changeset View
Standalone View
Standalone View
sys/x86/x86/local_apic.c
| Show First 20 Lines • Show All 1,437 Lines • ▼ Show 20 Lines | lapic_handle_timer(struct trapframe *frame) | ||||
| /* Send EOI first thing. */ | /* Send EOI first thing. */ | ||||
| lapic_eoi(); | lapic_eoi(); | ||||
| kasan_mark(frame, sizeof(*frame), sizeof(*frame), 0); | kasan_mark(frame, sizeof(*frame), sizeof(*frame), 0); | ||||
| kmsan_mark(frame, sizeof(*frame), KMSAN_STATE_INITED); | kmsan_mark(frame, sizeof(*frame), KMSAN_STATE_INITED); | ||||
| trap_check_kstack(); | trap_check_kstack(); | ||||
| #if defined(SMP) && !defined(SCHED_ULE) | if (!sched_do_timer_accounting()) | ||||
| /* | |||||
| * Don't do any accounting for the disabled HTT cores, since it | |||||
| * will provide misleading numbers for the userland. | |||||
| * | |||||
| * No locking is necessary here, since even if we lose the race | |||||
| * when hlt_cpus_mask changes it is not a big deal, really. | |||||
| * | |||||
| * Don't do that for ULE, since ULE doesn't consider hlt_cpus_mask | |||||
| * and unlike other schedulers it actually schedules threads to | |||||
| * those CPUs. | |||||
| */ | |||||
| if (CPU_ISSET(PCPU_GET(cpuid), &hlt_cpus_mask)) | |||||
| return; | return; | ||||
| #endif | |||||
| /* Look up our local APIC structure for the tick counters. */ | /* Look up our local APIC structure for the tick counters. */ | ||||
| la = &lapics[PCPU_GET(apic_id)]; | la = &lapics[PCPU_GET(apic_id)]; | ||||
| (*la->la_timer_count)++; | (*la->la_timer_count)++; | ||||
| critical_enter(); | critical_enter(); | ||||
| if (lapic_et.et_active) { | if (lapic_et.et_active) { | ||||
| td = curthread; | td = curthread; | ||||
| td->td_intr_nesting_level++; | td->td_intr_nesting_level++; | ||||
| ▲ Show 20 Lines • Show All 857 Lines • Show Last 20 Lines | |||||