summaryrefslogtreecommitdiff
path: root/sys/kern/kern_subr.c
AgeCommit message (Collapse)Author
2010-09-07remove the powerhook code. All architectures now use the ca_activate treeTheo de Raadt
traversal code to suspend/resume ok oga kettenis blambert
2010-09-06All PWR_{SUSPEND,RESUME} can now be replaced by DVACT_{SUSPEND,RESUME}Theo de Raadt
2008-06-12Remove silly panic when disestablish cookie doesnt existMarco Peereboom
ok art
2007-05-16The world of __HAVEs and __HAVE_NOTs is reducing. All architecturesArtur Grabowski
have cpu_info now, so kill the option. eyeballed by jsg@ and grange@
2005-11-28ansi/deregister.Jonathan Gray
'go for it' deraadt@
2004-11-28mountroothooks are called after the root filesystem is mounted.Theo de Raadt
2004-06-13debranch SMP, have funNiklas Hallqvist
2004-06-09Merge in a piece of the SMP branch into HEAD.Artur Grabowski
Introduce the cpu_info structure, p_cpu field in struct proc and global scheduling context and various changed code to deal with this. At the moment no architecture uses this stuff yet, but it will allow us slow and controlled migration to the new APIs. All new code is ifdef:ed out. ok deraadt@ niklas@
2003-10-31allocate at least as much elements as requested in hashinitMarkus Friedl
fixes pr 3537, based on patch from daniel@nofsk.nofsk.au.eu.org ok millert@, deraadt@, tedu@
2003-07-21remove caddr_t casts. it's just silly to cast something when the functionTed Unangst
takes a void *. convert uiomove to take a void * as well. ok deraadt@
2003-06-02Remove the advertising clause in the UCB license which BerkeleyTodd C. Miller
rescinded 22 July 1999. Proofed by myself and Theo.
2003-01-09Remove fetch(9) and store(9) functions from the kernel, and replace the fewMiod Vallat
remaining instances of them with appropriate copy(9) usage. ok art@, tested on all arches unless my memory is non-ECC
2002-07-12- Add a flags argument to dohooks.Artur Grabowski
The flag can be either HOOK_REMOVE or HOOK_REMOVE|HOOK_FREE. o HOOK_REMOVE removes the hook from the list before executing it. o HOOK_FREE frees the hook after that. - Let dostartuphooks use HOOK_REMOVE|HOOK_FREE so we can reclaim the memory. - Let doshutdownhooks use HOOK_REMOVE so that when some shutdown hook panics (they do that all the #@$%! time these days) we don't loop for ever. Don't HOOK_FREE, it doesn't matter and I don't want to add another possible panic condition for shutdown hooks. - Actually free the pointer we're throwing away in hook_disestablish (I wonder how much memory this has leaked over the years).
2002-03-14First round of __P removal in sysTodd C. Miller
2001-07-27Startup hooks. Can be used for providing root/swap devices from deviceNiklas Hallqvist
systems which want configuration to finish late, like I2O. Implemented via a general hooks mechanism which the shutdown hooks have been converted to use as well. It even has manpages!
2001-06-27remove old vmArtur Grabowski
2001-06-26Appease gcc by not using void pointers in arithmetic operations; art@ okAaron Campbell
2001-06-23Since malloc in hashinit can get M_NOWAIT flags, we shouldArtur Grabowski
check the return value.
2000-09-07On resume run the powerhook in installation order.Artur Grabowski
(the powerhooks were always run in reverse order).
2000-09-07Put powerhooks on a CIRCLEQ instead of LIST.Artur Grabowski
Use FOREACH macros instead of walking the list manually.
2000-09-07Run powerhooks at splhigh.Artur Grabowski
2000-09-05Wrap power hooks in splimp(), fixes WaveLAN suspend problem; thanks art@Aaron Campbell
2000-04-19Remove the roundrobin_attempts hack and replace it with per-process schedulingArtur Grabowski
flags (much nicer for future smp work). Add two generic functions yield() and preempt(). Use preepmt() in uio when we are told to yield. Based on my idea, code written by Jason Thorpe from NetBSD.
2000-03-03If we attempted reschedule two times without suceeding, uiomove will yield,Artur Grabowski
giving other processes a chance to run. A process feeding a huge buffer to {read,write}{,v} on a file that doesn't need to wait for I/O, could have hogged a lot of cpu in the kernel, blocking all userland activity. Based on a similiar fix in FreeBSD.
1999-11-07add APM powerhooks.Niels Provos
from NetBSD, Sat Jun 26 08:25:25 1999 UTC by augustss: Add powerhooks, i.e., the ability to register a function that will be called when the machine does a suspend or resume. XXX Will go away when Jason's kevents come to life.
1999-04-28zap the newhashinit hack.Artur Grabowski
Add an extra flag to hashinit telling if it should wait in malloc. update all calls to hashinit.
1999-02-26uvm uses kcopy when uiomoving from sysspaceArtur Grabowski
1999-02-26Add newhashinit(), which is identical to hashinit() except it takes a flagsTodd C. Miller
arg for passing to malloc() (hashinit always uses M_WAITOK which is not always what you want). Everything that uses hashinit should really get converted to newhashinit and then newhashinit can be renamed.
1998-07-28Return EINVAL when msg_iovlen or iovcnt <= 0; Make uio_resid unsigned ↵Todd C. Miller
(size_t) and don't return EINVAL if it is < 0 in sys_{read,write}. Remove check for uio_resid < 0 uiomove() now that uio_resid is unsigned and brack remaining panics with #ifdef DIAGNOSTIC. vn_rdwr() must now take a size_t * as its 9th argument so change that and clean up uses of vn_rdwr(). Fixes 549 + more
1998-05-11compile if iov_base is void *Theo de Raadt
1997-02-24OpenBSD tagsNiklas Hallqvist
1996-04-21partial sync with netbsd 960418, more to comeTheo de Raadt
1996-04-17Removed vax ifdefed function from kern_subr.c (from NetBSD).Michael Shalayeff
Do sync in the order of umount (vfs_syscals.c), as it was pointed by someone in NetBSD's lists.
1995-10-18initial import of NetBSD treeTheo de Raadt