summaryrefslogtreecommitdiffstats
path: root/lib/libkse/thread/thr_kern.c
diff options
context:
space:
mode:
Diffstat (limited to 'lib/libkse/thread/thr_kern.c')
-rw-r--r--lib/libkse/thread/thr_kern.c18
1 files changed, 17 insertions, 1 deletions
diff --git a/lib/libkse/thread/thr_kern.c b/lib/libkse/thread/thr_kern.c
index 22746c7..3a6966b 100644
--- a/lib/libkse/thread/thr_kern.c
+++ b/lib/libkse/thread/thr_kern.c
@@ -29,7 +29,7 @@
* OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
* SUCH DAMAGE.
*
- * $Id: uthread_kern.c,v 1.13 1998/09/30 06:36:56 jb Exp $
+ * $Id: uthread_kern.c,v 1.14 1998/10/09 19:01:30 dt Exp $
*
*/
#include <errno.h>
@@ -616,6 +616,22 @@ _thread_kern_sched_state(enum pthread_state state, char *fname, int lineno)
return;
}
+void
+_thread_kern_sched_state_unlock(enum pthread_state state,
+ spinlock_t *lock, char *fname, int lineno)
+{
+ /* Change the state of the current thread: */
+ _thread_run->state = state;
+ _thread_run->fname = fname;
+ _thread_run->lineno = lineno;
+
+ _SPINUNLOCK(lock);
+
+ /* Schedule the next thread that is ready: */
+ _thread_kern_sched(NULL);
+ return;
+}
+
static void
_thread_kern_select(int wait_reqd)
{
OpenPOWER on IntegriCloud