The Design and Implementation of the FreeBSD Operating System, Second Edition
Now available: The Design and Implementation of the FreeBSD Operating System (Second Edition)


[ source navigation ] [ diff markup ] [ identifier search ] [ freetext search ] [ file search ] [ list types ] [ track identifier ]

FreeBSD/Linux Kernel Cross Reference
sys/sys/_pthreadtypes.h

Version: -  FREEBSD  -  FREEBSD-12-STABLE  -  FREEBSD-12-0  -  FREEBSD-11-STABLE  -  FREEBSD-11-2  -  FREEBSD-11-1  -  FREEBSD-11-0  -  FREEBSD-10-STABLE  -  FREEBSD-10-4  -  FREEBSD-10-3  -  FREEBSD-10-2  -  FREEBSD-10-1  -  FREEBSD-10-0  -  FREEBSD-9-STABLE  -  FREEBSD-9-3  -  FREEBSD-9-2  -  FREEBSD-9-1  -  FREEBSD-9-0  -  FREEBSD-8-STABLE  -  FREEBSD-8-4  -  FREEBSD-8-3  -  FREEBSD-8-2  -  FREEBSD-8-1  -  FREEBSD-8-0  -  FREEBSD-7-STABLE  -  FREEBSD-7-4  -  FREEBSD-7-3  -  FREEBSD-7-2  -  FREEBSD-7-1  -  FREEBSD-7-0  -  FREEBSD-6-STABLE  -  FREEBSD-6-4  -  FREEBSD-6-3  -  FREEBSD-6-2  -  FREEBSD-6-1  -  FREEBSD-6-0  -  FREEBSD-5-STABLE  -  FREEBSD-5-5  -  FREEBSD-5-4  -  FREEBSD-5-3  -  FREEBSD-5-2  -  FREEBSD-5-1  -  FREEBSD-5-0  -  FREEBSD-4-STABLE  -  FREEBSD-3-STABLE  -  FREEBSD22  -  linux-2.6  -  linux-2.4.22  -  MK83  -  MK84  -  PLAN9  -  DFBSD  -  NETBSD  -  NETBSD5  -  NETBSD4  -  NETBSD3  -  NETBSD20  -  OPENBSD  -  xnu-517  -  xnu-792  -  xnu-792.6.70  -  xnu-1228  -  xnu-1456.1.26  -  xnu-1699.24.8  -  xnu-2050.18.24  -  OPENSOLARIS  -  minix-3-1-1 
SearchContext: -  none  -  3  -  10 

    1 /*-
    2  * SPDX-License-Identifier: BSD-3-Clause
    3  *
    4  * Copyright (c) 1993, 1994 by Chris Provenzano, proven@mit.edu
    5  * Copyright (c) 1995-1998 by John Birrell <jb@cimlogic.com.au>
    6  * All rights reserved.
    7  *
    8  * Redistribution and use in source and binary forms, with or without
    9  * modification, are permitted provided that the following conditions
   10  * are met:
   11  * 1. Redistributions of source code must retain the above copyright
   12  *    notice, this list of conditions and the following disclaimer.
   13  * 2. Redistributions in binary form must reproduce the above copyright
   14  *    notice, this list of conditions and the following disclaimer in the
   15  *    documentation and/or other materials provided with the distribution.
   16  * 3. All advertising materials mentioning features or use of this software
   17  *    must display the following acknowledgement:
   18  *  This product includes software developed by Chris Provenzano.
   19  * 4. The name of Chris Provenzano may not be used to endorse or promote 
   20  *        products derived from this software without specific prior written
   21  *        permission.
   22  *
   23  * THIS SOFTWARE IS PROVIDED BY CHRIS PROVENZANO ``AS IS'' AND
   24  * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
   25  * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
   26  * ARE DISCLAIMED.  IN NO EVENT SHALL CHRIS PROVENZANO BE LIABLE FOR ANY 
   27  * DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
   28  * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR 
   29  * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER
   30  * CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 
   31  * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
   32  * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF 
   33  * SUCH DAMAGE.
   34  *
   35  * $FreeBSD: stable/12/sys/sys/_pthreadtypes.h 326256 2017-11-27 15:01:59Z pfg $
   36  */
   37 
   38 #ifndef _SYS__PTHREADTYPES_H_
   39 #define _SYS__PTHREADTYPES_H_
   40 
   41 /*
   42  * Forward structure definitions.
   43  *
   44  * These are mostly opaque to the user.
   45  */
   46 struct pthread;
   47 struct pthread_attr;
   48 struct pthread_cond;
   49 struct pthread_cond_attr;
   50 struct pthread_mutex;
   51 struct pthread_mutex_attr;
   52 struct pthread_once;
   53 struct pthread_rwlock;
   54 struct pthread_rwlockattr;
   55 struct pthread_barrier;
   56 struct pthread_barrier_attr;
   57 struct pthread_spinlock;
   58 
   59 /*
   60  * Primitive system data type definitions required by P1003.1c.
   61  *
   62  * Note that P1003.1c specifies that there are no defined comparison
   63  * or assignment operators for the types pthread_attr_t, pthread_cond_t,
   64  * pthread_condattr_t, pthread_mutex_t, pthread_mutexattr_t.
   65  */
   66 #ifndef _PTHREAD_T_DECLARED
   67 typedef struct  pthread                 *pthread_t;
   68 #define _PTHREAD_T_DECLARED
   69 #endif
   70 typedef struct  pthread_attr            *pthread_attr_t;
   71 typedef struct  pthread_mutex           *pthread_mutex_t;
   72 typedef struct  pthread_mutex_attr      *pthread_mutexattr_t;
   73 typedef struct  pthread_cond            *pthread_cond_t;
   74 typedef struct  pthread_cond_attr       *pthread_condattr_t;
   75 typedef int                             pthread_key_t;
   76 typedef struct  pthread_once            pthread_once_t;
   77 typedef struct  pthread_rwlock          *pthread_rwlock_t;
   78 typedef struct  pthread_rwlockattr      *pthread_rwlockattr_t;
   79 typedef struct  pthread_barrier         *pthread_barrier_t;
   80 typedef struct  pthread_barrierattr     *pthread_barrierattr_t;
   81 typedef struct  pthread_spinlock        *pthread_spinlock_t;
   82 
   83 /*
   84  * Additional type definitions:
   85  *
   86  * Note that P1003.1c reserves the prefixes pthread_ and PTHREAD_ for
   87  * use in header symbols.
   88  */
   89 typedef void    *pthread_addr_t;
   90 typedef void    *(*pthread_startroutine_t)(void *);
   91 
   92 /*
   93  * Once definitions.
   94  */
   95 struct pthread_once {
   96         int             state;
   97         pthread_mutex_t mutex;
   98 };
   99 
  100 #endif /* ! _SYS__PTHREADTYPES_H_ */

Cache object: d008be0fb76268c3953291ca1ce53473


[ source navigation ] [ diff markup ] [ identifier search ] [ freetext search ] [ file search ] [ list types ] [ track identifier ]


This page is part of the FreeBSD/Linux Linux Kernel Cross-Reference, and was automatically generated using a modified version of the LXR engine.