Module: wine
Branch: master
Commit: d287548c77350b81faa946b0977dffcbfcce9b83
URL: https://gitlab.winehq.org/wine/wine/-/commit/d287548c77350b81faa946b0977dff…
Author: Zhiyi Zhang <zzhang(a)codeweavers.com>
Date: Wed Feb 28 10:22:23 2024 +0800
Revert "winex11.drv: Handle X error from vkGetRandROutputDisplayEXT()."
This reverts commit 6f9d20806e821ab07c8adf81ae6630fae94b00ef.
6f9d208 was committed to work around a Nvidia driver bug that can cause vkGetRandROutputDisplayEXT()
to generate an X exception and crash applications. The bug is later fixed in Nvidia driver 450.56.11
and newer. Thus 6f9d208 is no longer necessary on the newer Nvidia drivers.
Then after 18ae96e, another bug in the Nvidia driver can cause vkGetRandROutputDisplayEXT() to hang
forever when XLockDisplay() is called before vkGetRandROutputDisplayEXT() and this bug is still not
fixed and affects multiple applications. Reverting 6f9d208 allows us to work around the
vkGetRandROutputDisplayEXT() hang bug because then it no longer calls XLockDisplay() before
vkGetRandROutputDisplayEXT().
Nvidia driver 455 was released on September 9th 2020 so hopefully the fix is already widespread. We
could theoretically still keep 6f9d208 on older Nvidia drivers by doing version checks. But it's
more straightforward to remove the workaround since it's not a bug of Wine.
Wine-Bug: https://bugs.winehq.org/show_bug.cgi?id=53428
---
dlls/winex11.drv/xrandr.c | 4 +---
1 file changed, 1 insertion(+), 3 deletions(-)
diff --git a/dlls/winex11.drv/xrandr.c b/dlls/winex11.drv/xrandr.c
index 5c0269f3550..d77eb1a0163 100644
--- a/dlls/winex11.drv/xrandr.c
+++ b/dlls/winex11.drv/xrandr.c
@@ -707,11 +707,9 @@ static BOOL get_gpu_properties_from_vulkan( struct gdi_gpu *gpu, const XRRProvid
{
for (output_idx = 0; output_idx < provider_info->noutputs; ++output_idx)
{
- X11DRV_expect_error( gdi_display, XRandRErrorHandler, NULL );
vr = pvkGetRandROutputDisplayEXT( vk_physical_devices[device_idx], gdi_display,
provider_info->outputs[output_idx], &vk_display );
- XSync( gdi_display, FALSE );
- if (X11DRV_check_error() || vr != VK_SUCCESS || vk_display == VK_NULL_HANDLE)
+ if (vr != VK_SUCCESS || vk_display == VK_NULL_HANDLE)
continue;
memset( &id, 0, sizeof(id) );