743 |
if (worker == l4_nilthread) |
if (worker == l4_nilthread) |
744 |
err = EAGAIN; |
err = EAGAIN; |
745 |
else |
else |
746 |
err = pthread_create_from_l4_tid_np (worker_thread, NULL, |
{ |
747 |
worker, manage_mt_worker_sync, |
err = pthread_create_from_l4_tid_np (worker_thread, NULL, |
748 |
info); |
worker, manage_mt_worker_sync, |
749 |
|
info); |
750 |
|
/* Return the thread to the pool. */ |
751 |
|
if (err) |
752 |
|
pthread_pool_add_np (worker); |
753 |
|
} |
754 |
|
|
755 |
if (!err) |
if (!err) |
756 |
{ |
{ |
838 |
if (worker == l4_nilthread) |
if (worker == l4_nilthread) |
839 |
err = EAGAIN; |
err = EAGAIN; |
840 |
else |
else |
841 |
err = pthread_create_from_l4_tid_np (&worker_thread, NULL, |
{ |
842 |
worker, |
err = pthread_create_from_l4_tid_np (&worker_thread, NULL, |
843 |
manage_mt_worker_async, |
worker, |
844 |
info); |
manage_mt_worker_async, |
845 |
|
info); |
846 |
|
/* Return the thread to the pool. */ |
847 |
|
if (err) |
848 |
|
pthread_pool_add_np (worker); |
849 |
|
} |
850 |
|
|
851 |
if (!err) |
if (!err) |
852 |
{ |
{ |
853 |
pthread_detach (worker_thread); |
pthread_detach (worker_thread); |
927 |
err = pthread_create_from_l4_tid_np (&worker_thread, NULL, |
err = pthread_create_from_l4_tid_np (&worker_thread, NULL, |
928 |
worker, manage_mt_worker_sync, &info); |
worker, manage_mt_worker_sync, &info); |
929 |
if (err) |
if (err) |
930 |
return err; |
{ |
931 |
|
/* Return the thread to the pool. */ |
932 |
|
pthread_pool_add_np (worker); |
933 |
|
return err; |
934 |
|
} |
935 |
pthread_detach (worker_thread); |
pthread_detach (worker_thread); |
936 |
|
|
937 |
pthread_mutex_lock (&bucket->lock); |
pthread_mutex_lock (&bucket->lock); |