Skip to content

Commit

Permalink
assert that we're assigning a non-null taskqueue
Browse files Browse the repository at this point in the history
  • Loading branch information
Matt Macy committed Oct 17, 2016
1 parent 20a6983 commit 535865d
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions sys/kern/subr_gtaskqueue.c
Expand Up @@ -672,6 +672,7 @@ taskqgroup_attach_deferred(struct taskqgroup *qgroup, struct grouptask *gtask)

LIST_INSERT_HEAD(&qgroup->tqg_queue[qid].tgc_tasks, gtask,
gt_list);
MPASS(qgroup->tqg_queue[qid].tgc_taskq != NULL);
gtask->gt_taskqueue = qgroup->tqg_queue[qid].tgc_taskq;
mtx_unlock(&qgroup->tqg_lock);
}
Expand Down Expand Up @@ -736,6 +737,7 @@ taskqgroup_attach_cpu_deferred(struct taskqgroup *qgroup, struct grouptask *gtas
}
qgroup->tqg_queue[qid].tgc_cnt++;
LIST_INSERT_HEAD(&qgroup->tqg_queue[qid].tgc_tasks, gtask, gt_list);
MPASS(qgroup->tqg_queue[qid].tgc_taskq != NULL);
gtask->gt_taskqueue = qgroup->tqg_queue[qid].tgc_taskq;
mtx_unlock(&qgroup->tqg_lock);

Expand Down

0 comments on commit 535865d

Please sign in to comment.