aboutsummaryrefslogtreecommitdiff
path: root/sys/pc98
diff options
context:
space:
mode:
authorYoshihiro Takahashi <nyan@FreeBSD.org>2000-03-29 12:29:27 +0000
committerYoshihiro Takahashi <nyan@FreeBSD.org>2000-03-29 12:29:27 +0000
commit6566129694e50b9b7cf3760cf96d21362246e793 (patch)
tree034d196f620238901d9ae7ca8f558f8056018999 /sys/pc98
parent8b838a7ac2beb1e45589c7c40a871da579697bad (diff)
Notes
Diffstat (limited to 'sys/pc98')
-rw-r--r--sys/pc98/cbus/gdc.c16
-rw-r--r--sys/pc98/pc98/pc98gdc.c16
2 files changed, 20 insertions, 12 deletions
diff --git a/sys/pc98/cbus/gdc.c b/sys/pc98/cbus/gdc.c
index 26dcb4373532..504e9fda75ad 100644
--- a/sys/pc98/cbus/gdc.c
+++ b/sys/pc98/cbus/gdc.c
@@ -942,6 +942,7 @@ static int
gdc_blank_display(video_adapter_t *adp, int mode)
{
int s;
+ static int standby = 0;
if (!gdc_init_done)
return ENXIO;
@@ -950,10 +951,9 @@ gdc_blank_display(video_adapter_t *adp, int mode)
switch (mode) {
case V_DISPLAY_SUSPEND:
case V_DISPLAY_STAND_BY:
- /*
- * FIXME: I don't know how to put the display into `suspend'
- * or `stand-by' mode via GDC...
- */
+ outb(0x09a2, 0x80 | 0x40); /* V/H-SYNC mask */
+ if (inb(0x09a2) == (0x80 | 0x40))
+ standby = 1;
/* FALL THROUGH */
case V_DISPLAY_BLANK:
@@ -965,7 +965,7 @@ gdc_blank_display(video_adapter_t *adp, int mode)
} else {
while (!(inb(TEXT_GDC) & 0x20)) /* V-SYNC wait */
;
- outb(TEXT_GDC + 2, 0xc); /* text off */
+ outb(TEXT_GDC + 8, 0x0e); /* DISP off */
}
break;
@@ -978,7 +978,11 @@ gdc_blank_display(video_adapter_t *adp, int mode)
} else {
while (!(inb(TEXT_GDC) & 0x20)) /* V-SYNC wait */
;
- outb(TEXT_GDC + 2, 0xd); /* text on */
+ outb(TEXT_GDC + 8, 0x0f); /* DISP on */
+ }
+ if (standby) {
+ outb(0x09a2, 0x00); /* V/H-SYNC unmask */
+ standby = 0;
}
break;
}
diff --git a/sys/pc98/pc98/pc98gdc.c b/sys/pc98/pc98/pc98gdc.c
index 26dcb4373532..504e9fda75ad 100644
--- a/sys/pc98/pc98/pc98gdc.c
+++ b/sys/pc98/pc98/pc98gdc.c
@@ -942,6 +942,7 @@ static int
gdc_blank_display(video_adapter_t *adp, int mode)
{
int s;
+ static int standby = 0;
if (!gdc_init_done)
return ENXIO;
@@ -950,10 +951,9 @@ gdc_blank_display(video_adapter_t *adp, int mode)
switch (mode) {
case V_DISPLAY_SUSPEND:
case V_DISPLAY_STAND_BY:
- /*
- * FIXME: I don't know how to put the display into `suspend'
- * or `stand-by' mode via GDC...
- */
+ outb(0x09a2, 0x80 | 0x40); /* V/H-SYNC mask */
+ if (inb(0x09a2) == (0x80 | 0x40))
+ standby = 1;
/* FALL THROUGH */
case V_DISPLAY_BLANK:
@@ -965,7 +965,7 @@ gdc_blank_display(video_adapter_t *adp, int mode)
} else {
while (!(inb(TEXT_GDC) & 0x20)) /* V-SYNC wait */
;
- outb(TEXT_GDC + 2, 0xc); /* text off */
+ outb(TEXT_GDC + 8, 0x0e); /* DISP off */
}
break;
@@ -978,7 +978,11 @@ gdc_blank_display(video_adapter_t *adp, int mode)
} else {
while (!(inb(TEXT_GDC) & 0x20)) /* V-SYNC wait */
;
- outb(TEXT_GDC + 2, 0xd); /* text on */
+ outb(TEXT_GDC + 8, 0x0f); /* DISP on */
+ }
+ if (standby) {
+ outb(0x09a2, 0x00); /* V/H-SYNC unmask */
+ standby = 0;
}
break;
}