expose __lwp_park60
This commit is contained in:
parent
5570e6936a
commit
b2a02f6aa7
|
@ -1,4 +1,4 @@
|
|||
/* $NetBSD: lwp.h,v 1.3 2013/03/29 02:09:58 christos Exp $ */
|
||||
/* $NetBSD: lwp.h,v 1.4 2014/01/31 20:45:49 christos Exp $ */
|
||||
|
||||
/*-
|
||||
* Copyright (c) 2008 The NetBSD Foundation, Inc.
|
||||
|
@ -42,7 +42,7 @@ __BEGIN_DECLS
|
|||
struct timespec50;
|
||||
int _lwp_park(const struct timespec50 *, lwpid_t, const void *, const void *);
|
||||
int ___lwp_park50(const struct timespec *, lwpid_t, const void *, const void *);
|
||||
int ___lwp_park60(clockid_t , int, const struct timespec *, lwpid_t,
|
||||
int ___lwp_park60(clockid_t, int, const struct timespec *, lwpid_t,
|
||||
const void *, const void *);
|
||||
__END_DECLS
|
||||
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
/* $NetBSD: compat___lwp_park50.c,v 1.1 2013/03/29 02:09:58 christos Exp $ */
|
||||
/* $NetBSD: compat___lwp_park50.c,v 1.2 2014/01/31 20:45:49 christos Exp $ */
|
||||
|
||||
/*-
|
||||
* Copyright (c) 2013 The NetBSD Foundation, Inc.
|
||||
|
@ -32,7 +32,7 @@
|
|||
|
||||
#include <sys/cdefs.h>
|
||||
#if defined(LIBC_SCCS) && !defined(lint)
|
||||
__RCSID("$NetBSD: compat___lwp_park50.c,v 1.1 2013/03/29 02:09:58 christos Exp $");
|
||||
__RCSID("$NetBSD: compat___lwp_park50.c,v 1.2 2014/01/31 20:45:49 christos Exp $");
|
||||
#endif /* LIBC_SCCS and not lint */
|
||||
|
||||
#define __LIBC12_SOURCE__
|
||||
|
@ -43,11 +43,6 @@ __RCSID("$NetBSD: compat___lwp_park50.c,v 1.1 2013/03/29 02:09:58 christos Exp $
|
|||
#include <compat/sys/mount.h>
|
||||
#include <compat/include/lwp.h>
|
||||
|
||||
#ifndef notyet
|
||||
#include <unistd.h>
|
||||
#include <sys/syscall.h>
|
||||
#endif
|
||||
|
||||
__warn_references(fhstat,
|
||||
"warning: reference to compatibility ___lwp_park50(); include <lwp.h> to generate correct reference")
|
||||
|
||||
|
@ -58,10 +53,6 @@ int
|
|||
___lwp_park50(const struct timespec *ts, lwpid_t unpark, const void *hint,
|
||||
const void *unparkhint)
|
||||
{
|
||||
#ifdef notyet
|
||||
return ___lwp_park60(CLOCK_REALTIME, TIMER_ABSTIME, ts, unpark,
|
||||
hint, unparkhint);
|
||||
#else
|
||||
return syscall(SYS_compat_60__lwp_park, ts, unpark, hint, unparkhint);
|
||||
#endif
|
||||
}
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
# $NetBSD: shlib_version,v 1.248 2014/01/16 17:21:38 christos Exp $
|
||||
# $NetBSD: shlib_version,v 1.249 2014/01/31 20:45:48 christos Exp $
|
||||
# Remember to update distrib/sets/lists/base/shl.* when changing
|
||||
#
|
||||
# things we wish to do on next major version bump:
|
||||
|
@ -40,4 +40,4 @@
|
|||
# - consolidate ownership with crt0.o and avoid common symbols
|
||||
# - redo stdin/stdout/stderr to not require copy relocations
|
||||
major=12
|
||||
minor=189
|
||||
minor=190
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
# $NetBSD: Makefile.inc,v 1.222 2014/01/16 20:31:43 christos Exp $
|
||||
# $NetBSD: Makefile.inc,v 1.223 2014/01/31 20:45:49 christos Exp $
|
||||
# @(#)Makefile.inc 8.3 (Berkeley) 10/24/94
|
||||
|
||||
# sys sources
|
||||
|
@ -100,7 +100,7 @@ ASM= access.S acct.S \
|
|||
lchflags.S lchmod.S lchown.S lfs_bmapv.S lfs_markv.S lfs_segclean.S \
|
||||
__lfs_segwait50.S link.S linkat.S listen.S __lstat50.S \
|
||||
__lutimes50.S _lwp_create.S _lwp_exit.S _lwp_kill.S \
|
||||
_lwp_self.S _lwp_wait.S _lwp_unpark.S \
|
||||
___lwp_park60.S _lwp_self.S _lwp_wait.S _lwp_unpark.S \
|
||||
_lwp_unpark_all.S _lwp_suspend.S _lwp_continue.S \
|
||||
_lwp_wakeup.S _lwp_detach.S _lwp_setprivate.S \
|
||||
_lwp_setname.S _lwp_getname.S _lwp_ctl.S \
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
.\" $NetBSD: _lwp_park.2,v 1.7 2008/04/30 13:10:51 martin Exp $
|
||||
.\" $NetBSD: _lwp_park.2,v 1.8 2014/01/31 20:45:49 christos Exp $
|
||||
.\"
|
||||
.\" Copyright (c) 2003, 2007 The NetBSD Foundation, Inc.
|
||||
.\" All rights reserved.
|
||||
|
@ -27,7 +27,7 @@
|
|||
.\" ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
|
||||
.\" POSSIBILITY OF SUCH DAMAGE.
|
||||
.\"
|
||||
.Dd September 25, 2007
|
||||
.Dd March 28, 2013
|
||||
.Dt _LWP_PARK 2
|
||||
.Os
|
||||
.Sh NAME
|
||||
|
@ -38,7 +38,7 @@
|
|||
.Sh SYNOPSIS
|
||||
.In lwp.h
|
||||
.Ft int
|
||||
.Fn _lwp_park "const struct timespec *abstime" "lwpid_t unpark" "const void *hint" "const void *unparkhint"
|
||||
.Fn _lwp_park "clockid_t clock_id, int flags, const struct timespec *ts" "lwpid_t unpark" "const void *hint" "const void *unparkhint"
|
||||
.Sh DESCRIPTION
|
||||
.Fn _lwp_park
|
||||
can be used to synchronize access to resources among multiple light-weight
|
||||
|
@ -48,8 +48,22 @@ of the following conditions is met:
|
|||
.Bl -bullet
|
||||
.It
|
||||
The
|
||||
.Fa abstime
|
||||
argument is non-NULL, and the absolute UTC time it specifies has passed.
|
||||
.Fa ts
|
||||
argument is non-NULL, and the time it specifies has passed.
|
||||
The
|
||||
.Fa ts
|
||||
time can be an relative interval to wait if the
|
||||
.Ar flags
|
||||
argument does not contain
|
||||
.Dv TIMER_ABSTIME
|
||||
or it can be an absolute time compared to
|
||||
.Dv CLOCK_REALTIME
|
||||
or
|
||||
.Dv CLOCK_MONOTONIC
|
||||
depending on the value
|
||||
of the
|
||||
.Ar clock_id
|
||||
argument.
|
||||
.It
|
||||
The LWP receives a directed signal posted using
|
||||
.Fn _lwp_kill ,
|
||||
|
@ -125,14 +139,14 @@ following functions:
|
|||
.Fn _lwp_wakeup .
|
||||
.It Bq Er EINVAL
|
||||
The time value specified by
|
||||
.Fa abstime
|
||||
.Fa ts
|
||||
is invalid.
|
||||
.It Bq Er ESRCH
|
||||
No LWP can be found in the current process corresponding to
|
||||
.Fa unpark .
|
||||
.It Bq Er ETIMEDOUT
|
||||
The UTC time specified by
|
||||
.Fa abstime
|
||||
.Fa ts
|
||||
has passed.
|
||||
.El
|
||||
.Sh SEE ALSO
|
||||
|
|
Loading…
Reference in New Issue