Source-Changes-HG archive

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

[src/trunk]: src/sys/dev/wscons do this console device lookup thing the right...



details:   https://anonhg.NetBSD.org/src/rev/a563e8e7cd63
branches:  trunk
changeset: 510064:a563e8e7cd63
user:      drochner <drochner%NetBSD.org@localhost>
date:      Fri May 18 11:49:21 2001 +0000

description:
do this console device lookup thing the right way this time
(This "dev" argument to the console functions is nonsense - nothing
should depend on it.)

diffstat:

 sys/dev/wscons/wsdisplay.c |  15 +++++++--------
 1 files changed, 7 insertions(+), 8 deletions(-)

diffs (43 lines):

diff -r af1936369ef8 -r a563e8e7cd63 sys/dev/wscons/wsdisplay.c
--- a/sys/dev/wscons/wsdisplay.c        Fri May 18 08:56:27 2001 +0000
+++ b/sys/dev/wscons/wsdisplay.c        Fri May 18 11:49:21 2001 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: wsdisplay.c,v 1.50 2001/05/02 10:32:11 scw Exp $ */
+/* $NetBSD: wsdisplay.c,v 1.51 2001/05/18 11:49:21 drochner Exp $ */
 
 /*
  * Copyright (c) 1996, 1997 Christopher G. Demetriou.  All rights reserved.
@@ -31,7 +31,7 @@
  */
 
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: wsdisplay.c,v 1.50 2001/05/02 10:32:11 scw Exp $");
+__KERNEL_RCSID(0, "$NetBSD: wsdisplay.c,v 1.51 2001/05/18 11:49:21 drochner Exp $");
 
 #include <sys/param.h>
 #include <sys/conf.h>
@@ -1782,19 +1782,18 @@
        dev_t dev;
        int on;
 {
-       struct wsdisplay_softc *sc;
-
-       sc = device_lookup(&wsdisplay_cd, WSDISPLAYUNIT(dev));
 
        wsdisplay_cons_pollmode = on;
 
        /* notify to fb drivers */
-       if (sc != NULL && sc->sc_accessops->pollc != NULL)
-               (*sc->sc_accessops->pollc)(sc->sc_accesscookie, on);
+       if (wsdisplay_console_device != NULL &&
+           wsdisplay_console_device->sc_accessops->pollc != NULL)
+               (*wsdisplay_console_device->sc_accessops->pollc)
+                       (wsdisplay_console_device->sc_accesscookie, on);
 
        /* notify to kbd drivers */
        if (wsdisplay_cons_kbd_pollc)
-               (*wsdisplay_cons_kbd_pollc)(dev, on);
+               (*wsdisplay_cons_kbd_pollc)(NODEV, on);
 }
 
 void



Home | Main Index | Thread Index | Old Index