Skip to content
Snippets Groups Projects
NuttxUserGuide.html 120 KiB
Newer Older
patacongo's avatar
patacongo committed
<B>Function Prototype:</B>
<P>
<PRE>
    #include &lt;pthread.h&gt;
    int pthread_create(pthread_t *thread, pthread_attr_t *attr,
			  pthread_startroutine_t startRoutine,
			  pthread_addr_t arg);
</PRE>
<P>
<B>Description:</B>
To create a thread object and runnable thread, a routine
must be specified as the new thread's start routine.  An
argument may be passed to this routine, as an untyped
address; an untyped address may also be returned as the
routine's value.  An attributes object may be used to
specify details about the kind of thread being created.
<P>
<B>Input Parameters:</B>
<P>
<UL>
<LI><I>parm</I> 
</UL>
<P>
<B>Returned Values:</B>
<P>
If successful, the <I>xxx()</I> function will return
zero (<I>OK</I>).  Otherwise, an error number will be
returned to indicate the error:
<P>
<UL>
<LI><I>Exxx</I>.
</UL>
<B>Assumptions/Limitations:</B>
<P>
<B>POSIX Compatibility:</B> Comparable to the POSIX
interface of the same name.

patacongo's avatar
patacongo committed
<H3><a name="pthreaddetach">2.8.12 pthread_detach</A></H3>
patacongo's avatar
patacongo committed
<P>
<B>Function Prototype:</B>
<P>
<PRE>
    #include &lt;pthread.h&gt;
    int pthread_detach(pthread_t thread);
</PRE>
<P>
<B>Description:</B>
A thread object may be "detached" to specify that the
return value and completion status will not be requested.
<P>
<B>Input Parameters:</B>
<P>
<UL>
<LI><I>parm</I> 
</UL>
<P>
<B>Returned Values:</B>
<P>
If successful, the <I>xxx()</I> function will return
zero (<I>OK</I>).  Otherwise, an error number will be
returned to indicate the error:
<P>
<UL>
<LI><I>Exxx</I>.
</UL>
<B>Assumptions/Limitations:</B>
<P>
<B>POSIX Compatibility:</B> Comparable to the POSIX
interface of the same name.

patacongo's avatar
patacongo committed
<H3><a name="pthreadexit">2.8.13 pthread_exit</A></H3>
patacongo's avatar
patacongo committed
<P>
<B>Function Prototype:</B>
<P>
<PRE>
    #include &lt;pthread.h&gt;
    void pthread_exit(pthread_addr_t pvValue);
</PRE>
<P>
<B>Description:</B>
A thread may terminate it's own execution.
<P>
<B>Input Parameters:</B>
<P>
<UL>
<LI><I>parm</I> 
</UL>
<P>
<B>Returned Values:</B>
<P>
If successful, the <I>xxx()</I> function will return
zero (<I>OK</I>).  Otherwise, an error number will be
returned to indicate the error:
<P>
<UL>
<LI><I>Exxx</I>.
</UL>
<B>Assumptions/Limitations:</B>
<P>
<B>POSIX Compatibility:</B> Comparable to the POSIX
interface of the same name.

patacongo's avatar
patacongo committed
<H3><a name="pthreadcancel">2.8.14 pthread_cancel</A></H3>
patacongo's avatar
patacongo committed
<P>
<B>Function Prototype:</B>
<P>
<PRE>
    #include &lt;pthread.h&gt;
    int pthread_cancel(pthread_t thread);
</PRE>
<P>
<B>Description:</B>

<p>The  pthread_cancel() function shall request that thread
be canceled. The target thread's cancelability state determines
when the cancellation takes effect. When the
cancellation is acted on, thread shall be terminated.</p>

<p>When cancelability is disabled, all cancels are held pending
in the target thread until the thread changes the cancelability.
When cancelability is deferred, all cancels are held pending in
the target thread until the thread changes the cancelability or
calls pthread_testcancel().</p>

