Module Name: src Committed By: christos Date: Fri Nov 22 16:25:02 UTC 2013
Modified Files: src/include: mpool.h Log Message: use a TAILQ instead of a CIRCLEQ, from FreeBSD To generate a diff of this commit: cvs rdiff -u -r1.13 -r1.14 src/include/mpool.h Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files.
Modified files: Index: src/include/mpool.h diff -u src/include/mpool.h:1.13 src/include/mpool.h:1.14 --- src/include/mpool.h:1.13 Tue Aug 26 17:18:38 2008 +++ src/include/mpool.h Fri Nov 22 11:25:01 2013 @@ -1,4 +1,4 @@ -/* $NetBSD: mpool.h,v 1.13 2008/08/26 21:18:38 joerg Exp $ */ +/* $NetBSD: mpool.h,v 1.14 2013/11/22 16:25:01 christos Exp $ */ /*- * Copyright (c) 1991, 1993, 1994 @@ -49,8 +49,8 @@ /* The BKT structures are the elements of the queues. */ typedef struct _bkt { - CIRCLEQ_ENTRY(_bkt) hq; /* hash queue */ - CIRCLEQ_ENTRY(_bkt) q; /* lru queue */ + TAILQ_ENTRY(_bkt) hq; /* hash queue */ + TAILQ_ENTRY(_bkt) q; /* lru queue */ void *page; /* page */ pgno_t pgno; /* page number */ @@ -60,9 +60,9 @@ typedef struct _bkt { } BKT; typedef struct MPOOL { - CIRCLEQ_HEAD(_lqh, _bkt) lqh; /* lru queue head */ + TAILQ_HEAD(_lqh, _bkt) lqh; /* lru queue head */ /* hash queue array */ - CIRCLEQ_HEAD(_hqh, _bkt) hqh[HASHSIZE]; + TAILQ_HEAD(_hqh, _bkt) hqh[HASHSIZE]; pgno_t curcache; /* current number of cached pages */ pgno_t maxcache; /* max number of cached pages */ pgno_t npages; /* number of pages in the file */