From mboxrd@z Thu Jan 1 00:00:00 1970 Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.remote-ip=100.103.45.18 ARC-Seal: i=1; d=subspace.kernel.org; s=arc20261015; a=rsa-sha256; cv=none; t=1796380758; b=JHhY27H4iV46PGnwwBBmPC33aOKrQ4gfnRKcfpeiHfKzqBl67o3BTC/VmDCF2tmiG+M7 f29Ibv/+bptnEghvhwSX+kWbPAbEOrQK3SaD8HY/PxM74aGg3AqoBDzmXd35LIk3JHVTo 8Vgys4UbA06UQ3FU6bWrs3oTd3llMHRrxIIx4GVzqrOBJhqT/nAXDOW+fbfYzs+ELznRw ayFyYwoPc+SRfAEA4hS862xwkoI9vLozHzhz6C2PxhMfwgZuvNqeKqlDvGFERtwP//4oE 2y9iVkLP+9s6vzJgKm9taXhR3S9JADrFUBIFMPMpV93naJ0UWKuVPjvYt51I5oUbf/g== ARC-Message-Signature: i=1; d=subspace.kernel.org; s=arc20261015; a=rsa-sha256; c=relaxed/relaxed; t=1796380758; h=Received:DKIM-Signature:From:To:Cc:Subject:Date:Message-ID:X-Mailer: In-Reply-To:References:User-Agent:X-stable:X-Patchwork-Hint: MIME-Version:Content-Transfer-Encoding; bh=85nttat+l7HGWUK76rsAid1SPuYE3zIhWOazAPiDRLA=; b=wc64LIxH7zmd/4N+SerIubToqynfeC3kYRWgbg0WztwCfuGQZUoNPv3jvDFukDAptVOY Kmbs8oJnwlJzbzWjAlzqAfRrVYghWWCBBEUzltnwybbEUWyGCshZUztUKFe/PHA6sSFA2 HJHVCOYWuGrKe3BejpAwlv1ipId0KIXsmGWMYpAhWl8+Pj7LQn8DTL8yg19mcu/JXODoE yK82lNXQQHtitWap6FRgbL0iREIbbquCPEKLLMoUUmN2sxKEwZvpFngM7tL84800ZcxaH JljFPOc1PEyG3Fr4H8JIdDhEmNmOWrwwE5FV4QoOpMcoLo2RuInhPt8LXa4bPwO2lHw== ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dkim=pass header.d=linuxfoundation.org header.i=@linuxfoundation.org header.a=rsa-sha256 header.s=korg header.b=q344F4lf; arc=none smtp.remote-ip=100.103.45.18 Received: from smtp.kernel.org (quasi.space.kernel.org [100.103.45.18]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (prime256v1)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id B18CE606A322; Fri, 4 Dec 2026 10:39:18 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=linuxfoundation.org header.i=@linuxfoundation.org header.a=rsa-sha256 header.s=korg header.b=q344F4lf Received: by smtp.kernel.org (Postfix) with ESMTPSA id 2B5CB1F00897; Fri, 4 Dec 2026 10:39:18 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linuxfoundation.org; s=korg; t=1796380758; bh=85nttat+l7HGWUK76rsAid1SPuYE3zIhWOazAPiDRLA=; h=From:To:Cc:Subject:Date:In-Reply-To:References; b=q344F4lfQuq5mftEN5PHDzIkWUnaPP3mdKCMNsME5In1C8M2Bwc6kqir/6+0UN1vh h1wuIyZemyOFjKHIng0c5pqHyC/IWTckqsVwcenDQIofqtHnAehQMv5SU9BE7am0pV DcwMSxHGyvPQzy2r/V45K6sNjs5v1gyKAAnXfqDs= From: Greg Kroah-Hartman To: stable@vger.kernel.org Cc: Greg Kroah-Hartman , patches@lists.linux.dev, Tomas M , Maaz Mombasawala , fausten , Zack Rusin Subject: [PATCH 7.3 413/742] drm/vmwgfx: include legacy hotspots in GB-only cursor images Date: Fri, 4 Dec 2026 19:04:37 +0900 Message-ID: <20261204100646.073491172@linuxfoundation.org> X-Mailer: git-send-email 2.56.1 In-Reply-To: <20261204100635.034361255@linuxfoundation.org> References: <20261204100635.034361255@linuxfoundation.org> User-Agent: quilt/0.69 X-stable: review X-Patchwork-Hint: ignore X-Mailing-List: stable@vger.kernel.org List-Id: List-Post: List-Help: List-Subscribe: List-Unsubscribe: List-Owner: Precedence: list MIME-Version: 1.0 Content-Transfer-Encoding: 8bit 7.3-stable review patch. If anyone has any objections, please let me know. ------------------ From: Tomas M commit c116d38c3ad3ccdc1153ee7713c0eafd62b1c235 upstream. The guest-backed cursor path without cursor MOB support defines the image using only the hotspot from the plane state. Its position calculation also includes the legacy hotspot supplied through DRM_VMW_CURSOR_BYPASS. Xorg's xf86-video-vmware driver supplies its hotspot through that ioctl and loads the image with drmModeSetCursor(), which does not set a plane hotspot. The mismatched image and position hotspots displace the visible cursor by the legacy offset. Use the combined hotspot for both the GB-only image command and cursor position, matching the legacy and MOB image paths. Fixes: eef295a85082 ("drm/vmwgfx: Restore Guest-Backed only cursor plane support") Cc: stable@vger.kernel.org Assisted-by: LLM Signed-off-by: Tomas M Reviewed-by: Maaz Mombasawala Tested-by: fausten Signed-off-by: Zack Rusin Link: https://patch.msgid.link/20261027211729.646988-4-zack.rusin@broadcom.com Signed-off-by: Greg Kroah-Hartman --- drivers/gpu/drm/vmwgfx/vmwgfx_cursor_plane.c | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) --- a/drivers/gpu/drm/vmwgfx/vmwgfx_cursor_plane.c +++ b/drivers/gpu/drm/vmwgfx/vmwgfx_cursor_plane.c @@ -815,6 +815,10 @@ vmw_cursor_plane_atomic_update(struct dr return; } + /* Include legacy Xorg cursor-bypass offsets in the image and position. */ + hotspot_x = vps->cursor.legacy.hotspot_x + new_state->hotspot_x; + hotspot_y = vps->cursor.legacy.hotspot_y + new_state->hotspot_y; + switch (vps->cursor.update_type) { case VMW_CURSOR_UPDATE_LEGACY: vmw_cursor_plane_update_legacy(dev_priv, vps); @@ -828,8 +832,7 @@ vmw_cursor_plane_atomic_update(struct dr vmw_send_define_cursor_cmd(dev_priv, bo->map.virtual, vps->base.crtc_w, vps->base.crtc_h, - vps->base.hotspot_x, - vps->base.hotspot_y); + hotspot_x, hotspot_y); break; case VMW_CURSOR_UPDATE_NONE: /* do nothing */ @@ -842,9 +845,6 @@ vmw_cursor_plane_atomic_update(struct dr cursor_x = new_state->crtc_x + du->set_gui_x; cursor_y = new_state->crtc_y + du->set_gui_y; - hotspot_x = vps->cursor.legacy.hotspot_x + new_state->hotspot_x; - hotspot_y = vps->cursor.legacy.hotspot_y + new_state->hotspot_y; - vmw_cursor_update_position(dev_priv, true, cursor_x + hotspot_x, cursor_y + hotspot_y); }