Commit Graph

60 Commits

Author SHA1 Message Date
agc aad01611e7 Move UCB-licensed code from 4-clause to 3-clause licence.
Patches provided by Joel Baker in PR 22364, verified by myself.
2003-08-07 16:26:28 +00:00
lukem ed51729135 __KERNEL_RCSID() 2003-07-15 02:54:31 +00:00
fvdl d5aece61d6 Back out the lwp/ktrace changes. They contained a lot of colateral damage,
and need to be examined and discussed more.
2003-06-29 22:28:00 +00:00
simonb 964da8bfb6 Fix 'struct lwp *' lossage. 2003-06-29 09:56:28 +00:00
thorpej 71b2230367 Merge the nathanw_sa branch. 2003-01-18 06:05:42 +00:00
jdolecek e0cc03a09b merge kqueue branch into -current
kqueue provides a stateful and efficient event notification framework
currently supported events include socket, file, directory, fifo,
pipe, tty and device changes, and monitoring of processes and signals

kqueue is supported by all writable filesystems in NetBSD tree
(with exception of Coda) and all device drivers supporting poll(2)

based on work done by Jonathan Lemon for FreeBSD
initial NetBSD port done by Luke Mewburn and Jason Thorpe
2002-10-23 09:10:23 +00:00
gehenna 77a6b82b27 Merge the gehenna-devsw branch into the trunk.
This merge changes the device switch tables from static array to
dynamically generated by config(8).

- All device switches is defined as a constant structure in device drivers.

- The new grammer ``device-major'' is introduced to ``files''.

	device-major <prefix> char <num> [block <num>] [<rules>]

- All device major numbers must be listed up in port dependent majors.<arch>
  by using this grammer.

- Added the new naming convention.
  The name of the device switch must be <prefix>_[bc]devsw for auto-generation
  of device switch tables.

- The backward compatibility of loading block/character device
  switch by LKM framework is broken. This is necessary to convert
  from block/character device major to device name in runtime and vice versa.

- The restriction to assign device major by LKM is completely removed.
  We don't need to reserve LKM entries for dynamic loading of device switch.

- In compile time, device major numbers list is packed into the kernel and
  the LKM framework will refer it to assign device major number dynamically.
2002-09-06 13:18:43 +00:00
atatat 31144d9976 Convert ioctl code to use EPASSTHROUGH instead of -1 or ENOTTY for
indicating an unhandled "command".  ERESTART is -1, which can lead to
confusion.  ERESTART has been moved to -3 and EPASSTHROUGH has been
placed at -4.  No ioctl code should now return -1 anywhere.  The
ioctl() system call is now properly restartable.
2002-03-17 19:40:26 +00:00
ad b89e39b91a Reorganise the wsfont stuff slightly so that multiple display adapters
with different bit/byte order requirements can co-exist happily.
2002-03-13 15:05:13 +00:00
thorpej cc0751f230 Adjust to use <dev/sun/fbio.h> 2001-09-19 19:04:16 +00:00
simonb c23e6dcb90 b{cmp,copy,zero} -> mem{cmp,cpy,set}
Also remove some unnecessary argument casts.
2001-07-07 14:20:59 +00:00
scw 2963ff5c58 Add `l_poll' to `struct linesw' and provide an xxxpoll() entry point
in each tty driver to indirect through it.

This allows tty line-disciplines to handle poll(2) system calls.
2001-05-02 10:32:08 +00:00
ad 4a19c21be3 In rcons_connect(): PMAX_FBTYPE_PM_COLOR should use the defaults. 2001-01-22 17:18:32 +00:00
eeh c98778939f Fix tty initialization. From Arne H Juul <arnej@fast.no>. 2000-11-08 23:21:38 +00:00
mhitch b38f4a0528 From Andrew Doran:
Fix 2100/3100 monochrome font display problem.  Characters were being
rendered as a mirror-image, which was a bit hard to read.
2000-11-05 02:53:20 +00:00
simonb dde480911e Fix up line discipline change fallout. 2000-11-03 15:01:10 +00:00
eeh 8c3f6a0d10 Adapt to new line discipline scheme. 2000-11-02 00:37:56 +00:00
ad c3459ba769 Apply patch supplied by Konrad Schroder in PR 10452: fixes console output
on PMAG-D.
2000-06-28 11:03:25 +00:00
simonb 889c658b5b Change the kernel mmap interface so that the offset to map is an
"off_t" and the return value is a "paddr_t" to allow mappings
at offsets past 2^31 bytes.  Somewhat inspired by FreeBSD, which
only changed the offset to a "vm_offset_t".

Includes updates for the i386, pc532 and sh3 mmmmap from Jason Thorpe.
2000-06-26 04:55:19 +00:00
mhitch ac3bfd5e7f When the tty intialization was split out of rcons_init(), the call to
rcons_ttyinit() was never added to the pmax rasterconsole stuff.  Output
to the display using /dev/console has not been working since then.  Adding
the call to rcons_ttyinit() makes this work again.
2000-04-20 20:02:34 +00:00
simonb bf851ea6cb Nuke register. 2000-03-30 14:45:04 +00:00
thorpej 7b918b4088 New callout mechanism with two major improvements over the old
timeout()/untimeout() API:
- Clients supply callout handle storage, thus eliminating problems of
  resource allocation.
- Insertion and removal of callouts is constant time, important as
  this facility is used quite a lot in the kernel.