<p>Cancelability is asynchronous; all cancels are acted upon
immediately (when enable), interrupting the thread with its processing.</p>

<P>
<B>Input Parameters:</B>
<P>
<UL>
<LI><I>thread</I>.
Identifies the thread to be canceled.</li>
</UL>
<P>
<B>Returned Values:</B>
<P>
If successful, the <I>ptnread_cancel()</I> function will return zero (<I>OK</I>).
Otherwise, an error number will be returned to indicate the error:
<P>
<UL>
<LI><I>ESRCH</I>.
No thread could be found corresponding to that specified by the given thread ID.</li>
</UL>
<B>Assumptions/Limitations:</B>
<P>
<B>POSIX Compatibility:</B> Comparable to the POSIX
interface of the same name.  Except:</p>
<UL>
<LI>The thread-specific data destructor functions shall be called for thread.
However, these destructors are not currently supported.</li>
<li>Cancellation types are not supported.  The thread will be canceled
at the time that pthread_cancel() is called or, if cancelation is disabled, at
the time when cancelation is re-enabled.</li>
<li><tt>pthread_testcancel()</tt> is not supported.</li>
<li>Thread cancellation at <i>cancellation points</i> is not supported.</li>
</UL>

patacongo's avatar
patacongo committed
<H3><a name="pthreadsetcancelstate">2.8.15 pthread_setcancelstate</A></H3>
patacongo's avatar
patacongo committed
<P>
<B>Function Prototype:</B>
<P>
<PRE>
    #include &lt;pthread.h&gt;
    int pthread_setcancelstate(int state, int *oldstate);
</PRE>
<P>
<B>Description:</B>
<P>The <i>pthread_setcancelstate()</i> function atomically
sets both the calling thread's cancelability state to the indicated
state and returns the previous cancelability  state at the location
referenced by oldstate.
Legal values for state are PTHREAD_CANCEL_ENABLE and PTHREAD_CANCEL_DISABLE.<.li>

<p>Any pending thread cancelation may occur at the time that the
cancelation state is set to PTHREAD_CANCEL_ENABLE.</p>

<B>Input Parameters:</B>
<P>
<UL>
<LI><I>state</I> 
New cancelation state.  One of PTHREAD_CANCEL_ENABLE or PTHREAD_CANCEL_DISABLE.<.li>
<LI><I>oldstate</I>.
Location to return the previous cancelation state.
</UL>
<P>
<B>Returned Values:</B>
<P>
If successful, the <I>pthread_setcancelstate()</I> function will return
zero (<I>OK</I>).  Otherwise, an error number will be returned to indicate the error:
<P>
<UL>
<LI><I>ESRCH</I>.
No thread could be found corresponding to that specified by the given thread ID.</li>
</UL>
<B>Assumptions/Limitations:</B>
<P>
<B>POSIX Compatibility:</B> Comparable to the POSIX
interface of the same name.

patacongo's avatar
patacongo committed
<H3><a name="pthreadtestcancelstate">2.8.16 pthread_testcancelstate</A></H3>
patacongo's avatar
patacongo committed
<P>
<B>Function Prototype:</B>
<P>
<PRE>
    #include &lt;pthread.h&gt;
patacongo's avatar
patacongo committed
    int pthread_setcancelstate(void);
patacongo's avatar
patacongo committed
</PRE>
<P>
<B>Description:</B>
patacongo's avatar
patacongo committed
<P><b>NOT SUPPORTED</b>
patacongo's avatar
patacongo committed
<B>Input Parameters:</B>
<P>
<UL>
<LI><I>parm</I> 
</UL>
<P>
<B>Returned Values:</B>
<P>
If successful, the <I>xxx()</I> function will return
zero (<I>OK</I>).  Otherwise, an error number will be
returned to indicate the error:
<P>
<UL>
<LI><I>Exxx</I>.
</UL>
<B>Assumptions/Limitations:</B>
<P>
<B>POSIX Compatibility:</B> Comparable to the POSIX
interface of the same name.

