Lines Matching refs:thread

221     IOThread      thread;
732 nub->retain(); // thread will release()
1002 element->thread = IOThreadSelf();
1023 // determine whether it is the same or a different thread trying to lock
1024 if( active->thread != element->thread ) { // it is a different thread
1028 // before placing this new thread on the waiting queue, we look for
1032 // determine whether the active thread holding the object we
1040 if( waiting->thread == active->thread ) {
1047 if( found ) { // yes, active thread waiting for another object
1054 // find the thread that is holding this other object, that
1055 // is blocking the active thread from proceeding (fun :-)
1071 if( active->thread == element->thread ) {
1073 // doh, it's waiting for the thread that originated
1074 // this whole lock (ie. current thread) -> deadlock
1077 // the originating thread doesn't have the required
1082 } else { // originating thread is not willing to fail
1084 // see if we came across a waiting thread that did
1100 /* one thread */ true );
1102 // allow this thread to proceed (ie. wait)
1114 // repeat while loop, redefining active thread to be the
1115 // thread holding "this other object" (see above), and
1120 } else { // no, active thread is not waiting for another object
1130 // place this thread on the waiting queue and put it to sleep;
1137 // declare that this thread will wait for a given event
1145 // put thread to sleep, waiting for our event to fire...
1156 // ...plus a 3rd state, should the thread have been interrupted:
1227 } else { // it is the same thread, recursive access is allowed
1236 } else { // this object is not already locked, so let this thread through
1304 // determine whether a thread is waiting for object (head to tail scan)
1317 if ( found ) { // we found an interested thread on waiting queue
1331 // wake the waiting thread
1334 /* one thread */ true );
1378 invocation.thread = current_thread();
1599 if( next->thread != current_thread() ) {
1855 // wait to become the terminate thread
1883 IOLockWakeup( gJobsLock, (event_t) &gIOTerminateThread, /* one-thread */ false);
1893 IOLockWakeup(gJobsLock, (event_t) &gIOTerminateWork, /* one-thread */ false );
1911 IOLockWakeup( gJobsLock, (event_t) &gIOTerminateThread, /* one-thread */ false);
1937 IOLockWakeup(gJobsLock, (event_t) &gIOTerminateWork, /* one-thread */ false );
1961 IOLockWakeup(gJobsLock, (event_t) &gIOTerminateWork, /* one-thread */ false );
2569 invocation.thread = current_thread();
3429 IOLockWakeup( gJobsLock, (event_t) &gNumConfigThreads, /* one-thread */ false );
3489 // if( gNumConfigThreads) count++;// assume we're called from a config thread
3963 // priority doesn't help us much since we need a thread wakeup
4226 if( next->thread != current_thread() ) {