EPICS Base  7.0.6.1
 All Classes Files Functions Variables Typedefs Enumerations Enumerator Macros Groups Pages
dbLock.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 /* dbLock.h */
11 /* Author: Marty Kraimer Date: 12MAR96 */
12 
13 #ifndef INCdbLockh
14 #define INCdbLockh
15 
16 #include <stddef.h>
17 
18 #include "ellLib.h"
19 #include "dbCoreAPI.h"
20 
21 #ifdef __cplusplus
22 extern "C" {
23 #endif
24 
25 struct dbCommon;
26 struct dbBase;
27 typedef struct dbLocker dbLocker;
28 
29 DBCORE_API void dbScanLock(struct dbCommon *precord);
30 DBCORE_API void dbScanUnlock(struct dbCommon *precord);
31 
32 DBCORE_API dbLocker *dbLockerAlloc(struct dbCommon * const *precs,
33  size_t nrecs,
34  unsigned int flags);
35 
36 DBCORE_API void dbLockerFree(dbLocker *);
37 
38 DBCORE_API void dbScanLockMany(dbLocker*);
39 DBCORE_API void dbScanUnlockMany(dbLocker*);
40 
41 DBCORE_API unsigned long dbLockGetLockId(
42  struct dbCommon *precord);
43 
44 DBCORE_API void dbLockInitRecords(struct dbBase *pdbbase);
45 DBCORE_API void dbLockCleanupRecords(struct dbBase *pdbbase);
46 
47 
48 /* Lock Set Report */
49 DBCORE_API long dblsr(char *recordname,int level);
50 /* If recordname NULL then all records*/
51 /* level = (0,1,2) (lock set state, + recordname, +DB links) */
52 
53 DBCORE_API long dbLockShowLocked(int level);
54 
55 /*KLUDGE to support field TPRO*/
56 DBCORE_API int * dbLockSetAddrTrace(struct dbCommon *precord);
57 
58 /* debugging */
59 DBCORE_API unsigned long dbLockGetRefs(struct dbCommon*);
60 DBCORE_API unsigned long dbLockCountSets(void);
61 
62 #ifdef __cplusplus
63 }
64 #endif
65 
66 #endif /*INCdbLockh*/
Declaration of dbCommon.
Definition: dbCommon.h:18
A doubly-linked list library.
Definition: dbBase.h:171