openafs/src/afs/afs_cbqueue.h

46 lines
1.0 KiB
C
Raw Normal View History

2000-11-04 10:01:08 +00:00
/*
* Copyright 2000, International Business Machines Corporation and others.
* All Rights Reserved.
*
* This software has been released under the terms of the IBM Public
* License. For details, see the LICENSE file in the top-level source
* directory or online at http://www.openafs.org/dl/license10.html
*/
/*
2000-11-04 02:13:13 +00:00
* This package is used to actively manage the expiration of callbacks,
* so that the rest of the cache manager doesn't need to compute
* whether a callback has expired or not, but can tell with one simple
* check, that is, whether the CStatd bit is on or off.
*/
/* how many seconds in a slot */
#define CBHTSLOTLEN 128
/* how many slots in the table */
#define CBHTSIZE 128
/* 7 is LOG2(slotlen) */
#define CBHash(t) (t>>7)
extern int afs_BumpBase();
extern void afs_InitCBQueue();
extern void afs_CheckCallbacks();
extern void afs_DequeueCallback();
extern void afs_QueueCallback();
#define CBQTOV(e) ((struct vcache *)(((char *) (e)) - (((char *)(&(((struct vcache *)(e))->callsort))) - ((char *)(e)))))