patacongo's avatar
patacongo committed
<H3><a name="pthreadjoin">2.8.17 pthread_join</A></H3>
patacongo's avatar
patacongo committed
<P>
<B>Function Prototype:</B>
<P>
<PRE>
    #include &lt;pthread.h&gt;
    int pthread_join(pthread_t thread, pthread_addr_t *ppvValue);
</PRE>
<P>
<B>Description:</B>
A thread can await termination of another thread and retrieve
the return value of the thread.
<P>
<B>Input Parameters:</B>
<P>
<UL>
<LI><I>parm</I> 
</UL>
<P>
<B>Returned Values:</B>
<P>
If successful, the <I>xxx()</I> function will return
zero (<I>OK</I>).  Otherwise, an error number will be
returned to indicate the error:
<P>
<UL>
<LI><I>Exxx</I>.
</UL>
<B>Assumptions/Limitations:</B>
<P>
<B>POSIX Compatibility:</B> Comparable to the POSIX
interface of the same name.

patacongo's avatar
patacongo committed
<H3><a name="pthreadyield">2.8.18 pthread_yield</A></H3>
patacongo's avatar
patacongo committed
<P>
<B>Function Prototype:</B>
<P>
<PRE>
    #include &lt;pthread.h&gt;
    void pthread_yield(void);
</PRE>
<P>
<B>Description:</B>
A thread may tell the scheduler that its processor can be
made available.
<P>
<B>Input Parameters:</B>
<P>
<UL>
<LI><I>parm</I> 
</UL>
<P>
<B>Returned Values:</B>
<P>
If successful, the <I>xxx()</I> function will return
zero (<I>OK</I>).  Otherwise, an error number will be
returned to indicate the error:
<P>
<UL>
<LI><I>Exxx</I>.
</UL>
<B>Assumptions/Limitations:</B>
<P>
<B>POSIX Compatibility:</B> Comparable to the POSIX
interface of the same name.

patacongo's avatar
patacongo committed
<H3><a name="pthreadself">2.8.19 pthread_self</A></H3>
patacongo's avatar
patacongo committed
<P>
<B>Function Prototype:</B>
<P>
<PRE>
    #include &lt;pthread.h&gt;
    pthread_t pthread_self(void);
</PRE>
<P>
<B>Description:</B>
A thread may obtain a copy of its own thread handle.
<P>
<B>Input Parameters:</B>
<P>
<UL>
<LI><I>parm</I> 
</UL>
<P>
<B>Returned Values:</B>
<P>
If successful, the <I>xxx()</I> function will return
zero (<I>OK</I>).  Otherwise, an error number will be
returned to indicate the error:
<P>
<UL>
<LI><I>Exxx</I>.
</UL>
<B>Assumptions/Limitations:</B>
<P>
<B>POSIX Compatibility:</B> Comparable to the POSIX
interface of the same name.

patacongo's avatar
patacongo committed
<H3><a name="pthreadgetschedparam">2.8.20 pthread_getschedparam</A></H3>
patacongo's avatar
patacongo committed
<P>
<B>Function Prototype:</B>
<P>
<PRE>
    #include &lt;pthread.h&gt;
    int pthread_getschedparam(pthread_t thread, int *policy,
				 struct sched_param *param);
</PRE>
<P>
<B>Description:</B>
<P>
<B>Input Parameters:</B>
<P>
<UL>
<LI><I>parm</I> 
</UL>
<P>
<B>Returned Values:</B>
<P>
If successful, the <I>xxx()</I> function will return
zero (<I>OK</I>).  Otherwise, an error number will be
returned to indicate the error:
<P>
<UL>
<LI><I>Exxx</I>.
</UL>
<B>Assumptions/Limitations:</B>
<P>
<B>POSIX Compatibility:</B> Comparable to the POSIX
interface of the same name.

