Commit Graph

473 Commits

Author SHA1 Message Date
Andrey A. Chernov
6e424f2ea5 Make Reset (ESC c) reset attributes too, not only clear screen 2000-07-21 14:26:31 +00:00
Andrey A. Chernov
91de5914ec Implement SGR 22,24,25,27 from ECMA-48 2000-07-20 18:48:03 +00:00
Andrey A. Chernov
598cad91fd Accorfing to ECMA-48 SGR 39 and 49 are just another colors and must not reset
other attrs, so reset only bold on 39
2000-07-20 13:12:58 +00:00
Mark Murray
7d4e8b5df8 Don't break the ability to debug the kernel when gathering entropy.
Pointed out by:	bde
2000-07-16 09:25:04 +00:00
Andrey A. Chernov
40b376941a Shorten 49m attr resetting expression 2000-07-15 14:13:42 +00:00
Andrey A. Chernov
7e1eea4825 Reset corresponding color attributes on 39m and 49m
Unify comments related to color
2000-07-15 13:46:57 +00:00
Mark Murray
a909184e9d Add entropy-harvesting calls.
/dev/random now has new-and-improved entropy!
2000-07-09 12:26:38 +00:00
Mark Murray
0de838f6c0 Remove old entropy-harvesting hooks; this is going to be re-engineered
later.
2000-06-25 09:55:12 +00:00
Mark Murray
7ad194ad1d Remove unneeded header. 2000-06-25 09:39:11 +00:00
Peter Wemm
18a5d2dfdf Argh. This is what I get for trying to do too many things at once.
Revert last commit. sc.h/NSC is used.
2000-06-10 10:32:43 +00:00
Peter Wemm
08e002f412 Unused include: #include "sc.h" 2000-06-10 06:42:13 +00:00
Andrey A. Chernov
4d9a01eba4 Cosmetique: fix comments - don't use 'ansi' word for non-ansi (adapter) colors 2000-06-06 00:13:40 +00:00
Andrey A. Chernov
f9641ac41e Implement ANSI E[39m and E[49m to set fg and bg to initial (not to default!)
values. E[x is bad because set them to default values and should be used only
in reset sequence.
2000-06-05 22:16:11 +00:00
Andrey A. Chernov
b2f64c0141 Fix the TAB not cause scrolling when entered at the end of the last line.
It may cause misterious chars appearse in the middle of the scrolled lines.

The bug trigger: enter
grep P_32 /usr/include/*.h
command and see misterious "db.\" filename.
2000-05-29 18:35:13 +00:00
Jake Burkholder
e39756439c Back out the previous change to the queue(3) interface.
It was not discussed and should probably not happen.

Requested by:		msmith and others
2000-05-26 02:09:24 +00:00
Jake Burkholder
740a1973a6 Change the way that the queue(3) structures are declared; don't assume that
the type argument to *_HEAD and *_ENTRY is a struct.

Suggested by:	phk
Reviewed by:	phk
Approved by:	mdodd
2000-05-23 20:41:01 +00:00
Yoshihiro Takahashi
b95b56c7a0 Added PC-98 supports.
Obtained from:	FreeBSD(98) 4.0R-Rev01
2000-05-08 14:55:21 +00:00
Peter Wemm
365c5db0a7 Add $FreeBSD$ 2000-05-01 20:32:07 +00:00
Andrey A. Chernov
89fad7112d Back out t_timeout initializing, now in ttyregister 2000-05-01 10:53:12 +00:00
Andrey A. Chernov
e52ac4f6d6 Initialize t_timeout to -1 for console to set its default value once in ttyopen 2000-05-01 09:21:08 +00:00
Poul-Henning Kamp
eb95c536ad Remove unneeded #include <sys/kernel.h> 2000-04-29 15:36:14 +00:00
Yoshihiro Takahashi
d3331668b3 Supported EGC 640x400, PEGC 640x400 and PEGC 640x480 graphics modes.
Submitted by:	Chiharu Shibata <chi@bd.mbn.or.jp> and
		Tomokazu HARADA <tkhara@osk4.3web.ne.jp>
2000-04-27 13:34:32 +00:00
Boris Popov
6e478b8154 More machdep/random.h -> sys/random.h fixes. 2000-04-25 05:06:31 +00:00
David E. O'Brien
b0e56cde37 * Use sys/sys/random.h rather than a i386 specific one.
* There was nothing that should be machine dependant about
  i386/isa/random_machdep.c, so it is now sys/kern/kern_random.c.
2000-04-24 17:30:08 +00:00
Kazutaka YOKOTA
c2c86c2b88 Unbreak LINT. 2000-04-03 09:24:16 +00:00
Kazutaka YOKOTA
091323598f - Fix SC_ALT_MOUSE_IMAGE; don't blink the mouse cursor.
- Fix non-destructive, underline text cursor.
2000-03-31 16:05:46 +00:00
Kazutaka YOKOTA
2886c99404 White-space-only change. The file originally had screwed indentation. 2000-03-20 08:18:00 +00:00
Kazutaka YOKOTA
8c219e162a - Fix bugs when painting border and the mouse cursor in the raster
text mode.
2000-03-18 15:28:48 +00:00
Kazutaka YOKOTA
40de16e3c3 - Don't reset text colors when changing the video mode.
Approved by: jkh
2000-02-11 01:20:34 +00:00
Kazutaka YOKOTA
ade2307229 - Fix text cursor logic so that multiple instances of the "normal" cursor
won't appear on the screen, and "blinking" and "destructive" cursor
  won't appear in the vty for which the text cursor is currently hidden.

Approved by: jkh
2000-02-11 01:19:44 +00:00
Peter Wemm
8f8e587948 Use config's conditional compilation rather than using #ifdefs that make
modular compilation harder.  I'm doing this because people seem to like
cut/pasting examples of bad practices in existing code.
2000-01-29 15:08:56 +00:00
Kazutaka YOKOTA
3c0931ff87 Fix a bug exposed by the previous commit. Do not use scp->font_size,
if the screen is in a graphics mode

Reported by: Maxim Sobolev <sobomax@altavista.net>
2000-01-24 13:44:39 +00:00
Kazutaka YOKOTA
e17b116645 Unconditionally define sc_paste(). 2000-01-20 13:23:03 +00:00
Kazutaka YOKOTA
acdf858c9b Fix wrong usage of FONT_NONE. It was not meant to be set in
scp->font_size in the first place.  It is redundant now and is
removed.

Found by: bde
2000-01-20 13:21:47 +00:00
Kazutaka YOKOTA
2b944ee2b9 This is the 3rd stage of syscons code reorganization.
- Split terminal emulation code from the main part of the driver so
that we can have alternative terminal emulator modules if we like in
the future.  (We are not quite there yet, though.)

- Put sysmouse related code in a separate file, thus, simplifying the
main part of the driver.

As some files are added to the source tree, you need to run config(8)
before you compile a new kernel next time.

You shouldn't see any functional change by this commit; this is only
internal code reorganization.
2000-01-15 15:25:43 +00:00
Kazutaka YOKOTA
e2f29c6e43 Make the mouse cursor char code configurable via the CONS_MOUSECTL
ioctl.

By popular demand.
2000-01-12 12:30:33 +00:00
Kazutaka YOKOTA
35e61cbd71 Add a new mechanism, cndbctl(), to tell the console driver that
ddb is entered.  Don't refer to `in_Debugger' to see if we
are in the debugger.  (The variable used to be static in Debugger()
and wasn't updated if ddb is entered via traps and panic anyway.)

- Don't refer to `in_Debugger'.
- Add `db_active' to i386/i386/db_interface.d (as in
  alpha/alpha/db_interface.c).
- Remove cnpollc() stub from ddb/db_input.c.
- Add the dbctl function to syscons, pcvt, and sio. (The function for
  pcvt and sio is noop at the moment.)

Jointly developed by: bde and me

(The final version was tweaked by me and not reviewed by bde.  Thus,
if there is any error in this commit, that is entirely of mine, not
his.)

Some changes were obtained from: NetBSD
2000-01-11 14:54:01 +00:00
Kazutaka YOKOTA
579958932a - Remember the keyboard repeat delay and rate.
- Add a new ioctl, KDGETREPEAT, to retrieve the keyboard repeat rate.
- Delete unnecessary #include.
1999-12-13 09:31:43 +00:00
Kazutaka YOKOTA
da7c907d09 Fix memory leak.
PR: kern/15363
Submitted by: Oliver Fromme
1999-12-10 09:36:05 +00:00
Kazutaka YOKOTA
b2f564ea70 Add "panic key" function to syscons. When this key is defined in a
keymap and pressed, the system panic will be forced.

This feature must be specifically enabled by a new sysctl variable:
machdep.enable_panic_key.  Its default value is 0.  The panic key
won't do anything unless this variable is set to non-zero.

To use the panic key, add a keyword 'panic' to a key in your
keymap file.  The following example assigns the panic function
to SysReq (Alt-PrintScreen) key (keycode 84).

  083   del    '.'    '.'    '.'    '.'    '.'    boot   boot    N
  084   panic  nop    nop    nop    panic  nop    nop    nop     O
  085   nop    nop    nop    nop    nop    nop    nop    nop     O

PR: kern/13721
1999-12-10 04:30:58 +00:00
Kazutaka YOKOTA
daa6e0a9a5 Fix mouse cursor logic which I broke in 1.1 ;-<
Reported by: Christian Weisgerber <naddy@unix-ag.uni-kl.de>
1999-12-06 03:22:16 +00:00
Kazutaka YOKOTA
7d09323f2d Fix cursor position calculation.
Submitted by: Cejka Rudolf <cejkar@dcse.fee.vutbr.cz>
1999-12-05 10:04:37 +00:00
Kazutaka YOKOTA
102adbe199 - Fail VT switching when the controlling program, such as the
X server, is not responding to the VT switching protocol. (This part
  of the code has been somewhat wrong in -CURRENT, but -STABLE has the
  correct code...)
1999-11-28 07:44:11 +00:00
Kazutaka YOKOTA
cc5c7f76de Correctly record the mouse position in the current VTY. 1999-11-09 12:35:36 +00:00
Kazutaka YOKOTA
51ebcb230e - Added a new kernel configuration option: SC_TWOBUTTON_MOUSE.
The new option will make the right mouse button the `paste' button.
  Useful for two button mice.

Submitted by: morganw@engr.sc.edu (Wes Morgan)
1999-11-08 10:04:29 +00:00
Kazutaka YOKOTA
73027df75c - Removed SC_VIDEO_DEBUG. It is broken and useless now. 1999-11-08 09:57:16 +00:00
Archie Cobbs
2ea6270424 Change isspace() macro name to avoid conflict. 1999-11-02 22:42:56 +00:00
Kazutaka YOKOTA
afa239de67 - Remove cdevsw_add(). 1999-10-06 13:03:09 +00:00
Nick Sayer
472a4993b0 Add the apm_saver syscons screen saver module.
apm_saver uses the apm_display() routine from the apm system to
"suspend" the "display" part of the machine.

This is beneficial for some laptops (or other machines with
non-traditional displays) that choke on the 'green' saver's
effect.

Another way of looking at this is that it's the same as a screen
saver that does an 'apm -d 0' to blank the display and an 'apm -d 1'
to bring it back. One probably ought to use these commands to make
sure the effect will be correct before using it unattended.
1999-10-02 03:56:42 +00:00
Poul-Henning Kamp
1ab305ef60 Introduce ttyread() and ttywrite() which do the canonical thing.
Use them in many tty drivers.

Reviewed by: julian, bde
1999-09-28 11:45:31 +00:00
Poul-Henning Kamp
d6a0e38a1b Remove five now unused fields from struct cdevsw. They should never
have been there in the first place.  A GENERIC kernel shrinks almost 1k.

Add a slightly different safetybelt under nostop for tty drivers.

Add some missing FreeBSD tags
1999-09-25 18:24:47 +00:00
Poul-Henning Kamp
ae8e1d08d7 This patch clears the way for removing a number of tty related
fields in struct cdevsw:

        d_stop          moved to struct tty.
        d_reset         already unused.
        d_devtotty      linkage now provided by dev_t->si_tty.

These fields will be removed from struct cdevsw together with
d_params and d_maxio Real Soon Now.

The changes in this patch consist of:

        initialize dev->si_tty in *_open()
        initialize tty->t_stop
        remove devtotty functions
        rename ttpoll to ttypoll
        a few adjustments to these changes in the generic code
        a bump of __FreeBSD_version
        add a couple of FreeBSD tags
1999-09-25 16:21:39 +00:00
Kazutaka YOKOTA
8c12242c81 - Hang the scr_stat struct from dev_t.
- Remove sc_get_scr_stat().  It's not necessary anymore.
- Call ttymalloc() to allocate the struct tty for each vty, rather than
  statically declaring an array of struct tty.  We still need a statically
  allocated struct tty for the first vty which is used for the kernel
  console I/O, though.
- Likewise, call ttymalloc() for /dev/sysmouse and /dev/consolectl.
- Delete unnecessary test on the pointer struct tty *tp in some functions.
- Delete unused code in scmouse.c.

WARNING: this change requires you to recompile screen savers!
1999-09-19 08:58:53 +00:00
Kazutaka YOKOTA
d94eccc2ad - Preserve the content of the back scroll buffer when changing the
video mode.

Requested by: a lot of people.
PR: kern/13764
1999-09-19 08:07:46 +00:00
Kazutaka YOKOTA
b86daab4e5 Enable ioctls to manipulate color palette. They have been implemented,
but disabled until now...
1999-09-02 08:09:13 +00:00
Poul-Henning Kamp
c5b72c3d85 s/si_tty_tty/si_tty/g 1999-08-30 10:35:37 +00:00
Peter Wemm
c3aac50f28 $Id$ -> $FreeBSD$ 1999-08-28 01:08:13 +00:00
Kazutaka YOKOTA
21f652c5b1 - Retain the previous vty and history buffers when setting up
the graphics mode.  This was the behavior prior to syscons.c
  rev 1.278, but broken in scvidctl.c rev 1.1.
1999-08-27 09:20:41 +00:00
Poul-Henning Kamp
9dcbe2404a Convert DEVFS hooks in (most) drivers to make_dev().
Diskslice/label code not yet handled.

Vinum, i4b, alpha, pc98 not dealt with (left to respective Maintainers)

Add the correct hook for devfs to kern_conf.c

The net result of this excercise is that a lot less files depends on DEVFS,
and devtoname() gets more sensible output in many cases.

A few drivers had minor additional cleanups performed relating to cdevsw
registration.

A few drivers don't register a cdevsw{} anymore, but only use make_dev().
1999-08-23 20:59:21 +00:00
Mike Smith
fcb893a801 Implement a new generic mechanism for attaching handler functions to
events, in order to pave the way for removing a number of the ad-hoc
implementations currently in use.

Retire the at_shutdown family of functions and replace them with
new event handler lists.

Rework kern_shutdown.c to take greater advantage of the use of event
handlers.

Reviewed by:	green
1999-08-21 06:24:40 +00:00
Julian Elischer
1744fcd082 First small steps at merging DEVFS and PHK's Dev_t stuff. 1999-08-20 20:25:00 +00:00
Bill Fumerola
aa498bf3d4 Wrap two declarations that are only used in an #ifdef in their own #ifdef.
Reviewed by:	bde
1999-08-17 22:06:17 +00:00
Dmitrij Tejblum
e9e879c34d Fix a warning on the alpha. 1999-08-13 16:17:54 +00:00
Poul-Henning Kamp
ce9edcf5b5 Merge the cons.c and cons.h to the best of my ability. alpha may or
may not compile, I can't test it.
1999-08-09 10:35:05 +00:00
Poul-Henning Kamp
57ad459b75 register tty devices so they will look right in pstat. 1999-08-08 21:35:17 +00:00
Kazutaka YOKOTA
f1235db8bd - Clear relevant variables when the keyboard is not available.
- Do not touch the `tty' struct when it's not yet available.
- Initialize correct bits in `fonts_loaded'.
1999-07-18 06:16:53 +00:00
Kazutaka YOKOTA
c4c9400b69 - Fixed memory leak in sc_alloc_history_buffer().
- Correctly observe the variable `extra_history_size' when changing
  the size of history (scroll back) buffer.
- Added sc_free_history_buffer().

Pointed out by: des
1999-07-07 13:48:50 +00:00
Peter Wemm
4180e07c29 Tidy up a few warnings when used without splash. (things defined but not
used)
1999-07-01 20:43:03 +00:00
Peter Wemm
ea24629773 Fix warnings on the Alpha. 1999-07-01 20:29:25 +00:00
Kazutaka YOKOTA
8c76a16644 Fill in tp->t_windowsize AFTER the call to (*linesw[tp->t_line].l_open)(),
rather than BEFORE the call.  Otherwise the structure will be `zero'ed out
by l_open, which actually is ttyopen(), if !TS_OPEN.

PR: kern/12420
1999-06-29 17:30:33 +00:00
Peter Wemm
81b1c87805 Fix a dev_t/udev_t issue 1999-06-26 11:00:17 +00:00
Kazutaka YOKOTA
7107ea4aa1 Fix ESC[P (delete N chars) and ESC[@ (insert N chars). These deletion
and insertion should affect the line the cursor is on only.

This change should have been committed together with syscons.c rev 1.308.
(I forgot to do so, when I committed syscons.c :-(

Pointed out by: sos
1999-06-24 13:04:33 +00:00
Kazutaka YOKOTA
d1bb8e0e13 Fix ESC[P (delete N chars) and ESC[@ (insert N chars). These deletion
and insertion should affect the line the cursor is on only.
1999-06-24 09:21:27 +00:00
Kazutaka YOKOTA
6e8394b8ba The second phase of syscons reorganization.
- Split syscons source code into manageable chunks and reorganize
  some of complicated functions.

- Many static variables are moved to the softc structure.

- Added a new key function, PREV.  When this key is pressed, the vty
  immediately before the current vty will become foreground.  Analogue
  to PREV, which is usually assigned to the PrntScrn key.
  PR: kern/10113
  Submitted by: Christian Weisgerber <naddy@mips.rhein-neckar.de>

- Modified the kernel console input function sccngetc() so that it
  handles function keys properly.

- Reorganized the screen update routine.

- VT switching code is reorganized.  It now should be slightly more
  robust than before.

- Added the DEVICE_RESUME function so that syscons no longer hooks the
  APM resume event directly.

- New kernel configuration options: SC_NO_CUTPASTE, SC_NO_FONT_LOADING,
  SC_NO_HISTORY and SC_NO_SYSMOUSE.
  Various parts of syscons can be omitted so that the kernel size is
  reduced.

  SC_PIXEL_MODE
  Made the VESA 800x600 mode an option, rather than a standard part of
  syscons.

  SC_DISABLE_DDBKEY
  Disables the `debug' key combination.

  SC_ALT_MOUSE_IMAGE
  Inverse the character cell at the mouse cursor position in the text
  console, rather than drawing an arrow on the screen.
  Submitted by: Nick Hibma (n_hibma@FreeBSD.ORG)

  SC_DFLT_FONT
  makeoptions "SC_DFLT_FONT=_font_name_"
  Include the named font as the default font of syscons.  16-line,
  14-line and 8-line font data will be compiled in.  This option replaces
  the existing STD8X16FONT option, which loads 16-line font data only.

- The VGA driver is split into /sys/dev/fb/vga.c and /sys/isa/vga_isa.c.

- The video driver provides a set of ioctl commands to manipulate the
  frame buffer.

- New kernel configuration option: VGA_WIDTH90
  Enables 90 column modes: 90x25, 90x30, 90x43, 90x50, 90x60.  These
  modes are mot always supported by the video card.
  PR: i386/7510
  Submitted by: kbyanc@freedomnet.com and alexv@sui.gda.itesm.mx.

- The header file machine/console.h is reorganized; its contents is now
  split into sys/fbio.h, sys/kbio.h (a new file) and sys/consio.h
  (another new file).  machine/console.h is still maintained for
  compatibility reasons.

- Kernel console selection/installation routines are fixed and
  slightly rebumped so that it should now be possible to switch between
  the interanl kernel console (sc or vt) and a remote kernel console
  (sio) again, as it was in 2.x, 3.0 and 3.1.

- Screen savers and splash screen decoders
  Because of the header file reorganization described above, screen
  savers and splash screen decoders are slightly modified.  After this
  update, /sys/modules/syscons/saver.h is no longer necessary and is
  removed.
1999-06-22 14:14:06 +00:00
Jonathan Lemon
2171c52a81 Unifdef VM86
Reviewed by:	silence on on -current
1999-06-01 18:17:50 +00:00
Poul-Henning Kamp
2447bec829 Simplify cdevsw registration.
The cdevsw_add() function now finds the major number(s) in the
struct cdevsw passed to it.  cdevsw_add_generic() is no longer
needed, cdevsw_add() does the same thing.

cdevsw_add() will print an message if the d_maj field looks bogus.

Remove nblkdev and nchrdev variables.  Most places they were used
bogusly.  Instead check a dev_t for validity by seeing if devsw()
or bdevsw() returns NULL.

Move bdevsw() and devsw() functions to kern/kern_conf.c

Bump __FreeBSD_version to 400006

This commit removes:
        72 bogus makedev() calls
        26 bogus SYSINIT functions

if_xe.c bogusly accessed cdevsw[], author/maintainer please fix.

I4b and vinum not changed.  Patches emailed to authors.  LINT
probably broken until they catch up.
1999-05-31 11:29:30 +00:00
Poul-Henning Kamp
4e2f199e0c This commit should be a extensive NO-OP:
Reformat and initialize correctly all "struct cdevsw".

        Initialize the d_maj and d_bmaj fields.

        The d_reset field was not removed, although it is never used.

I used a program to do most of this, so all the files now use the
same consistent format.  Please keep it that way.

Vinum and i4b not modified, patches emailed to respective authors.
1999-05-30 16:53:49 +00:00
Bruce Evans
4a79c0bea3 Removed global variable `Crtat'. This was once (bogusly) shared with
pcvt, but it had rotted into unuse here, and of course its type had
become inconsisent with its type in pcvt.

Fixed some minor style bugs.
1999-05-12 04:45:56 +00:00
Dag-Erling Smørgrav
4a5222d798 MFS: indent-assisted style cleanup. 1999-05-10 15:25:50 +00:00
Doug Rabson
1d3710bdf3 Adjust console stuff now that makedev is no longer a macro. 1999-05-10 14:01:35 +00:00
Dag-Erling Smørgrav
7782bb379d A little closer to style(9). 1999-05-08 11:51:51 +00:00
Jordan K. Hubbard
d4fb5cb1e8 Add missing copyright. 1999-05-04 12:58:56 +00:00
Jordan K. Hubbard
cc611a43c2 Add "fire" screen saver.
Submitted by:	Brad Forschinger <retch@flag.blackened.net>
1999-05-04 12:23:32 +00:00
Poul-Henning Kamp
f711d546d2 Suser() simplification:
1:
  s/suser/suser_xxx/

2:
  Add new function: suser(struct proc *), prototyped in <sys/proc.h>.

3:
  s/suser_xxx(\([a-zA-Z0-9_]*\)->p_ucred, \&\1->p_acflag)/suser(\1)/

The remaining suser_xxx() calls will be scrutinized and dealt with
later.

There may be some unneeded #include <sys/cred.h>, but they are left
as an exercise for Bruce.

More changes to the suser() API will come along with the "jail" code.
1999-04-27 11:18:52 +00:00
Peter Wemm
6182fdbda8 Bring the 'new-bus' to the i386. This extensively changes the way the
i386 platform boots, it is no longer ISA-centric, and is fully dynamic.
Most old drivers compile and run without modification via 'compatability
shims' to enable a smoother transition.  eisa, isapnp and pccard* are
not yet using the new resource manager.  Once fully converted, all drivers
will be loadable, including PCI and ISA.

(Some other changes appear to have snuck in, including a port of Soren's
 ATA driver to the Alpha.  Soren, back this out if you need to.)

This is a checkpoint of work-in-progress, but is quite functional.

The bulk of the work was done over the last few years by Doug Rabson and
Garrett Wollman.

Approved by:	core
1999-04-16 21:22:55 +00:00
Dag-Erling Smørgrav
601752d5a7 Centralize and reorganize a few macros. 1999-04-12 13:34:58 +00:00
Kazutaka YOKOTA
e9deda23ae Keyboard driver update in preparation for the USB keyboard driver.
- Refined internal interface in keyboard drivers so that:
  1. the side effect of device probe is kept minimal,
  2. polling mode function is added,
  3. and new ioctl and configuration options are added (see below).

- Added new ioctl: KDSETREPEAT
  Set keyboard typematic rate.  There has existed an ioctl command,
  KDSETRAD, for the same purpose.  However, KDSETRAD is dependent on
  the AT keyboard.  KDSETREPEAT provides more generic interface.
  KDSETRAD will still be supported in the atkbd driver.

- Added new configuration options:
  ATKBD_DFLT_KEYMAP
  Specify a keymap to be used as the default, built-in keymap.
  (There has been undocumented options, DKKEYMAP, UKKEYMAP, GRKEYMAP,
  SWKEYMAP, RUKEYMAP, ESKEYMAP, and ISKEYMAP to set the default keymap.
  These options are now gone for good.  The new option is more general.)

  KBD_DISABLE_KEYMAP_LOADING
  Don't allow the user to change the keymap.
1999-03-10 10:36:53 +00:00
Dag-Erling Smørgrav
2da199da53 Followup to yokota's last commit:
- va_mode_flags -> va_info.vi_flags
 - scanline width may be different from screen width
1999-02-05 12:40:16 +00:00
Kazutaka YOKOTA
1c27745f73 - Don't assume the line length in the video memory is always the same as
the screen width.
- Store the current video mode information in the `video_adapter' struct.
- The size of the `v_offscreensize' field in the VESA mode information
  block is u_int16, not u_int8.
1999-02-05 11:52:13 +00:00
Poul-Henning Kamp
4e2d2aa1cd Use suser() to check for super user rather than examining cr_uid directly.
Use TTYDEF_SPEED rather than 9600 a couple of places.

Reviewed by:	bde, with a few grumbles.
1999-01-30 12:17:38 +00:00
Matthew Dillon
697457a133 Fix warnings related to -Wall -Wcast-qual 1999-01-28 17:32:05 +00:00
Matthew Dillon
0a5e03dda5 Fix warnings in preparation for adding -Wall -Wcast-qual to the
kernel compile
1999-01-28 01:59:53 +00:00
Kazutaka YOKOTA
44ad10ea41 Pull down the splash screen when someone is about to read from the
keyboard.  Do this in scread(), rather than in scopen().
1999-01-26 09:58:37 +00:00
Kazutaka YOKOTA
f359876ff1 syscons
- Bring down the splash screen when a vty is opened for the first
  time.
- Make sure the splash screen/screen saver is stopped before
  switching vtys.
- Read and save initial values in the BIOS data area early.
  VESA BIOS may change BIOS data values when switching modes.
- Fix missing '&' operator.
- Move ISA specific part of driver initialization to syscons_isa.c.

atkbd
- kbdtables.h is now in /sys/dev/kbd.

all
- Adjust for forthcoming alpha port.  Submitted by: dfr
1999-01-19 11:31:22 +00:00
Kazutaka YOKOTA
f9e730bbb3 Retrun EAGAIN if the current video mode is a graphics mode. 1999-01-17 14:25:19 +00:00
Kazutaka YOKOTA
6d479db3c3 - Examine the error code from the screen saver and act accordingly.
0	success
	EAGAIN	try again later
	other	don't call this screen saver again
- Test flags consistently to examine the status of the screen saver.
	scrn_blanked: the screen saver is running
	scp->status & SAVER_RUNNING: the saver is running in this vty
- Correctlyu preserve status flag bits in set/restore_scrn_saver_mdoe().
1999-01-17 14:23:15 +00:00
Dag-Erling Smørgrav
9402dfb01a Move the definition of set_origin from logo_saver.c to saver.h. 1999-01-16 10:20:16 +00:00
Kazutaka YOKOTA
aae6a996c3 Get conditional compilation right so that unnecessary reference
to splash-relatec call won't be made if there is no splash pseudo
device.
1999-01-13 01:14:26 +00:00
Kazutaka YOKOTA
2ad872c579 The first stage of console driver reorganization: activate new
keyboard and video card drivers.

Because of the changes, you are required to update your kernel
configuration file now!

The files in sys/dev/syscons are still i386-specific (but less so than
before), and won't compile for alpha and PC98 yet.

syscons still directly accesses the video card registers here and
there; this will be rectified in the later stages.
1999-01-11 03:18:56 +00:00
Kazutaka YOKOTA
fc847f6651 Remove a hard-coded table of kernel console I/O functions exported
from sc, vt and sio drivers.  Use instead a linker_set to collect them.

Staticize ??cngetc(), ??cnputc(), etc functions in sc and vt drivers.
We must still have siocngetc() and siocnputc() as globals because they
are directly referred to by i386-gdbstub.c :-(

Oked by: bde
1999-01-07 14:14:24 +00:00