Lines Matching refs:job
40 tpool_job_t *job;
45 for (job = tpool->tp_head; job != NULL; job = tpool->tp_head) {
46 tpool->tp_head = job->tpj_next;
47 free(job);
84 * Called by a worker thread on return from a tpool_dispatch()d job.
112 tpool_job_t *job;
161 if ((job = tpool->tp_head) != NULL &&
164 func = job->tpj_func;
165 arg = job->tpj_arg;
166 tpool->tp_head = job->tpj_next;
167 if (job == tpool->tp_tail)
174 free(job);
260 * Else just return with the job added to the queue.
265 tpool_job_t *job;
267 if ((job = calloc(1, sizeof (*job))) == NULL)
269 job->tpj_next = NULL;
270 job->tpj_func = func;
271 job->tpj_arg = arg;
276 tpool->tp_head = job;
278 tpool->tp_tail->tpj_next = job;
279 tpool->tp_tail = job;
297 * Calling tpool_destroy() from a job in the pool will cause deadlock.
354 * Calling tpool_wait() from a job in the pool will cause deadlock.