patacongo's avatar
patacongo committed
<H3><a name="pthreadsetschedparam">2.8.21 pthread_setschedparam</A></H3>
patacongo's avatar
patacongo committed
<P>
<B>Function Prototype:</B>
<P>
<PRE>
    #include &lt;pthread.h&gt;
    int pthread_setschedparam(pthread_t thread, int policy,
				 const struct sched_param *param);
</PRE>
<P>
<B>Description:</B>
<P>
<B>Input Parameters:</B>
<P>
<UL>
<LI><I>parm</I> 
</UL>
<P>
<B>Returned Values:</B>
<P>
If successful, the <I>xxx()</I> function will return
zero (<I>OK</I>).  Otherwise, an error number will be
returned to indicate the error:
<P>
<UL>
<LI><I>Exxx</I>.
</UL>
<B>Assumptions/Limitations:</B>
<P>
<B>POSIX Compatibility:</B> Comparable to the POSIX
interface of the same name.

patacongo's avatar
patacongo committed
<H3><a name="pthreadkeycreate">2.8.22 pthread_key_create</A></H3>
patacongo's avatar
patacongo committed
<P>
<B>Function Prototype:</B>
<P>
<PRE>
    #include &lt;pthread.h&gt;
    int pthread_key_create( pthread_key_t *key, void (*destructor)(void*) )
</PRE>
<P>
<B>Description:</B>
<P>
This function creates a thread-specific data key visible
to all threads in the system.  Although the same key value
may be used by different threads, the values bound to
the key by <I>pthread_setspecific()</I> are maintained on a
per-thread basis and persist for the life of the calling
thread.
<P>
Upon key creation, the value <I>NULL</I> will be associated with
the the new key in all active threads.  Upon thread
creation, the value <I>NULL</I> will be associated with all
defined keys in the new thread.
<P>
<B>Input Parameters:</B>
<P>
<UL>
<LI><I>key</I> is a pointer to the key to create.
<LI><I>destructor</I> is an optional destructor() function that may
be associated with each key that is invoked when a
thread exits.  However, this argument is ignored in
the current implementation.
</UL>
<P>
<B>Returned Values:</B>
<P>
If successful, the <I>pthread_key_create()</I> function will
store the newly created key value at *<I>key</I> and return
zero (<I>OK</I>).  Otherwise, an error number will be
returned to indicate the error:
<P>
<UL>
<LI><I>EAGAIN</I>.  The system lacked sufficient resources
to create another thread-specific data key, or the
system-imposed limit on the total number of keys
per task {<I>PTHREAD_KEYS_MAX</I>} has been exceeded
<LI><I>ENONMEM</I>  Insufficient memory exists to create the key.
</UL>
<B>Assumptions/Limitations:</B>
<P>
<B>POSIX Compatibility:</B> Comparable to the POSIX
interface of the same name.
<UL>
<LI>The present implementation ignores the destructor argument.
</UL>

patacongo's avatar
patacongo committed
<H3><a name="pthreadsetspecific">2.8.23 pthread_setspecific</A></H3>
patacongo's avatar
patacongo committed
<P>
<B>Function Prototype:</B>
<P>
<PRE>
    #include &lt;pthread.h&gt;
    int pthread_setspecific( pthread_key_t key, void *value )
</PRE>
<P>
<B>Description:</B>
<P>
The <I>pthread_setspecific()</I> function associates a thread-
specific value with a key obtained via a previous call
to <I>pthread_key_create()</I>.  Different threads may bind
different values to the same key.  These values are
typically pointers to blocks of dynamically allocated
memory that have been reserved for use by the calling
thread.
<P>
The effect of calling <I>pthread_setspecific()</I> with a key value
not obtained from <I>pthread_key_create()</I> or after a key has been
deleted with <I>pthread_key_delete()</I> is undefined.
<P>
<B>Input Parameters:</B>
<P>
<UL>
<LI><I>key</I>.  The data key to set the binding for.
<LI><I>value</I>. The value to bind to the key.
</UL>
<P>
<B>Returned Values:</B>
<P>
If successful, <I>pthread_setspecific()</I> will return zero (<I>OK</I>).
Otherwise, an error number will be returned:
<P>
<UL>
<LI><I>ENOMEM</I>.  Insufficient memory exists to associate the value
with the key.
<LI><I>EINVAL</I>.  The key value is invalid.
</UL>
<P>
<B>Assumptions/Limitations:</B>
<P>
<B>POSIX Compatibility:</B> Comparable to the POSIX
interface of the same name.
<UL>
<LI>pthread_setspecific() may be called from a thread-specific data
destructor function.
</UL>

