summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAdam Jackson <ajax@redhat.com>2019-03-06 12:45:11 -0500
committerAdam Jackson <ajax@redhat.com>2019-03-06 12:45:11 -0500
commit634dae745cf71c257554b4c18bde7710cd1716e8 (patch)
tree630d1c10649b3d5e29dcd911b7b44af5c7d73b97
parent637c968d1a2fecfb25bd6d14e4fe285e3ceafc13 (diff)
downloadxorg-driver-xf86-video-vesa-634dae745cf71c257554b4c18bde7710cd1716e8.tar.gz
Try harder to avoid 24bpp
We're preferring depth 24 even if that means 24bpp. Newer servers don't support 24bpp anymore, and even for old servers it's suboptimal. Change the heuristic to only try 24bpp if the alternative is pseudocolor. Fixes: xorg/driver/xf86-video-vesa#3
-rw-r--r--src/vesa.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/src/vesa.c b/src/vesa.c
index af750e2..7f11175 100644
--- a/src/vesa.c
+++ b/src/vesa.c
@@ -690,12 +690,14 @@ 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_15)
defaultDepth = 15;
+ else if (depths & V_DEPTH_24)
+ defaultDepth = 24; /* ew though */
else if (depths & V_DEPTH_8)
defaultDepth = 8;
else if (depths & V_DEPTH_4)