diff options
Diffstat (limited to 'src/include/storage')
-rw-r--r-- | src/include/storage/buf_internals.h | 6 | ||||
-rw-r--r-- | src/include/storage/bufmgr.h | 4 | ||||
-rw-r--r-- | src/include/storage/bufpage.h | 10 | ||||
-rw-r--r-- | src/include/storage/ipc.h | 20 | ||||
-rw-r--r-- | src/include/storage/itemid.h | 4 | ||||
-rw-r--r-- | src/include/storage/itemptr.h | 4 | ||||
-rw-r--r-- | src/include/storage/large_object.h | 14 | ||||
-rw-r--r-- | src/include/storage/lmgr.h | 8 | ||||
-rw-r--r-- | src/include/storage/lock.h | 30 | ||||
-rw-r--r-- | src/include/storage/proc.h | 20 | ||||
-rw-r--r-- | src/include/storage/shmem.h | 24 | ||||
-rw-r--r-- | src/include/storage/sinvaladt.h | 24 |
12 files changed, 84 insertions, 84 deletions
diff --git a/src/include/storage/buf_internals.h b/src/include/storage/buf_internals.h index be40014b0bc..b0d268be08a 100644 --- a/src/include/storage/buf_internals.h +++ b/src/include/storage/buf_internals.h @@ -6,7 +6,7 @@ * * Copyright (c) 1994, Regents of the University of California * - * $Id: buf_internals.h,v 1.17 1997/09/08 20:59:00 momjian Exp $ + * $Id: buf_internals.h,v 1.18 1997/09/08 21:54:14 momjian Exp $ * * NOTE * If BUFFERPAGE0 is defined, then 0 will be used as a @@ -212,7 +212,7 @@ extern void InitFreeList(bool init); /* buf_table.c */ extern void InitBufTable(void); -extern BufferDesc *BufTableLookup(BufferTag * tagPtr); +extern BufferDesc *BufTableLookup(BufferTag *tagPtr); extern bool BufTableDelete(BufferDesc *buf); extern bool BufTableInsert(BufferDesc *buf); @@ -231,7 +231,7 @@ extern int NLocBuffer; extern BufferDesc * LocalBufferAlloc(Relation reln, BlockNumber blockNum, - bool * foundPtr); + bool *foundPtr); extern int WriteLocalBuffer(Buffer buffer, bool release); extern int FlushLocalBuffer(Buffer buffer, bool release); extern void InitLocalBuffer(void); diff --git a/src/include/storage/bufmgr.h b/src/include/storage/bufmgr.h index 469eca4de28..e9afc2e7e12 100644 --- a/src/include/storage/bufmgr.h +++ b/src/include/storage/bufmgr.h @@ -6,7 +6,7 @@ * * Copyright (c) 1994, Regents of the University of California * - * $Id: bufmgr.h,v 1.14 1997/09/08 20:59:05 momjian Exp $ + * $Id: bufmgr.h,v 1.15 1997/09/08 21:54:18 momjian Exp $ * *------------------------------------------------------------------------- */ @@ -82,7 +82,7 @@ ReleaseAndReadBuffer(Buffer buffer, Relation relation, BlockNumber blockNum); extern void InitBufferPool(IPCKey key); -extern void PrintBufferUsage(FILE * statfp); +extern void PrintBufferUsage(FILE *statfp); extern void ResetBufferUsage(void); extern void ResetBufferPool(void); extern int BufferPoolCheckLeak(void); diff --git a/src/include/storage/bufpage.h b/src/include/storage/bufpage.h index 4b031746f0b..befb6b0849c 100644 --- a/src/include/storage/bufpage.h +++ b/src/include/storage/bufpage.h @@ -6,7 +6,7 @@ * * Copyright (c) 1994, Regents of the University of California * - * $Id: bufpage.h,v 1.12 1997/09/08 02:38:59 momjian Exp $ + * $Id: bufpage.h,v 1.13 1997/09/08 21:54:20 momjian Exp $ * *------------------------------------------------------------------------- */ @@ -102,7 +102,7 @@ typedef uint16 LocationIndex; typedef struct OpaqueData { uint16 od_pagesize; -} OpaqueData; +} OpaqueData; typedef OpaqueData *Opaque; @@ -117,7 +117,7 @@ typedef struct PageHeaderData LocationIndex pd_special; /* offset to start of special space */ OpaqueData pd_opaque; /* AM-generic information */ ItemIdData pd_linp[1]; /* line pointers */ -} PageHeaderData; +} PageHeaderData; typedef PageHeaderData *PageHeader; @@ -125,7 +125,7 @@ typedef enum { ShufflePageManagerMode, OverwritePageManagerMode -} PageManagerMode; +} PageManagerMode; /* ---------------- * misc support macros @@ -280,7 +280,7 @@ typedef enum */ extern void PageInit(Page page, Size pageSize, Size specialSize); -extern OffsetNumber +extern OffsetNumber PageAddItem(Page page, Item item, Size size, OffsetNumber offsetNumber, ItemIdFlags flags); extern Page PageGetTempPage(Page page, Size specialSize); diff --git a/src/include/storage/ipc.h b/src/include/storage/ipc.h index e75a26c0454..b62387b668e 100644 --- a/src/include/storage/ipc.h +++ b/src/include/storage/ipc.h @@ -6,7 +6,7 @@ * * Copyright (c) 1994, Regents of the University of California * - * $Id: ipc.h,v 1.19 1997/09/08 02:39:01 momjian Exp $ + * $Id: ipc.h,v 1.20 1997/09/08 21:54:21 momjian Exp $ * * NOTES * This file is very architecture-specific. This stuff should actually @@ -28,15 +28,15 @@ #if defined(HAS_TEST_AND_SET) -extern void S_LOCK(slock_t * lock); -extern void S_UNLOCK(slock_t * lock); -extern void S_INIT_LOCK(slock_t * lock); +extern void S_LOCK(slock_t *lock); +extern void S_UNLOCK(slock_t *lock); +extern void S_INIT_LOCK(slock_t *lock); #if (defined(alpha) && !defined(linuxalpha)) || \ defined(hpux) || \ defined(irix5) || \ defined(nextstep) -extern int S_LOCK_FREE(slock_t * lock); +extern int S_LOCK_FREE(slock_t *lock); #else #define S_LOCK_FREE(lock) ((*lock) == 0) @@ -93,7 +93,7 @@ extern void exitpg(int code); extern void quasi_exitpg(void); extern int on_exitpg(void (*function) (), caddr_t arg); -extern IpcSemaphoreId +extern IpcSemaphoreId IpcSemaphoreCreate(IpcSemaphoreKey semKey, int semNum, int permission, int semStartValue, int removeOnExit, int *status); @@ -102,7 +102,7 @@ extern void IpcSemaphoreLock(IpcSemaphoreId semId, int sem, int lock); extern void IpcSemaphoreUnlock(IpcSemaphoreId semId, int sem, int lock); extern int IpcSemaphoreGetCount(IpcSemaphoreId semId, int sem); extern int IpcSemaphoreGetValue(IpcSemaphoreId semId, int sem); -extern IpcMemoryId +extern IpcMemoryId IpcMemoryCreate(IpcMemoryKey memKey, uint32 size, int permission); extern IpcMemoryId IpcMemoryIdGet(IpcMemoryKey memKey, uint32 size); @@ -135,7 +135,7 @@ typedef enum _LockId_ PROCSTRUCTLOCKID, FIRSTFREELOCKID -} _LockId_; +} _LockId_; #define MAX_SPINS FIRSTFREELOCKID @@ -148,7 +148,7 @@ typedef struct slock slock_t exlock; slock_t comlock; struct slock *next; -} SLock; +} SLock; extern void ExclusiveLock(int lockid); extern void ExclusiveUnlock(int lockid); @@ -171,7 +171,7 @@ typedef enum _LockId_ PROCSTRUCTLOCKID, OIDGENLOCKID, FIRSTFREELOCKID -} _LockId_; +} _LockId_; #define MAX_SPINS FIRSTFREELOCKID diff --git a/src/include/storage/itemid.h b/src/include/storage/itemid.h index 1c382fb1b9e..c6b0abc19bd 100644 --- a/src/include/storage/itemid.h +++ b/src/include/storage/itemid.h @@ -6,7 +6,7 @@ * * Copyright (c) 1994, Regents of the University of California * - * $Id: itemid.h,v 1.3 1997/09/08 02:39:02 momjian Exp $ + * $Id: itemid.h,v 1.4 1997/09/08 21:54:24 momjian Exp $ * *------------------------------------------------------------------------- */ @@ -26,7 +26,7 @@ typedef struct ItemIdData /* can be reduced by 2 if necc. */ lp_flags:6, /* flags on tuple */ lp_len:13; /* length of tuple */ -} ItemIdData; +} ItemIdData; typedef struct ItemIdData *ItemId; diff --git a/src/include/storage/itemptr.h b/src/include/storage/itemptr.h index b6156ca229c..5bac77c9fcc 100644 --- a/src/include/storage/itemptr.h +++ b/src/include/storage/itemptr.h @@ -6,7 +6,7 @@ * * Copyright (c) 1994, Regents of the University of California * - * $Id: itemptr.h,v 1.6 1997/09/08 02:39:03 momjian Exp $ + * $Id: itemptr.h,v 1.7 1997/09/08 21:54:25 momjian Exp $ * *------------------------------------------------------------------------- */ @@ -27,7 +27,7 @@ typedef struct ItemPointerData { BlockIdData ip_blkid; OffsetNumber ip_posid; -} ItemPointerData; +} ItemPointerData; typedef ItemPointerData *ItemPointer; diff --git a/src/include/storage/large_object.h b/src/include/storage/large_object.h index 710b1bac5c2..276792e19e2 100644 --- a/src/include/storage/large_object.h +++ b/src/include/storage/large_object.h @@ -7,7 +7,7 @@ * * Copyright (c) 1994, Regents of the University of California * - * $Id: large_object.h,v 1.6 1997/09/08 02:39:03 momjian Exp $ + * $Id: large_object.h,v 1.7 1997/09/08 21:54:29 momjian Exp $ * *------------------------------------------------------------------------- */ @@ -38,7 +38,7 @@ typedef struct LargeObjectDesc #define IFS_ATEOF (1 << 2) u_long flags; /* locking info, etc */ -} LargeObjectDesc; +} LargeObjectDesc; /* * Function definitions... @@ -47,11 +47,11 @@ typedef struct LargeObjectDesc /* inversion stuff in inv_api.c */ extern LargeObjectDesc *inv_create(int flags); extern LargeObjectDesc *inv_open(Oid lobjId, int flags); -extern void inv_close(LargeObjectDesc * obj_desc); +extern void inv_close(LargeObjectDesc *obj_desc); extern int inv_destroy(Oid lobjId); -extern int inv_seek(LargeObjectDesc * obj_desc, int offset, int whence); -extern int inv_tell(LargeObjectDesc * obj_desc); -extern int inv_read(LargeObjectDesc * obj_desc, char *buf, int nbytes); -extern int inv_write(LargeObjectDesc * obj_desc, char *buf, int nbytes); +extern int inv_seek(LargeObjectDesc *obj_desc, int offset, int whence); +extern int inv_tell(LargeObjectDesc *obj_desc); +extern int inv_read(LargeObjectDesc *obj_desc, char *buf, int nbytes); +extern int inv_write(LargeObjectDesc *obj_desc, char *buf, int nbytes); #endif /* LARGE_OBJECT_H */ diff --git a/src/include/storage/lmgr.h b/src/include/storage/lmgr.h index bd8d50f709f..2cfea514e10 100644 --- a/src/include/storage/lmgr.h +++ b/src/include/storage/lmgr.h @@ -6,7 +6,7 @@ * * Copyright (c) 1994, Regents of the University of California * - * $Id: lmgr.h,v 1.7 1997/09/08 02:39:04 momjian Exp $ + * $Id: lmgr.h,v 1.8 1997/09/08 21:54:30 momjian Exp $ * *------------------------------------------------------------------------- */ @@ -24,7 +24,7 @@ typedef struct LRelId { Oid relId; /* a relation identifier */ Oid dbId; /* a database identifier */ -} LRelId; +} LRelId; typedef struct LockInfoData { @@ -32,7 +32,7 @@ typedef struct LockInfoData LRelId lRelId; TransactionId transactionIdData; uint16 flags; -} LockInfoData; +} LockInfoData; typedef LockInfoData *LockInfo; #define LockInfoIsValid(linfo) \ @@ -73,7 +73,7 @@ extern void RelationUnsetWIntentLock(Relation relation); /* single.c */ extern bool SingleLockReln(LockInfo linfo, LOCKT lockt, int action); -extern bool +extern bool SingleLockPage(LockInfo linfo, ItemPointer tidPtr, LOCKT lockt, int action); diff --git a/src/include/storage/lock.h b/src/include/storage/lock.h index 89879575342..d7f9b20472e 100644 --- a/src/include/storage/lock.h +++ b/src/include/storage/lock.h @@ -6,7 +6,7 @@ * * Copyright (c) 1994, Regents of the University of California * - * $Id: lock.h,v 1.7 1997/09/08 02:39:05 momjian Exp $ + * $Id: lock.h,v 1.8 1997/09/08 21:54:31 momjian Exp $ * *------------------------------------------------------------------------- */ @@ -60,7 +60,7 @@ typedef struct ltag Oid relId; Oid dbId; ItemPointerData tupleId; -} LOCKTAG; +} LOCKTAG; #define TAGSIZE (sizeof(LOCKTAG)) @@ -91,7 +91,7 @@ typedef struct lockctl int conflictTab[MAX_LOCKTYPES]; int prio[MAX_LOCKTYPES]; SPINLOCK masterLock; -} LOCKCTL; +} LOCKCTL; /* * lockHash -- hash table on lock Ids, @@ -104,7 +104,7 @@ typedef struct ltable HTAB *lockHash; HTAB *xidHash; LOCKCTL *ctl; -} LOCKTAB; +} LOCKTAB; /* ----------------------- * A transaction never conflicts with its own locks. Hence, if @@ -140,7 +140,7 @@ typedef struct XIDTAG SHMEM_OFFSET lock; int pid; TransactionId xid; -} XIDTAG; +} XIDTAG; typedef struct XIDLookupEnt { @@ -151,7 +151,7 @@ typedef struct XIDLookupEnt int holders[MAX_LOCKTYPES]; int nHolding; SHM_QUEUE queue; -} XIDLookupEnt; +} XIDLookupEnt; #define XID_TAGSIZE (sizeof(XIDTAG)) @@ -160,7 +160,7 @@ typedef struct procQueue { SHM_QUEUE links; int size; -} PROC_QUEUE; +} PROC_QUEUE; /* @@ -186,7 +186,7 @@ typedef struct Lock int nHolding; int activeHolders[MAX_LOCKTYPES]; int nActive; -} LOCK; +} LOCK; #define LockGetLock_nHolders(l) l->nHolders @@ -204,16 +204,16 @@ extern SPINLOCK LockMgrLock; */ extern void InitLocks(void); extern void LockDisable(int status); -extern LockTableId -LockTabInit(char *tabName, MASK * conflictsP, int *prioP, +extern LockTableId +LockTabInit(char *tabName, MASK *conflictsP, int *prioP, int ntypes); -extern bool LockAcquire(LockTableId tableId, LOCKTAG * lockName, LOCKT lockt); +extern bool LockAcquire(LockTableId tableId, LOCKTAG *lockName, LOCKT lockt); extern int -LockResolveConflicts(LOCKTAB * ltable, LOCK * lock, LOCKT lockt, +LockResolveConflicts(LOCKTAB *ltable, LOCK *lock, LOCKT lockt, TransactionId xid); -extern bool LockRelease(LockTableId tableId, LOCKTAG * lockName, LOCKT lockt); -extern void GrantLock(LOCK * lock, LOCKT lockt); -extern bool LockReleaseAll(LockTableId tableId, SHM_QUEUE * lockQueue); +extern bool LockRelease(LockTableId tableId, LOCKTAG *lockName, LOCKT lockt); +extern void GrantLock(LOCK *lock, LOCKT lockt); +extern bool LockReleaseAll(LockTableId tableId, SHM_QUEUE *lockQueue); extern int LockShmemSize(void); extern bool LockingDisabled(void); diff --git a/src/include/storage/proc.h b/src/include/storage/proc.h index d8ea70918a7..5a7c85b0b1b 100644 --- a/src/include/storage/proc.h +++ b/src/include/storage/proc.h @@ -6,7 +6,7 @@ * * Copyright (c) 1994, Regents of the University of California * - * $Id: proc.h,v 1.7 1997/09/08 02:39:07 momjian Exp $ + * $Id: proc.h,v 1.8 1997/09/08 21:54:32 momjian Exp $ * *------------------------------------------------------------------------- */ @@ -21,7 +21,7 @@ typedef struct int semNum; IpcSemaphoreId semId; IpcSemaphoreKey semKey; -} SEMA; +} SEMA; /* * Each backend has: @@ -54,7 +54,7 @@ typedef struct proc short sLocks[MAX_SPINS]; /* Spin lock stats */ SHM_QUEUE lockQueue; /* locks associated with current * transaction */ -} PROC; +} PROC; /* @@ -72,7 +72,7 @@ typedef struct procglobal int numProcs; IPCKey currKey; int32 freeSemMap[MAX_PROC_SEMS / PROC_NSEMS_PER_SET]; -} PROC_HDR; +} PROC_HDR; extern PROC *MyProc; @@ -101,13 +101,13 @@ extern bool ProcRemove(int pid); /* extern bool ProcKill(int exitStatus, int pid); */ /* make static in storage/lmgr/proc.c -- jolly */ -extern void ProcQueueInit(PROC_QUEUE * queue); +extern void ProcQueueInit(PROC_QUEUE *queue); extern int -ProcSleep(PROC_QUEUE * queue, SPINLOCK spinlock, int token, - int prio, LOCK * lock); -extern int ProcLockWakeup(PROC_QUEUE * queue, char *ltable, char *lock); -extern void ProcAddLock(SHM_QUEUE * elem); -extern void ProcReleaseSpins(PROC * proc); +ProcSleep(PROC_QUEUE *queue, SPINLOCK spinlock, int token, + int prio, LOCK *lock); +extern int ProcLockWakeup(PROC_QUEUE *queue, char *ltable, char *lock); +extern void ProcAddLock(SHM_QUEUE *elem); +extern void ProcReleaseSpins(PROC *proc); extern void ProcFreeAllSemaphores(void); #endif /* PROC_H */ diff --git a/src/include/storage/shmem.h b/src/include/storage/shmem.h index a11783f91d0..168d4fb9693 100644 --- a/src/include/storage/shmem.h +++ b/src/include/storage/shmem.h @@ -6,7 +6,7 @@ * * Copyright (c) 1994, Regents of the University of California * - * $Id: shmem.h,v 1.8 1997/09/08 20:59:07 momjian Exp $ + * $Id: shmem.h,v 1.9 1997/09/08 21:54:33 momjian Exp $ * *------------------------------------------------------------------------- */ @@ -56,7 +56,7 @@ typedef struct SHM_QUEUE { SHMEM_OFFSET prev; SHMEM_OFFSET next; -} SHM_QUEUE; +} SHM_QUEUE; /* shmem.c */ extern void ShmemBindingTabReset(void); @@ -66,12 +66,12 @@ extern long *ShmemAlloc(unsigned long size); extern int ShmemIsValid(unsigned long addr); extern HTAB * ShmemInitHash(char *name, long init_size, long max_size, - HASHCTL * infoP, int hash_flags); -extern bool ShmemPIDLookup(int pid, SHMEM_OFFSET * locationPtr); + HASHCTL *infoP, int hash_flags); +extern bool ShmemPIDLookup(int pid, SHMEM_OFFSET *locationPtr); extern SHMEM_OFFSET ShmemPIDDestroy(int pid); extern long * ShmemInitStruct(char *name, unsigned long size, - bool * foundPtr); + bool *foundPtr); extern bool TransactionIdIsInProgress(TransactionId xid); @@ -96,13 +96,13 @@ typedef struct /* * prototypes for functions in shmqueue.c */ -extern void SHMQueueInit(SHM_QUEUE * queue); -extern void SHMQueueElemInit(SHM_QUEUE * queue); -extern void SHMQueueDelete(SHM_QUEUE * queue); -extern void SHMQueueInsertTL(SHM_QUEUE * queue, SHM_QUEUE * elem); +extern void SHMQueueInit(SHM_QUEUE *queue); +extern void SHMQueueElemInit(SHM_QUEUE *queue); +extern void SHMQueueDelete(SHM_QUEUE *queue); +extern void SHMQueueInsertTL(SHM_QUEUE *queue, SHM_QUEUE *elem); extern void -SHMQueueFirst(SHM_QUEUE * queue, Pointer * nextPtrPtr, - SHM_QUEUE * nextQueue); -extern bool SHMQueueEmpty(SHM_QUEUE * queue); +SHMQueueFirst(SHM_QUEUE *queue, Pointer *nextPtrPtr, + SHM_QUEUE *nextQueue); +extern bool SHMQueueEmpty(SHM_QUEUE *queue); #endif /* SHMEM_H */ diff --git a/src/include/storage/sinvaladt.h b/src/include/storage/sinvaladt.h index 1862cda616e..d499dc3b35f 100644 --- a/src/include/storage/sinvaladt.h +++ b/src/include/storage/sinvaladt.h @@ -6,7 +6,7 @@ * * Copyright (c) 1994, Regents of the University of California * - * $Id: sinvaladt.h,v 1.5 1997/09/08 02:39:13 momjian Exp $ + * $Id: sinvaladt.h,v 1.6 1997/09/08 21:54:34 momjian Exp $ * *------------------------------------------------------------------------- */ @@ -57,7 +57,7 @@ typedef struct ProcState bool resetState; /* true, if backend has to reset its state */ int tag; /* special tag, recieved from the * postmaster */ -} ProcState; +} ProcState; typedef struct SISeg @@ -74,7 +74,7 @@ typedef struct SISeg ProcState procState[MaxBackendId]; /* reflects the * invalidation state */ /* here starts the entry section, controlled by offsets */ -} SISeg; +} SISeg; #define SizeSISeg sizeof(SISeg) @@ -83,7 +83,7 @@ typedef struct SharedInvalidData int cacheId; /* XXX */ Index hashIndex; ItemPointerData pointerData; -} SharedInvalidData; +} SharedInvalidData; typedef SharedInvalidData *SharedInvalid; @@ -93,7 +93,7 @@ typedef struct SISegEntry SharedInvalidData entryData;/* the message data */ bool isfree; /* entry free? */ Offset next; /* offset to next entry */ -} SISegEntry; +} SISegEntry; #define SizeOfOneSISegEntry sizeof(SISegEntry) @@ -102,7 +102,7 @@ typedef struct SISegOffsets Offset startSegment; /* always 0 (for now) */ Offset offsetToFirstEntry; /* A + a = B */ Offset offsetToEndOfSegemnt; /* A + a + b */ -} SISegOffsets; +} SISegOffsets; /****************************************************************************/ @@ -119,15 +119,15 @@ extern SISeg *shmInvalBuffer; /* * prototypes for functions in sinvaladt.c */ -extern int SIBackendInit(SISeg * segInOutP); +extern int SIBackendInit(SISeg *segInOutP); extern int SISegmentInit(bool killExistingSegment, IPCKey key); -extern bool SISetDataEntry(SISeg * segP, SharedInvalidData * data); -extern void SISetProcStateInvalid(SISeg * segP); -extern bool SIDelDataEntry(SISeg * segP); +extern bool SISetDataEntry(SISeg *segP, SharedInvalidData *data); +extern void SISetProcStateInvalid(SISeg *segP); +extern bool SIDelDataEntry(SISeg *segP); extern void -SIReadEntryData(SISeg * segP, int backendId, +SIReadEntryData(SISeg *segP, int backendId, void (*invalFunction) (), void (*resetFunction) ()); -extern void SIDelExpiredDataEntries(SISeg * segP); +extern void SIDelExpiredDataEntries(SISeg *segP); #endif /* SINVALADT_H */ |