patacongo's avatar
patacongo committed
<H3><a name="pthreadgetspecific">2.8.24 pthread_getspecific</A></H3>
patacongo's avatar
patacongo committed
<P>
<B>Function Prototype:</B>
<P>
<PRE>
    #include &lt;pthread.h&gt;
    void *pthread_getspecific( pthread_key_t key )
</PRE>
<P>
<B>Description:</B>
<P>
The <I>pthread_getspecific()</I> function returns the value
currently bound to the specified key on behalf of the
calling thread.
<P>
The effect of calling <I>pthread_getspecific()</I> with a key value
not obtained from <I>pthread_key_create()</I> or after a key has been
deleted with <I>pthread_key_delete()</I> is undefined.
<P>
<B>Input Parameters:</B>
<P>
<UL>
<LI><I>key</I>.  The data key to get the binding for.
</UL>
<P>
<B>Returned Values:</B>
<P>
The function <I>pthread_getspecific()</I> returns the thread-
specific data associated with the given key.  If no
thread specific data is associated with the key, then
the value <I>NULL</I> is returned.
<P>
<B>Assumptions/Limitations:</B>
<P>
<B>POSIX Compatibility:</B> Comparable to the POSIX
interface of the same name.
<UL>
<LI>pthread_getspecific() may be called from a thread-specific data
destructor function.
</UL>

patacongo's avatar
patacongo committed
<H3><a name="pthreadkeydelete">2.8.25 pthread_key_delete</A></H3>
patacongo's avatar
patacongo committed
<P>
<B>Function Prototype:</B>
<P>
<PRE>
    #include &lt;pthread.h&gt;
    int pthread_key_delete( pthread_key_t key )
</PRE>
<P>
<B>Description:</B>
<P>
This POSIX function should delete a thread-specific data
key previously returned by <I>pthread_key_create()</I>.  However,
this function does nothing in the present implementation.
<P>
<B>Input Parameters:</B>
<P>
<UL>
<LI><I>key</I>.  The key to delete
</UL>
<P>
<B>Returned Values:</B>
<P>
<UL>
<LI>Always returns <I>EINVAL</I>.
</UL>
<P>
<B>Assumptions/Limitations:</B>
<P>
<B>POSIX Compatibility:</B> Comparable to the POSIX
interface of the same name.

patacongo's avatar
patacongo committed
<H3><a name="pthreadmutexattrinit">2.8.26 pthread_mutexattr_init</A></H3>
patacongo's avatar
patacongo committed
<P>
<B>Function Prototype:</B>
<P>
<PRE>
    #include &lt;pthread.h&gt;
    int pthread_mutexattr_init(pthread_mutexattr_t *attr);
</PRE>
<P>
<B>Description:</B>
<P>
<B>Input Parameters:</B>
<P>
<UL>
<LI><I>parm</I> 
</UL>
<P>
<B>Returned Values:</B>
<P>
If successful, the <I>xxx()</I> function will return
zero (<I>OK</I>).  Otherwise, an error number will be
returned to indicate the error:
<P>
<UL>
<LI><I>Exxx</I>.
</UL>
<B>Assumptions/Limitations:</B>
<P>
<B>POSIX Compatibility:</B> Comparable to the POSIX
interface of the same name.

patacongo's avatar
patacongo committed
<H3><a name="pthreadmutexattrdestroy">2.8.27 pthread_mutexattr_destroy</A></H3>
patacongo's avatar
patacongo committed
<P>
<B>Function Protoype:</B>
<P>
<PRE>
    #include &lt;pthread.h&gt;
    int pthread_mutexattr_destroy(pthread_mutexattr_t *attr);
