* Add WSDISPLAY_TYPE_VESA for vesafb. While here, fix a typo in a comment.
* Add WSDISPLAYIO_SSPLASH and WSDISPLAYIO_SPROGRESS ioctls. The former
toggles the splash screen on and off, and the latter updates the progress
animation.
* Prevent more than one hw driver from claiming to be the console.
* In vcons, keep two pointers to the screen's vcons_data. This lets us
override the original (ie with null emulops during boot), and restore
them later on.
Checking the number of events after you've trashed the stack is not very
useful. Instead, break out of the loop if we ran out, printing a message.
Also don't try to inject 0 events; reset our state instead. Maybe having
0 events should be a diagnostic printf at this point? Anyway it is not
nice having the kernel die because the mouse code got confused. Finally,
explain why the array of events is sized funny.
- Add a wsevent_inject function that atomically adds a set of events to an
event queue and change all code that directly messed with a queue to use it.
- Replace the WSEVENT_WAKEUP macro with a regular function.
- Make WSEVENT_QSIZE, PWSEVENT and splwsevent private definitions to
wsevent.c, instead of exposing them in the header file.
- Make the wsevent_init function take a process to attach to the queue,
instead of leaving this task to the caller (which always did it).
Reviewed in tech-kern@.
change wsconsctl(4) so that this is configurable.
This is specially useful for mice that provide page up/down buttons instead
of a real wheel and that do not send events repeatedly from the hardware.
(E.g.: Logitech Marble Mouse.)
No objections in tech-kern@.
- for structure fields that are conditionally present,
make those fields always present.
- for functions which are conditionally inline, make them never inline.
- remove some other functions which are conditionally defined but
don't actually do anything anymore.
- make a lock-debugging function conditional on only LOCKDEBUG.
as discussed on tech-kern some time back.
The problem is that these ioctl()s are declared as _IO() and expect to pass an
integer as argument, instead of a pointer. When dereferencing the argument
pointer in the ioctl() handler as an int we get the upper 32bit of the value so
we simply dereference it as long. Other _IO() ioctl()s may need similar fixes.
Tested on sparc64, sparc and macppc.
a W "coordinate" that can be used for these.
This changes the type of wsmouse_input(). To avoid changing a lot of drivers
a compatibilty #define is provided. Maybe changing all drivers would have
been better?
auto repeat was only available in translated mode, but not in event mode.
Now both modes have auto repeat. There are actually a few users of
the event mode, and they deserve auto repeat too. :)
Also make it possible to turn off auto repeat by setting repeat.del1=0.
at the moment.
This includes the addition of two new wsdisplay ioctls, WSDISPLAY_{G,S}BORDER,
one to get the actual color and one to set it, respectively. Possible colors
match those defined by ANSI (and listed in wsdisplayvar.h).
It also adds two accessops to the underlying graphics device, getborder and
setborder, which mach their ioctl counterparts.
Two kernel options are added: WSDISPLAY_CUSTOM_BORDER, which enables the
ioctls described above (to customize the border color from userland after
boot), and WSDISPLAY_BORDER_COLOR, which sets the color at boot time.
The former is enabled by default on the GENERIC kernel, but not on INSTALL
(among others). The later is always commented out, leaving the usual black
border as a default.
wsconsctl is modified to allow accessing this value easily. For example,
'wsconsctl -d -w border=blue'.
Two new ioctls are added to the wsdisplay device, named WSDISPLAY_GMSGATTRS
and WSDISPLAY_SMSGATTRS, used to retrieve the actual values and set them,
respectively (the name, if you are wondering, comes from "message attributes").
A new emulop is added to the underlying display driver (only vga, for now)
which sets the new attribute for the whole screen, without having to clear
it. This is optional, which means that this also works with other drivers
that don't have this new operation.
Five new kernel options have been added, although only documented in
i386 kernels (for now):
- WSDISPLAY_CUSTOM_OUTPUT, which enables the ioctls described above to
change the colors dynamically from userland. This is enabled by default
in the GENERIC kernel (as well as others) but disabled on all INSTALL*
kernels (as this feature is useless there).
- WS_DEFAULT_COLATTR, WS_DEFAULT_MONOATTR, WS_DEFAULT_BG and WS_DEFAULT_FG,
which specify the default colors for the console at boot time. These have
the same meaning as the (already existing) WS_KERNEL_* variables.
wsconsctl is modified to add msg.default.{attrs,bg,fg} and
msg.kernel.{attrs,bg,fg} to the display part, so that colors can be changed
after boot.
Tested on NetBSD/i386 with vga (and vga in mono mode), and on NetBSD/mac68k.
No objections in tech-kern@.