Commit Graph

62 Commits

Author SHA1 Message Date
dholland f9228f4225 Add d_discard to all struct cdevsw instances I could find.
All have been set to "nodiscard"; some should get a real implementation.
2014-07-25 08:10:31 +00:00
dholland a68f9396b6 Change (mostly mechanically) every cdevsw/bdevsw I can find to use
designated initializers.

I have not built every extant kernel so I have probably broken at
least one build; however I've also found and fixed some wrong
cdevsw/bdevsw entries so even if so I think we come out ahead.
2014-03-16 05:20:22 +00:00
macallan a98db642b2 get rid of junk variable 2013-11-19 10:49:00 +00:00
chs cbab9cadce split device_t/softc for all remaining drivers.
replace "struct device *" with "device_t".
use device_xname(), device_unit(), etc.
2012-10-27 17:17:22 +00:00
macallan 3726c338fd get rid of gc_attr & allocattr() 2012-10-05 01:19:03 +00:00
macallan 8672c8bb4a support anti-aliased fonts, glyph caching etc. 2012-09-21 01:07:44 +00:00
macallan 2cbec7eebc use rasops_init(0, 0) 2012-01-11 16:08:57 +00:00
macallan 1c134541af use box drawing font if needed 2010-05-04 05:10:25 +00:00
macallan 3bc5d8b535 make latching optional.
The SPARCbook docs claim it's necessary but my 3GX happily works without.
2010-03-01 05:42:08 +00:00
macallan 539b768657 fix ancient typo, noticed by mouse@ 2010-03-01 05:26:53 +00:00
dyoung c1b390d493 A pointer typedef entails trading too much flexibility to declare const
and non-const types, and the kernel uses both const and non-const
PMF qualifiers and device suspensors, so change the pmf_qual_t and
device_suspensor_t typedefs from "pointers to const" to non-pointer,
non-const types.
2010-02-24 22:37:54 +00:00
dyoung cd6e1fbf91 Expand PMF_FN_* macros. 2010-01-08 19:53:10 +00:00
tsutsui 579b9cbd30 u_intNN_t -> uintNN_t 2009-09-19 11:53:42 +00:00
tsutsui 08c902218f Include "ioconf.h" instead of extern struct cfdriver foo_cd decls. 2009-09-17 16:39:48 +00:00
tsutsui 12ad76b18c Remove struct sbusdev and related functions sbus_establish() and sbusreset().
They are derived from 4.4BSD/sparc and have been there since initial import
of NetBSD/sparc in 1993, but the struct sbusdev is almost unused for years,
nothing calls sbusreset(), and all (*sd->sd_reset)() functions look bogus.

Suggested by mrg@ and martin@, and tested on SS1+ and SS20.
2009-09-17 16:28:12 +00:00
macallan a63997dc13 call vcons_replay_msgbuf() if we're the console 2009-08-20 02:29:16 +00:00
macallan f48726983f make this compile again without tctrl 2009-06-03 16:25:22 +00:00
macallan b538f79eb0 use pmf, while there do some cleanup, fix typos etc. 2009-05-27 15:13:22 +00:00
macallan 5052b0a047 finally commit a lot of stuff that's been sitting in my source tree for
several ages:
- convert to device_t
- add support for programming colour depth and such, use it to reset the
  console to something usable when we enter ddb or exit X etc.
