summaryrefslogtreecommitdiffstats
path: root/usr.bin/doscmd/video.c
diff options
context:
space:
mode:
authortg <tg@FreeBSD.org>2001-10-02 11:28:59 +0000
committertg <tg@FreeBSD.org>2001-10-02 11:28:59 +0000
commit5a5faeb1fdc45ba96f1845430e14e114bf638d07 (patch)
tree15ee4fccd16594c90a39dddc748220e18b5aa6f0 /usr.bin/doscmd/video.c
parentb377b771103513eea4b0a6853c82cc12a35fc3e7 (diff)
downloadFreeBSD-src-5a5faeb1fdc45ba96f1845430e14e114bf638d07.zip
FreeBSD-src-5a5faeb1fdc45ba96f1845430e14e114bf638d07.tar.gz
- First shot at PIC emulation;
- better 8250 emulation; - fake vertical retrace bit in Input Status #1 register (this was lost in the VGA emu rewrite). Submitted by: Igor Serikov <bt@turtle.pangeatech.com>
Diffstat (limited to 'usr.bin/doscmd/video.c')
-rw-r--r--usr.bin/doscmd/video.c6
1 files changed, 4 insertions, 2 deletions
diff --git a/usr.bin/doscmd/video.c b/usr.bin/doscmd/video.c
index bd14804..3874a8c 100644
--- a/usr.bin/doscmd/video.c
+++ b/usr.bin/doscmd/video.c
@@ -138,6 +138,7 @@ video_inb(int port)
return gdc_index;
case VGA_InputStatus1Port:
set_atc_index = 1;
+ VGA_InputStatus1 = (VGA_InputStatus1 + 1) & 15;
return VGA_InputStatus1;
default:
return 0;
@@ -259,6 +260,7 @@ video_init()
define_input_port_handler(TSC_DataPort, video_inb);
define_input_port_handler(GDC_IndexPort, video_inb);
define_input_port_handler(GDC_DataPort, video_inb);
+ define_input_port_handler(VGA_InputStatus1Port, video_inb);
define_output_port_handler(CRTC_IndexPortColor, video_outb);
define_output_port_handler(CRTC_DataPortColor, video_outb);
@@ -364,6 +366,8 @@ init_vga(void)
vplane1 = vram + 0x10000;
vplane2 = vram + 0x20000;
vplane3 = vram + 0x30000;
+
+ VGA_InputStatus1 = 0;
}
/*
@@ -450,7 +454,6 @@ init_mode(int mode)
BIOS_DpyRows = DpyRows;
BIOS_CharHeight = CharHeight;
- _BlockIO();
/* Load 'pixels[]' from default DAC values. */
update_pixels();
@@ -460,7 +463,6 @@ init_mode(int mode)
/* Resize window if necessary. */
resize_window();
- _UnblockIO();
/* Mmap video memory for the graphics modes. Write access to 0xa0000 -
0xaffff will generate a T_PAGEFAULT trap in VM86 mode (aside: why not a
OpenPOWER on IntegriCloud