Lines Matching refs:thread_state
35 static int thread_state;
37 /* thread_state indicates child thread state:
55 thread_state = ENTERED_THREAD;
71 thread_state = PASSED_RLOCK1;
87 thread_state = PASSED_RLOCK2;
103 thread_state = EXITING_THREAD;
129 thread_state = NOT_CREATED_THREAD;
142 }while (thread_state !=PASSED_RLOCK2 && cnt++ < 3);
144 if(thread_state == ENTERED_THREAD)
149 else if(thread_state == PASSED_RLOCK1)
155 else if(thread_state != PASSED_RLOCK2)
157 printf("Unexpected thread state: %d\n", thread_state);
161 /* thread_state == 4, i.e. child thread blocks on write lock */
173 }while (thread_state !=EXITING_THREAD && cnt++ < 3);
175 if(thread_state != EXITING_THREAD)