diff options
-rw-r--r-- | lib/libkse/thread/thr_kern.c | 2 | ||||
-rw-r--r-- | lib/libpthread/thread/thr_kern.c | 2 |
2 files changed, 2 insertions, 2 deletions
diff --git a/lib/libkse/thread/thr_kern.c b/lib/libkse/thread/thr_kern.c index c26279e..a153a4d 100644 --- a/lib/libkse/thread/thr_kern.c +++ b/lib/libkse/thread/thr_kern.c @@ -785,7 +785,6 @@ kse_sched_multi(struct kse *curkse) ; /* Nothing to do here. */ else if ((curthread->need_switchout == 0) && (curthread->blocked == 0) && (THR_IN_CRITICAL(curthread))) { - kse_wakeup_multi(curkse); /* * Resume the thread and tell it to yield when * it leaves the critical region. @@ -798,6 +797,7 @@ kse_sched_multi(struct kse *curkse) curthread->kse = curkse; DBG_MSG("Continuing thread %p in critical region\n", curthread); + kse_wakeup_multi(curkse); if (curthread->lock_switch) { KSE_SCHED_LOCK(curkse, curkse->k_kseg); ret = _thread_switch(&curthread->tmbx, 0); diff --git a/lib/libpthread/thread/thr_kern.c b/lib/libpthread/thread/thr_kern.c index c26279e..a153a4d 100644 --- a/lib/libpthread/thread/thr_kern.c +++ b/lib/libpthread/thread/thr_kern.c @@ -785,7 +785,6 @@ kse_sched_multi(struct kse *curkse) ; /* Nothing to do here. */ else if ((curthread->need_switchout == 0) && (curthread->blocked == 0) && (THR_IN_CRITICAL(curthread))) { - kse_wakeup_multi(curkse); /* * Resume the thread and tell it to yield when * it leaves the critical region. @@ -798,6 +797,7 @@ kse_sched_multi(struct kse *curkse) curthread->kse = curkse; DBG_MSG("Continuing thread %p in critical region\n", curthread); + kse_wakeup_multi(curkse); if (curthread->lock_switch) { KSE_SCHED_LOCK(curkse, curkse->k_kseg); ret = _thread_switch(&curthread->tmbx, 0); |