- basic power management
TODO:
- convert to PMF
- get rid of rconsole code so we don't need to map the framebuffer
- power down the whole DAC when not in use
2009-05-27 00:35:34 +00:00
cegger 7cf2991222 struct device * -> device_t, no functional changes intended. 2009-05-12 14:38:26 +00:00
cegger d16a259fe3 struct cfdata * -> cfdata_t, no functional changes intended. 2009-05-12 13:15:24 +00:00
dsl 454af1c0e8 Change about 4500 of the K&R function definitions to ANSI ones.
There are still about 1600 left, but they have ',' or /* ... */
in the actual variable definitions - which my awk script doesn't handle.
There are also many that need () -> (void).
(The script does handle misordered arguments.)
2009-03-14 15:35:58 +00:00
he ecff12ce83 Sprinkle #if NTCTRL > 0 so that this builds again without
warning that some static function is defined but never used.
2008-12-26 22:37:29 +00:00
drochner 1a9e64b4a7 mechanical changes to use device_private() or device_lookup_private()
to get softcs, makes the code compile under the stricter type checking
introduced earlier today
2008-06-11 21:25:31 +00:00
martin ce099b4099 Remove clause 3 and 4 from TNF licenses 2008-04-28 20:22:51 +00:00
cegger 4c5fa20d1f use aprint_*_dev and device_xname 2008-04-05 18:35:31 +00:00
ad a2a3828545 machine/{bus,cpu,intr}.h -> sys/{bus,cpu,intr}.h 2007-10-19 11:59:34 +00:00
christos 53524e44ef Kill caddr_t; there will be some MI fallout, but it will be fixed shortly. 2007-03-04 05:59:00 +00:00
jmcneill f135e0d607 Add "name" parameter to powerhook_establish, to aid debugging. No objections
on tech-kern@
2006-09-24 03:53:07 +00:00
blymn 3a0170518a Clean up bogus whitespace 2006-05-28 13:12:42 +00:00
jmmv aec18036fd Remove the getwschar and putwschar accessops from wsdisplay drivers as
requested by uwe@.  These were wrong because they were receiving an
emulcookie yet they were accessops (thus having to receive an accesscookie).
Instead, just handle the WSDISPLAYIO_{GET,PUT}WSCHAR ioctls from the
driver's ioctl accessop.

As this reduces the amount of code needed to handle these operations to
two small functions in each driver, remove the WSDISPLAY_CHARFUNCS kernel
option.

Reviewed by, at least, uwe@ and macallan@.  No objections in tech-kern@.
2006-04-15 17:48:23 +00:00
jmmv 7a51d4dddc Add an extra cookie to the ioctl and mmap wsdisplay accessops that points
to the screen on which they are being called.  The driver cannot guess
this by itself but it is needed to implement, at least, the getwschar and
putwschar functions in the correct place.  There are no functional changes
yet.

Tested on i386 (vga, vga_raster, machfb, vesafb), macppc and sparc64.
Suggested and reviewed by macallan@.
2006-04-12 19:38:22 +00:00
drochner 41a5bdfbb9 kill NULL initialisation of get/setborder 2006-04-06 12:22:05 +00:00
thorpej 2be6494fc9 Use device_cfdata(). 2006-03-29 04:16:44 +00:00
macallan a12ced4fd9 sprinkle #if NWSDISPLAY > 0 to make this compile cleanly without wscons again 2006-03-08 20:09:01 +00:00
macallan 8700623aff - use vcons
- enable the external VGA port when tctrl detects a monitor
2006-03-06 21:53:17 +00:00
christos 9f7f6692b9 proc -> lwp 2005-12-14 00:35:31 +00:00
christos 95e1ffb156 merge ktrace-lwp. 2005-12-11 12:16:03 +00:00
macallan 0ea32fbae1 Add hardware cursor support, needs testing. 2005-11-12 23:25:46 +00:00
tsutsui b22c03af41 Fix a shadowing variable. 2005-06-04 04:35:27 +00:00
macallan 8f8a7a4e38 forgot to include rasops_glue.h 2005-05-16 15:16:43 +00:00
macallan 9efeaffa68 Added:
- wscons support
- acceleration
- virtual consoles
- colour
- made cg3 emulation optional for native XFree driver
2005-05-16 14:43:23 +00:00
perry f31bd063e9 nuke trailing whitespace 2005-02-27 00:26:58 +00:00
pk ea53363e84 Rename PROM_getprop*() => prom_getprop*(). 2004-03-17 17:04:58 +00:00
uwe bb09aff859 Undo previous as it broke things.
There are some scattered implicit RASTERCONSOLE dependencies,
so there should be a better way.
2003-08-25 17:50:22 +00:00
uwe 65aeb1d742 #include "opt_rcons.h" 2003-08-24 17:31:59 +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
darrenr 28c230cff5 More changes for providing lwpid for ktrace (sparc GENERIC built) 2003-06-29 09:56:29 +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
thorpej b75a007d9f Add trailing ; to CFATTACH_DECL. 2002-10-02 16:51:16 +00:00