Lines Matching refs:crtc

500 	crtc_state = drm_atomic_get_crtc_state(state->state, state->crtc);  in tegra_plane_state_add()
517 struct tegra_dc *dc = to_tegra_dc(state->crtc); in tegra_plane_atomic_check()
521 if (!state->crtc) in tegra_plane_atomic_check()
562 struct tegra_dc *dc = to_tegra_dc(plane->state->crtc); in tegra_plane_atomic_update()
569 if (!plane->state->crtc || !plane->state->fb) in tegra_plane_atomic_update()
608 if (!old_state || !old_state->crtc) in tegra_plane_atomic_disable()
611 dc = to_tegra_dc(old_state->crtc); in tegra_plane_atomic_disable()
685 if (!state->crtc) in tegra_cursor_atomic_check()
712 struct tegra_dc *dc = to_tegra_dc(plane->state->crtc); in tegra_cursor_atomic_update()
717 if (!plane->state->crtc || !plane->state->fb) in tegra_cursor_atomic_update()
777 if (!old_state || !old_state->crtc) in tegra_cursor_atomic_disable()
780 dc = to_tegra_dc(old_state->crtc); in tegra_cursor_atomic_disable()
956 struct drm_crtc *crtc = &dc->base; in tegra_dc_finish_page_flip() local
967 bo = tegra_fb_get_plane(crtc->primary->fb, 0); in tegra_dc_finish_page_flip()
979 if (base == bo->paddr + crtc->primary->fb->offsets[0]) { in tegra_dc_finish_page_flip()
980 drm_crtc_send_vblank_event(crtc, dc->event); in tegra_dc_finish_page_flip()
981 drm_crtc_vblank_put(crtc); in tegra_dc_finish_page_flip()
988 void tegra_dc_cancel_page_flip(struct drm_crtc *crtc, struct drm_file *file) in tegra_dc_cancel_page_flip() argument
990 struct tegra_dc *dc = to_tegra_dc(crtc); in tegra_dc_cancel_page_flip()
991 struct drm_device *drm = crtc->dev; in tegra_dc_cancel_page_flip()
998 drm_crtc_vblank_put(crtc); in tegra_dc_cancel_page_flip()
1005 static void tegra_dc_destroy(struct drm_crtc *crtc) in tegra_dc_destroy() argument
1007 drm_crtc_cleanup(crtc); in tegra_dc_destroy()
1010 static void tegra_crtc_reset(struct drm_crtc *crtc) in tegra_crtc_reset() argument
1014 if (crtc->state) in tegra_crtc_reset()
1015 __drm_atomic_helper_crtc_destroy_state(crtc, crtc->state); in tegra_crtc_reset()
1017 kfree(crtc->state); in tegra_crtc_reset()
1018 crtc->state = NULL; in tegra_crtc_reset()
1022 crtc->state = &state->base; in tegra_crtc_reset()
1023 crtc->state->crtc = crtc; in tegra_crtc_reset()
1026 drm_crtc_vblank_reset(crtc); in tegra_crtc_reset()
1030 tegra_crtc_atomic_duplicate_state(struct drm_crtc *crtc) in tegra_crtc_atomic_duplicate_state() argument
1032 struct tegra_dc_state *state = to_dc_state(crtc->state); in tegra_crtc_atomic_duplicate_state()
1039 __drm_atomic_helper_crtc_duplicate_state(crtc, &copy->base); in tegra_crtc_atomic_duplicate_state()
1048 static void tegra_crtc_atomic_destroy_state(struct drm_crtc *crtc, in tegra_crtc_atomic_destroy_state() argument
1051 __drm_atomic_helper_crtc_destroy_state(crtc, state); in tegra_crtc_atomic_destroy_state()
1193 static void tegra_crtc_disable(struct drm_crtc *crtc) in tegra_crtc_disable() argument
1195 struct tegra_dc *dc = to_tegra_dc(crtc); in tegra_crtc_disable()
1232 drm_crtc_vblank_off(crtc); in tegra_crtc_disable()
1235 static void tegra_crtc_enable(struct drm_crtc *crtc) in tegra_crtc_enable() argument
1237 struct drm_display_mode *mode = &crtc->state->adjusted_mode; in tegra_crtc_enable()
1238 struct tegra_dc_state *state = to_dc_state(crtc->state); in tegra_crtc_enable()
1239 struct tegra_dc *dc = to_tegra_dc(crtc); in tegra_crtc_enable()
1266 drm_crtc_vblank_on(crtc); in tegra_crtc_enable()
1269 static int tegra_crtc_atomic_check(struct drm_crtc *crtc, in tegra_crtc_atomic_check() argument
1275 static void tegra_crtc_atomic_begin(struct drm_crtc *crtc, in tegra_crtc_atomic_begin() argument
1278 struct tegra_dc *dc = to_tegra_dc(crtc); in tegra_crtc_atomic_begin()
1280 if (crtc->state->event) { in tegra_crtc_atomic_begin()
1281 crtc->state->event->pipe = drm_crtc_index(crtc); in tegra_crtc_atomic_begin()
1283 WARN_ON(drm_crtc_vblank_get(crtc) != 0); in tegra_crtc_atomic_begin()
1285 dc->event = crtc->state->event; in tegra_crtc_atomic_begin()
1286 crtc->state->event = NULL; in tegra_crtc_atomic_begin()
1290 static void tegra_crtc_atomic_flush(struct drm_crtc *crtc, in tegra_crtc_atomic_flush() argument
1293 struct tegra_dc_state *state = to_dc_state(crtc->state); in tegra_crtc_atomic_flush()
1294 struct tegra_dc *dc = to_tegra_dc(crtc); in tegra_crtc_atomic_flush()