mirror of
https://github.com/freebsd/freebsd-src.git
synced 2024-12-03 08:22:44 +00:00
kern_intr.c:
- Count (scheduling of) software interrupts (SWIs) as SWIs, not as hardware interrupts. - Don't count (scheduling of) delayed SWIs as interrupts at all, since in the delayed case it is expected that there are many more scheduling calls than handling calls. Perhaps all interrupts should be counted only when they are handled, but it is only counts of delayed SWIs that shouldn never be combined with the other counts. subr_trap.c: - Count (handling of) Asynchronous System Traps (ASTs) as traps, not as software interrupts. Before these changes, the counter for SWIs only counted ASTs, and SWIs weren't counted separately, but a subcounter for ASTs alone is less needed than for most other exception sources. 4.4BSD-Lite uses the counters for similar things (actually matching their names) on its main arches (hp300, ..., !i386) where more of the exceptions are in hardware.
This commit is contained in:
parent
6e5bfbba9a
commit
1ca2c0183f
Notes:
svn2git
2020-12-20 02:59:44 +00:00
svn path=/head/; revision=163474
@ -583,8 +583,6 @@ swi_sched(void *cookie, int flags)
|
||||
struct intr_event *ie = ih->ih_event;
|
||||
int error;
|
||||
|
||||
PCPU_LAZY_INC(cnt.v_intr);
|
||||
|
||||
CTR3(KTR_INTR, "swi_sched: %s %s need=%d", ie->ie_name, ih->ih_name,
|
||||
ih->ih_need);
|
||||
|
||||
@ -594,7 +592,9 @@ swi_sched(void *cookie, int flags)
|
||||
* it will execute it the next time it runs.
|
||||
*/
|
||||
atomic_store_rel_int(&ih->ih_need, 1);
|
||||
|
||||
if (!(flags & SWI_DELAY)) {
|
||||
PCPU_LAZY_INC(cnt.v_soft);
|
||||
error = intr_event_schedule_thread(ie);
|
||||
KASSERT(error == 0, ("stray software interrupt"));
|
||||
}
|
||||
|
@ -190,7 +190,7 @@ ast(struct trapframe *framep)
|
||||
#endif
|
||||
td->td_flags &= ~(TDF_ASTPENDING | TDF_NEEDSIGCHK |
|
||||
TDF_NEEDRESCHED | TDF_INTERRUPT);
|
||||
cnt.v_soft++;
|
||||
cnt.v_trap++;
|
||||
mtx_unlock_spin(&sched_lock);
|
||||
|
||||
/*
|
||||
|
Loading…
Reference in New Issue
Block a user