Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Missing support for Cirrus 4 bpp modes #360

Open
Vort opened this issue Oct 5, 2024 · 0 comments
Open

Missing support for Cirrus 4 bpp modes #360

Vort opened this issue Oct 5, 2024 · 0 comments

Comments

@Vort
Copy link
Contributor

Vort commented Oct 5, 2024

When Windows 3.11 CL-GD5446 driver tries switching to 800x600x4 or 1024x768x4 modes, switch to 640x480x4 happens instead.

It happens because Cirrus modes 0x58 and 0x5D are missing from BIOS tables.
With vgatables.h hacked this way, driver is able to switch to 800x600x4 mode successfully, but such solution is of course incorrect - proper implementation is needed.

diff --git a/vgabios/vgatables.h b/vgabios/vgatables.h
index ff6e7a8..adea6d9 100644
--- a/vgabios/vgatables.h
+++ b/vgabios/vgatables.h
@@ -85,7 +85,7 @@
  * Tables of default values for each mode
  *
  */
-#define MODE_MAX   15
+#define MODE_MAX   16
 #define TEXT       0x00
 #define GRAPH      0x01
 
@@ -129,6 +129,7 @@ static VGAMODES vga_modes[MODE_MAX+1]=
  {0x11, GRAPH, PLANAR1, 1, 0xA000, 0x02, 0x1a},
  {0x12, GRAPH, PLANAR4, 4, 0xA000, 0x02, 0x1b},
  {0x13, GRAPH, LINEAR8, 8, 0xA000, 0x03, 0x1c},
+ {0x58, GRAPH, PLANAR4, 4, 0xA000, 0x02, 0x1d},
  {0x6A, GRAPH, PLANAR4, 4, 0xA000, 0x02, 0x1d}
 };

Besides Windows 3.11, VBETest shows lack of these modes as well:
image

With cl-gd5446_pci_vga_bios_version_1.31.u2, these modes are in place:
image

Version: 85c58ff

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant