update xorg-x11-drv-vesa to 2.5.0
This commit is contained in:
parent
8af5c768f5
commit
14b92df7b2
@ -1,63 +0,0 @@
|
|||||||
From 57301015f16e26f12caf6f6cb4d730e7793cb2c3 Mon Sep 17 00:00:00 2001
|
|
||||||
From: Adam Jackson <ajax@redhat.com>
|
|
||||||
Date: Wed, 30 May 2018 11:46:46 -0400
|
|
||||||
Subject: [PATCH xf86-video-vesa] Disable shadow by default on known-virtual
|
|
||||||
GPUs
|
|
||||||
|
|
||||||
Device memory is the same domain as host memory, in this case, so the
|
|
||||||
shadow just introduces more memcpy.
|
|
||||||
|
|
||||||
Signed-off-by: Adam Jackson <ajax@redhat.com>
|
|
||||||
---
|
|
||||||
src/vesa.c | 35 ++++++++++++++++++++++++++++++++---
|
|
||||||
1 file changed, 32 insertions(+), 3 deletions(-)
|
|
||||||
|
|
||||||
diff --git a/src/vesa.c b/src/vesa.c
|
|
||||||
index 2300f4e..7d2bf94 100644
|
|
||||||
--- a/src/vesa.c
|
|
||||||
+++ b/src/vesa.c
|
|
||||||
@@ -844,9 +844,38 @@ VESAPreInit(ScrnInfoPtr pScrn, int flags)
|
|
||||||
memcpy(pVesa->Options, VESAOptions, sizeof(VESAOptions));
|
|
||||||
xf86ProcessOptions(pScrn->scrnIndex, pScrn->options, pVesa->Options);
|
|
||||||
|
|
||||||
- /* Use shadow by default */
|
|
||||||
- pVesa->shadowFB = xf86ReturnOptValBool(pVesa->Options, OPTION_SHADOW_FB,
|
|
||||||
- TRUE);
|
|
||||||
+ /* Use shadow by default, for non-virt hardware */
|
|
||||||
+ if (!xf86GetOptValBool(pVesa->Options, OPTION_SHADOW_FB, &pVesa->shadowFB))
|
|
||||||
+ {
|
|
||||||
+ switch (pVesa->pciInfo->vendor_id) {
|
|
||||||
+ case 0x1234: /* bochs vga (not in pci.ids) */
|
|
||||||
+ case 0x15ad: /* vmware */
|
|
||||||
+ case 0x1b36: /* qemu qxl */
|
|
||||||
+ case 0x80ee: /* virtualbox */
|
|
||||||
+ case 0xaaaa: /* parallels (not in pci.ids) */
|
|
||||||
+ pVesa->shadowFB = FALSE;
|
|
||||||
+ break;
|
|
||||||
+
|
|
||||||
+ case 0x1013: /* qemu's cirrus emulation */
|
|
||||||
+ if (pVesa->pciInfo->subvendor_id == 0x1af4)
|
|
||||||
+ pVesa->shadowFB = FALSE;
|
|
||||||
+ else
|
|
||||||
+ pVesa->shadowFB = TRUE;
|
|
||||||
+ break;
|
|
||||||
+
|
|
||||||
+ case 0x1414: /* microsoft hyper-v */
|
|
||||||
+ if (pVesa->pciInfo->device_id == 0x5353)
|
|
||||||
+ pVesa->shadowFB = FALSE;
|
|
||||||
+ else
|
|
||||||
+ pVesa->shadowFB = TRUE;
|
|
||||||
+ break;
|
|
||||||
+
|
|
||||||
+ default:
|
|
||||||
+ pVesa->shadowFB = TRUE;
|
|
||||||
+ break;
|
|
||||||
+ }
|
|
||||||
+ }
|
|
||||||
+
|
|
||||||
/* Use default refresh by default. Too many VBE 3.0
|
|
||||||
* BIOSes are incorrectly implemented.
|
|
||||||
*/
|
|
||||||
--
|
|
||||||
2.17.0
|
|
||||||
|
|
||||||
@ -1,17 +0,0 @@
|
|||||||
diff -up xf86-video-vesa-2.3.0/src/vesa.c.jx xf86-video-vesa-2.3.0/src/vesa.c
|
|
||||||
--- xf86-video-vesa-2.3.0/src/vesa.c.jx 2010-01-04 14:16:31.000000000 -0500
|
|
||||||
+++ xf86-video-vesa-2.3.0/src/vesa.c 2010-10-11 15:29:52.000000000 -0400
|
|
||||||
@@ -651,10 +651,12 @@ VESAPreInit(ScrnInfoPtr pScrn, int flags
|
|
||||||
V_MODETYPE_VBE);
|
|
||||||
|
|
||||||
/* Preferred order for default depth selection. */
|
|
||||||
- if (depths & V_DEPTH_24)
|
|
||||||
+ if ((depths & V_DEPTH_24) && (flags24 & Support32bppFb))
|
|
||||||
defaultDepth = 24;
|
|
||||||
else if (depths & V_DEPTH_16)
|
|
||||||
defaultDepth = 16;
|
|
||||||
+ else if (depths & V_DEPTH_24)
|
|
||||||
+ defaultDepth = 24;
|
|
||||||
else if (depths & V_DEPTH_15)
|
|
||||||
defaultDepth = 15;
|
|
||||||
else if (depths & V_DEPTH_8)
|
|
||||||
@ -1,46 +0,0 @@
|
|||||||
From 2645e0aa9c17c2c966a0533e52ad00510311483e Mon Sep 17 00:00:00 2001
|
|
||||||
From: Adam Jackson <ajax@redhat.com>
|
|
||||||
Date: Wed, 29 Aug 2018 11:04:23 -0400
|
|
||||||
Subject: [PATCH xf86-video-vesa] Refuse to run on UEFI machines
|
|
||||||
|
|
||||||
No possible good can come of this.
|
|
||||||
|
|
||||||
v2: Check for .../efi-framebuffer.0 ("is there an EFI framebuffer")
|
|
||||||
instead of /sys/firmware/efi ("is this an EFI machine"). Suggested by
|
|
||||||
Peter Jones.
|
|
||||||
|
|
||||||
Reviewed-by: Peter Jones <pjones@redhat.com>
|
|
||||||
Signed-off-by: Adam Jackson <ajax@redhat.com>
|
|
||||||
|
|
||||||
diff --git a/src/vesa.c b/src/vesa.c
|
|
||||||
index 9b65b9b..af750e2 100644
|
|
||||||
--- a/src/vesa.c
|
|
||||||
+++ b/src/vesa.c
|
|
||||||
@@ -43,7 +43,7 @@
|
|
||||||
#endif
|
|
||||||
|
|
||||||
#include <string.h>
|
|
||||||
-
|
|
||||||
+#include <unistd.h>
|
|
||||||
#include "vesa.h"
|
|
||||||
|
|
||||||
/* All drivers initialising the SW cursor need this */
|
|
||||||
@@ -450,7 +450,14 @@ VESAPciProbe(DriverPtr drv, int entity_num, struct pci_device *dev,
|
|
||||||
intptr_t match_data)
|
|
||||||
{
|
|
||||||
ScrnInfoPtr pScrn;
|
|
||||||
-
|
|
||||||
+
|
|
||||||
+#ifdef __linux__
|
|
||||||
+ if (access("/sys/devices/platform/efi-framebuffer.0", F_OK) == 0) {
|
|
||||||
+ ErrorF("vesa: Refusing to run on UEFI\n");
|
|
||||||
+ return FALSE;
|
|
||||||
+ }
|
|
||||||
+#endif
|
|
||||||
+
|
|
||||||
pScrn = xf86ConfigPciEntity(NULL, 0, entity_num, NULL,
|
|
||||||
NULL, NULL, NULL, NULL, NULL);
|
|
||||||
if (pScrn != NULL) {
|
|
||||||
--
|
|
||||||
2.17.1
|
|
||||||
|
|
||||||
Binary file not shown.
BIN
xf86-video-vesa-2.5.0.tar.bz2
Normal file
BIN
xf86-video-vesa-2.5.0.tar.bz2
Normal file
Binary file not shown.
@ -4,17 +4,13 @@
|
|||||||
%undefine _hardened_build
|
%undefine _hardened_build
|
||||||
|
|
||||||
Name: xorg-x11-drv-vesa
|
Name: xorg-x11-drv-vesa
|
||||||
Version: 2.4.0
|
Version: 2.5.0
|
||||||
Release: 2
|
Release: 1
|
||||||
Summary: Xorg X11 vesa video driver
|
Summary: Xorg X11 vesa video driver
|
||||||
License: MIT
|
License: MIT
|
||||||
URL: https://www.x.org
|
URL: https://www.x.org
|
||||||
Source0: https://xorg.freedesktop.org/releases/individual/driver/xf86-video-vesa-%{version}.tar.bz2
|
Source0: https://xorg.freedesktop.org/releases/individual/driver/xf86-video-vesa-%{version}.tar.bz2
|
||||||
|
|
||||||
Patch0: vesa-2.3.0-24bpp-sucks.patch
|
|
||||||
Patch1: 0001-Disable-shadow-by-default-on-known-virtual-GPUs.patch
|
|
||||||
Patch2: vesa-Refuse-to-run-on-UEFI-machines.patch
|
|
||||||
|
|
||||||
ExclusiveArch: %{ix86} x86_64
|
ExclusiveArch: %{ix86} x86_64
|
||||||
|
|
||||||
BuildRequires: xorg-x11-server-devel >= 1.10.99.902
|
BuildRequires: xorg-x11-server-devel >= 1.10.99.902
|
||||||
@ -49,10 +45,16 @@ autoreconf -v --install || exit 1
|
|||||||
|
|
||||||
%files help
|
%files help
|
||||||
%defattr(-,root,root)
|
%defattr(-,root,root)
|
||||||
%doc README ChangeLog
|
%doc README.md ChangeLog
|
||||||
%{_mandir}/man4/vesa.4*
|
%{_mandir}/man4/vesa.4*
|
||||||
|
|
||||||
%changelog
|
%changelog
|
||||||
|
* Sat Jan 30 2021 xihaochen <xihaochen@huawei.com> - 2.5.0-1
|
||||||
|
- Type:requirements
|
||||||
|
- Id:NA
|
||||||
|
- SUG:NA
|
||||||
|
- DESC:update xorg-x11-drv-vesa to 2.5.0
|
||||||
|
|
||||||
* Sat Mar 21 2020 fengtao <fengtao40@huawei.com> - 2.4.0-2
|
* Sat Mar 21 2020 fengtao <fengtao40@huawei.com> - 2.4.0-2
|
||||||
- Refuse vesa on UEFI
|
- Refuse vesa on UEFI
|
||||||
|
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user