</PRE>
<P>
<B>Description:</B>
<P>
<B>Input Parameters:</B>
<P>
<UL>
<LI><I>parm</I> 
</UL>
<P>
<B>Returned Values:</B>
<P>
If successful, the <I>xxx()</I> function will return
zero (<I>OK</I>).  Otherwise, an error number will be
returned to indicate the error:
<P>
<UL>
<LI><I>Exxx</I>.
</UL>
<B>Assumptions/Limitations:</B>
<P>
<B>POSIX Compatibility:</B> Comparable to the POSIX
interface of the same name.

patacongo's avatar
patacongo committed
<H3><a name="pthreadmutexattrgetpshared">2.8.28 pthread_mutexattr_getpshared</A></H3>
patacongo's avatar
patacongo committed
<P>
<B>Function Prototype:</B>
<P>
<PRE>
    #include &lt;pthread.h&gt;
    int pthread_mutexattr_getpshared(pthread_mutexattr_t *attr,
					int *pshared);
</PRE>
<P>
<B>Description:</B>
<P>
<B>Input Parameters:</B>
<P>
<UL>
<LI><I>parm</I> 
</UL>
<P>
<B>Returned Values:</B>
<P>
If successful, the <I>xxx()</I> function will return
zero (<I>OK</I>).  Otherwise, an error number will be
returned to indicate the error:
<P>
<UL>
<LI><I>Exxx</I>.
</UL>
<B>Assumptions/Limitations:</B>
<P>
<B>POSIX Compatibility:</B> Comparable to the POSIX
interface of the same name.

patacongo's avatar
patacongo committed
<H3><a name="pthreadmutexattrsetpshared">2.8.29 pthread_mutexattr_setpshared</A></H3>
patacongo's avatar
patacongo committed
<P>
<B>Function Prototype:</B>
<P>
<PRE>
    #include &lt;pthread.h&gt;
   int pthread_mutexattr_setpshared(pthread_mutexattr_t *attr,
					int pshared);
</PRE>
<P>
<B>Description:</B>
<P>
<B>Input Parameters:</B>
<P>
<UL>
<LI><I>parm</I> 
</UL>
<P>
<B>Returned Values:</B>
<P>
If successful, the <I>xxx()</I> function will return
zero (<I>OK</I>).  Otherwise, an error number will be
returned to indicate the error:
<P>
<UL>
<LI><I>Exxx</I>.
</UL>
<B>Assumptions/Limitations:</B>
<P>
<B>POSIX Compatibility:</B> Comparable to the POSIX
interface of the same name.

patacongo's avatar
patacongo committed
<H3><a name="pthreadmutexinit">2.8.30 pthread_mutex_init</A></H3>
patacongo's avatar
patacongo committed
<P>
<B>Function Prototype:</B>
<P>
<PRE>
    #include &lt;pthread.h&gt;
    int pthread_mutex_init(pthread_mutex_t *mutex,
			      pthread_mutexattr_t *attr);
</PRE>
<P>
<B>Description:</B>
<P>
<B>Input Parameters:</B>
<P>
<UL>
<LI><I>parm</I> 
</UL>
<P>
<B>Returned Values:</B>
<P>
If successful, the <I>xxx()</I> function will return
zero (<I>OK</I>).  Otherwise, an error number will be
returned to indicate the error:
<P>
<UL>
<LI><I>Exxx</I>.
</UL>
<B>Assumptions/Limitations:</B>
<P>
<B>POSIX Compatibility:</B> Comparable to the POSIX
interface of the same name.

patacongo's avatar
patacongo committed
<H3><a name="pthreadmutexdestrory">2.8.31 pthread_mutex_destroy</A></H3>
patacongo's avatar
patacongo committed
<P>
<B>Function Prototype:</B>
<P>
<PRE>
    #include &lt;pthread.h&gt;
    int pthread_mutex_destroy(pthread_mutex_t *mutex);
