Lines Matching refs:commit
1364 else if (funcs->commit) in drm_atomic_helper_commit_modeset_enables()
1365 funcs->commit(crtc); in drm_atomic_helper_commit_modeset_enables()
1399 else if (funcs->commit) in drm_atomic_helper_commit_modeset_enables()
1400 funcs->commit(encoder); in drm_atomic_helper_commit_modeset_enables()
1544 struct drm_crtc_commit *commit = old_state->crtcs[i].commit; in drm_atomic_helper_wait_for_flip_done() local
1549 if (!crtc || !commit) in drm_atomic_helper_wait_for_flip_done()
1552 ret = wait_for_completion_timeout(&commit->flip_done, 10 * HZ); in drm_atomic_helper_wait_for_flip_done()
1740 if (old_plane_state->commit && in drm_atomic_helper_async_check()
1741 !try_wait_for_completion(&old_plane_state->commit->hw_done)) { in drm_atomic_helper_async_check()
1949 struct drm_crtc_commit *commit, *stall_commit = NULL; in stall_checks() local
1956 list_for_each_entry(commit, &crtc->commit_list, commit_entry) { in stall_checks()
1958 completed = try_wait_for_completion(&commit->flip_done); in stall_checks()
1971 stall_commit = drm_crtc_commit_get(commit); in stall_checks()
1998 struct drm_crtc_commit *commit = container_of(completion, in release_crtc_commit() local
1999 typeof(*commit), in release_crtc_commit()
2002 drm_crtc_commit_put(commit); in release_crtc_commit()
2005 static void init_commit(struct drm_crtc_commit *commit, struct drm_crtc *crtc) in init_commit() argument
2007 init_completion(&commit->flip_done); in init_commit()
2008 init_completion(&commit->hw_done); in init_commit()
2009 init_completion(&commit->cleanup_done); in init_commit()
2010 INIT_LIST_HEAD(&commit->commit_entry); in init_commit()
2011 kref_init(&commit->ref); in init_commit()
2012 commit->crtc = crtc; in init_commit()
2023 return new_crtc_state->commit; in crtc_or_fake_commit()
2092 struct drm_crtc_commit *commit; in drm_atomic_helper_setup_commit() local
2099 commit = kzalloc(sizeof(*commit), GFP_KERNEL); in drm_atomic_helper_setup_commit()
2100 if (!commit) in drm_atomic_helper_setup_commit()
2103 init_commit(commit, crtc); in drm_atomic_helper_setup_commit()
2105 new_crtc_state->commit = commit; in drm_atomic_helper_setup_commit()
2117 complete_all(&commit->flip_done); in drm_atomic_helper_setup_commit()
2123 complete_all(&commit->flip_done); in drm_atomic_helper_setup_commit()
2128 commit->event = kzalloc(sizeof(*commit->event), in drm_atomic_helper_setup_commit()
2130 if (!commit->event) in drm_atomic_helper_setup_commit()
2133 new_crtc_state->event = commit->event; in drm_atomic_helper_setup_commit()
2136 new_crtc_state->event->base.completion = &commit->flip_done; in drm_atomic_helper_setup_commit()
2138 drm_crtc_commit_get(commit); in drm_atomic_helper_setup_commit()
2140 commit->abort_completion = true; in drm_atomic_helper_setup_commit()
2142 state->crtcs[i].commit = commit; in drm_atomic_helper_setup_commit()
2143 drm_crtc_commit_get(commit); in drm_atomic_helper_setup_commit()
2151 if (nonblock && old_conn_state->commit && in drm_atomic_helper_setup_commit()
2152 !try_wait_for_completion(&old_conn_state->commit->flip_done)) { in drm_atomic_helper_setup_commit()
2160 commit = crtc_or_fake_commit(state, new_conn_state->crtc ?: old_conn_state->crtc); in drm_atomic_helper_setup_commit()
2161 if (!commit) in drm_atomic_helper_setup_commit()
2164 new_conn_state->commit = drm_crtc_commit_get(commit); in drm_atomic_helper_setup_commit()
2172 if (nonblock && old_plane_state->commit && in drm_atomic_helper_setup_commit()
2173 !try_wait_for_completion(&old_plane_state->commit->flip_done)) { in drm_atomic_helper_setup_commit()
2181 commit = crtc_or_fake_commit(state, new_plane_state->crtc ?: old_plane_state->crtc); in drm_atomic_helper_setup_commit()
2182 if (!commit) in drm_atomic_helper_setup_commit()
2185 new_plane_state->commit = drm_crtc_commit_get(commit); in drm_atomic_helper_setup_commit()
2219 ret = drm_crtc_commit_wait(old_crtc_state->commit); in drm_atomic_helper_wait_for_dependencies()
2226 ret = drm_crtc_commit_wait(old_conn_state->commit); in drm_atomic_helper_wait_for_dependencies()
2233 ret = drm_crtc_commit_wait(old_plane_state->commit); in drm_atomic_helper_wait_for_dependencies()
2301 struct drm_crtc_commit *commit; in drm_atomic_helper_commit_hw_done() local
2305 commit = new_crtc_state->commit; in drm_atomic_helper_commit_hw_done()
2306 if (!commit) in drm_atomic_helper_commit_hw_done()
2314 if (old_crtc_state->commit) in drm_atomic_helper_commit_hw_done()
2315 drm_crtc_commit_put(old_crtc_state->commit); in drm_atomic_helper_commit_hw_done()
2317 old_crtc_state->commit = drm_crtc_commit_get(commit); in drm_atomic_helper_commit_hw_done()
2321 complete_all(&commit->hw_done); in drm_atomic_helper_commit_hw_done()
2346 struct drm_crtc_commit *commit; in drm_atomic_helper_commit_cleanup_done() local
2350 commit = old_crtc_state->commit; in drm_atomic_helper_commit_cleanup_done()
2351 if (WARN_ON(!commit)) in drm_atomic_helper_commit_cleanup_done()
2354 complete_all(&commit->cleanup_done); in drm_atomic_helper_commit_cleanup_done()
2355 WARN_ON(!try_wait_for_completion(&commit->hw_done)); in drm_atomic_helper_commit_cleanup_done()
2358 list_del(&commit->commit_entry); in drm_atomic_helper_commit_cleanup_done()
2765 struct drm_crtc_commit *commit; in drm_atomic_helper_swap_state() local
2780 commit = old_crtc_state->commit; in drm_atomic_helper_swap_state()
2782 if (!commit) in drm_atomic_helper_swap_state()
2785 ret = wait_for_completion_interruptible(&commit->hw_done); in drm_atomic_helper_swap_state()
2791 commit = old_conn_state->commit; in drm_atomic_helper_swap_state()
2793 if (!commit) in drm_atomic_helper_swap_state()
2796 ret = wait_for_completion_interruptible(&commit->hw_done); in drm_atomic_helper_swap_state()
2802 commit = old_plane_state->commit; in drm_atomic_helper_swap_state()
2804 if (!commit) in drm_atomic_helper_swap_state()
2807 ret = wait_for_completion_interruptible(&commit->hw_done); in drm_atomic_helper_swap_state()
2832 if (new_crtc_state->commit) { in drm_atomic_helper_swap_state()
2834 list_add(&new_crtc_state->commit->commit_entry, in drm_atomic_helper_swap_state()
2838 new_crtc_state->commit->event = NULL; in drm_atomic_helper_swap_state()