Lines Matching refs:stdu

133 static void vmw_stdu_destroy(struct vmw_screen_target_display_unit *stdu);
173 struct vmw_screen_target_display_unit *stdu, in vmw_stdu_define_st() argument
189 cmd->body.stid = stdu->base.unit; in vmw_stdu_define_st()
197 stdu->base.set_gui_x = cmd->body.xRoot; in vmw_stdu_define_st()
198 stdu->base.set_gui_y = cmd->body.yRoot; in vmw_stdu_define_st()
202 stdu->defined = true; in vmw_stdu_define_st()
203 stdu->display_width = mode->hdisplay; in vmw_stdu_define_st()
204 stdu->display_height = mode->vdisplay; in vmw_stdu_define_st()
221 struct vmw_screen_target_display_unit *stdu, in vmw_stdu_bind_st() argument
232 if (!stdu->defined) { in vmw_stdu_bind_st()
248 cmd->body.stid = stdu->base.unit; in vmw_stdu_bind_st()
296 struct vmw_screen_target_display_unit *stdu) in vmw_stdu_update_st() argument
300 if (!stdu->defined) { in vmw_stdu_update_st()
309 vmw_stdu_populate_update(cmd, stdu->base.unit, in vmw_stdu_update_st()
310 0, stdu->display_width, in vmw_stdu_update_st()
311 0, stdu->display_height); in vmw_stdu_update_st()
327 struct vmw_screen_target_display_unit *stdu) in vmw_stdu_destroy_st() argument
338 if (unlikely(!stdu->defined)) in vmw_stdu_destroy_st()
348 cmd->body.stid = stdu->base.unit; in vmw_stdu_destroy_st()
357 stdu->defined = false; in vmw_stdu_destroy_st()
358 stdu->display_width = 0; in vmw_stdu_destroy_st()
359 stdu->display_height = 0; in vmw_stdu_destroy_st()
376 struct vmw_screen_target_display_unit *stdu; in vmw_stdu_crtc_mode_set_nofb() local
381 stdu = vmw_crtc_to_stdu(crtc); in vmw_stdu_crtc_mode_set_nofb()
383 conn_state = stdu->base.connector.state; in vmw_stdu_crtc_mode_set_nofb()
386 if (stdu->defined) { in vmw_stdu_crtc_mode_set_nofb()
387 ret = vmw_stdu_bind_st(dev_priv, stdu, NULL); in vmw_stdu_crtc_mode_set_nofb()
391 (void) vmw_stdu_update_st(dev_priv, stdu); in vmw_stdu_crtc_mode_set_nofb()
393 ret = vmw_stdu_destroy_st(dev_priv, stdu); in vmw_stdu_crtc_mode_set_nofb()
397 stdu->content_fb_type = SAME_AS_DISPLAY; in vmw_stdu_crtc_mode_set_nofb()
407 ret = vmw_stdu_define_st(dev_priv, stdu, &crtc->mode, x, y); in vmw_stdu_crtc_mode_set_nofb()
428 struct vmw_screen_target_display_unit *stdu; in vmw_stdu_crtc_atomic_disable() local
437 stdu = vmw_crtc_to_stdu(crtc); in vmw_stdu_crtc_atomic_disable()
440 if (stdu->defined) { in vmw_stdu_crtc_atomic_disable()
441 ret = vmw_stdu_bind_st(dev_priv, stdu, NULL); in vmw_stdu_crtc_atomic_disable()
445 (void) vmw_stdu_update_st(dev_priv, stdu); in vmw_stdu_crtc_atomic_disable()
447 ret = vmw_stdu_destroy_st(dev_priv, stdu); in vmw_stdu_crtc_atomic_disable()
451 stdu->content_fb_type = SAME_AS_DISPLAY; in vmw_stdu_crtc_atomic_disable()
502 struct vmw_screen_target_display_unit *stdu = in vmw_stdu_bo_fifo_commit() local
503 container_of(dirty->unit, typeof(*stdu), base); in vmw_stdu_bo_fifo_commit()
519 cmd->body.host.sid = stdu->display_srf->res.id; in vmw_stdu_bo_fifo_commit()
529 vmw_stdu_populate_update(&suffix[1], stdu->base.unit, in vmw_stdu_bo_fifo_commit()
536 stdu->display_srf->res.res_dirty = true; in vmw_stdu_bo_fifo_commit()
584 struct vmw_screen_target_display_unit *stdu = in vmw_stdu_bo_cpu_commit() local
585 container_of(dirty->unit, typeof(*stdu), base); in vmw_stdu_bo_cpu_commit()
590 struct vmw_diff_cpy diff = VMW_CPU_BLIT_DIFF_INITIALIZER(stdu->cpp); in vmw_stdu_bo_cpu_commit()
602 dst_pitch = stdu->display_srf->metadata.base_size.width * stdu->cpp; in vmw_stdu_bo_cpu_commit()
603 dst_bo = &stdu->display_srf->res.backup->base; in vmw_stdu_bo_cpu_commit()
604 dst_offset = ddirty->top * dst_pitch + ddirty->left * stdu->cpp; in vmw_stdu_bo_cpu_commit()
608 src_offset = ddirty->fb_top * src_pitch + ddirty->fb_left * stdu->cpp; in vmw_stdu_bo_cpu_commit()
619 width * stdu->cpp, height, &diff); in vmw_stdu_bo_cpu_commit()
633 ret = vmw_kms_update_proxy(&stdu->display_srf->res, &region, in vmw_stdu_bo_cpu_commit()
639 dev_priv = vmw_priv(stdu->base.crtc.dev); in vmw_stdu_bo_cpu_commit()
644 vmw_stdu_populate_update(cmd, stdu->base.unit, in vmw_stdu_bo_cpu_commit()
762 struct vmw_screen_target_display_unit *stdu = in vmw_kms_stdu_surface_clip() local
763 container_of(dirty->unit, typeof(*stdu), base); in vmw_kms_stdu_surface_clip()
765 if (sdirty->sid != stdu->display_srf->res.id) { in vmw_kms_stdu_surface_clip()
800 struct vmw_screen_target_display_unit *stdu = in vmw_kms_stdu_surface_fifo_commit() local
801 container_of(dirty->unit, typeof(*stdu), base); in vmw_kms_stdu_surface_fifo_commit()
812 if (sdirty->sid != stdu->display_srf->res.id) { in vmw_kms_stdu_surface_fifo_commit()
818 cmd->body.dest.sid = stdu->display_srf->res.id; in vmw_kms_stdu_surface_fifo_commit()
821 stdu->display_srf->res.res_dirty = true; in vmw_kms_stdu_surface_fifo_commit()
827 vmw_stdu_populate_update(update, stdu->base.unit, sdirty->left, in vmw_kms_stdu_surface_fifo_commit()
1200 struct vmw_screen_target_display_unit *stdu; in vmw_stdu_bo_populate_dma() local
1204 stdu = container_of(update->du, typeof(*stdu), base); in vmw_stdu_bo_populate_dma()
1213 cmd_dma->body.host.sid = stdu->display_srf->res.id; in vmw_stdu_bo_populate_dma()
1243 struct vmw_screen_target_display_unit *stdu; in vmw_stdu_bo_populate_update() local
1247 stdu = container_of(update->du, typeof(*stdu), base); in vmw_stdu_bo_populate_update()
1253 vmw_stdu_populate_update(&suffix[1], stdu->base.unit, bb->x1, bb->x2, in vmw_stdu_bo_populate_update()
1289 struct vmw_screen_target_display_unit *stdu; in vmw_stdu_bo_populate_update_cpu() local
1300 stdu = container_of(update->du, typeof(*stdu), base); in vmw_stdu_bo_populate_update_cpu()
1306 diff.cpp = stdu->cpp; in vmw_stdu_bo_populate_update_cpu()
1308 dst_bo = &stdu->display_srf->res.backup->base; in vmw_stdu_bo_populate_update_cpu()
1309 dst_pitch = stdu->display_srf->metadata.base_size.width * stdu->cpp; in vmw_stdu_bo_populate_update_cpu()
1310 dst_offset = bb->y1 * dst_pitch + bb->x1 * stdu->cpp; in vmw_stdu_bo_populate_update_cpu()
1315 stdu->cpp; in vmw_stdu_bo_populate_update_cpu()
1318 src_offset, src_pitch, width * stdu->cpp, height, in vmw_stdu_bo_populate_update_cpu()
1326 cmd_img->body.image.sid = stdu->display_srf->res.id; in vmw_stdu_bo_populate_update_cpu()
1338 vmw_stdu_populate_update(cmd_update, stdu->base.unit, in vmw_stdu_bo_populate_update_cpu()
1477 struct vmw_screen_target_display_unit *stdu; in vmw_stdu_surface_populate_copy() local
1481 stdu = container_of(update->du, typeof(*stdu), base); in vmw_stdu_surface_populate_copy()
1488 cmd_copy->body.dest.sid = stdu->display_srf->res.id; in vmw_stdu_surface_populate_copy()
1542 struct vmw_screen_target_display_unit *stdu; in vmw_stdu_plane_update_surface() local
1545 stdu = vmw_crtc_to_stdu(plane->state->crtc); in vmw_stdu_plane_update_surface()
1562 if (vfbs->surface->res.id != stdu->display_srf->res.id) { in vmw_stdu_plane_update_surface()
1594 struct vmw_screen_target_display_unit *stdu; in vmw_stdu_primary_plane_atomic_update() local
1604 stdu = vmw_crtc_to_stdu(crtc); in vmw_stdu_primary_plane_atomic_update()
1607 stdu->display_srf = vps->surf; in vmw_stdu_primary_plane_atomic_update()
1608 stdu->content_fb_type = vps->content_fb_type; in vmw_stdu_primary_plane_atomic_update()
1609 stdu->cpp = vps->cpp; in vmw_stdu_primary_plane_atomic_update()
1611 ret = vmw_stdu_bind_st(dev_priv, stdu, &stdu->display_srf->res); in vmw_stdu_primary_plane_atomic_update()
1626 stdu = vmw_crtc_to_stdu(crtc); in vmw_stdu_primary_plane_atomic_update()
1630 if (!stdu->defined) in vmw_stdu_primary_plane_atomic_update()
1633 ret = vmw_stdu_bind_st(dev_priv, stdu, NULL); in vmw_stdu_primary_plane_atomic_update()
1637 ret = vmw_stdu_update_st(dev_priv, stdu); in vmw_stdu_primary_plane_atomic_update()
1727 struct vmw_screen_target_display_unit *stdu; in vmw_stdu_init() local
1736 stdu = kzalloc(sizeof(*stdu), GFP_KERNEL); in vmw_stdu_init()
1737 if (!stdu) in vmw_stdu_init()
1740 stdu->base.unit = unit; in vmw_stdu_init()
1741 crtc = &stdu->base.crtc; in vmw_stdu_init()
1742 encoder = &stdu->base.encoder; in vmw_stdu_init()
1743 connector = &stdu->base.connector; in vmw_stdu_init()
1744 primary = &stdu->base.primary; in vmw_stdu_init()
1745 cursor = &stdu->base.cursor; in vmw_stdu_init()
1747 stdu->base.pref_active = (unit == 0); in vmw_stdu_init()
1748 stdu->base.pref_width = dev_priv->initial_width; in vmw_stdu_init()
1749 stdu->base.pref_height = dev_priv->initial_height; in vmw_stdu_init()
1750 stdu->base.is_implicit = false; in vmw_stdu_init()
1774 drm_plane_cleanup(&stdu->base.primary); in vmw_stdu_init()
1834 kfree(stdu); in vmw_stdu_init()
1847 static void vmw_stdu_destroy(struct vmw_screen_target_display_unit *stdu) in vmw_stdu_destroy() argument
1849 vmw_du_cleanup(&stdu->base); in vmw_stdu_destroy()
1850 kfree(stdu); in vmw_stdu_destroy()