</PRE>
<P>
<B>Description:</B>
<P>
<B>Input Parameters:</B>
<P>
<UL>
<LI><I>parm</I> 
</UL>
<P>
<B>Returned Values:</B>
<P>
If successful, the <I>xxx()</I> function will return
zero (<I>OK</I>).  Otherwise, an error number will be
returned to indicate the error:
<P>
<UL>
<LI><I>Exxx</I>.
</UL>
<B>Assumptions/Limitations:</B>
<P>
<B>POSIX Compatibility:</B> Comparable to the POSIX
interface of the same name.

patacongo's avatar
patacongo committed
<H3><a name="pthreadmutexlock">2.8.32 pthread_mutex_lock</A></H3>
patacongo's avatar
patacongo committed
<P>
<B>Function Prototype:</B>
<P>
<PRE>
    #include &lt;pthread.h&gt;
    int pthread_mutex_lock(pthread_mutex_t *mutex);
</PRE>
<P>
<B>Description:</B>
<P>
<B>Input Parameters:</B>
<P>
<UL>
<LI><I>parm</I> 
</UL>
<P>
<B>Returned Values:</B>
<P>
If successful, the <I>xxx()</I> function will return
zero (<I>OK</I>).  Otherwise, an error number will be
returned to indicate the error:
<P>
<UL>
<LI><I>Exxx</I>.
</UL>
<B>Assumptions/Limitations:</B>
<P>
<B>POSIX Compatibility:</B> Comparable to the POSIX
interface of the same name.

patacongo's avatar
patacongo committed
<H3><a name="pthreadmutextrylock">2.8.33 pthread_mutex_trylock</A></H3>
patacongo's avatar
patacongo committed
<P>
<B>Function Prototype:</B>
<P>
<PRE>
    #include &lt;pthread.h&gt;
    int pthread_mutex_trylock(pthread_mutex_t *mutex);
</PRE>
<P>
<B>Description:</B>
<P>
<B>Input Parameters:</B>
<P>
<UL>
<LI><I>parm</I> 
</UL>
<P>
<B>Returned Values:</B>
<P>
If successful, the <I>xxx()</I> function will return
zero (<I>OK</I>).  Otherwise, an error number will be
returned to indicate the error:
<P>
<UL>
<LI><I>Exxx</I>.
</UL>
<B>Assumptions/Limitations:</B>
<P>
<B>POSIX Compatibility:</B> Comparable to the POSIX
interface of the same name.

patacongo's avatar
patacongo committed
<H3><a name="pthreadmutexunlock">2.8.34 pthread_mutex_unlock</A></H3>
patacongo's avatar
patacongo committed
<P>
<B>Function Prototype:</B>
<P>
<PRE>
    #include &lt;pthread.h&gt;
    int pthread_mutex_unlock(pthread_mutex_t *mutex);
</PRE>
<P>
<B>Description:</B>
<P>
<B>Input Parameters:</B>
<P>
<UL>
<LI><I>parm</I> 
</UL>
<P>
<B>Returned Values:</B>
<P>
If successful, the <I>xxx()</I> function will return
zero (<I>OK</I>).  Otherwise, an error number will be
returned to indicate the error:
<P>
<UL>
<LI><I>Exxx</I>.
</UL>
<B>Assumptions/Limitations:</B>
<P>
<B>POSIX Compatibility:</B> Comparable to the POSIX
interface of the same name.

patacongo's avatar
patacongo committed
<H3><a name="pthreadconaddrinit">2.8.35 pthread_condattr_init</A></H3>
patacongo's avatar
patacongo committed
<P>
<B>Function Prototype:</B>
<P>
<PRE>
    #include &lt;pthread.h&gt;
    int pthread_condattr_init(pthread_condattr_t *attr);
