summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorIan Forbes <ian.forbes@broadcom.com>2026-05-14 10:31:03 -0500
committerZack Rusin <zack.rusin@broadcom.com>2026-11-16 15:09:36 -0500
commitd3cbc7400e075eb8b50845fe0bb9fa2ad560df60 (patch)
treedc9093b4a73c55a9edfa4a5dc6d6638180e1ceec
parent8a9b3b4c3a6cc95ea959183e20871d2421a6b986 (diff)
drm/vmwgfx: Never destroy STDU zero's Screen Target
When some VMware clients connect to a VM they query the existing screen target information to create a window of the same size. If the VM display is asleep and the CRTC is disabled we don't have a screen target and the client will not create a window which may lead it to have no way of accepting user input. Without input the VM cannot be awoken and the user is left with a blank screen. This can be overcome by using the 'Send Key' command from the client's application menu but this is not an ideal experience for users. This can be fixed by always leaving display unit zero with a screen target. Fixes: 7ef91dcba172 ("drm/vmwgfx: Don't destroy Screen Target when CRTC is enabled but inactive") Signed-off-by: Ian Forbes <ian.forbes@broadcom.com> Reviewed-by: Zack Rusin <zack.rusin@broadcom.com> Signed-off-by: Zack Rusin <zack.rusin@broadcom.com> Link: https://patch.msgid.link/20260514153103.1465013-1-ian.forbes@broadcom.com
-rw-r--r--drivers/gpu/drm/vmwgfx/vmwgfx_stdu.c7
1 files changed, 7 insertions, 0 deletions
diff --git a/drivers/gpu/drm/vmwgfx/vmwgfx_stdu.c b/drivers/gpu/drm/vmwgfx/vmwgfx_stdu.c
index cbf55084110a..c6eec395d503 100644
--- a/drivers/gpu/drm/vmwgfx/vmwgfx_stdu.c
+++ b/drivers/gpu/drm/vmwgfx/vmwgfx_stdu.c
@@ -448,6 +448,13 @@ static void vmw_stdu_crtc_atomic_disable(struct drm_crtc *crtc,
!new_crtc_state->mode_changed)
return;
+ /* Never destroy DU 0's ST so that the VM client always has a
+ * window to accept input from. Otherwise we may never receive
+ * input to wake the VM when the CRTC is disabled during idle.
+ */
+ if (stdu->base.unit == 0)
+ return;
+
ret = vmw_stdu_destroy_st(dev_priv, stdu);
if (ret)
DRM_ERROR("Failed to destroy Screen Target\n");