summaryrefslogtreecommitdiff
path: root/share/man/man4
diff options
context:
space:
mode:
authorKenji Aoyama <aoyama@cvs.openbsd.org>2014-04-16 12:01:34 +0000
committerKenji Aoyama <aoyama@cvs.openbsd.org>2014-04-16 12:01:34 +0000
commit4996567438ccba9f4d7be798894b816ce339ed1b (patch)
tree7b3794819e44d77bd26824bb1284e5d6ea6444d3 /share/man/man4
parentf835eee727683f1f21e319510529b3bf48777c3f (diff)
Add generic driver for "NEC PC-9801(*) extension board slot" on
LUNA-88K. LUNA-88K{,2} has one or two slot(s) that can attach the extension board designed for PC-9801. This driver provides dedicated mmap(2) and capability for waiting specified interrupt on that slot so that we can use the extension board from userland program. (*)PC-9801 is a Japanese popular personal computer, mainly used in 1980-90's. (see http://en.wikipedia.org/wiki/NEC_PC-9801) ok miod@, and man pages jmc@
Diffstat (limited to 'share/man/man4')
-rw-r--r--share/man/man4/man4.luna88k/Makefile4
-rw-r--r--share/man/man4/man4.luna88k/pcexmem.476
2 files changed, 78 insertions, 2 deletions
diff --git a/share/man/man4/man4.luna88k/Makefile b/share/man/man4/man4.luna88k/Makefile
index aa57c7c6884..6dea1ffcb67 100644
--- a/share/man/man4/man4.luna88k/Makefile
+++ b/share/man/man4/man4.luna88k/Makefile
@@ -1,7 +1,7 @@
-# $OpenBSD: Makefile,v 1.2 2007/02/15 14:19:59 aoyama Exp $
+# $OpenBSD: Makefile,v 1.3 2014/04/16 12:01:33 aoyama Exp $
# TODO: clock fb sio/siotty ws
-MAN= autoconf.4 intro.4 lcd.4 le.4 mem.4 spc.4
+MAN= autoconf.4 intro.4 lcd.4 le.4 mem.4 pcexmem.4 spc.4
MANSUBDIR=luna88k
MLINKS+= mem.4 kmem.4
diff --git a/share/man/man4/man4.luna88k/pcexmem.4 b/share/man/man4/man4.luna88k/pcexmem.4
new file mode 100644
index 00000000000..d00b90f1642
--- /dev/null
+++ b/share/man/man4/man4.luna88k/pcexmem.4
@@ -0,0 +1,76 @@
+.\" $OpenBSD: pcexmem.4,v 1.1 2014/04/16 12:01:33 aoyama Exp $
+.\"
+.\" Copyright (c) 2014 Kenji Aoyama.
+.\"
+.\" Permission to use, copy, modify, and distribute this software for any
+.\" purpose with or without fee is hereby granted, provided that the above
+.\" copyright notice and this permission notice appear in all copies.
+.\"
+.\" THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
+.\" WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
+.\" MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
+.\" ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
+.\" WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
+.\" ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
+.\" OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
+.Dd $Mdocdate: April 16 2014 $
+.Dt PCEXMEM 4 luna88k
+.Os
+.Sh NAME
+.Nm pcexmem ,
+.Nm pcexio
+.Nd NEC PC-9801 extension board slot
+.Sh SYNOPSIS
+.Cd "pcex0 at mainbus0"
+.Sh DESCRIPTION
+The file
+.Pa /dev/pcexmem
+is an
+.Xr mmap 2
+capable interface to the memory area of the installed board at "NEC PC-9801
+extension board slot" on LUNA88K.
+Byte offsets in this file are interpreted as relative memory addresses
+of the installed board.
+The range should be between 0x0 and 0xffffff.
+.Pp
+The I/O port area of the installed board is accessed via the file
+.Pa /dev/pcexio
+in the same manner as
+.Pa /dev/pcexmem .
+The range should be between 0x0 and 0xffff.
+.Pp
+The following
+.Xr ioctl 2
+calls apply to
+.Pa /dev/pcexmem
+and
+.Pa /dev/pcexio
+in order to handle interrupts of this extension slot.
+Currently 7 levels of interrupt (0 to 6) are supported.
+.Bl -tag -width PCEX
+.It Dv PCEXSETLEVEL Fa "u_int *"
+Register the specified interrupt level with this driver to handle.
+.It Dv PCEXRESETLEVEL Fa "u_int *"
+Unregister the specified interrupt level with this driver.
+.It Dv PCEXWAITINT Fa "u_int *"
+Wait for the interrupt with the specified level.
+.El
+.Sh FILES
+.Bl -tag -width /dev/pcexmem -compact
+.It Pa /dev/pcexmem
+.It Pa /dev/pcexio
+.El
+.Sh ERRORS
+.Bl -tag -width Er
+.It Bq Er EWOULDBLOCK
+PCEXWAITINT timeouts (currently 1 second).
+.El
+.Sh SEE ALSO
+.Xr ioctl 2
+.Sh HISTORY
+The
+.Pa /dev/pcexmem
+and
+.Pa /dev/pcexio
+files first appeared in
+.Ox 5.6 .