Source-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[src/trunk]: src/sys/dev/ic When disabling the hardware cursor, use the 'curs...



details:   https://anonhg.NetBSD.org/src/rev/2d7b8eb57d4a
branches:  trunk
changeset: 758111:2d7b8eb57d4a
user:      jmcneill <jmcneill%NetBSD.org@localhost>
date:      Tue Oct 19 22:27:19 2010 +0000

description:
When disabling the hardware cursor, use the 'cursor disable' bit in the
cursor start register. I think this only accidentally worked for the past
11 years because the start and end scanlines were both set to 0x10.

See also http://www.osdever.net/FreeVGA/vga/crtcreg.htm#0A

diffstat:

 sys/dev/ic/pcdisplay_subr.c |  9 +++++----
 1 files changed, 5 insertions(+), 4 deletions(-)

diffs (30 lines):

diff -r 30d59a87d36c -r 2d7b8eb57d4a sys/dev/ic/pcdisplay_subr.c
--- a/sys/dev/ic/pcdisplay_subr.c       Tue Oct 19 19:19:41 2010 +0000
+++ b/sys/dev/ic/pcdisplay_subr.c       Tue Oct 19 22:27:19 2010 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: pcdisplay_subr.c,v 1.34 2007/10/19 11:59:58 ad Exp $ */
+/* $NetBSD: pcdisplay_subr.c,v 1.35 2010/10/19 22:27:19 jmcneill Exp $ */
 
 /*
  * Copyright (c) 1995, 1996 Carnegie-Mellon University.
@@ -28,7 +28,7 @@
  */
 
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: pcdisplay_subr.c,v 1.34 2007/10/19 11:59:58 ad Exp $");
+__KERNEL_RCSID(0, "$NetBSD: pcdisplay_subr.c,v 1.35 2010/10/19 22:27:19 jmcneill Exp $");
 
 #include "opt_wsmsgattrs.h" /* for WSDISPLAY_CUSTOM_OUTPUT */
 
@@ -51,8 +51,9 @@
        bus_space_handle_t memh;
        int off;
 
-       pcdisplay_6845_write(scr->hdl, curstart, 0x10);
-       pcdisplay_6845_write(scr->hdl, curend, 0x10);
+       /* Disable the hardware cursor */
+       pcdisplay_6845_write(scr->hdl, curstart, 0x20);
+       pcdisplay_6845_write(scr->hdl, curend, 0x00);
 
        if (existing) {
                /*



Home | Main Index | Thread Index | Old Index