summaryrefslogtreecommitdiff
path: root/sys/dev/raidframe/rf_threadstuff.h
AgeCommit message (Collapse)Author
2011-05-11convert the main raidPtr mutex to a kmutex, and add a couple of cv's tomrg
cover the old sleep/wakeup points for adding_hot_spare and waitForReconCond. convert all remaining simple_lock's to kmutexes (they're not used or compiled right now... even with all options enabled) and remove the support for them. this leaves just a pair of tsleep()/wakeup() calls using old scheduling APIs.
2011-05-11convert regionInfo[regionID].mutex to a kmutex.mrg
2011-05-05RF_BROADCAST_COND() is no more.mrg
2011-05-03convert the pssTable mutex into a kmutex/cv.mrg
2011-05-02re-apply the reverted previous, after fixing the missed wakeup:mrg
convert eq_mutex to a kmutex/cv. convert ltsleep() used for plain timeout into kpause().
2011-05-02rever the previous for now; it hangs reconstruction.mrg
2011-05-01convert eq_mutex to a kmutex.mrg
convert ltsleep() used for plain timeout into kpause().
2011-04-30- convert rf_printf_mutex to a kmutexmrg
- convert rf_rad_lock and the per-raid "cv" to per-raid kmutex/and real cv - use rf_mutex_init() in places, and move it with the similar definitions
2011-04-27prepare to convert more raidframe old lock/sleep APIs to mutex/condvar:mrg
- remove RF_DECLARE_EXTERN_MUTEX and RF_DECLARE_STATIC_MUTEX, the qualifier can be provided at the use point with the normal define - rename the *LGMGR_MUTEX() macros to *mutex2() names, and add some more defines for use: rf_declare_mutex2() rf_declare_cond2() rf_lock_mutex2() rf_unlock_mutex2() rf_init_mutex2() rf_destroy_mutex2() rf_init_cond2() rf_destroy_cond2() rf_wait_cond2() rf_signal_cond2() rf_broadcast_cond2() - use the new names for the configureMutex(), which previous used some combo of direct mutex* calls and macros - convert the node_queue to use a mutex/cv combo - in rf_ShutdownEngine() and DAGExecutionThread(), also signal the former from the latter when it is done and about to exit - convert iodone_lock to use the new macros
2007-12-05lockmgr -> mutexad
2007-07-18Fix fallout from recent kthread changes.ad
2007-07-09Merge some of the less invasive changes from the vmlocking branch:ad
- kthread, callout, devsw API changes - select()/poll() improvements - miscellaneous MT safety improvements
2005-12-11merge ktrace-lwp.christos
2003-12-29rf_lkmgr_mutex_init() is only called from one spot, and it reallyoster
can't fail. Simplify life in rf_BootRaidframe(), and then nuke rf_lkmgr_mutex_init(). Cleanup rf_threadstuff.h a bit more too. rf_threadstuff.c is about to Go Away.
2003-12-29Garbage-collect a whole mess of this RF_THREADGROUP_* stuff that isn'toster
being used. Then, nuke rf_init_managed_threadgroup() and all descendants and relations.
2003-12-29_rf_create_managed_cond() is now left doing nothing. Convert callers.oster
Mash DO_RAID_COND in rf_driver.c out of existance. - Nuke (already #if 0'ed) _rf_create_managed_lkmgr_mutex() while we're busy here. simplify DO_INIT in rf_engine.c
2003-12-29cond_destroyer joins mutex_destroyer in the "nothing useful is doneoster
here" department. remove _rf_init_threadgroup() and rf_destroy_threadgroup() which were already #if 0'ed. rf_cond_destroy() does nothing. Nuke it, and all callers. rf_cond_init() doesn't deserve to be a separate function any more. Fix up the remaining 3 callers, and nuke rf_cond_init(). Another 0.4K goes "poof", but still no functionality lost!
2003-12-29_rf_create_managed_mutex() is doing just a simple:oster
rf_mutex_init(m) now. The rest of the fluff is no longer needed. It also cannot fail, so error checking on rf_create_managed_mutex() is just wasting space. Nuke the #define's associated with rf_create_managed_mutex(). Convert rf_create_managed_mutex(listp,m) to just rf_mutex_init(m). Remove wasteful "error checking" and simplify all instances where this is called. (another 0.3K saved in the binary, but the real savings is in code readability!)
2003-12-29Since rf_mutex_destroy() is effectively a NOP now, nuke it.oster
2003-12-29Simplify defn's of rf_mutex_init() and rf_mutex_destroy(). Sinceoster
neither of these ever fail, no need to have a return value. That makes all the "error detection" on these functions completely unneeded. But since we're here, if we don't have a return value, then why not make these macros? My.. look how things keep shrinking, with no loss in functionality!
2002-10-02Create a thread creation macro that make it easier to name the DAG process.oster
Use it to have the DAGExecutionThread have a better name for each RAID process ('raid0', 'raid1', etc., vs. just 'raid', 'raid', etc.)
2002-08-08Initial kick at some functions to provide lockmgr lock supportoster
instead of only simplelock support.
2001-10-04Step 2 of the disentanglement. We now look to <dev/raidframe/*> foroster
the stuff that used to live in rf_types.h, rf_raidframe.h, rf_layout.h, rf_netbsd.h, rf_raid.h, rf_decluster,h, and a few other places. Believe it or not, when this is all done, things will be cleaner. No functional changes to RAIDframe.
2001-01-27Un-'__P'ify.oster
2000-08-20RF_COND_WAIT(): use ltsleep().thorpej
RF_SIGNAL_COND(): use wakeup_one().
2000-06-11Nuke a (mostly) now-incorrect comment.oster
2000-01-09Nuke a couple of obsolete comments.oster
2000-01-05- update RF_CREATE_THREAD to handle a 'process name' argument.oster
- fire up a new thread for parity re-writes, copybacks, and reconstructs. The ioctl's which trigger these actions now return immediately. - add progress accounting for the above actions. - minor rototillage of rf_netbsdkintf.c to deal with all of the above.
1999-07-06Make the kthread API a bit friendlier to loadable kernel modules.thorpej
1999-03-14Disallow interrupting parity re-writes or copybacks by removing PCATCHoster
from the tsleep()'s (they probably shouldn't have been there in the first place!). Making parity re-writing and copybacks interruptable will require re-designing how a few things are done (e.g. how memory is freed for structures shipped off to routines that run asynchronously relative to the calling routine). Fix a few other tsleep's while we're at it.
1999-02-05Phase 2 of the RAIDframe cleanup. The source is now closer to KNFoster
and is much easier to read. No functionality changes.
1999-01-26RAIDframe cleanup, phase 1. Nuke simulator support, user-land driver,oster
out-dated comments, and other unneeded stuff. This helps prepare for cleaning up the rest of the code, and adding new functionality. No functional changes to the kernel code in this commit.
1998-11-13RAIDframe, version 1.1, from the Parallel Data Laboratory atoster
Carnegie Mellon University. Full RAID implementation, including levels 0, 1, 4, 5, 6, parity logging, and a few other goodies. Ported to NetBSD by Greg Oster.