EPICS Base  7.0.6.1
 All Classes Files Functions Variables Typedefs Enumerations Enumerator Macros Groups Pages
osdThread.h
1 /*************************************************************************\
2 * Copyright (c) 2002 The University of Chicago, as Operator of Argonne
3 * National Laboratory.
4 * Copyright (c) 2002 The Regents of the University of California, as
5 * Operator of Los Alamos National Laboratory.
6 * SPDX-License-Identifier: EPICS
7 * EPICS BASE is distributed subject to a Software License Agreement found
8 * in file LICENSE that is included with this distribution.
9 \*************************************************************************/
10 #ifndef INC_osdThread_H
11 #define INC_osdThread_H
12 
13 #include <pthread.h>
14 #include <sys/types.h>
15 
16 #include "libComAPI.h"
17 #include "ellLib.h"
18 #include "epicsEvent.h"
19 
20 #ifdef __cplusplus
21 extern "C" {
22 #endif
23 
24 typedef struct epicsThreadOSD {
25  ELLNODE node;
26  int refcnt;
27  pthread_t tid;
28  pid_t lwpId;
29  pthread_attr_t attr;
30  struct sched_param schedParam;
31  int schedPolicy;
32  EPICSTHREADFUNC createFunc;
33  void *createArg;
34  epicsEventId suspendEvent;
35  int isSuspended;
36  int isEpicsThread;
37  int isRealTimeScheduled;
38  int isOnThreadList;
39  unsigned int osiPriority;
40  int joinable;
41  char name[1]; /* actually larger */
43 
44 LIBCOM_API pthread_t epicsThreadGetPosixThreadId(epicsThreadId id);
45 LIBCOM_API int epicsThreadGetPosixPriority(epicsThreadId id);
46 
47 #ifdef __cplusplus
48 }
49 #endif
50 
51 #endif /* INC_osdThread_H */
List node type.
Definition: ellLib.h:46
APIs for the epicsEvent binary semaphore.
A doubly-linked list library.
struct epicsEventOSD * epicsEventId
An identifier for an epicsEvent for use with the C API.
Definition: epicsEvent.h:47