Lines Matching defs:ih
215 struct intr_handler *ih;
227 CK_SLIST_FOREACH(ih, &ie->ie_handlers, ih_next) {
228 if (strlen(ie->ie_fullname) + strlen(ih->ih_name) + 1 <
231 strcat(ie->ie_fullname, ih->ih_name);
235 flags |= ih->ih_flags;
247 ih = CK_SLIST_FIRST(&ie->ie_handlers);
248 missed = strlen(ie->ie_fullname) + strlen(ih->ih_name) + 2 -
251 strcat(ie->ie_fullname, &ih->ih_name[missed]);
606 struct intr_handler *ih, *temp_ih;
620 ih = malloc(sizeof(struct intr_handler), M_ITHREAD, M_WAITOK | M_ZERO);
621 ih->ih_filter = filter;
622 ih->ih_handler = handler;
623 ih->ih_argument = arg;
624 strlcpy(ih->ih_name, name, sizeof(ih->ih_name));
625 ih->ih_event = ie;
626 ih->ih_pri = pri;
628 ih->ih_flags = IH_EXCLUSIVE;
630 ih->ih_flags |= IH_MPSAFE;
632 ih->ih_flags |= IH_ENTROPY;
634 ih->ih_flags |= IH_NET;
642 free(ih, M_ITHREAD);
668 if (temp_ih->ih_pri > ih->ih_pri)
671 CK_SLIST_INSERT_PREVPTR(prevptr, temp_ih, ih, ih_next);
675 CTR3(KTR_INTR, "%s: added %s to %s", __func__, ih->ih_name,
680 *cookiep = ih;
692 struct intr_handler *ih;
698 CK_SLIST_FOREACH(ih, &ie->ie_handlers, ih_next) {
699 if (ih == cookie)
702 if (ih == NULL) {
707 ih = cookie;
716 start = strchr(ih->ih_name, ':');
718 start = strchr(ih->ih_name, 0);
725 space = sizeof(ih->ih_name) - (start - ih->ih_name) - 1;
746 struct intr_handler *ih;
749 ih = (struct intr_handler *)cookie;
750 if (ih == NULL)
752 ie = ih->ih_event;
755 ih->ih_name));
864 struct intr_handler *ih;
877 CK_SLIST_FOREACH_PREVPTR(ih, prevptr, &ie->ie_handlers, ih_next) {
878 if (ih == handler)
881 if (ih == NULL) {
894 CK_SLIST_REMOVE_PREVPTR(prevptr, ih, ih_next);
1077 struct intr_handler *ih = (struct intr_handler *)cookie;
1078 struct intr_event *ie = ih->ih_event;
1082 CTR3(KTR_INTR, "swi_sched: %s %s need=%d", ie->ie_name, ih->ih_name,
1083 ih->ih_need);
1086 entropy.event = (uintptr_t)ih;
1096 ih->ih_need = 1;
1130 struct intr_handler *ih, *ihn, *ihp;
1133 CK_SLIST_FOREACH_SAFE(ih, &ie->ie_handlers, ih_next, ihn) {
1138 if (ih->ih_flags & IH_DEAD) {
1144 ih->ih_flags &= ~IH_DEAD;
1145 wakeup(ih);
1154 ihp = ih;
1156 if ((ih->ih_flags & IH_CHANGED) != 0) {
1158 ih->ih_flags &= ~IH_CHANGED;
1159 wakeup(ih);
1164 if (ih->ih_handler == NULL)
1168 if ((ih->ih_flags & IH_SUSP) != 0)
1181 atomic_cmpset_int(&ih->ih_need, 1, 0) == 0)
1186 __func__, p->p_pid, (void *)ih->ih_handler,
1187 ih->ih_argument, ih->ih_name, ih->ih_flags);
1189 if (!(ih->ih_flags & IH_MPSAFE))
1191 ih->ih_handler(ih->ih_argument);
1192 if (!(ih->ih_flags & IH_MPSAFE))
1347 struct intr_handler *ih;
1384 CK_SLIST_FOREACH(ih, &ie->ie_handlers, ih_next) {
1385 if ((ih->ih_flags & IH_SUSP) != 0)
1387 if ((ie->ie_flags & IE_SOFT) != 0 && ih->ih_need == 0)
1389 if (ih->ih_filter == NULL) {
1394 ih->ih_filter, ih->ih_argument, ih->ih_name);
1395 ret = ih->ih_filter(ih->ih_argument);
1403 ih->ih_name));
1467 db_dump_intrhand(struct intr_handler *ih)
1471 db_printf("\t%-10s ", ih->ih_name);
1472 switch (ih->ih_pri) {
1480 if (ih->ih_pri >= PI_SOFT)
1483 db_printf("%4u", ih->ih_pri);
1487 if (ih->ih_filter != NULL) {
1489 db_printsym((uintptr_t)ih->ih_filter, DB_STGY_PROC);
1491 if (ih->ih_handler != NULL) {
1492 if (ih->ih_filter != NULL)
1495 db_printsym((uintptr_t)ih->ih_handler, DB_STGY_PROC);
1497 db_printf("(%p)", ih->ih_argument);
1498 if (ih->ih_need ||
1499 (ih->ih_flags & (IH_EXCLUSIVE | IH_ENTROPY | IH_DEAD |
1503 if (ih->ih_flags & IH_EXCLUSIVE) {
1509 if (ih->ih_flags & IH_ENTROPY) {
1515 if (ih->ih_flags & IH_DEAD) {
1521 if (ih->ih_flags & IH_MPSAFE) {
1527 if (ih->ih_need) {
1543 struct intr_handler *ih;
1577 CK_SLIST_FOREACH(ih, &ie->ie_handlers, ih_next)
1578 db_dump_intrhand(ih);