Commit Graph

164 Commits

Author SHA1 Message Date
ad
88ab7da936 Merge some of the less invasive changes from the vmlocking branch:
- kthread, callout, devsw API changes
- select()/poll() improvements
- miscellaneous MT safety improvements
2007-07-09 20:51:58 +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
thorpej
c8daa94cb1 TRUE -> true, FALSE -> false 2007-02-22 16:57:56 +00:00
thorpej
712239e366 Replace the Mach-derived boolean_t type with the C99 bool type. A
future commit will replace use of TRUE and FALSE with true and false.
2007-02-21 22:59:35 +00:00
elad
1e70d64818 Consistent usage of KAUTH_GENERIC_ISSUSER. 2007-01-04 16:55:29 +00:00
elad
65792a0340 More from Matt Fleming:
Adapt to KAUTH_DEVICE_TTY_PRIVSET and KAUTH_DEVICE_TTY_OPEN.
2006-10-01 20:31:49 +00:00
elad
e8373398dc Adapt MD code to KAUTH_DEVICE_TTY_OPEN. Patch from Matt Fleming, thanks! 2006-10-01 18:56:21 +00:00
simonb
4f4791b37f Switch pc532 to timecounters and generic TODR.
From Garrett D'Amore, with only a couple of minor tweaks by me.
2006-09-07 15:56:01 +00:00
ad
f474dceb13 Use the LWP cached credentials where sane. 2006-07-23 22:06:03 +00:00
elad
8ccb6c9341 integrate kauth. 2006-05-14 21:55:09 +00:00
simonb
c1924fc56d KNF, ANSIfy, white space clean up. 2006-05-12 06:05:22 +00:00
thorpej
ff5e3107c9 No need to check if dv_cfdata is NULL here. 2006-03-29 03:58:48 +00:00
thorpej
39cd836ee1 Use device_unit(). 2006-03-28 17:38:24 +00:00
simonb
c66cd10ee8 Trim use of "volatile" a little. 2006-03-11 14:07:35 +00:00
perry
5f1c88d70d Remove leading __ from __(const|inline|signed|volatile) -- it is obsolete. 2005-12-24 20:06:46 +00:00
christos
95e1ffb156 merge ktrace-lwp. 2005-12-11 12:16:03 +00:00
chs
c4cc0529a0 make this compile again after stricter warnings and compat changes. 2005-10-02 15:07:41 +00:00
kleink
aece7a90fd Change the driver open function's conditional for overriding exclusive tty
use from checking the proc's uid to suser(9), and account for the use of
privileges.  Noted by David Holland in PR kern/31126.
2005-09-06 21:40:37 +00:00
chs
e03cd70434 require that the register address and irq be specified in the config file
instead of inferring them from the unit number.
2005-02-22 14:42:17 +00:00
chs
0ded74691b for drivers that support only one instance, use a global variable to ensure
that only one instance is configured rather than requiring that its
unit number be zero.
2004-12-13 02:14:13 +00:00
simonb
6765e4c055 Fix trailing white space and trailing blank line nits. 2004-01-23 04:12:39 +00:00
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
thorpej
cb53206514 * Defflag CPU30MHZ.
* Unrelated cosmetic change in files.pc532.
2003-06-24 04:57:58 +00:00
thorpej
9f7d0893c1 Use PAGE_SIZE rather than NBPG. 2003-04-02 02:19:29 +00:00
simonb
fe72c084d6 Switch to using evcnt(9) to track interrupt counts. 2002-11-22 13:26:39 +00:00
simonb
4c350ad4fa Put back extern declaration of scn_cd so this builds again. 2002-11-21 00:23:24 +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
adb90ad2ae Use CFATTACH_DECL(). 2002-10-02 04:17:21 +00:00
thorpej
f818766afe Declare all cfattach structures const. 2002-09-27 20:31:45 +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
simonb
648246d46a Add an empty statement after a goto label to keep gcc-current happy. 2002-05-25 03:45:12 +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
jdolecek
ff8305bbac Switch to MI dev/md_root.c for archs which don't have any special
memory disk hooks (i.e. everything except atari).
2002-01-21 21:56:57 +00:00
wiz
1fd7eeefcd "than" instead of "then". 2001-11-21 19:14:19 +00:00
wiz
a9356936b4 seperate -> separate 2001-07-22 13:33:58 +00:00
wiz
0a600be867 receive, not recieve 2001-06-12 15:17:10 +00:00
lukem
d84d2c6c85 add missing #include "opt_kgdb.h" 2001-05-30 15:24:23 +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
bouyer
937a7a3ed9 Pull up the thorpej_scsipi branch to main branch.
This is a completely rewritten scsipi_xfer execution engine, and the
associated changes to HBA drivers. Overview of changes & features:
- All xfers are queued in the mid-layer, rather than doing so in an
  ad-hoc fashion in individual adapter drivers.
- Adapter/channel resource management in the mid-layer, avoids even trying
  to start running an xfer if the adapter/channel doesn't have the resources.
- Better communication between the mid-layer and the adapters.
- Asynchronous event notification mechanism from adapter to mid-layer and
  peripherals.
- Better peripheral queue management: freeze/thaw, sorted requeueing during
  recovery, etc.
- Clean separation of peripherals, adapters, and adapter channels (no more
  scsipi_link).
- Kernel thread for each scsipi_channel makes error recovery much easier
  (no more dealing with interrupt context when recovering from an error).
- Mid-layer support for tagged queueing: commands can have the tag type
  set explicitly, tag IDs are allocated in the mid-layer (thus eliminating
  the need to use buggy tag ID allocation schemes in many adapter drivers).
- support for QUEUE FULL and CHECK CONDITION status in mid-layer; the command
  will be requeued, or a REQUEST SENSE will be sent as appropriate.

Just before the merge syssrc has been tagged with thorpej_scsipi_beforemerge
2001-04-25 17:53:04 +00:00
thorpej
bf2dcec4f5 Remove the use of splimp() from the NetBSD kernel. splnet()
and only splnet() is allowed for the protection of data structures
used by network devices.
2001-04-13 23:29:55 +00:00
matthias
2282e42ec2 Fix type in pliptransmit declaration (C version). Noticed by
Tyrel Beede <tb90@mail.csuchico.edu>.
2001-03-22 08:14:23 +00:00
matthias
172ba55ce5 Make it work again after the linediscipline changes. 2000-12-19 16:23:57 +00:00
thorpej
b84f740be0 Move bpfattach()/bpfdetach() calls into ether_ifattach()/ether_ifdetach(). 2000-11-15 01:02:11 +00:00
eeh
8c3f6a0d10 Adapt to new line discipline scheme. 2000-11-02 00:37:56 +00:00
matthias
0688add8e8 Take care of prototype changes for console probe and console getc. 2000-07-14 08:18:49 +00:00
cgd
5f23f3b392 Fix typo: 68681, not 68881. (I'm a UART, Jim, not an FPU!!!) 2000-05-26 23:03:18 +00:00
tsutsui
9100212ef0 Add a "sc_rev" member to ncr5380_softc and handle CXD1180 quirk
in MI ncr5380sbc.
2000-03-25 15:27:54 +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
mycroft
0af581a1a1 Add a ncr5380_attach() routine which does part of the initialization, attaches
the scsibus, and does the addref/delref dance.
2000-03-18 16:13:22 +00:00