2004-12-01 02:41:04 +03:00
|
|
|
Index: clext.c
|
|
|
|
===================================================================
|
2006-03-25 04:25:02 +03:00
|
|
|
RCS file: /sources/vgabios/vgabios/clext.c,v
|
2006-05-15 01:03:52 +04:00
|
|
|
retrieving revision 1.10
|
|
|
|
diff -u -w -r1.10 clext.c
|
|
|
|
--- clext.c 25 Mar 2006 10:19:15 -0000 1.10
|
|
|
|
+++ clext.c 14 May 2006 20:49:29 -0000
|
|
|
|
@@ -544,6 +544,13 @@
|
|
|
|
cirrus_set_video_mode_extended:
|
|
|
|
call cirrus_switch_mode
|
|
|
|
pop ax ;; mode
|
|
|
|
+ test al, #0x80
|
|
|
|
+ jnz cirrus_set_video_mode_extended_1
|
|
|
|
+ push ax
|
|
|
|
+ mov ax, #0xffff ; set to 0xff to keep win 2K happy
|
|
|
|
+ call cirrus_clear_vram
|
|
|
|
+ pop ax
|
|
|
|
+cirrus_set_video_mode_extended_1:
|
|
|
|
and al, #0x7f
|
|
|
|
|
|
|
|
push ds
|
|
|
|
@@ -1011,6 +1018,13 @@
|
|
|
|
jnz cirrus_vesa_02h_3
|
|
|
|
call cirrus_enable_16k_granularity
|
|
|
|
cirrus_vesa_02h_3:
|
|
|
|
+ test bx, #0x8000 ;; no clear
|
|
|
|
+ jnz cirrus_vesa_02h_4
|
|
|
|
+ push ax
|
|
|
|
+ xor ax,ax
|
|
|
|
+ call cirrus_clear_vram
|
|
|
|
+ pop ax
|
|
|
|
+cirrus_vesa_02h_4:
|
|
|
|
pop ax
|
|
|
|
push ds
|
|
|
|
#ifdef CIRRUS_VESA3_PMINFO
|
|
|
|
@@ -1479,6 +1493,38 @@
|
|
|
|
pop bx
|
2006-03-25 04:25:02 +03:00
|
|
|
ret
|
|
|
|
|
2006-05-15 01:03:52 +04:00
|
|
|
+cirrus_clear_vram:
|
|
|
|
+ pusha
|
|
|
|
+ push es
|
|
|
|
+ mov si, ax
|
2006-03-25 04:25:02 +03:00
|
|
|
+
|
2006-05-15 01:03:52 +04:00
|
|
|
+ call cirrus_enable_16k_granularity
|
|
|
|
+ call cirrus_extbios_85h
|
|
|
|
+ shl al, #2
|
|
|
|
+ mov bl, al
|
|
|
|
+ xor ah,ah
|
|
|
|
+cirrus_clear_vram_1:
|
|
|
|
+ mov al, #0x09
|
|
|
|
+ mov dx, #0x3ce
|
|
|
|
+ out dx, ax
|
|
|
|
+ push ax
|
|
|
|
+ mov cx, #0xa000
|
|
|
|
+ mov es, cx
|
|
|
|
+ xor di, di
|
|
|
|
+ mov ax, si
|
|
|
|
+ mov cx, #8192
|
|
|
|
+ cld
|
|
|
|
+ rep
|
|
|
|
+ stosw
|
|
|
|
+ pop ax
|
|
|
|
+ inc ah
|
|
|
|
+ cmp ah, bl
|
|
|
|
+ jne cirrus_clear_vram_1
|
2006-03-25 04:25:02 +03:00
|
|
|
+
|
2006-05-15 01:03:52 +04:00
|
|
|
+ pop es
|
|
|
|
+ popa
|
|
|
|
+ ret
|
2006-03-25 04:25:02 +03:00
|
|
|
+
|
2006-05-15 01:03:52 +04:00
|
|
|
cirrus_extbios_handlers:
|
|
|
|
;; 80h
|
|
|
|
dw cirrus_extbios_80h
|