Source-Changes-HG archive

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

[src/trunk]: src Add wscons devices.



details:   https://anonhg.NetBSD.org/src/rev/98e07dedd6e8
branches:  trunk
changeset: 517976:98e07dedd6e8
user:      soren <soren%NetBSD.org@localhost>
date:      Thu Nov 22 04:50:04 2001 +0000

description:
Add wscons devices.

diffstat:

 etc/etc.sgimips/MAKEDEV         |  94 ++++++++++++++++++++++++++++++++++++++++-
 sys/arch/sgimips/sgimips/conf.c |  45 +++++++++++++++++++-
 2 files changed, 137 insertions(+), 2 deletions(-)

diffs (203 lines):

diff -r 815209cfbaf2 -r 98e07dedd6e8 etc/etc.sgimips/MAKEDEV
--- a/etc/etc.sgimips/MAKEDEV   Thu Nov 22 04:31:01 2001 +0000
+++ b/etc/etc.sgimips/MAKEDEV   Thu Nov 22 04:50:04 2001 +0000
@@ -1,5 +1,5 @@
 #!/bin/sh -
-#      $NetBSD: MAKEDEV,v 1.8 2001/11/11 00:39:33 soren Exp $
+#      $NetBSD: MAKEDEV,v 1.9 2001/11/22 04:50:18 soren Exp $
 #
 # Copyright (c) 1990 The Regents of the University of California.
 # All rights reserved.
@@ -62,6 +62,15 @@
 #      vnd*    file pseudo-disks
 #      wd*     IDE disks
 #
+# Console ports:
+#      ttyE*   wscons
+#
+# Pointing devices:
+#      wsmouse* wscons mouse events
+#
+# Keyboard devices:
+#      wskbd*  wscons keyboard events
+#
 # Terminals:
 #      ttyC*   NS16550 ("com") serial ports
 #      ttyZ*   Zilog 8530 ("zstty") serial ports
@@ -86,6 +95,8 @@
 #      ss*     SCSI scanner
 #      tun*    network tunnel driver
 #      uk*     SCSI unknown
+#      wsfont* console font control
+#      wsmux*  wscons event multiplexor
 
 dialin=0
 dialout=524288
@@ -137,6 +148,80 @@
        mknod stderr            c 26 2  ; chmod 666 stderr
        ;;
 
