Lines Matching refs:ldu
59 static void vmw_ldu_destroy(struct vmw_legacy_display_unit *ldu) in vmw_ldu_destroy() argument
61 list_del_init(&ldu->active); in vmw_ldu_destroy()
62 vmw_du_cleanup(&ldu->base); in vmw_ldu_destroy()
63 kfree(ldu); in vmw_ldu_destroy()
140 struct vmw_legacy_display_unit *ldu) in vmw_ldu_del_active() argument
143 if (list_empty(&ldu->active)) in vmw_ldu_del_active()
147 list_del_init(&ldu->active); in vmw_ldu_del_active()
159 struct vmw_legacy_display_unit *ldu, in vmw_ldu_add_active() argument
176 if (!list_empty(&ldu->active)) in vmw_ldu_add_active()
181 if (entry->base.unit > ldu->base.unit) in vmw_ldu_add_active()
187 list_add(&ldu->active, at); in vmw_ldu_add_active()
289 struct vmw_legacy_display_unit *ldu; in vmw_ldu_primary_plane_atomic_update() local
295 ldu = vmw_crtc_to_ldu(crtc); in vmw_ldu_primary_plane_atomic_update()
302 vmw_ldu_add_active(dev_priv, ldu, vfb); in vmw_ldu_primary_plane_atomic_update()
304 vmw_ldu_del_active(dev_priv, ldu); in vmw_ldu_primary_plane_atomic_update()
357 struct vmw_legacy_display_unit *ldu; in vmw_ldu_init() local
365 ldu = kzalloc(sizeof(*ldu), GFP_KERNEL); in vmw_ldu_init()
366 if (!ldu) in vmw_ldu_init()
369 ldu->base.unit = unit; in vmw_ldu_init()
370 crtc = &ldu->base.crtc; in vmw_ldu_init()
371 encoder = &ldu->base.encoder; in vmw_ldu_init()
372 connector = &ldu->base.connector; in vmw_ldu_init()
373 primary = &ldu->base.primary; in vmw_ldu_init()
374 cursor = &ldu->base.cursor; in vmw_ldu_init()
376 INIT_LIST_HEAD(&ldu->active); in vmw_ldu_init()
378 ldu->base.pref_active = (unit == 0); in vmw_ldu_init()
379 ldu->base.pref_width = dev_priv->initial_width; in vmw_ldu_init()
380 ldu->base.pref_height = dev_priv->initial_height; in vmw_ldu_init()
381 ldu->base.pref_mode = NULL; in vmw_ldu_init()
387 ldu->base.is_implicit = true; in vmw_ldu_init()
392 ret = drm_universal_plane_init(dev, &ldu->base.primary, in vmw_ldu_init()
407 ret = drm_universal_plane_init(dev, &ldu->base.cursor, in vmw_ldu_init()
414 drm_plane_cleanup(&ldu->base.primary); in vmw_ldu_init()
453 ret = drm_crtc_init_with_planes(dev, crtc, &ldu->base.primary, in vmw_ldu_init()
454 &ldu->base.cursor, in vmw_ldu_init()
486 kfree(ldu); in vmw_ldu_init()