summaryrefslogtreecommitdiffstats
path: root/sys/pc98/cbus/gdc.c
diff options
context:
space:
mode:
authorkato <kato@FreeBSD.org>1999-07-03 08:44:32 +0000
committerkato <kato@FreeBSD.org>1999-07-03 08:44:32 +0000
commita4c978543ac386452ece7df41af386780d5b2c9e (patch)
tree44dfc58914e81247337e543f482489de17946706 /sys/pc98/cbus/gdc.c
parente386828d08b325c9724bd9f79c8d8dcdf7af4ebc (diff)
downloadFreeBSD-src-a4c978543ac386452ece7df41af386780d5b2c9e.zip
FreeBSD-src-a4c978543ac386452ece7df41af386780d5b2c9e.tar.gz
Moved LCD controle routine for certain models of EPSON laptops into
suitable place. Submitted by: yokota
Diffstat (limited to 'sys/pc98/cbus/gdc.c')
-rw-r--r--sys/pc98/cbus/gdc.c34
1 files changed, 5 insertions, 29 deletions
diff --git a/sys/pc98/cbus/gdc.c b/sys/pc98/cbus/gdc.c
index e98f35e..4702090 100644
--- a/sys/pc98/cbus/gdc.c
+++ b/sys/pc98/cbus/gdc.c
@@ -25,7 +25,7 @@
* (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
* THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*
- * $Id: pc98gdc.c,v 1.9 1999/05/30 16:53:20 phk Exp $
+ * $Id: pc98gdc.c,v 1.10 1999/06/24 10:51:29 kato Exp $
*/
#include "gdc.h"
@@ -886,25 +886,9 @@ gdc_set_hw_cursor(video_adapter_t *adp, int col, int row)
if ((col == -1) && (row == -1)) {
off = -1;
- /* XXX */
- if (epson_machine_id == 0x20) {
- s = spltty();
- outb(0x43f, 0x42);
- outb(0x0c17, inb(0xc17) & ~0x08);
- outb(0x43f, 0x40);
- splx(s);
- }
} else {
if (adp->va_info.vi_flags & V_INFO_GRAPHICS)
return ENODEV;
- /* XXX */
- if (epson_machine_id == 0x20) {
- s = spltty();
- outb(0x43f, 0x42);
- outb(0x0c17, inb(0xc17) | 0x08);
- outb(0x43f, 0x40);
- splx(s);
- }
off = row*adp->va_info.vi_width + col;
}
@@ -944,14 +928,6 @@ gdc_set_hw_cursor_shape(video_adapter_t *adp, int base, int height,
--end;
s = spltty();
- if (epson_machine_id == 0x20) { /* XXX */
- outb(0x43f, 0x42);
- if (height > 0)
- outb(0x0c17, inb(0xc17) | 0x08);
- else
- outb(0x0c17, inb(0xc17) & ~0x08);
- outb(0x43f, 0x40);
- }
master_gdc_cmd(0x4b); /* _GDC_CSRFORM */
master_gdc_prm(((height > 0) ? 0x80 : 0) /* cursor on/off */
| ((celsize - 1) & 0x1f)); /* cel size */
@@ -987,10 +963,10 @@ gdc_blank_display(video_adapter_t *adp, int mode)
/* FALL THROUGH */
case V_DISPLAY_BLANK:
- if (epson_machine_id == 0x20) { /* XXX */
+ if (epson_machine_id == 0x20) {
outb(0x43f, 0x42);
- outb(0xc17, inb(0xc17) & ~0x08);
- outb(0xc16, inb(0xc16) & ~0x02);
+ outb(0xc17, inb(0xc17) & ~0x08); /* turn off side light */
+ outb(0xc16, inb(0xc16) & ~0x02); /* turn off back light */
outb(0x43f, 0x40);
} else {
while (!(inb(TEXT_GDC) & 0x20)) /* V-SYNC wait */
@@ -1000,7 +976,7 @@ gdc_blank_display(video_adapter_t *adp, int mode)
break;
case V_DISPLAY_ON:
- if (epson_machine_id == 0x20) { /* XXX */
+ if (epson_machine_id == 0x20) {
outb(0x43f, 0x42);
outb(0xc17, inb(0xc17) | 0x08);
outb(0xc16, inb(0xc16) | 0x02);
OpenPOWER on IntegriCloud