stable.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH 1/6] drm/vmwgfx: Don't send drm sysfs hotplug events on initial master set
@ 2019-05-21  8:24 Thomas Hellstrom
  2019-05-21  8:24 ` [PATCH 2/6] drm/vmwgfx: Fix user space handle equal to zero Thomas Hellstrom
                   ` (3 more replies)
  0 siblings, 4 replies; 5+ messages in thread
From: Thomas Hellstrom @ 2019-05-21  8:24 UTC (permalink / raw)
  To: dri-devel; +Cc: Thomas Hellstrom, stable, Deepak Singh Rawat

This may confuse user-space clients like plymouth that opens a drm
file descriptor as a result of a hotplug event and then generates a
new event...

Cc: <stable@vger.kernel.org>
Fixes: 5ea1734827bb ("drm/vmwgfx: Send a hotplug event at master_set")
Signed-off-by: Thomas Hellstrom <thellstrom@vmware.com>
Reviewed-by: Deepak Rawat <drawat@vmware.com>
---
 drivers/gpu/drm/vmwgfx/vmwgfx_drv.c | 8 +++++++-
 1 file changed, 7 insertions(+), 1 deletion(-)

diff --git a/drivers/gpu/drm/vmwgfx/vmwgfx_drv.c b/drivers/gpu/drm/vmwgfx/vmwgfx_drv.c
index bf6c3500d363..4ff11a0077e1 100644
--- a/drivers/gpu/drm/vmwgfx/vmwgfx_drv.c
+++ b/drivers/gpu/drm/vmwgfx/vmwgfx_drv.c
@@ -1239,7 +1239,13 @@ static int vmw_master_set(struct drm_device *dev,
 	}
 
 	dev_priv->active_master = vmaster;
-	drm_sysfs_hotplug_event(dev);
+
+	/*
+	 * Inform a new master that the layout may have changed while
+	 * it was gone.
+	 */
+	if (!from_open)
+		drm_sysfs_hotplug_event(dev);
 
 	return 0;
 }
-- 
2.20.1


^ permalink raw reply related	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2019-05-21  8:25 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2019-05-21  8:24 [PATCH 1/6] drm/vmwgfx: Don't send drm sysfs hotplug events on initial master set Thomas Hellstrom
2019-05-21  8:24 ` [PATCH 2/6] drm/vmwgfx: Fix user space handle equal to zero Thomas Hellstrom
2019-05-21  8:24 ` [PATCH 3/6] drm/vmwgfx: Fix compat mode shader operation Thomas Hellstrom
2019-05-21  8:25 ` [PATCH 5/6] drm/vmwgfx: NULL pointer dereference from vmw_cmd_dx_view_define() Thomas Hellstrom
2019-05-21  8:25 ` [PATCH 6/6] drm/vmwgfx: integer underflow in vmw_cmd_dx_set_shader() leading to an invalid read Thomas Hellstrom

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).