]> git.ipfire.org Git - thirdparty/kernel/stable-queue.git/commitdiff
4.12-stable patches
authorGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Wed, 9 Aug 2017 16:39:33 +0000 (09:39 -0700)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Wed, 9 Aug 2017 16:39:33 +0000 (09:39 -0700)
added patches:
drm-vmwgfx-fix-cursor-hotspot-issue-with-wayland-on-fedora.patch

queue-4.12/drm-vmwgfx-fix-cursor-hotspot-issue-with-wayland-on-fedora.patch [new file with mode: 0644]
queue-4.12/series

diff --git a/queue-4.12/drm-vmwgfx-fix-cursor-hotspot-issue-with-wayland-on-fedora.patch b/queue-4.12/drm-vmwgfx-fix-cursor-hotspot-issue-with-wayland-on-fedora.patch
new file mode 100644 (file)
index 0000000..b705553
--- /dev/null
@@ -0,0 +1,53 @@
+From 14979adb0294f04cf6fbbb81555acff9ec1e7c9c Mon Sep 17 00:00:00 2001
+From: Sinclair Yeh <syeh@vmware.com>
+Date: Mon, 17 Jul 2017 23:26:21 -0700
+Subject: drm/vmwgfx: Fix cursor hotspot issue with Wayland on Fedora
+MIME-Version: 1.0
+Content-Type: text/plain; charset=UTF-8
+Content-Transfer-Encoding: 8bit
+
+From: Sinclair Yeh <syeh@vmware.com>
+
+commit 14979adb0294f04cf6fbbb81555acff9ec1e7c9c upstream.
+
+Parts of commit <8fbf9d92a7bc> (“drm/vmwgfx: Implement the
+cursor_set2 callback v2”) were not moved over when we started
+atomic mode set development because at that time the DRM did
+not support cursor hotspots in the fb struct.
+
+This patch fixes what was not moved over.
+
+Signed-off-by: Sinclair Yeh <syeh@vmware.com>
+Reviewed-by: Brian Paul <brianp@vmware.com>
+Tested-by: Brian Paul <brianp@vmware.com>
+Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
+
+---
+ drivers/gpu/drm/vmwgfx/vmwgfx_kms.c |    9 +++++++++
+ 1 file changed, 9 insertions(+)
+
+--- a/drivers/gpu/drm/vmwgfx/vmwgfx_kms.c
++++ b/drivers/gpu/drm/vmwgfx/vmwgfx_kms.c
+@@ -384,6 +384,12 @@ vmw_du_cursor_plane_atomic_update(struct
+       hotspot_x = du->hotspot_x;
+       hotspot_y = du->hotspot_y;
++
++      if (plane->fb) {
++              hotspot_x += plane->fb->hot_x;
++              hotspot_y += plane->fb->hot_y;
++      }
++
+       du->cursor_surface = vps->surf;
+       du->cursor_dmabuf = vps->dmabuf;
+@@ -411,6 +417,9 @@ vmw_du_cursor_plane_atomic_update(struct
+               vmw_cursor_update_position(dev_priv, true,
+                                          du->cursor_x + hotspot_x,
+                                          du->cursor_y + hotspot_y);
++
++              du->core_hotspot_x = hotspot_x - du->hotspot_x;
++              du->core_hotspot_y = hotspot_y - du->hotspot_y;
+       } else {
+               DRM_ERROR("Failed to update cursor image\n");
+       }
index 555766e0368c9cb4a5a570559a0aa455c46afaff..6fd42fba1314bd9b69016afc43a16cf8657ee282 100644 (file)
@@ -103,3 +103,4 @@ sparc64-measure-receiver-forward-progress-to-avoid-send-mondo-timeout.patch
 sparc64-prevent-perf-from-running-during-super-critical-sections.patch
 sparc64-register-hugepages-during-arch-init.patch
 sparc64-fix-exception-handling-in-ultrasparc-iii-memcpy.patch
+drm-vmwgfx-fix-cursor-hotspot-issue-with-wayland-on-fedora.patch