+wscons)
+       sh $0 ttyE0 ttyE1 ttyE2 ttyE3 ttyE4 ttyE5 ttyE6 ttyE7
+       sh $0 wsmouse0 wsmouse1 wsmouse2 wsmouse3
+       sh $0 wskbd0 wskbd1 wskbd2 wskbd3
+       sh $0 wsmux0 wsmux1 wsmux2 wsmux3
+       sh $0 wsmouse wskbd
+       sh $0 ttyEcfg
+       sh $0 wsfont
+       ;;
+
+wsmouse)
+       rm -f wsmouse
+       mknod wsmouse c 53 0
+       chown root.wheel wsmouse
+       chmod 600 wsmouse
+       ;;
+
+wskbd)
+       rm -f wskbd
+       mknod wskbd c 53 1
+       chown root.wheel wskbd
+       chmod 600 wskbd
+       ;;
+
+wsmux*)
+       unit=${i#wsmux}
+       unitctl=$(($unit + 128))
+       wsmux=wsmux$unit
+       wsmuxctl=wsmuxctl$unit
+       major=53
+       rm -f $wsmux $wsmuxctl
+       mknod $wsmux c $major $unit
+       chown root.wheel $wsmux
+       chmod 600 $wsmux
+       mknod $wsmuxctl c $major $unitctl
+       chown root.wheel $wsmuxctl
+       chmod 200 $wsmuxctl
+       ;;
+
+ttyEcfg)
+       chr=50
+       rm -f ttyEcfg
+       mknod ttyEcfg c $chr 255
+       chown root.wheel ttyEcfg
+       chmod 600 ttyEcfg
+       ;;
+
+ttyE*)
+       chr=50; unit=${i#ttyE}
+       rm -f ttyE$unit
+       mknod ttyE$unit c $chr $unit
+       chown root.wheel ttyE$unit
+       ;;
+
+wsmouse*)
+       unit=${i#wsmouse}
+       wsmouse=wsmouse$unit
+       major=52
+       rm -f $wsmouse
+       mknod $wsmouse c $major $unit
+       chown root.wheel $wsmouse
+       chmod 600 $wsmouse
+       ;;
+
+wskbd*)
+       unit=${i#wskbd}
+       wskbd=wskbd$unit
+       major=51
+       rm -f $wskbd
+       mknod $wskbd c $major $unit
+       chown root.wheel $wskbd
+       chmod 600 $wskbd
+       ;;
+
 fd)
        rm -f fd/*
        mkdir fd > /dev/null 2>&1
@@ -377,6 +462,13 @@
        chmod 600 i4btrc$unit
        ;;
 
+wsfont) 
+       rm -f wsfont
+       mknod wsfont c 54 0
+       chown root:wheel wsfont
+       chmod 600 wsfont 
+       ;;
+
 local)
        umask 0
        sh $0.local all
diff -r 815209cfbaf2 -r 98e07dedd6e8 sys/arch/sgimips/sgimips/conf.c
--- a/sys/arch/sgimips/sgimips/conf.c   Thu Nov 22 04:31:01 2001 +0000
+++ b/sys/arch/sgimips/sgimips/conf.c   Thu Nov 22 04:50:04 2001 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: conf.c,v 1.10 2001/11/11 00:38:30 soren Exp $  */
+/*     $NetBSD: conf.c,v 1.11 2001/11/22 04:50:04 soren Exp $  */
 
 /*
  * Copyright (c) 1992, 1993
@@ -72,6 +72,17 @@
 #include "com.h"
 cdev_decl(com);
 
+#include "wsdisplay.h"
+cdev_decl(wsdisplay); 
+#include "wskbd.h" 
+cdev_decl(wskbd);
+#include "wsmouse.h"
+cdev_decl(wsmouse);
+#include "wsmux.h"
+cdev_decl(wsmux);
+#include "wsfont.h"
+cdev_decl(wsfont);
+
 #include "i4b.h"
 #include "i4bctl.h"
 #include "i4btrc.h"
@@ -167,6 +178,23 @@
        cdev_i4btel_init(NI4BTEL, i4btel),      /* 42: i4b phone device */
        cdev_notdef(),                  /* 43: */
        cdev_notdef(),                  /* 44: */
+       cdev_notdef(),                  /* 45: */
+       cdev_notdef(),                  /* 46: */
+       cdev_notdef(),                  /* 47: */
+       cdev_notdef(),                  /* 48: */
+       cdev_notdef(),                  /* 49: */
+       cdev_wsdisplay_init(NWSDISPLAY,
+                       wsdisplay),     /* 50: frame buffers, etc. */
+       cdev_mouse_init(NWSKBD,wskbd),  /* 51: keyboards */
+       cdev_mouse_init(NWSMOUSE,
+                       wsmouse),       /* 52: mice */
+       cdev_mouse_init(NWSMUX, wsmux), /* 53: ws multiplexor */
+       cdev__oci_init(NWSFONT,wsfont), /* 54: wsfont pseudo-device */
+       cdev_notdef(),                  /* 55: */
+       cdev_notdef(),                  /* 56: */
+       cdev_notdef(),                  /* 57: */
+       cdev_notdef(),                  /* 58: */
+       cdev_notdef(),                  /* 59: */
 };
 int    nchrdev = sizeof(cdevsw) / sizeof(cdevsw[0]);
 
@@ -233,6 +261,21 @@
        /* 42 */        NODEV,
        /* 43 */        NODEV,
        /* 44 */        NODEV,
+       /* 45 */        NODEV,
+       /* 46 */        NODEV,
+       /* 47 */        NODEV,
+       /* 48 */        NODEV,
+       /* 49 */        NODEV,
+       /* 50 */        NODEV,
+       /* 51 */        NODEV,
+       /* 52 */        NODEV,
+       /* 53 */        NODEV,
+       /* 54 */        NODEV,
+       /* 55 */        NODEV,
+       /* 56 */        NODEV,
+       /* 57 */        NODEV,
+       /* 58 */        NODEV,
+       /* 59 */        NODEV,
 };
 
 dev_t



Home | Main Index | Thread Index | Old Index