The old timeout()/untimeout() API has been removed from the kernel.
2000-03-23 06:40:33 +00:00
simonb ede7778a1c Remove unneeded include files (up to 16 in two files!). 2000-01-10 03:24:31 +00:00
simonb 636b65bec8 The clean-up continues:
- Make local-only function and variables static.
 - Move function prototypes and extern variable declarations to
   header files.
 - Delete unused variables.
There's still a handful of extern declaraions that should be fixed up.
2000-01-09 03:55:28 +00:00
simonb ee075b7de7 Function prototype cleanup. 2000-01-08 01:02:35 +00:00
simonb 5f95b56bc8 Need to include <dev/wscons/wsconsio.h> for WSDISPLAY_FONTORDER_L2R. 2000-01-07 13:43:02 +00:00
ad 59a1ab9791 Add two new members to 'struct wsdisplay_font': 'bitorder' and 'byteorder'. 2000-01-05 18:44:21 +00:00
simonb 644ff8f7ed Include <pmax/pmax/cons.h> instead of <dev/cons.h> to get RCONSDEV.
That file includes <dev/cons.h>.
1999-12-30 00:31:02 +00:00
thorpej 8c92a5344c PMAX uses white-on-black for the default rcons colors. 1999-08-26 20:49:40 +00:00
ad c9adbf13c2 Update to match new rasops_init semantics. 1999-08-24 11:16:03 +00:00
thorpej eb20bbc780 Change the semantics of splsoftclock() to be like other spl*() functions,
that is priority is rasied.  Add a new spllowersoftclock() to provide the
atomic drop-to-softclock semantics that the old splsoftclock() provided,
and update calls accordingly.

This fixes a problem with using the "rnd" pseudo-device from within
interrupt context to extract random data (e.g. from within the softnet
interrupt) where doing so would incorrectly unblock interrupts (causing
all sorts of lossage).

XXX 4 platforms do not have priority-raising capability: newsmips, sparc,
XXX sparc64, and VAX.  This platforms still have this bug until their
XXX spl*() functions are fixed.
1999-08-05 18:08:08 +00:00
ad 080560c8c6 - Setting initial position of cursor is up to caller.
- Set cursor position properly for SPARC. From Juergen Hannken-Illjes.
1999-05-23 17:59:39 +00:00
ad 02bc362e3e Add arg to rcons_init() that when set causes screen to be cleared. 1999-05-19 20:34:19 +00:00
ad 3b602e5afa Panic if rasops_init() fails us (should never be the case). 1999-05-15 13:04:03 +00:00
ad 6db752a5c1 "px.h" requires inclusion. 1999-04-26 04:34:00 +00:00
simonb f676307241 Include "px.h" - rcons_connect_native is only compiled in of NPX > 0.
Fixes PR port-pmax/7456 from Jason Thorpe.
1999-04-24 15:22:45 +00:00
simonb dc1d3940db Nuke register and remove trailling white space. 1999-04-24 08:01:01 +00:00
ad a895fbfd58 Define rcons_connect() only if (NFB > 0). Define rcons_connect_native() only
if (NPX > 0). Needed for fixed `rasops' config glue.
1999-04-22 00:33:30 +00:00
ad 0993fa2727 Add configuration glue needed by rasops, wsfont, rcons and the px driver. 1999-04-13 18:53:27 +00:00
jonathan 7bfe0eabb6 Use lk_bell() for audible bell. 1999-01-28 10:35:53 +00:00
simonb 384f5d9970 Remove unused pmax/stand/dec_*.h include files. 1999-01-27 03:03:51 +00:00
jonathan 89cad55ba4 Make rcons work, if configured, even when using serial console:
do rcons_connect() even if using a serial console.
  identify first attached framebuffer as being `rcons' output device.
1998-11-23 04:26:15 +00:00
mrg db3051d720 fix problems in many d_mmap routines:
- returned EOPNOTSUPP rather than -1.
	- no check for negative offset.
many of these fix potential security problems in these drivers.


XXX XXX XXX
the d_mmap cdev routine should be changed to have a prototype like:
	paddr_t (*d_mmap) __P((dev_t, off_t, int));

by someone!
1998-11-19 15:38:20 +00:00
jonathan a3a77d9561 Add skeleton code to defer rcons console output to soft-interrupt time.
ifdef'ed out for now.
1998-11-16 00:10:39 +00:00
jonathan 6a3abc10f7 Create in rconsvar.h, with exported variables and RCONSDEV. 1998-03-24 09:51:23 +00:00
jonathan 6d836436ac Commit snapshot of pmax console rework as basepoint for 1.3.2 pullup:
* Do rcons output properly, using cn_tab->cn_dev which points
   at rcons cdevsw entrypoints.

 * The pmadx console code was using keyboard (serial) device
   (major,minor) for raster consoles with special code in the keyboard
   drivers to catch output intended for consoles, pull it off the device
   queue, and print them via cnputc().
   Ifdef out  RCONS_BRAINDAMAGE.

* Other minor cleanup to pmax scc driver.
1998-03-24 00:23:55 +00:00
jonathan 23ad284399 Remove obsolete `#include <machine/MachConst.h>'.
Where CACHED_TO_HYS() is still needed for kernel-virtual-to-physical
or physical-to-uncached mapping (fb drivers), replace with
`#include <mips/cpuregs.h>'.
1996-10-13 13:13:50 +00:00
jonathan 0c048bf278 poll(2) changes for rcons, pmax framebuffer hardware-independent layer. 1996-10-13 12:47:55 +00:00
christos d286889901 backout previous kprintf change 1996-10-13 03:39:27 +00:00
christos 19d8368f2f printf -> kprintf, sprintf -> ksprintf 1996-10-11 00:44:42 +00:00