</PRE>
<P>
<B>Description:</B>
<P>
<B>Input Parameters:</B>
<P>
<UL>
<LI><I>parm</I> 
</UL>
<P>
<B>Returned Values:</B>
<P>
If successful, the <I>xxx()</I> function will return
zero (<I>OK</I>).  Otherwise, an error number will be
returned to indicate the error:
<P>
<UL>
<LI><I>Exxx</I>.
</UL>
<B>Assumptions/Limitations:</B>
<P>
<B>POSIX Compatibility:</B> Comparable to the POSIX
interface of the same name.

patacongo's avatar
patacongo committed
<H3><a name="pthreadocndattrdestroy">2.8.36 pthread_condattr_destroy</A></H3>
patacongo's avatar
patacongo committed
<P>
<B>Function Prototype:</B>
<P>
<PRE>
    #include &lt;pthread.h&gt;
    int pthread_condattr_destroy(pthread_condattr_t *attr);
</PRE>
<P>
<B>Description:</B>
<P>
<B>Input Parameters:</B>
<P>
<UL>
<LI><I>parm</I> 
</UL>
<P>
<B>Returned Values:</B>
<P>
If successful, the <I>xxx()</I> function will return
zero (<I>OK</I>).  Otherwise, an error number will be
returned to indicate the error:
<P>
<UL>
<LI><I>Exxx</I>.
</UL>
<B>Assumptions/Limitations:</B>
<P>
<B>POSIX Compatibility:</B> Comparable to the POSIX
interface of the same name.

patacongo's avatar
patacongo committed
<H3><a name="pthreadcondinit">2.8.37 pthread_cond_init</A></H3>
patacongo's avatar
patacongo committed
<P>
<B>Function Prototype:</B>
<P>
<PRE>
    #include &lt;pthread.h&gt;
    int pthread_cond_init(pthread_cond_t *cond, pthread_condattr_t *attr);
</PRE>
<P>
<B>Description:</B>
<P>
<B>Input Parameters:</B>
<P>
<UL>
<LI><I>parm</I> 
</UL>
<P>
<B>Returned Values:</B>
<P>
If successful, the <I>xxx()</I> function will return
zero (<I>OK</I>).  Otherwise, an error number will be
returned to indicate the error:
<P>
<UL>
<LI><I>Exxx</I>.
</UL>
<B>Assumptions/Limitations:</B>
<P>
<B>POSIX Compatibility:</B> Comparable to the POSIX
interface of the same name.

patacongo's avatar
patacongo committed
<H3><a name="pthreadconddestroy">2.8.38 pthread_cond_destroy</A></H3>
patacongo's avatar
patacongo committed
<P>
<B>Function Prototype:</B>
<P>
<PRE>
    #include &lt;pthread.h&gt;
    int pthread_cond_destroy(pthread_cond_t *cond);
</PRE>
<P>
<B>Description:</B>
<P>
<B>Input Parameters:</B>
<P>
<UL>
<LI><I>parm</I> 
</UL>
<P>
<B>Returned Values:</B>
<P>
If successful, the <I>xxx()</I> function will return
zero (<I>OK</I>).  Otherwise, an error number will be
returned to indicate the error:
<P>
<UL>
<LI><I>Exxx</I>.
</UL>
<B>Assumptions/Limitations:</B>
<P>
<B>POSIX Compatibility:</B> Comparable to the POSIX
interface of the same name.

patacongo's avatar
patacongo committed
<H3><a name="pthreadcondbroadcast">2.8.39 pthread_cond_broadcast</A></H3>
patacongo's avatar
patacongo committed
<P>
<B>Function Prototype:</B>
<P>
<PRE>
    #include &lt;pthread.h&gt;
    int pthread_cond_broadcast(pthread_cond_t *cond);
</PRE>
<P>
<B>Description:</B>
<P>
<B>Input Parameters:</B>
<P>
<UL>
<LI><I>parm</I> 
</UL>
<P>
<B>Returned Values:</B>
<P>
If successful, the <I>xxx()</I> function will return
zero (<I>OK</I>).  Otherwise, an error number will be
returned to indicate the error:
<P>