Lines Matching refs:job
176 struct host1x_job *job) in cdma_start_timer_locked() argument
185 cdma->timeout.client = job->client; in cdma_start_timer_locked()
186 cdma->timeout.syncpt = host1x_syncpt_get(host, job->syncpt_id); in cdma_start_timer_locked()
187 cdma->timeout.syncpt_val = job->syncpt_end; in cdma_start_timer_locked()
191 msecs_to_jiffies(job->timeout)); in cdma_start_timer_locked()
218 struct host1x_job *job, *n; in update_cdma_locked() local
228 list_for_each_entry_safe(job, n, &cdma->sync_queue, list) { in update_cdma_locked()
230 host1x_syncpt_get(host1x, job->syncpt_id); in update_cdma_locked()
233 if (!host1x_syncpt_is_expired(sp, job->syncpt_end)) { in update_cdma_locked()
235 if (job->timeout) in update_cdma_locked()
236 cdma_start_timer_locked(cdma, job); in update_cdma_locked()
245 host1x_job_unpin(job); in update_cdma_locked()
248 if (job->num_slots) { in update_cdma_locked()
250 host1x_pushbuffer_pop(pb, job->num_slots); in update_cdma_locked()
255 list_del(&job->list); in update_cdma_locked()
256 host1x_job_put(job); in update_cdma_locked()
274 struct host1x_job *job = NULL; in host1x_cdma_update_sync_queue() local
293 list_for_each_entry(job, &cdma->sync_queue, list) { in host1x_cdma_update_sync_queue()
294 if (syncpt_val < job->syncpt_end) in host1x_cdma_update_sync_queue()
297 host1x_job_dump(dev, job); in host1x_cdma_update_sync_queue()
319 restart_addr = job->first_get; in host1x_cdma_update_sync_queue()
324 list_for_each_entry_from(job, &cdma->sync_queue, list) { in host1x_cdma_update_sync_queue()
326 if (job->client != cdma->timeout.client) in host1x_cdma_update_sync_queue()
330 job->timeout = 0; in host1x_cdma_update_sync_queue()
332 syncpt_incrs = job->syncpt_end - syncpt_val; in host1x_cdma_update_sync_queue()
335 host1x_job_dump(dev, job); in host1x_cdma_update_sync_queue()
338 host1x_hw_cdma_timeout_cpu_incr(host1x, cdma, job->first_get, in host1x_cdma_update_sync_queue()
339 syncpt_incrs, job->syncpt_end, in host1x_cdma_update_sync_queue()
340 job->num_slots); in host1x_cdma_update_sync_queue()
349 list_for_each_entry_from(job, &cdma->sync_queue, list) in host1x_cdma_update_sync_queue()
350 if (job->client == cdma->timeout.client) in host1x_cdma_update_sync_queue()
351 job->timeout = min_t(unsigned int, job->timeout, 500); in host1x_cdma_update_sync_queue()
403 int host1x_cdma_begin(struct host1x_cdma *cdma, struct host1x_job *job) in host1x_cdma_begin() argument
409 if (job->timeout) { in host1x_cdma_begin()
414 job->syncpt_id); in host1x_cdma_begin()
428 trace_host1x_cdma_begin(dev_name(job->channel->dev)); in host1x_cdma_begin()
463 struct host1x_job *job) in host1x_cdma_end() argument
470 job->first_get = cdma->first_get; in host1x_cdma_end()
471 job->num_slots = cdma->slots_used; in host1x_cdma_end()
472 host1x_job_get(job); in host1x_cdma_end()
473 list_add_tail(&job->list, &cdma->sync_queue); in host1x_cdma_end()
476 if (job->timeout && idle) in host1x_cdma_end()
477 cdma_start_timer_locked(cdma, job); in host1x_cdma_end()
479 trace_host1x_cdma_end(dev_name(job->channel->dev)); in host1x_cdma_end()