Lines Matching full:job

262 int drm_writeback_prepare_job(struct drm_writeback_job *job)  in drm_writeback_prepare_job()  argument
264 struct drm_writeback_connector *connector = job->connector; in drm_writeback_prepare_job()
270 ret = funcs->prepare_writeback_job(connector, job); in drm_writeback_prepare_job()
275 job->prepared = true; in drm_writeback_prepare_job()
281 * drm_writeback_queue_job - Queue a writeback job for later signalling
282 * @wb_connector: The writeback connector to queue a job on
283 * @conn_state: The connector state containing the job to queue
285 * This function adds the job contained in @conn_state to the job_queue for a
286 * writeback connector. It takes ownership of the writeback job and sets the
287 * @conn_state->writeback_job to NULL, and so no access to the job may be
302 struct drm_writeback_job *job; in drm_writeback_queue_job() local
305 job = conn_state->writeback_job; in drm_writeback_queue_job()
309 list_add_tail(&job->list_entry, &wb_connector->job_queue); in drm_writeback_queue_job()
314 void drm_writeback_cleanup_job(struct drm_writeback_job *job) in drm_writeback_cleanup_job() argument
316 struct drm_writeback_connector *connector = job->connector; in drm_writeback_cleanup_job()
320 if (job->prepared && funcs->cleanup_writeback_job) in drm_writeback_cleanup_job()
321 funcs->cleanup_writeback_job(connector, job); in drm_writeback_cleanup_job()
323 if (job->fb) in drm_writeback_cleanup_job()
324 drm_framebuffer_put(job->fb); in drm_writeback_cleanup_job()
326 if (job->out_fence) in drm_writeback_cleanup_job()
327 dma_fence_put(job->out_fence); in drm_writeback_cleanup_job()
329 kfree(job); in drm_writeback_cleanup_job()
334 * @cleanup_work: deferred cleanup of a writeback job
336 * The job cannot be cleaned up directly in drm_writeback_signal_completion,
342 struct drm_writeback_job *job = container_of(work, in cleanup_work() local
346 drm_writeback_cleanup_job(job); in cleanup_work()
350 * drm_writeback_signal_completion - Signal the completion of a writeback job
351 * @wb_connector: The writeback connector whose job is complete
355 * writeback job. It should be called as soon as possible after the hardware
370 struct drm_writeback_job *job; in drm_writeback_signal_completion() local
374 job = list_first_entry_or_null(&wb_connector->job_queue, in drm_writeback_signal_completion()
377 if (job) in drm_writeback_signal_completion()
378 list_del(&job->list_entry); in drm_writeback_signal_completion()
382 if (WARN_ON(!job)) in drm_writeback_signal_completion()
385 out_fence = job->out_fence; in drm_writeback_signal_completion()
391 job->out_fence = NULL; in drm_writeback_signal_completion()
394 INIT_WORK(&job->cleanup_work, cleanup_work); in drm_writeback_signal_completion()
395 queue_work(system_long_wq, &job->cleanup_work); in drm_writeback_signal_completion()