diff options
| author | John Baldwin <jhb@FreeBSD.org> | 2002-04-11 21:03:35 +0000 |
|---|---|---|
| committer | John Baldwin <jhb@FreeBSD.org> | 2002-04-11 21:03:35 +0000 |
| commit | b106d2f56a4b4461d660f74f282b8b73fe9b71dc (patch) | |
| tree | 2787151457ae05b1d9c124d93f4665d094d0ddcc /sys/kern/kern_intr.c | |
| parent | 5a882ddd662af3fa0c14d6e650a8e6e4dbd066d1 (diff) | |
Notes
Diffstat (limited to 'sys/kern/kern_intr.c')
| -rw-r--r-- | sys/kern/kern_intr.c | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/sys/kern/kern_intr.c b/sys/kern/kern_intr.c index dce8a47f0e08..a7c3bd1d4f7c 100644 --- a/sys/kern/kern_intr.c +++ b/sys/kern/kern_intr.c @@ -131,14 +131,18 @@ ithread_update(struct ithd *ithd) strncpy(p->p_comm, ithd->it_name, sizeof(ithd->it_name)); ih = TAILQ_FIRST(&ithd->it_handlers); if (ih == NULL) { + mtx_lock_spin(&sched_lock); td->td_priority = PRI_MAX_ITHD; + td->td_base_pri = PRI_MAX_ITHD; + mtx_unlock_spin(&sched_lock); ithd->it_flags &= ~IT_ENTROPY; return; } - entropy = 0; + mtx_lock_spin(&sched_lock); td->td_priority = ih->ih_pri; td->td_base_pri = ih->ih_pri; + mtx_unlock_spin(&sched_lock); TAILQ_FOREACH(ih, &ithd->it_handlers, ih_next) { if (strlen(p->p_comm) + strlen(ih->ih_name) + 1 < sizeof(p->p_comm)) { @@ -154,12 +158,10 @@ ithread_update(struct ithd *ithd) if (ih->ih_flags & IH_ENTROPY) entropy++; } - if (entropy) ithd->it_flags |= IT_ENTROPY; else ithd->it_flags &= ~IT_ENTROPY; - CTR2(KTR_INTR, "%s: updated %s\n", __func__, p->p_comm); } |
