Lines Matching refs:crtc

79 	drm_crtc_cleanup(&du->crtc);  in vmw_display_unit_cleanup()
174 int vmw_du_crtc_cursor_set(struct drm_crtc *crtc, struct drm_file *file_priv, in vmw_du_crtc_cursor_set() argument
177 struct vmw_private *dev_priv = vmw_priv(crtc->dev); in vmw_du_crtc_cursor_set()
178 struct vmw_display_unit *du = vmw_crtc_to_du(crtc); in vmw_du_crtc_cursor_set()
190 drm_modeset_unlock_crtc(crtc); in vmw_du_crtc_cursor_set()
221 du->cursor_surface->snooper.crtc = NULL; in vmw_du_crtc_cursor_set()
232 du->cursor_surface->snooper.crtc = crtc; in vmw_du_crtc_cursor_set()
255 drm_modeset_lock_crtc(crtc, crtc->cursor); in vmw_du_crtc_cursor_set()
260 int vmw_du_crtc_cursor_move(struct drm_crtc *crtc, int x, int y) in vmw_du_crtc_cursor_move() argument
262 struct vmw_private *dev_priv = vmw_priv(crtc->dev); in vmw_du_crtc_cursor_move()
263 struct vmw_display_unit *du = vmw_crtc_to_du(crtc); in vmw_du_crtc_cursor_move()
266 du->cursor_x = x + crtc->x; in vmw_du_crtc_cursor_move()
267 du->cursor_y = y + crtc->y; in vmw_du_crtc_cursor_move()
276 drm_modeset_unlock_crtc(crtc); in vmw_du_crtc_cursor_move()
284 drm_modeset_lock_crtc(crtc, crtc->cursor); in vmw_du_crtc_cursor_move()
388 struct drm_crtc *crtc; in vmw_kms_cursor_post_execbuf() local
392 list_for_each_entry(crtc, &dev->mode_config.crtc_list, head) { in vmw_kms_cursor_post_execbuf()
393 du = vmw_crtc_to_du(crtc); in vmw_kms_cursor_post_execbuf()
456 struct drm_crtc *crtc; in do_surface_dirty_sou() local
469 list_for_each_entry(crtc, &dev_priv->dev->mode_config.crtc_list, in do_surface_dirty_sou()
471 if (crtc->primary->fb != &framebuffer->base) in do_surface_dirty_sou()
473 units[num_units++] = vmw_crtc_to_du(crtc); in do_surface_dirty_sou()
533 clip.x1 = left - unit->crtc.x; in do_surface_dirty_sou()
534 clip.y1 = top - unit->crtc.y; in do_surface_dirty_sou()
535 clip.x2 = right - unit->crtc.x; in do_surface_dirty_sou()
536 clip.y2 = bottom - unit->crtc.y; in do_surface_dirty_sou()
539 if (clip.x1 >= unit->crtc.mode.hdisplay || in do_surface_dirty_sou()
540 clip.y1 >= unit->crtc.mode.vdisplay || in do_surface_dirty_sou()
554 clip.x2 = unit->crtc.mode.hdisplay - clip.x1; in do_surface_dirty_sou()
555 clip.y2 = unit->crtc.mode.vdisplay - clip.y1; in do_surface_dirty_sou()
864 struct drm_crtc *crtc; in do_dmabuf_dirty_sou() local
884 list_for_each_entry(crtc, &dev_priv->dev->mode_config.crtc_list, head) { in do_dmabuf_dirty_sou()
885 if (crtc->primary->fb != &framebuffer->base) in do_dmabuf_dirty_sou()
887 units[num_units++] = vmw_crtc_to_du(crtc); in do_dmabuf_dirty_sou()
896 int clip_x1 = clips_ptr->x1 - unit->crtc.x; in do_dmabuf_dirty_sou()
897 int clip_y1 = clips_ptr->y1 - unit->crtc.y; in do_dmabuf_dirty_sou()
898 int clip_x2 = clips_ptr->x2 - unit->crtc.x; in do_dmabuf_dirty_sou()
899 int clip_y2 = clips_ptr->y2 - unit->crtc.y; in do_dmabuf_dirty_sou()
903 if (clip_x1 >= unit->crtc.mode.hdisplay || in do_dmabuf_dirty_sou()
904 clip_y1 >= unit->crtc.mode.vdisplay || in do_dmabuf_dirty_sou()
909 clip_x2 = min_t(int, clip_x2, unit->crtc.mode.hdisplay); in do_dmabuf_dirty_sou()
910 clip_y2 = min_t(int, clip_y2, unit->crtc.mode.vdisplay); in do_dmabuf_dirty_sou()
1232 struct drm_crtc *crtc; in vmw_kms_present() local
1245 list_for_each_entry(crtc, &dev_priv->dev->mode_config.crtc_list, head) { in vmw_kms_present()
1246 if (crtc->primary->fb != &vfb->base) in vmw_kms_present()
1248 units[num_units++] = vmw_crtc_to_du(crtc); in vmw_kms_present()
1303 clip.x1 = left + destX - unit->crtc.x; in vmw_kms_present()
1304 clip.y1 = top + destY - unit->crtc.y; in vmw_kms_present()
1305 clip.x2 = right + destX - unit->crtc.x; in vmw_kms_present()
1306 clip.y2 = bottom + destY - unit->crtc.y; in vmw_kms_present()
1309 if (clip.x1 >= unit->crtc.mode.hdisplay || in vmw_kms_present()
1310 clip.y1 >= unit->crtc.mode.vdisplay || in vmw_kms_present()
1324 clip.x2 = unit->crtc.mode.hdisplay - clip.x1; in vmw_kms_present()
1325 clip.y2 = unit->crtc.mode.vdisplay - clip.y1; in vmw_kms_present()
1368 struct drm_crtc *crtc; in vmw_kms_readback() local
1382 list_for_each_entry(crtc, &dev_priv->dev->mode_config.crtc_list, head) { in vmw_kms_readback()
1383 if (crtc->primary->fb != &vfb->base) in vmw_kms_readback()
1385 units[num_units++] = vmw_crtc_to_du(crtc); in vmw_kms_readback()
1414 int clip_x1 = c->x - units[i]->crtc.x; in vmw_kms_readback()
1415 int clip_x2 = c->x - units[i]->crtc.x + c->w; in vmw_kms_readback()
1416 int clip_y1 = c->y - units[i]->crtc.y; in vmw_kms_readback()
1417 int clip_y2 = c->y - units[i]->crtc.y + c->h; in vmw_kms_readback()
1432 clip_x2 = min(clip_x2, units[i]->crtc.mode.hdisplay); in vmw_kms_readback()
1433 clip_y2 = min(clip_y2, units[i]->crtc.mode.vdisplay); in vmw_kms_readback()
1436 if (clip_x1 >= units[i]->crtc.mode.hdisplay || in vmw_kms_readback()
1437 clip_y1 >= units[i]->crtc.mode.vdisplay || in vmw_kms_readback()
1504 struct drm_crtc *crtc; in vmw_kms_cursor_bypass_ioctl() local
1511 list_for_each_entry(crtc, &dev->mode_config.crtc_list, head) { in vmw_kms_cursor_bypass_ioctl()
1512 du = vmw_crtc_to_du(crtc); in vmw_kms_cursor_bypass_ioctl()
1521 crtc = drm_crtc_find(dev, arg->crtc_id); in vmw_kms_cursor_bypass_ioctl()
1522 if (!crtc) { in vmw_kms_cursor_bypass_ioctl()
1527 du = vmw_crtc_to_du(crtc); in vmw_kms_cursor_bypass_ioctl()
1651 u32 vmw_get_vblank_counter(struct drm_device *dev, int crtc) in vmw_get_vblank_counter() argument
1659 int vmw_enable_vblank(struct drm_device *dev, int crtc) in vmw_enable_vblank() argument
1667 void vmw_disable_vblank(struct drm_device *dev, int crtc) in vmw_disable_vblank() argument
1718 int vmw_du_page_flip(struct drm_crtc *crtc, in vmw_du_page_flip() argument
1723 struct vmw_private *dev_priv = vmw_priv(crtc->dev); in vmw_du_page_flip()
1724 struct drm_framebuffer *old_fb = crtc->primary->fb; in vmw_du_page_flip()
1739 if (!vmw_kms_screen_object_flippable(dev_priv, crtc)) in vmw_du_page_flip()
1742 crtc->primary->fb = fb; in vmw_du_page_flip()
1776 if (vmw_crtc_to_du(crtc)->is_implicit) in vmw_du_page_flip()
1777 vmw_kms_screen_object_update_implicit_fb(dev_priv, crtc); in vmw_du_page_flip()
1782 crtc->primary->fb = old_fb; in vmw_du_page_flip()
1787 void vmw_du_crtc_save(struct drm_crtc *crtc) in vmw_du_crtc_save() argument
1791 void vmw_du_crtc_restore(struct drm_crtc *crtc) in vmw_du_crtc_restore() argument
1795 void vmw_du_crtc_gamma_set(struct drm_crtc *crtc, in vmw_du_crtc_gamma_set() argument
1799 struct vmw_private *dev_priv = vmw_priv(crtc->dev); in vmw_du_crtc_gamma_set()