Module Name:    src
Committed By:   pooka
Date:           Tue Apr 30 13:37:03 UTC 2013

Modified Files:
        src/lib/librumpuser: rumpuser_pth_dummy.c

Log Message:
make this build/work again


To generate a diff of this commit:
cvs rdiff -u -r1.11 -r1.12 src/lib/librumpuser/rumpuser_pth_dummy.c

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.

Modified files:

Index: src/lib/librumpuser/rumpuser_pth_dummy.c
diff -u src/lib/librumpuser/rumpuser_pth_dummy.c:1.11 src/lib/librumpuser/rumpuser_pth_dummy.c:1.12
--- src/lib/librumpuser/rumpuser_pth_dummy.c:1.11	Tue Apr 30 13:29:28 2013
+++ src/lib/librumpuser/rumpuser_pth_dummy.c	Tue Apr 30 13:37:03 2013
@@ -1,4 +1,4 @@
-/*	$NetBSD: rumpuser_pth_dummy.c,v 1.11 2013/04/30 13:29:28 pooka Exp $	*/
+/*	$NetBSD: rumpuser_pth_dummy.c,v 1.12 2013/04/30 13:37:03 pooka Exp $	*/
 
 /*
  * Copyright (c) 2009 Antti Kantee.  All Rights Reserved.
@@ -29,7 +29,7 @@
 
 #include <sys/cdefs.h>
 #if !defined(lint)
-__RCSID("$NetBSD: rumpuser_pth_dummy.c,v 1.11 2013/04/30 13:29:28 pooka Exp $");
+__RCSID("$NetBSD: rumpuser_pth_dummy.c,v 1.12 2013/04/30 13:37:03 pooka Exp $");
 #endif /* !lint */
 
 #include <sys/time.h>
@@ -58,11 +58,6 @@ struct rumpuser_rw {
 	int v;
 };
 
-struct rumpuser_mtx rumpuser_aio_mtx;
-struct rumpuser_cv rumpuser_aio_cv;
-int rumpuser_aio_head, rumpuser_aio_tail;
-struct rumpuser_aio rumpuser_aios[N_AIOS];
-
 void
 rumpuser__thrinit(void)
 {
@@ -71,15 +66,6 @@ rumpuser__thrinit(void)
 }
 
 /*ARGSUSED*/
-void
-rumpuser_biothread(void *arg)
-{
-
-	fprintf(stderr, "rumpuser: threads not available\n");
-	abort();
-}
-
-/*ARGSUSED*/
 int
 rumpuser_thread_create(void *(*f)(void *), void *arg, const char *thrname,
 	int joinable, int pri, int cpuidx, void **tptr)
@@ -98,6 +84,13 @@ rumpuser_thread_exit(void)
 	abort();
 }
 
+int
+rumpuser_thread_join(void *p)
+{
+
+	return 0;
+}
+
 void
 rumpuser_mutex_init(struct rumpuser_mtx **mtx, int flgas)
 {
@@ -125,7 +118,7 @@ rumpuser_mutex_tryenter(struct rumpuser_
 {
 
 	mtx->v++;
-	return 1;
+	return 0;
 }
 
 void
@@ -144,11 +137,11 @@ rumpuser_mutex_destroy(struct rumpuser_m
 	free(mtx);
 }
 
-struct lwp *
-rumpuser_mutex_owner(struct rumpuser_mtx *mtx)
+void
+rumpuser_mutex_owner(struct rumpuser_mtx *mtx, struct lwp **lp)
 {
 
-	return mtx->o;
+	*lp = mtx->o;
 }
 
 void
@@ -176,7 +169,7 @@ rumpuser_rw_tryenter(struct rumpuser_rw 
 {
 
 	rumpuser_rw_enter(rw, write);
-	return 1;
+	return 0;
 }
 
 void
@@ -198,25 +191,25 @@ rumpuser_rw_destroy(struct rumpuser_rw *
 	free(rw);
 }
 
-int
-rumpuser_rw_held(struct rumpuser_rw *rw)
+void
+rumpuser_rw_held(struct rumpuser_rw *rw, int *rvp)
 {
 
-	return rw->v != 0;
+	*rvp = rw->v != 0;
 }
 
-int
-rumpuser_rw_rdheld(struct rumpuser_rw *rw)
+void
+rumpuser_rw_rdheld(struct rumpuser_rw *rw, int *rvp)
 {
 
-	return rw->v < 0;
+	*rvp = rw->v < 0;
 }
 
-int
-rumpuser_rw_wrheld(struct rumpuser_rw *rw)
+void
+rumpuser_rw_wrheld(struct rumpuser_rw *rw, int *rvp)
 {
 
-	return rw->v > 0;
+	*rvp = rw->v > 0;
 }
 
 /*ARGSUSED*/
@@ -241,6 +234,13 @@ rumpuser_cv_wait(struct rumpuser_cv *cv,
 }
 
 /*ARGSUSED*/
+void
+rumpuser_cv_wait_nowrap(struct rumpuser_cv *cv, struct rumpuser_mtx *mtx)
+{
+
+}
+
+/*ARGSUSED*/
 int
 rumpuser_cv_timedwait(struct rumpuser_cv *cv, struct rumpuser_mtx *mtx,
 	int64_t sec, int64_t nsec)
@@ -271,11 +271,11 @@ rumpuser_cv_broadcast(struct rumpuser_cv
 }
 
 /*ARGSUSED*/
-int
-rumpuser_cv_has_waiters(struct rumpuser_cv *cv)
+void
+rumpuser_cv_has_waiters(struct rumpuser_cv *cv, int *rvp)
 {
 
-	return 0;
+	*rvp = 0;
 }
 
 /*

Reply via email to