Source-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[src/trunk]: src Add the wsmux pseudo device.
details: https://anonhg.NetBSD.org/src/rev/981fa7279568
branches: trunk
changeset: 475018:981fa7279568
user: augustss <augustss%NetBSD.org@localhost>
date: Thu Jul 29 18:20:02 1999 +0000
description:
Add the wsmux pseudo device.
diffstat:
share/man/man4/Makefile | 6 +-
share/man/man4/wscons.4 | 18 +-
share/man/man4/wskbd.4 | 22 +-
share/man/man4/wsmouse.4 | 15 +-
share/man/man4/wsmux.4 | 95 +++++
sys/dev/wscons/files.wscons | 5 +-
sys/dev/wscons/wscons_callbacks.h | 13 +-
sys/dev/wscons/wsconsio.h | 29 +-
sys/dev/wscons/wsdisplay.c | 117 +++--
sys/dev/wscons/wskbd.c | 222 +++++++++--
sys/dev/wscons/wskbdvar.h | 4 +-
sys/dev/wscons/wsmouse.c | 132 ++++++-
sys/dev/wscons/wsmousevar.h | 8 +-
sys/dev/wscons/wsmux.c | 716 ++++++++++++++++++++++++++++++++++++++
sys/dev/wscons/wsmuxvar.h | 88 ++++
15 files changed, 1337 insertions(+), 153 deletions(-)
diffs (truncated from 2055 to 300 lines):
diff -r e681cf868a97 -r 981fa7279568 share/man/man4/Makefile
--- a/share/man/man4/Makefile Thu Jul 29 17:01:21 1999 +0000
+++ b/share/man/man4/Makefile Thu Jul 29 18:20:02 1999 +0000
@@ -1,4 +1,4 @@
-# $NetBSD: Makefile,v 1.94 1999/07/17 07:09:40 itojun Exp $
+# $NetBSD: Makefile,v 1.95 1999/07/29 18:22:03 augustss Exp $
# @(#)Makefile 8.1 (Berkeley) 6/18/93
MAN= ahb.4 ahc.4 aria.4 atalk.4 audio.4 bha.4 bpf.4 ccd.4 cd.4 ch.4 \
@@ -10,8 +10,8 @@
pcscp.4 pms.4 ppp.4 pty.4 puc.4 qsphy.4 raid.4 rnd.4 route.4 rtpphy.4 \
scsi.4 sd.4 sl.4 sm.4 spp.4 sqphy.4 ss.4 st.4 sv.4 strip.4 tb.4 tcp.4 \
termios.4 tl.4 tlphy.4 tp.4 tr.4 tty.4 tun.4 udp.4 uha.4 uk.4 unix.4 \
- vga.4 vnd.4 wd.4 wdc.4 wscons.4 wsdisplay.4 wskbd.4 wsmouse.4 ym.4 \
- zstty.4
+ vga.4 vnd.4 wd.4 wdc.4 wscons.4 wsdisplay.4 wskbd.4 wsmouse.4 wsmux.4 \
+ ym.4 zstty.4
# USB devices
MAN+= uaudio.4 ugen.4 uhid.4 ukbd.4 ulpt.4 ums.4 usb.4
diff -r e681cf868a97 -r 981fa7279568 share/man/man4/wscons.4
--- a/share/man/man4/wscons.4 Thu Jul 29 17:01:21 1999 +0000
+++ b/share/man/man4/wscons.4 Thu Jul 29 18:20:02 1999 +0000
@@ -1,4 +1,4 @@
-.\" $NetBSD: wscons.4,v 1.8 1999/04/13 20:25:29 augustss Exp $
+.\" $NetBSD: wscons.4,v 1.9 1999/07/29 18:22:04 augustss Exp $
.\"
.\" Copyright (c) 1999 The NetBSD Foundation, Inc.
.\" All rights reserved.
@@ -49,9 +49,11 @@
.Cd options WSDISPLAY_COMPAT_USL
.Cd options WSDISPLAY_COMPAT_RAWKBD
-.Cd wsdisplay* at ...
-.Cd wskbd* at ...
-.Cd wsmouse* at ...
+.Cd "wsdisplay* at ..."
+.Cd "wskbd* at ... mux N"
+.Cd "wsmouse* at ... mux N"
+
+.Cd pseudo-device wsmux N
.Pp
.Sh DESCRIPTION
The
@@ -67,6 +69,9 @@
.Xr wskbd 4 , and
.Xr wsmouse 4
.It
+input event multiplexor, see
+.Xr wsmux 4
+.It
terminal emulation modules (see below), and
.It
compatibility options to support control operations and other low-level
@@ -161,12 +166,12 @@
.El
.Pp
The
-.Cd WSEMUL_DEFAULT
+.Va WSEMUL_DEFAULT
kernel option allows to select one of the described terminal options
as default choice. The default gets into effect in kernel startup, i.e.
for the operating system console or additional screens allocated
through the
-.Cd WSDISPLAY_DEFAULTSCREENS
+.Va WSDISPLAY_DEFAULTSCREENS
option (see
.Xr wsdisplay 4
), or if no emulation type was passed to the
@@ -254,6 +259,7 @@
.Xr wsdisplay 4 ,
.Xr wskbd 4 ,
.Xr wsmouse 4 ,
+.Xr wsmux 4 ,
.Xr wsconscfg 8 ,
.Xr wsconsctl 8 ,
.Xr wsfontload 8
diff -r e681cf868a97 -r 981fa7279568 share/man/man4/wskbd.4
--- a/share/man/man4/wskbd.4 Thu Jul 29 17:01:21 1999 +0000
+++ b/share/man/man4/wskbd.4 Thu Jul 29 18:20:02 1999 +0000
@@ -1,4 +1,4 @@
-.\" $NetBSD: wskbd.4,v 1.2 1999/04/08 16:29:56 drochner Exp $
+.\" $NetBSD: wskbd.4,v 1.3 1999/07/29 18:22:04 augustss Exp $
.Dd March 20, 1999
.Os
@@ -8,13 +8,13 @@
.Nd generic keyboard support in wscons
.Sh SYNOPSIS
-.Cd "wskbd* at pckbd? console ?"
+.Cd "wskbd* at pckbd? console ? mux 1"
(standard PC keyboard)
-.Cd "wskbd* at ukbd? console ?"
+.Cd "wskbd* at ukbd? console ? mux 1"
(USB keyboard)
-.Cd "wskbd0 at akbd? console ?"
+.Cd "wskbd0 at akbd? console ? mux 1"
(Apple ADB keyboard)
-.Cd "wskbd0 at nextkbd? console ?"
+.Cd "wskbd0 at nextkbd? console ? mux 1"
(NeXT keyboard)
.Sh DESCRIPTION
@@ -85,19 +85,9 @@
.Pa /usr/include/dev/wscons/wsconsio.h .
.El
-.Sh BUGS
-.Dq wskbd
-devices are connected logically to
-.Dq wsdisplay
-devices at boot time. There is little support for hot insertion and
-removal. It is not possible to feed a
-.Dq wsdisplay
-from multiple
-.Dq wskbd
-devices.
-
.Sh SEE ALSO
.Xr wscons 4 ,
.Xr wsconsctl 8 ,
+.Xr wsmux 4 ,
.Xr pckbd 4 ,
.Xr ukbd 4
diff -r e681cf868a97 -r 981fa7279568 share/man/man4/wsmouse.4
--- a/share/man/man4/wsmouse.4 Thu Jul 29 17:01:21 1999 +0000
+++ b/share/man/man4/wsmouse.4 Thu Jul 29 18:20:02 1999 +0000
@@ -1,4 +1,4 @@
-.\" $NetBSD: wsmouse.4,v 1.1 1999/03/22 19:15:03 drochner Exp $
+.\" $NetBSD: wsmouse.4,v 1.2 1999/07/29 18:22:04 augustss Exp $
.Dd March 20, 1999
.Os
@@ -8,19 +8,19 @@
.Nd generic mouse support in wscons
.Sh SYNOPSIS
-.Cd "wsmouse* at pms?"
+.Cd "wsmouse* at pms? mux 0"
(PS/2 mouse)
-.Cd "wsmouse* at pmsi?"
+.Cd "wsmouse* at pmsi? mux 0"
(
.Dq Intellimouse
-compatible wheel mouse with PS/2 interface)
-.Cd "wsmouse* at ums?"
+.Cd "wsmouse* at ums? mux 0"
(USB mouse)
-.Cd "wsmouse* at lms?"
+.Cd "wsmouse* at lms? mux 0"
(Logitech bus mouse, i386 only)
-.Cd "wsmouse* at mms?"
+.Cd "wsmouse* at mms? mux 0"
(Microsoft InPort mouse, i386 only)
-.Cd "wsmouse0 at ams?"
+.Cd "wsmouse0 at ams? mux 0"
(Apple ADB mouse)
.Sh DESCRIPTION
@@ -57,6 +57,7 @@
.Sh SEE ALSO
.Xr wscons 4 ,
.Xr wsconsctl 8 ,
+.Xr wsmux 4 ,
.Xr pms 4 ,
.Xr lms 4 ,
.Xr mms 4 ,
diff -r e681cf868a97 -r 981fa7279568 share/man/man4/wsmux.4
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/share/man/man4/wsmux.4 Thu Jul 29 18:20:02 1999 +0000
@@ -0,0 +1,95 @@
+.\" $NetBSD: wsmux.4,v 1.1 1999/07/29 18:22:04 augustss Exp $
+.\"
+.\" Copyright (c) 1999 The NetBSD Foundation, Inc.
+.\" All rights reserved.
+.\"
+.\" Redistribution and use in source and binary forms, with or without
+.\" modification, are permitted provided that the following conditions
+.\" are met:
+.\" 1. Redistributions of source code must retain the above copyright
+.\" notice, this list of conditions and the following disclaimer.
+.\" 2. Redistributions in binary form must reproduce the above copyright
+.\" notice, this list of conditions and the following disclaimer in the
+.\" documentation and/or other materials provided with the distribution.
+.\" 3. All advertising materials mentioning features or use of this software
+.\" must display the following acknowledgement:
+.\" This product includes software developed by the NetBSD
+.\" Foundation, Inc. and its contributors.
+.\" 4. Neither the name of The NetBSD Foundation nor the names of its
+.\" contributors may be used to endorse or promote products derived
+.\" from this software without specific prior written permission.
+.\"
+.\" THIS SOFTWARE IS PROVIDED BY THE NETBSD FOUNDATION, INC. AND CONTRIBUTORS
+.\" ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED
+.\" TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
+.\" PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE FOUNDATION OR CONTRIBUTORS
+.\" BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
+.\" CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
+.\" SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
+.\" INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
+.\" CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
+.\" ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
+.\" POSSIBILITY OF SUCH DAMAGE.
+.\"
+.Dd July 26, 1999
+.Dt WSMUX 4
+.Os
+.Sh NAME
+.Nm wsmux
+.Nd console keyboard/mouse multiplexor
+.Sh SYNOPSIS
+.Cd "wskbd* at ... mux N"
+.Cd "wsmouse* at ... mux N"
+
+.Cd pseudo-device wsmux N
+.Pp
+.Sh DESCRIPTION
+The
+.Nm
+is a pseudo-device driver that allows several
+.Xr wscons 4
+input devices to have their events multiplexed into one stream.
+.Pp
+The typical usage for this device is to have two multiplexors, one
+for mouse events and one for keyboard events. All
+.Xr wsmouse 4
+devices should direct their events to the mouse mux (normally 0)
+and all keyboard devices, except the console, should direct their
+events to the keyboard mux (normally 1). A device will
+send its events to the mux indicated my the
+.Va mux
+locator. If none is given the device will not use a multiplexor.
+The keyboard multiplexor should be connected to the display, using
+the
+.Xr wsconscfg 8
+command. It will then recieve all keystrokes from all keyboards
+and, furthermore, keyboards can be dynamically attached and detached without
+further user interaction.
+In a similar way, the window system will open the mouse multiplexor
+and recieve all mouse events; mice can also be dynamically attached
+and detached.
+.Pp
+It is also possible to inject events into a multiplexor from a
+user program. This is used by the
+.Xr moused 8
+deamon to take data from a mouse connected to a serial port and
+make it appear on the standard mouse mux.
+.Pp
+.Sh FILES
+.Bl -item
+.It
+.Pa /dev/wsmouse
+.It
+.Pa /dev/wskbd
+.It
+.Pa /usr/include/dev/wscons/wsconsio.h .
+.El
+.Sh SEE ALSO
+.Xr moused 8 ,
+.Xr wscons 4 ,
+.Xr wsdisplay 4 ,
+.Xr wskbd 4 ,
+.Xr wsmouse 4 ,
+.Xr wsconscfg 8 ,
+.Xr wsconsctl 8 ,
+.Xr wsfontload 8
diff -r e681cf868a97 -r 981fa7279568 sys/dev/wscons/files.wscons
--- a/sys/dev/wscons/files.wscons Thu Jul 29 17:01:21 1999 +0000
+++ b/sys/dev/wscons/files.wscons Thu Jul 29 18:20:02 1999 +0000
@@ -1,4 +1,4 @@
-# $NetBSD: files.wscons,v 1.15 1999/05/15 14:22:46 drochner Exp $
+# $NetBSD: files.wscons,v 1.16 1999/07/29 18:20:02 augustss Exp $
#
# "Workstation Console" glue; attaches frame buffer to emulator & keyboard,
@@ -52,3 +52,6 @@
file dev/rcons/raster_text.c wsrasteremulops
file dev/wscons/wscons_rinit.c wsrasteremulops
file dev/wscons/wscons_rops.c wsrasteremulops
+
+defpseudo wsmux
+file dev/wscons/wsmux.c wsmux | wsdisplay needs-count
diff -r e681cf868a97 -r 981fa7279568 sys/dev/wscons/wscons_callbacks.h
--- a/sys/dev/wscons/wscons_callbacks.h Thu Jul 29 17:01:21 1999 +0000
+++ b/sys/dev/wscons/wscons_callbacks.h Thu Jul 29 18:20:02 1999 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: wscons_callbacks.h,v 1.9 1999/05/15 14:22:46 drochner Exp $ */
+/* $NetBSD: wscons_callbacks.h,v 1.10 1999/07/29 18:20:02 augustss Exp $ */
/*
* Copyright (c) 1996, 1997 Christopher G. Demetriou. All rights reserved.
@@ -53,12 +53,7 @@
/*
* Calls to the keyboard interface from the glue code.
*/
-int wskbd_set_display __P((int, struct device *, struct device **));
-struct device *wskbd_set_console_display __P((struct device *));
+struct wsmux_softc;
+struct device *wskbd_set_console_display
Home |
Main Index |
Thread Index |
Old Index