6408c5
From 9e3aaa8c60399e1a66f4700b34698ef4cc59c773 Mon Sep 17 00:00:00 2001
6408c5
From: Gerd Hoffmann <kraxel@redhat.com>
6408c5
Date: Thu, 2 Jul 2020 16:33:09 -0400
6408c5
Subject: [PATCH] vga: fix cirrus bios
6408c5
6408c5
RH-Author: Gerd Hoffmann <kraxel@redhat.com>
6408c5
Message-id: <20200702163309.29589-2-kraxel@redhat.com>
6408c5
Patchwork-id: 97895
6408c5
O-Subject: [RHEL-AV-8.2.1 seabios PATCH 1/1] vga: fix cirrus bios
6408c5
Bugzilla: 1847959
6408c5
RH-Acked-by: Laszlo Ersek <lersek@redhat.com>
6408c5
RH-Acked-by: Juan Quintela <quintela@redhat.com>
6408c5
RH-Acked-by: Dr. David Alan Gilbert <dgilbert@redhat.com>
6408c5
6408c5
Little mistake, big effect.  The patch adding the ati driver broke
6408c5
cirrus due to a missing "else", which effectively downgrades cirrus
6408c5
to standard vga.
6408c5
6408c5
Fixes: 34b6ecc16074 ("vga: add atiext driver")
6408c5
Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
6408c5
(cherry picked from commit d11c75185276ded944f2ea0277532b7fee849bbc)
6408c5
Signed-off-by: Danilo C. L. de Paula <ddepaula@redhat.com>
6408c5
---
6408c5
 vgasrc/vgahw.h | 2 +-
6408c5
 1 file changed, 1 insertion(+), 1 deletion(-)
6408c5
6408c5
diff --git a/vgasrc/vgahw.h b/vgasrc/vgahw.h
6408c5
index c774f4f2..8b64660e 100644
6408c5
--- a/vgasrc/vgahw.h
6408c5
+++ b/vgasrc/vgahw.h
6408c5
@@ -36,7 +36,7 @@ static inline int vgahw_set_mode(struct vgamode_s *vmode_g, int flags) {
6408c5
 static inline void vgahw_list_modes(u16 seg, u16 *dest, u16 *last) {
6408c5
     if (CONFIG_VGA_CIRRUS)
6408c5
         clext_list_modes(seg, dest, last);
6408c5
-    if (CONFIG_VGA_ATI)
6408c5
+    else if (CONFIG_VGA_ATI)
6408c5
         ati_list_modes(seg, dest, last);
6408c5
     else if (CONFIG_VGA_BOCHS)
6408c5
         bochsvga_list_modes(seg, dest, last);
6408c5
-- 
6408c5
2.27.0
6408c5