libsysio-commit Mailing List for libsysio (Page 5)
Brought to you by:
lward
You can subscribe to this list here.
2003 |
Jan
|
Feb
|
Mar
|
Apr
(25) |
May
(28) |
Jun
(25) |
Jul
(30) |
Aug
(60) |
Sep
(52) |
Oct
(100) |
Nov
(15) |
Dec
(34) |
---|---|---|---|---|---|---|---|---|---|---|---|---|
2004 |
Jan
(89) |
Feb
(48) |
Mar
(22) |
Apr
(59) |
May
(16) |
Jun
(15) |
Jul
(50) |
Aug
(26) |
Sep
(40) |
Oct
(27) |
Nov
(12) |
Dec
|
2005 |
Jan
(24) |
Feb
(11) |
Mar
|
Apr
|
May
(3) |
Jun
(6) |
Jul
|
Aug
(14) |
Sep
(21) |
Oct
(10) |
Nov
|
Dec
|
2006 |
Jan
(8) |
Feb
(5) |
Mar
(2) |
Apr
(6) |
May
(11) |
Jun
(2) |
Jul
|
Aug
|
Sep
|
Oct
|
Nov
|
Dec
(3) |
2007 |
Jan
(3) |
Feb
(5) |
Mar
(20) |
Apr
(41) |
May
(21) |
Jun
(3) |
Jul
(5) |
Aug
(12) |
Sep
(21) |
Oct
(5) |
Nov
(16) |
Dec
|
2008 |
Jan
|
Feb
(2) |
Mar
(4) |
Apr
(23) |
May
|
Jun
(22) |
Jul
(13) |
Aug
|
Sep
|
Oct
(9) |
Nov
(3) |
Dec
(13) |
2009 |
Jan
(14) |
Feb
(10) |
Mar
(2) |
Apr
(11) |
May
(7) |
Jun
(1) |
Jul
(1) |
Aug
(36) |
Sep
(12) |
Oct
|
Nov
|
Dec
(10) |
2010 |
Jan
|
Feb
|
Mar
|
Apr
|
May
|
Jun
|
Jul
(1) |
Aug
|
Sep
|
Oct
|
Nov
|
Dec
|
2014 |
Jan
|
Feb
|
Mar
|
Apr
|
May
|
Jun
|
Jul
|
Aug
|
Sep
(1) |
Oct
|
Nov
|
Dec
|
From: Lee W. <lw...@us...> - 2009-01-22 19:12:27
|
Update of /cvsroot/libsysio/libsysio/include In directory ddv4jf1.ch3.sourceforge.com:/tmp/cvs-serv16097/include Modified Files: inode.h Log Message: Updated copyright. Sorry, should have done this with last check-in. Index: inode.h =================================================================== RCS file: /cvsroot/libsysio/libsysio/include/inode.h,v retrieving revision 1.49 retrieving revision 1.50 diff -u -w -b -B -p -r1.49 -r1.50 --- inode.h 22 Jan 2009 19:07:42 -0000 1.49 +++ inode.h 22 Jan 2009 19:12:19 -0000 1.50 @@ -9,7 +9,7 @@ * terms of the GNU Lesser General Public License * (see cit/LGPL or http://www.gnu.org/licenses/lgpl.html) * - * Cplant(TM) Copyright 1998-2008 Sandia Corporation. + * Cplant(TM) Copyright 1998-2009 Sandia Corporation. * Under the terms of Contract DE-AC04-94AL85000, there is a non-exclusive * license for use of this work by or on behalf of the US Government. * Export of this program may require a license from the United States |
From: Lee W. <lw...@us...> - 2009-01-22 19:07:55
|
Update of /cvsroot/libsysio/libsysio/include In directory ddv4jf1.ch3.sourceforge.com:/tmp/cvs-serv15278/include Modified Files: inode.h Log Message: With I_ASSOCIATIONS defined, inodes keep a list of all path-base nodes that are currently associated. Always, association of a path-base node with an i-node is now done via the macro PB_SET_ASSOC(). This, new, macro will not allow an already associated path-base node to gain a new association; This to enforce the emerging policy of "once set, immutable" for these nodes. You can set the association of an unassociated path-base node or clear it, only. Index: inode.h =================================================================== RCS file: /cvsroot/libsysio/libsysio/include/inode.h,v retrieving revision 1.48 retrieving revision 1.49 diff -u -w -b -B -p -r1.48 -r1.49 --- inode.h 5 Jan 2009 19:19:29 -0000 1.48 +++ inode.h 22 Jan 2009 19:07:42 -0000 1.49 @@ -139,10 +139,22 @@ struct inode { struct inode_ops i_ops; /* operations */ struct intnl_stat i_stbuf; /* attrs */ struct filesys *i_fs; /* file system ptr */ +#ifdef I_ASSOCIATIONS + LIST_HEAD(, pnode_base) i_assoc; /* assoc'd pbnodes */ +#endif void *i_private; /* driver data */ TAILQ_ENTRY(inode) i_nodes; /* all i-nodes link */ }; +#ifdef I_ASSOCIATIONS +#define _I_INIT_MORE(_ino) \ + do { \ + LIST_INIT(&(_ino)->i_assoc); \ + } while (0) +#else +#define _I_INIT_MORE(_ino) +#endif + /* * Init an i-node record. */ @@ -160,6 +172,7 @@ struct inode { (ino)->i_stbuf = *(stat); \ (ino)->i_fs = (fs); \ (ino)->i_private = (private); \ + _I_INIT_MORE(ino); \ } while (0) #ifdef LOCK_DEBUG @@ -248,6 +261,20 @@ struct inode { } while (0) /* + * Check association; Logical true if so, otherwise false. + * + * NB: The given i-node should be locked or otherwise protected from + * manipulation by others. + */ +#ifdef I_ASSOCIATIONS +#define I_ISASSOC(_ino) \ + ((_ino)->i_assoc.lh_first) +#else +#define I_ISASSOC(_ino) \ + (0) +#endif + +/* * The "quick string" record (inspired by the structure of the same name * from Linux) is used to pass a string without delimiters as well as useful * information about the string. @@ -276,6 +303,9 @@ struct pnode_base { LIST_HEAD(, pnode_base) pb_children; /* children if a dir */ LIST_ENTRY(pnode_base) pb_sibs; /* links to siblings */ LIST_HEAD(, pnode) pb_aliases; /* aliases */ +#ifdef I_ASSOCIATIONS + LIST_ENTRY(pnode_base) pb_alinks; /* names to same ino */ +#endif #ifdef PB_DEBUG TAILQ_ENTRY(pnode_base) pb_links; /* leaf pbnodes links */ #endif @@ -284,7 +314,7 @@ struct pnode_base { /* * Init a path-base record. */ -#define PB_INIT(_pb, _name, _parent, _ino) \ +#define PB_INIT(_pb, _name, _parent) \ do { \ mutex_init(&(_pb)->pb_mutex, MUTEX_RECURSIVE); \ (_pb)->pb_lckcnt = 0; \ @@ -293,7 +323,7 @@ struct pnode_base { (_pb)->pb_tentry.tn_left = (_pb)->pb_tentry.tn_right = NULL; \ (_pb)->pb_key.pbk_name = *(_name); \ (_pb)->pb_key.pbk_parent = (_parent); \ - (_pb)->pb_ino = (_ino); \ + (_pb)->pb_ino = NULL; \ LIST_INIT(&(_pb)->pb_children); \ LIST_INIT(&(_pb)->pb_aliases); \ } while (0) @@ -342,6 +372,42 @@ struct pnode_base { } while (0) /* + * Set path-base node association. + * + * NB: All of the path-base node, any i-node it currently points at, and + * the new i-node must be locked. If the path-base node is associated, + * the association will be removed before making the new but it will not be + * released, unlocked, or dereferenced. + * + * NB(2): We no longer support re-association. Now, an association can be + * set, anew, or cleared (only when destroying the path-base node. + */ +#ifdef I_ASSOCIATIONS +#define PB_SET_ASSOC(_pb, _ino) \ + do { \ + _PB_CHECK_LOCK((_pb), 1); \ + if ((_pb)->pb_ino) { \ + assert(!(_ino)); \ + _I_CHECK_LOCK((_pb)->pb_ino, 1); \ + LIST_REMOVE((_pb), pb_alinks); \ + } \ + (_pb)->pb_ino = (_ino); \ + if ((_pb)->pb_ino) { \ + _I_CHECK_LOCK((_pb)->pb_ino, 1); \ + LIST_INSERT_HEAD(&(_pb)->pb_ino->i_assoc, \ + (_pb), \ + pb_alinks); \ + } \ + } while (0) +#else +#define PB_SET_ASSOC(_pb, _ino) \ + do { \ + assert(!((_pb)->pb_ino && (_ino))); \ + (_pb)->pb_ino = (_ino); \ + } while (0) +#endif + +/* * Since a file system may be multiply mounted, in different parts of the local * tree, a file system object may appear in different places. We handle that * with aliases. There is one pnode for every alias the system is tracking. |
From: Lee W. <lw...@us...> - 2009-01-22 19:07:51
|
Update of /cvsroot/libsysio/libsysio/src In directory ddv4jf1.ch3.sourceforge.com:/tmp/cvs-serv15278/src Modified Files: inode.c Log Message: With I_ASSOCIATIONS defined, inodes keep a list of all path-base nodes that are currently associated. Always, association of a path-base node with an i-node is now done via the macro PB_SET_ASSOC(). This, new, macro will not allow an already associated path-base node to gain a new association; This to enforce the emerging policy of "once set, immutable" for these nodes. You can set the association of an unassociated path-base node or clear it, only. Index: inode.c =================================================================== RCS file: /cvsroot/libsysio/libsysio/src/inode.c,v retrieving revision 1.52 retrieving revision 1.53 diff -u -w -b -B -p -r1.52 -r1.53 --- inode.c 22 Jan 2009 18:06:44 -0000 1.52 +++ inode.c 22 Jan 2009 19:07:42 -0000 1.53 @@ -304,6 +304,9 @@ _sysio_i_gone(struct inode *ino) if (ino->i_ref) abort(); +#ifdef I_ASSOCIATIIONS + assert(!I_ISASSOC(ino)); +#endif if (!ino->i_zombie) icache_delete(ino); TAILQ_REMOVE(&_sysio_inodes, ino, i_nodes); @@ -508,7 +511,8 @@ _sysio_pb_new(struct qstr *name, struct if (!name) name = &noname; - PB_INIT(pb, name, parent, ino); + PB_INIT(pb, name, parent); + PB_SET_ASSOC(pb, ino); if (ino) I_REF(ino); PB_LOCK(pb); @@ -587,14 +591,14 @@ _sysio_pb_gone(struct pnode_base *pb) ino = pb->pb_ino; if (ino) I_LOCK(ino); - pb->pb_ino = NULL; + PB_SET_ASSOC(pb, NULL); PB_UNLOCK(pb); mutex_destroy(&pb->pb_mutex); free(pb); if (ino) { I_RELE(ino); - if (!(ino->i_ref || ino->i_immune)) + if (!(ino->i_ref || ino->i_immune || I_ISASSOC(ino))) _sysio_i_gone(ino); else I_UNLOCK(ino); @@ -893,12 +897,17 @@ _sysio_p_validate(struct pnode *pno, str /* * Make valid. */ - pno->p_base->pb_ino = ino; + PB_SET_ASSOC(pno->p_base, ino); I_REF(pno->p_base->pb_ino); } else if (pno->p_base->pb_ino != ino) { /* * Path resolves to a different inode, now. The * currently attached inode, then, is stale. + * + * Don't want to disconnect it. If caller + * is handles based, we want to keep returning + * stale. Other users should know better than to + * keep retrying; It'll never become valid. */ err = -ESTALE; I_PUT(ino); @@ -1280,7 +1289,7 @@ _sysio_p_link(struct pnode *old, struct err = PNOP_LINK(old, new); if (err) return err; - new->p_base->pb_ino = old->p_base->pb_ino; + PB_SET_ASSOC(new->p_base, old->p_base->pb_ino); I_REF(new->p_base->pb_ino); return 0; } |
From: Lee W. <lw...@us...> - 2009-01-22 18:06:57
|
Update of /cvsroot/libsysio/libsysio/src In directory ddv4jf1.ch3.sourceforge.com:/tmp/cvs-serv12343 Modified Files: inode.c Log Message: Can't call p_reclaim_debug unless PB_DEBUG is defined. Fixed. Index: inode.c =================================================================== RCS file: /cvsroot/libsysio/libsysio/src/inode.c,v retrieving revision 1.51 retrieving revision 1.52 diff -u -w -b -B -p -r1.51 -r1.52 --- inode.c 5 Jan 2009 19:19:29 -0000 1.51 +++ inode.c 22 Jan 2009 18:06:44 -0000 1.52 @@ -401,6 +401,10 @@ p_reclaim(unsigned limit) else PB_UNLOCK(pb); } while ((!limit || limit-- > 1) && next); + +#ifdef PB_DEBUG + p_reclaim_debug(); +#endif } static int |
From: Lee W. <lw...@us...> - 2009-01-05 19:19:42
|
Update of /cvsroot/libsysio/libsysio/include In directory ddv4jf1.ch3.sourceforge.com:/tmp/cvs-serv10773/include Modified Files: inode.h Log Message: We no longer reclaim i_nodes directly. Instead, as path-base nodes are released by the path node reclamation, the i-node is dismissed directly. It served no useful purpose to retain these beyond the life of the set of associated path-base nodes. As well, if PB_DEBUG is defined then a list of leaf path-base nodes is kept and reported when we are dbugging reclamation. Index: inode.h =================================================================== RCS file: /cvsroot/libsysio/libsysio/include/inode.h,v retrieving revision 1.47 retrieving revision 1.48 diff -u -w -b -B -p -r1.47 -r1.48 --- inode.h 15 Dec 2008 19:55:54 -0000 1.47 +++ inode.h 5 Jan 2009 19:19:29 -0000 1.48 @@ -276,8 +276,8 @@ struct pnode_base { LIST_HEAD(, pnode_base) pb_children; /* children if a dir */ LIST_ENTRY(pnode_base) pb_sibs; /* links to siblings */ LIST_HEAD(, pnode) pb_aliases; /* aliases */ -#ifdef P_RECLAIM_DEBUG - TAILQ_ENTRY(pnode_base) pb_links; /* all pbnodes links */ +#ifdef PB_DEBUG + TAILQ_ENTRY(pnode_base) pb_links; /* leaf pbnodes links */ #endif }; |
From: Lee W. <lw...@us...> - 2009-01-05 19:19:37
|
Update of /cvsroot/libsysio/libsysio/src In directory ddv4jf1.ch3.sourceforge.com:/tmp/cvs-serv10773/src Modified Files: inode.c Log Message: We no longer reclaim i_nodes directly. Instead, as path-base nodes are released by the path node reclamation, the i-node is dismissed directly. It served no useful purpose to retain these beyond the life of the set of associated path-base nodes. As well, if PB_DEBUG is defined then a list of leaf path-base nodes is kept and reported when we are dbugging reclamation. Index: inode.c =================================================================== RCS file: /cvsroot/libsysio/libsysio/src/inode.c,v retrieving revision 1.50 retrieving revision 1.51 diff -u -w -b -B -p -r1.50 -r1.51 --- inode.c 15 Dec 2008 19:55:54 -0000 1.50 +++ inode.c 5 Jan 2009 19:19:29 -0000 1.51 @@ -73,6 +73,7 @@ */ #define P_RECLAIM_MIN 511 #if P_RECLAIM_MIN > (NAMES_TABLE_LEN / 4) +#undef P_RECLAIM_MIN #define P_RECLAIM_MIN (NAMES_TABLE_LEN / 4) #endif @@ -92,8 +93,8 @@ static size_t n_names = 0; */ struct pnodes_head _sysio_idle_pnodes; -#ifdef P_RECLAIM_DEBUG -static TAILQ_HEAD(, pnode_base) pbnodes; +#ifdef PB_DEBUG +static TAILQ_HEAD(, pnode_base) pb_leaf_nodes; #endif /* @@ -105,11 +106,6 @@ struct pnode *_sysio_root = NULL; static struct { unsigned long long cst_iprobes; unsigned long long cst_ihits; -#if 0 - unsigned long long cst_ireclaims; - unsigned long long cst_iexamined; - unsigned long long cst_idismissed; -#endif unsigned long long cst_pbprobes; unsigned long long cst_pbhits; unsigned long long cst_preclaims; @@ -122,11 +118,6 @@ ino_cstats_init() { cstats.cst_iprobes = cstats.cst_ihits = 0; -#if 0 - cstats.cst_ireclaims = - cstats.cst_iexamined = - cstats.cst_idismissed = 0; -#endif cstats.cst_pbprobes = cstats.cst_pbhits = 0; cstats.cst_preclaims = cstats.cst_pexamined = @@ -151,7 +142,9 @@ _sysio_i_init() { TAILQ_INIT(&_sysio_inodes); - +#ifdef PB_DEBUG + TAILQ_INIT(&pb_leaf_nodes); +#endif TAILQ_INIT(&_sysio_idle_pnodes); #ifdef INO_CACHE_STATS @@ -161,33 +154,6 @@ _sysio_i_init() return 0; } -#if 0 -/* - * Garbage-collect idle i-nodes. - */ -static void -i_reclaim() -{ - struct inode *next, *ino; - size_t t; - - INO_CST_UPDCNT(ireclaims); - t = n_inodes - n_inodes / 10; - next = _sysio_inodes.tqh_first; - while (next) { - ino = next; - next = ino->i_nodes.tqe_next; - INO_CST_UPDCNT(iexamined); - if (ino->i_ref || (ino->i_immune && !ino->i_zombie)) - continue; - INO_CST_UPDCNT(idismissed); - _sysio_i_gone(ino); - if (n_inodes < t) - break; - } -} -#endif - /* * Compare two file identifiers, returning -1 if length of first is * less than the second, or 1 if length of first greater than then the @@ -273,17 +239,6 @@ _sysio_i_new(struct filesys *fs, struct inode *ino; struct inode_ops operations; -#if 0 - if (n_inodes > n_names) { - /* - * This has become pretty badly skewed relative to - * the number of active nodes in the system. Try to - * correct that, now. - */ - i_reclaim(); - } -#endif - ino = malloc(sizeof(struct inode)); if (!ino) return NULL; @@ -374,7 +329,7 @@ _sysio_i_undead(struct inode *ino) icache_delete(ino); } -#ifdef P_RECLAIM_DEBUG +#ifdef PB_DEBUG static void p_reclaim_debug() { @@ -385,7 +340,7 @@ p_reclaim_debug() npbleaves = 0; npborphans = 0; - nxt = pbnodes.tqh_first; + nxt = pb_leaf_nodes.tqh_first; while ((pb = nxt)) { nxt = pb->pb_links.tqe_next; npb++; @@ -410,10 +365,6 @@ p_reclaim(unsigned limit) struct pnode *next, *pno; struct pnode_base *pb; -#ifdef P_RECLAIM_DEBUG - p_reclaim_debug(); -#endif - INO_CST_UPDCNT(preclaims); next = _sysio_idle_pnodes.tqh_first; if (!next) @@ -536,6 +487,17 @@ _sysio_pb_new(struct qstr *name, struct struct pnode_base *pb; static struct qstr noname = { NULL, 0, 0 }; + if (n_names > NAMES_TABLE_LEN) { + unsigned n; + /* + * Limit growth. + */ + n = n_names - NAMES_TABLE_LEN; + if (n < P_RECLAIM_MIN) + n = P_RECLAIM_MIN; + p_reclaim(n); + } + pb = malloc(sizeof(struct pnode_base) + name->len); if (!pb) return NULL; @@ -547,8 +509,18 @@ _sysio_pb_new(struct qstr *name, struct I_REF(ino); PB_LOCK(pb); - if (parent) + if (pb->pb_key.pbk_parent) { +#if defined(PB_DEBUG) + if (!parent->pb_children.lh_first) { + /* + * The parent is no longer a leaf. We + * need to remove it from that list. + */ + TAILQ_REMOVE(&pb_leaf_nodes, parent, pb_links); + } +#endif LIST_INSERT_HEAD(&parent->pb_children, pb, pb_sibs); + } if (pb->pb_key.pbk_name.len) { char *cp; @@ -563,8 +535,8 @@ _sysio_pb_new(struct qstr *name, struct pb->pb_key.pbk_name.name = cp; ncache_insert(pb); } -#ifdef P_RECLAIM_DEBUG - TAILQ_INSERT_HEAD(&pbnodes, pb, pb_links); +#ifdef PB_DEBUG + TAILQ_INSERT_TAIL(&pb_leaf_nodes, pb, pb_links); #endif PB_GET(pb); PB_UNLOCK(pb); @@ -572,17 +544,6 @@ _sysio_pb_new(struct qstr *name, struct n_names++; assert(n_names); - if (n_names > NAMES_TABLE_LEN) { - unsigned n; - /* - * Limit growth. - */ - n = n_names - NAMES_TABLE_LEN; - if (n < P_RECLAIM_MIN) - n = P_RECLAIM_MIN; - p_reclaim(n); - } - return pb; } @@ -602,10 +563,22 @@ _sysio_pb_gone(struct pnode_base *pb) if (pb->pb_key.pbk_name.len) ncache_delete(pb); - if (pb->pb_key.pbk_parent) + if (pb->pb_key.pbk_parent) { LIST_REMOVE(pb, pb_sibs); -#ifdef P_RECLAIM_DEBUG - TAILQ_REMOVE(&pbnodes, pb, pb_links); +#if defined(PB_DEBUG) + /* + * If we just removed the last child, put the parent on + * the list of leaves. + */ + if (!pb->pb_key.pbk_parent->pb_children.lh_first) { + TAILQ_INSERT_TAIL(&pb_leaf_nodes, + pb->pb_key.pbk_parent, + pb_links); + } +#endif + } +#ifdef PB_DEBUG + TAILQ_REMOVE(&pb_leaf_nodes, pb, pb_links); #endif ino = pb->pb_ino; if (ino) @@ -653,12 +626,6 @@ _sysio_i_shutdown() _sysio_cprintf("inode: probe %llu, hit %llu\n", cstats.cst_iprobes, cstats.cst_ihits); -#if 0 - _sysio_cprintf("inode: reclaims %llu, examined %llu dismissed %llu\n", - cstats.cst_ireclaims, - cstats.cst_iexamined, - cstats.cst_idismissed); -#endif _sysio_cprintf("pbnode: probe %llu, hit %llu\n", cstats.cst_pbprobes, cstats.cst_pbhits); |
From: Lee W. <lw...@us...> - 2008-12-15 19:56:02
|
Update of /cvsroot/libsysio/libsysio/include In directory ddv4jf1.ch3.sourceforge.com:/tmp/cvs-serv20145/include Modified Files: inode.h Log Message: The all-pbnodes list is changed to be maintained as a tailq, instead of a simple linked list. Index: inode.h =================================================================== RCS file: /cvsroot/libsysio/libsysio/include/inode.h,v retrieving revision 1.46 retrieving revision 1.47 diff -u -w -b -B -p -r1.46 -r1.47 --- inode.h 15 Dec 2008 18:32:40 -0000 1.46 +++ inode.h 15 Dec 2008 19:55:54 -0000 1.47 @@ -277,7 +277,7 @@ struct pnode_base { LIST_ENTRY(pnode_base) pb_sibs; /* links to siblings */ LIST_HEAD(, pnode) pb_aliases; /* aliases */ #ifdef P_RECLAIM_DEBUG - LIST_ENTRY(pnode_base) pb_links; /* all pbnodes links */ + TAILQ_ENTRY(pnode_base) pb_links; /* all pbnodes links */ #endif }; |
From: Lee W. <lw...@us...> - 2008-12-15 19:56:02
|
Update of /cvsroot/libsysio/libsysio/src In directory ddv4jf1.ch3.sourceforge.com:/tmp/cvs-serv20145/src Modified Files: inode.c Log Message: The all-pbnodes list is changed to be maintained as a tailq, instead of a simple linked list. Index: inode.c =================================================================== RCS file: /cvsroot/libsysio/libsysio/src/inode.c,v retrieving revision 1.49 retrieving revision 1.50 diff -u -w -b -B -p -r1.49 -r1.50 --- inode.c 12 Dec 2008 22:28:15 -0000 1.49 +++ inode.c 15 Dec 2008 19:55:54 -0000 1.50 @@ -93,7 +93,7 @@ static size_t n_names = 0; struct pnodes_head _sysio_idle_pnodes; #ifdef P_RECLAIM_DEBUG -static LIST_HEAD(, pnode_base) pbnodes; +static TAILQ_HEAD(, pnode_base) pbnodes; #endif /* @@ -385,9 +385,9 @@ p_reclaim_debug() npbleaves = 0; npborphans = 0; - nxt = pbnodes.lh_first; + nxt = pbnodes.tqh_first; while ((pb = nxt)) { - nxt = pb->pb_links.le_next; + nxt = pb->pb_links.tqe_next; npb++; if (!pb->pb_children.lh_first) npbleaves++; @@ -545,7 +545,8 @@ _sysio_pb_new(struct qstr *name, struct PB_INIT(pb, name, parent, ino); if (ino) I_REF(ino); - PB_GET(pb); + PB_LOCK(pb); + if (parent) LIST_INSERT_HEAD(&parent->pb_children, pb, pb_sibs); if (pb->pb_key.pbk_name.len) { @@ -562,14 +563,15 @@ _sysio_pb_new(struct qstr *name, struct pb->pb_key.pbk_name.name = cp; ncache_insert(pb); } +#ifdef P_RECLAIM_DEBUG + TAILQ_INSERT_HEAD(&pbnodes, pb, pb_links); +#endif + PB_GET(pb); + PB_UNLOCK(pb); n_names++; assert(n_names); -#ifdef P_RECLAIM_DEBUG - LIST_INSERT_HEAD(&pbnodes, pb, pb_links); -#endif - if (n_names > NAMES_TABLE_LEN) { unsigned n; /* @@ -603,7 +605,7 @@ _sysio_pb_gone(struct pnode_base *pb) if (pb->pb_key.pbk_parent) LIST_REMOVE(pb, pb_sibs); #ifdef P_RECLAIM_DEBUG - LIST_REMOVE(pb, pb_links); + TAILQ_REMOVE(&pbnodes, pb, pb_links); #endif ino = pb->pb_ino; if (ino) |
From: Lee W. <lw...@us...> - 2008-12-15 18:32:53
|
Update of /cvsroot/libsysio/libsysio/include In directory ddv4jf1.ch3.sourceforge.com:/tmp/cvs-serv15635/include Modified Files: inode.h Log Message: Remove move-to-front policy maintenance for inodes. Since we no longer reclaim them, separately, this was work to no end. Index: inode.h =================================================================== RCS file: /cvsroot/libsysio/libsysio/include/inode.h,v retrieving revision 1.45 retrieving revision 1.46 diff -u -w -b -B -p -r1.45 -r1.46 --- inode.h 6 Dec 2008 18:47:14 -0000 1.45 +++ inode.h 15 Dec 2008 18:32:40 -0000 1.46 @@ -190,8 +190,6 @@ struct inode { #define _I_REF_NO_LOCK(_ino) \ do { \ _I_CHECK_LOCK((_ino), 1); \ - TAILQ_REMOVE(&_sysio_inodes, (_ino), i_nodes); \ - TAILQ_INSERT_TAIL(&_sysio_inodes, (_ino), i_nodes); \ (_ino)->i_ref++; \ assert((_ino)->i_ref); \ } while (0) |
From: Lee W. <lw...@us...> - 2008-12-12 22:28:22
|
Update of /cvsroot/libsysio/libsysio/src In directory ddv4jf1.ch3.sourceforge.com:/tmp/cvs-serv13919/src Modified Files: inode.c Log Message: Removed inode reclaim functionality. This is handled, now, by the base node reclamation; It kills idle inodes. Also, set the minimum reclaim for base nodes to 511 or 1/4 or NAMES_TABLE_LEN, whichever is smaller. Index: inode.c =================================================================== RCS file: /cvsroot/libsysio/libsysio/src/inode.c,v retrieving revision 1.48 retrieving revision 1.49 diff -u -w -b -B -p -r1.48 -r1.49 --- inode.c 6 Dec 2008 23:28:19 -0000 1.48 +++ inode.c 12 Dec 2008 22:28:15 -0000 1.49 @@ -70,7 +71,10 @@ /* * Desired high-water mark. */ -#define P_RECLAIM_MIN 16 +#define P_RECLAIM_MIN 511 +#if P_RECLAIM_MIN > (NAMES_TABLE_LEN / 4) +#define P_RECLAIM_MIN (NAMES_TABLE_LEN / 4) +#endif /* * Active i-nodes in the system and the number of same. @@ -101,9 +105,11 @@ struct pnode *_sysio_root = NULL; static struct { unsigned long long cst_iprobes; unsigned long long cst_ihits; +#if 0 unsigned long long cst_ireclaims; unsigned long long cst_iexamined; unsigned long long cst_idismissed; +#endif unsigned long long cst_pbprobes; unsigned long long cst_pbhits; unsigned long long cst_preclaims; @@ -116,9 +122,11 @@ ino_cstats_init() { cstats.cst_iprobes = cstats.cst_ihits = 0; +#if 0 cstats.cst_ireclaims = cstats.cst_iexamined = cstats.cst_idismissed = 0; +#endif cstats.cst_pbprobes = cstats.cst_pbhits = 0; cstats.cst_preclaims = cstats.cst_pexamined = @@ -153,6 +161,7 @@ _sysio_i_init() return 0; } +#if 0 /* * Garbage-collect idle i-nodes. */ @@ -177,6 +186,7 @@ i_reclaim() break; } } +#endif /* * Compare two file identifiers, returning -1 if length of first is @@ -263,6 +273,7 @@ _sysio_i_new(struct filesys *fs, struct inode *ino; struct inode_ops operations; +#if 0 if (n_inodes > n_names) { /* * This has become pretty badly skewed relative to @@ -271,6 +282,7 @@ _sysio_i_new(struct filesys *fs, */ i_reclaim(); } +#endif ino = malloc(sizeof(struct inode)); if (!ino) @@ -639,10 +651,12 @@ _sysio_i_shutdown() _sysio_cprintf("inode: probe %llu, hit %llu\n", cstats.cst_iprobes, cstats.cst_ihits); +#if 0 _sysio_cprintf("inode: reclaims %llu, examined %llu dismissed %llu\n", cstats.cst_ireclaims, cstats.cst_iexamined, cstats.cst_idismissed); +#endif _sysio_cprintf("pbnode: probe %llu, hit %llu\n", cstats.cst_pbprobes, cstats.cst_pbhits); |
From: Lee W. <lw...@us...> - 2008-12-06 23:29:01
|
Update of /cvsroot/libsysio/libsysio/drivers/incore In directory ddv4jf1.ch3.sourceforge.com:/tmp/cvs-serv8263 Modified Files: fs_incore.c Log Message: Ported to the new pnode-only infrastructure changes. Index: fs_incore.c =================================================================== RCS file: /cvsroot/libsysio/libsysio/drivers/incore/fs_incore.c,v retrieving revision 1.35 retrieving revision 1.36 diff -u -w -b -B -p -r1.35 -r1.36 --- fs_incore.c 24 Sep 2007 19:00:02 -0000 1.35 +++ fs_incore.c 6 Dec 2008 23:28:55 -0000 1.36 @@ -96,9 +96,16 @@ struct incore_inode { #define I2IC(ino) ((struct incore_inode *)(ino)->i_private) struct incore_filesys { + ino_t icfs_nxtnum; /* next inum */ LIST_HEAD(, incore_inode) icfs_icinodes; /* all i-nodes list */ }; +#define ICFS_INIT(_icfs) \ + do { \ + (_icfs)->icfs_nxtnum = 1; \ + LIST_INIT(&(_icfs)->icfs_icinodes); \ + } while (0) + /* * Given pointer to filesys, return pointer to incore-filesys. */ @@ -125,38 +132,35 @@ static int _sysio_incore_dirop_lookup(st struct intent *intnt, const char *path); static int _sysio_incore_inop_getattr(struct pnode *pno, - struct inode *ino, struct intnl_stat *stbuf); static int _sysio_incore_inop_setattr(struct pnode *pno, - struct inode *ino, unsigned mask, struct intnl_stat *stbuf); -static ssize_t _sysio_incore_dirop_filldirentries(struct inode *ino, +static ssize_t _sysio_incore_dirop_filldirentries(struct pnode *pno, _SYSIO_OFF_T *posp, char *buf, size_t nbytes); static int _sysio_incore_dirop_mkdir(struct pnode *pno, mode_t mode); static int _sysio_incore_dirop_rmdir(struct pnode *pno); static int _sysio_incore_inop_open(struct pnode *pno, int flags, mode_t mode); -static int _sysio_incore_inop_close(struct inode *ino); +static int _sysio_incore_inop_close(struct pnode *pno); static int _sysio_incore_dirop_link(struct pnode *old, struct pnode *new); static int _sysio_incore_dirop_unlink(struct pnode *pno); static int _sysio_incore_dirop_rename(struct pnode *old, struct pnode *new); -static int _sysio_incore_filop_read(struct inode *ino, struct ioctx *ioctx); -static int _sysio_incore_filop_write(struct inode *ino, struct ioctx *ioctx); -static _SYSIO_OFF_T _sysio_incore_filop_pos(struct inode *ino, +static int _sysio_incore_filop_read(struct ioctx *ioctx); +static int _sysio_incore_filop_write(struct ioctx *ioctx); +static _SYSIO_OFF_T _sysio_incore_filop_pos(struct pnode *pno, _SYSIO_OFF_T off); static int _sysio_incore_filop_iodone(struct ioctx *ioctx); -static int _sysio_incore_filop_fcntl(struct inode *ino, +static int _sysio_incore_filop_fcntl(struct pnode *pno, int cmd, va_list ap, int *rtn); -static int _sysio_incore_inop_sync(struct inode *ino); -static int _sysio_incore_filop_ioctl(struct inode *ino, +static int _sysio_incore_inop_sync(struct pnode *pno); +static int _sysio_incore_filop_ioctl(struct pnode *pno, unsigned long int request, va_list ap); static int _sysio_incore_dirop_mknod(struct pnode *pno, mode_t mode, dev_t dev); #ifdef _HAVE_STATVFS static int _sysio_incore_inop_statvfs(struct pnode *pno, - struct inode *ino, struct intnl_statvfs *buf); #endif static void _sysio_incore_inop_gone(struct inode *ino); @@ -166,20 +170,18 @@ static void _sysio_incore_inop_gone(stru #define _sysio_incore_dirop_readlink \ (int (*)(struct pnode *, char *, size_t))_sysio_do_enosys #define _sysio_incore_dirop_read \ - (int (*)(struct inode *, \ - struct ioctx *))_sysio_do_eisdir + (int (*)(struct ioctx *))_sysio_do_eisdir #define _sysio_incore_dirop_write \ - (int (*)(struct inode *, \ - struct ioctx *))_sysio_do_eisdir + (int (*)(struct ioctx *))_sysio_do_eisdir #define _sysio_incore_dirop_pos \ - (_SYSIO_OFF_T (*)(struct inode *, \ + (_SYSIO_OFF_T (*)(struct pnode *, \ _SYSIO_OFF_T))_sysio_do_eisdir #define _sysio_incore_dirop_iodone \ (int (*)(struct ioctx *))_sysio_do_illop #define _sysio_incore_dirop_fcntl \ - (int (*)(struct inode *, int, va_list, int *))_sysio_do_eisdir + (int (*)(struct pnode *, int, va_list, int *))_sysio_do_eisdir #define _sysio_incore_dirop_ioctl \ - (int (*)(struct inode *, \ + (int (*)(struct pnode *, \ unsigned long int, \ va_list))_sysio_do_eisdir @@ -217,7 +219,7 @@ static int _sysio_incore_filop_lookup(st struct intent *intnt, const char *path); #define _sysio_incore_filop_filldirentries \ - (ssize_t (*)(struct inode *, \ + (ssize_t (*)(struct pnode *, \ _SYSIO_OFF_T *, \ char *, \ size_t))_sysio_do_illop @@ -398,12 +400,11 @@ _sysio_incore_init() } static ino_t -incore_inum_alloc() +incore_inum_alloc(struct incore_filesys *icfs) { - static ino_t nxtnum = 1; - assert(nxtnum); - return nxtnum++; + assert(icfs->icfs_nxtnum); + return icfs->icfs_nxtnum++; } static struct incore_inode * @@ -596,15 +597,14 @@ _sysio_incore_fsswop_mount(const char *s err = -ENOMEM; goto error; } - (void )memset(icfs, 0, sizeof(struct incore_filesys)); - LIST_INIT(&icfs->icfs_icinodes); + ICFS_INIT(icfs); /* * Create root i-node. */ (void )memset(&stat, 0, sizeof(stat)); stat.st_dev = dev; - inum = incore_inum_alloc(); + inum = incore_inum_alloc(icfs); #ifdef HAVE__ST_INO stat.__st_ino = inum; #endif @@ -654,6 +654,8 @@ _sysio_incore_fsswop_mount(const char *s */ mnt = NULL; err = _sysio_mounti(fs, rooti, flags, tocover, &mnt); + I_PUT(rooti); + rooti = NULL; if (err) goto error; @@ -891,28 +893,25 @@ _sysio_incore_filop_lookup(struct pnode static int _sysio_incore_inop_getattr(struct pnode *pno, - struct inode *ino, struct intnl_stat *stbuf) { struct incore_inode *icino; - if (!ino) - ino = pno->p_base->pb_ino; - icino = I2IC(ino); + assert(pno->p_base->pb_ino); + icino = I2IC(pno->p_base->pb_ino); *stbuf = icino->ici_st; return 0; } static int _sysio_incore_inop_setattr(struct pnode *pno, - struct inode *ino, unsigned mask, struct intnl_stat *stbuf) { + struct inode *ino; struct incore_inode *icino; int err; - if (!ino) ino = pno->p_base->pb_ino; if (!ino) return -EBADF; @@ -988,16 +987,18 @@ incore_directory_enumerate(struct intnl_ } static ssize_t -_sysio_incore_dirop_filldirentries(struct inode *ino, +_sysio_incore_dirop_filldirentries(struct pnode *pno, _SYSIO_OFF_T *posp, char *buf, size_t nbytes) { - struct incore_inode *icino = I2IC(ino); + struct incore_inode *icino; off_t off; struct intnl_dirent *de; struct copy_info copy_info; + assert(pno->p_base->pb_ino); + icino = I2IC(pno->p_base->pb_ino); if (*posp >= icino->ici_st.st_size) return 0; @@ -1172,7 +1173,7 @@ _sysio_incore_dirop_mkdir(struct pnode * (void )memset(&stat, 0, sizeof(stat)); stat.st_dev = pno->p_parent->p_base->pb_ino->i_fs->fs_dev; - inum = incore_inum_alloc(); + inum = incore_inum_alloc(FS2ICFS(ino->i_fs)); #ifdef HAVE__ST_INO stat.__st_ino = inum; #endif @@ -1222,7 +1223,7 @@ _sysio_incore_dirop_mkdir(struct pnode * return err; } - pno->p_base->pb_ino = ino; + I_PUT(ino); return 0; } @@ -1295,7 +1296,6 @@ _sysio_incore_dirop_rmdir(struct pnode * if (icino->ici_st.st_nlink > 2) return -ENOTEMPTY; - pno->p_base->pb_ino = NULL; err = incore_unlink_entry(I2IC(pno->p_parent->p_base->pb_ino), &pno->p_base->pb_key.pbk_name); @@ -1347,7 +1347,7 @@ incore_create(struct pnode *pno, struct return err; } - pno->p_base->pb_ino = ino; + I_PUT(ino); return 0; } @@ -1368,7 +1368,7 @@ _sysio_incore_inop_open(struct pnode *pn */ (void )memset(&stat, 0, sizeof(stat)); stat.st_dev = pno->p_parent->p_base->pb_ino->i_fs->fs_dev; - inum = incore_inum_alloc(); + inum = incore_inum_alloc(FS2ICFS(pno->p_parent->p_base->pb_ino->i_fs)); #ifdef HAVE__ST_INO stat.__st_ino = inum; #endif @@ -1387,7 +1387,7 @@ _sysio_incore_inop_open(struct pnode *pn } static int -_sysio_incore_inop_close(struct inode *ino __IS_UNUSED) +_sysio_incore_inop_close(struct pnode *pno __IS_UNUSED) { return 0; @@ -1496,7 +1496,6 @@ _sysio_incore_dirop_unlink(struct pnode static int doio(ssize_t (*f)(void *, size_t, _SYSIO_OFF_T, struct incore_inode *), - struct inode *ino, struct ioctx *ioctx) { @@ -1504,7 +1503,7 @@ doio(ssize_t (*f)(void *, size_t, _SYSIO _sysio_doio(ioctx->ioctx_xtv, ioctx->ioctx_xtvlen, ioctx->ioctx_iov, ioctx->ioctx_iovlen, (ssize_t (*)(void *, size_t, _SYSIO_OFF_T, void *))f, - I2IC(ino)); + I2IC(ioctx->ioctx_pno->p_base->pb_ino)); if (ioctx->ioctx_cc < 0) { ioctx->ioctx_errno = -ioctx->ioctx_cc; ioctx->ioctx_cc = -1; @@ -1534,11 +1533,11 @@ incore_read(void *buf, size_t nbytes, } static int -_sysio_incore_filop_read(struct inode *ino, struct ioctx *ioctx) +_sysio_incore_filop_read(struct ioctx *ioctx) { - return doio(incore_read, ino, ioctx); + return doio(incore_read, ioctx); } static ssize_t @@ -1573,18 +1572,17 @@ incore_write(const void *buf, size_t nby } static int -_sysio_incore_filop_write(struct inode *ino, struct ioctx *ioctx) +_sysio_incore_filop_write(struct ioctx *ioctx) { return doio((ssize_t (*)(void *, size_t, _SYSIO_OFF_T, struct incore_inode *))incore_write, - ino, ioctx); } static _SYSIO_OFF_T -_sysio_incore_filop_pos(struct inode *ino __IS_UNUSED, _SYSIO_OFF_T off) +_sysio_incore_filop_pos(struct pnode *pno __IS_UNUSED, _SYSIO_OFF_T off) { return off; @@ -1601,7 +1599,7 @@ _sysio_incore_filop_iodone(struct ioctx } static int -_sysio_incore_filop_fcntl(struct inode *ino __IS_UNUSED, +_sysio_incore_filop_fcntl(struct pnode *pno __IS_UNUSED, int cmd __IS_UNUSED, va_list ap __IS_UNUSED, int *rtn) @@ -1615,7 +1613,7 @@ _sysio_incore_filop_fcntl(struct inode * } static int -_sysio_incore_inop_sync(struct inode *ino __IS_UNUSED) +_sysio_incore_inop_sync(struct pnode *pno __IS_UNUSED) { /* @@ -1625,7 +1623,7 @@ _sysio_incore_inop_sync(struct inode *in } static int -_sysio_incore_filop_ioctl(struct inode *ino __IS_UNUSED, +_sysio_incore_filop_ioctl(struct pnode *pno __IS_UNUSED, unsigned long int request __IS_UNUSED, va_list ap __IS_UNUSED) { @@ -1662,7 +1660,7 @@ _sysio_incore_dirop_mknod(struct pnode * */ (void )memset(&stat, 0, sizeof(stat)); stat.st_dev = pno->p_parent->p_base->pb_ino->i_fs->fs_dev; - inum = incore_inum_alloc(); + inum = incore_inum_alloc(FS2ICFS(pno->p_parent->p_base->pb_ino->i_fs)); #ifdef HAVE__ST_INO stat.__st_ino = inum; #endif @@ -1683,7 +1681,6 @@ _sysio_incore_dirop_mknod(struct pnode * #ifdef _HAVE_STATVFS static int _sysio_incore_inop_statvfs(struct pnode *pno, - struct inode *ino __IS_UNUSED, struct intnl_statvfs *buf) { struct filesys *fs; |
From: Lee W. <lw...@us...> - 2008-12-06 23:28:26
|
Update of /cvsroot/libsysio/libsysio/src In directory ddv4jf1.ch3.sourceforge.com:/tmp/cvs-serv8101 Modified Files: inode.c Log Message: When removing file system objects, make them undead. Go ahead and kill inodes marked immune if they are also zombies. Index: inode.c =================================================================== RCS file: /cvsroot/libsysio/libsysio/src/inode.c,v retrieving revision 1.47 retrieving revision 1.48 diff -u -w -b -B -p -r1.47 -r1.48 --- inode.c 6 Dec 2008 21:56:25 -0000 1.47 +++ inode.c 6 Dec 2008 23:28:19 -0000 1.48 @@ -169,7 +169,7 @@ i_reclaim() ino = next; next = ino->i_nodes.tqe_next; INO_CST_UPDCNT(iexamined); - if (ino->i_ref || ino->i_immune) + if (ino->i_ref || (ino->i_immune && !ino->i_zombie)) continue; INO_CST_UPDCNT(idismissed); _sysio_i_gone(ino); @@ -1321,6 +1321,7 @@ _sysio_p_unlink(struct pnode *pno) /* * Clean the namespace graphs to reflect the unlink. */ + _sysio_i_undead(pno->p_base->pb_ino); _sysio_pb_disconnect(pno->p_base); return 0; } @@ -1367,6 +1368,7 @@ _sysio_p_rmdir(struct pnode *pno) /* * Clean the namespace graphs to reflect the unlink. */ + _sysio_i_undead(pno->p_base->pb_ino); _sysio_pb_disconnect(pno->p_base); return 0; } |
From: Lee W. <lw...@us...> - 2008-12-06 22:16:43
|
Update of /cvsroot/libsysio/libsysio/drivers/incore In directory ddv4jf1.ch3.sourceforge.com:/tmp/cvs-serv26562/drivers/incore Modified Files: fs_incore.c Log Message: In do_mnt(), must put the directory being covered whether the mount succeded or not. Fixed. Index: fs_incore.c =================================================================== RCS file: /cvsroot/libsysio/libsysio/drivers/incore/fs_incore.c,v retrieving revision 1.35 retrieving revision 1.36 diff -u -w -b -B -p -r1.35 -r1.36 --- fs_incore.c 24 Sep 2007 19:00:02 -0000 1.35 +++ fs_incore.c 6 Dec 2008 21:56:25 -0000 1.36 @@ -125,38 +125,35 @@ static int _sysio_incore_dirop_lookup(st struct intent *intnt, const char *path); static int _sysio_incore_inop_getattr(struct pnode *pno, - struct inode *ino, struct intnl_stat *stbuf); static int _sysio_incore_inop_setattr(struct pnode *pno, - struct inode *ino, unsigned mask, struct intnl_stat *stbuf); -static ssize_t _sysio_incore_dirop_filldirentries(struct inode *ino, +static ssize_t _sysio_incore_dirop_filldirentries(struct pnode *pno, _SYSIO_OFF_T *posp, char *buf, size_t nbytes); static int _sysio_incore_dirop_mkdir(struct pnode *pno, mode_t mode); static int _sysio_incore_dirop_rmdir(struct pnode *pno); static int _sysio_incore_inop_open(struct pnode *pno, int flags, mode_t mode); -static int _sysio_incore_inop_close(struct inode *ino); +static int _sysio_incore_inop_close(struct pnode *pno); static int _sysio_incore_dirop_link(struct pnode *old, struct pnode *new); static int _sysio_incore_dirop_unlink(struct pnode *pno); static int _sysio_incore_dirop_rename(struct pnode *old, struct pnode *new); -static int _sysio_incore_filop_read(struct inode *ino, struct ioctx *ioctx); -static int _sysio_incore_filop_write(struct inode *ino, struct ioctx *ioctx); -static _SYSIO_OFF_T _sysio_incore_filop_pos(struct inode *ino, +static int _sysio_incore_filop_read(struct ioctx *ioctx); +static int _sysio_incore_filop_write(struct ioctx *ioctx); +static _SYSIO_OFF_T _sysio_incore_filop_pos(struct pnode *pno, _SYSIO_OFF_T off); static int _sysio_incore_filop_iodone(struct ioctx *ioctx); -static int _sysio_incore_filop_fcntl(struct inode *ino, +static int _sysio_incore_filop_fcntl(struct pnode *pno, int cmd, va_list ap, int *rtn); -static int _sysio_incore_inop_sync(struct inode *ino); -static int _sysio_incore_filop_ioctl(struct inode *ino, +static int _sysio_incore_inop_sync(struct pnode *pno); +static int _sysio_incore_filop_ioctl(struct pnode *pno, unsigned long int request, va_list ap); static int _sysio_incore_dirop_mknod(struct pnode *pno, mode_t mode, dev_t dev); #ifdef _HAVE_STATVFS static int _sysio_incore_inop_statvfs(struct pnode *pno, - struct inode *ino, struct intnl_statvfs *buf); #endif static void _sysio_incore_inop_gone(struct inode *ino); @@ -166,20 +163,18 @@ static void _sysio_incore_inop_gone(stru #define _sysio_incore_dirop_readlink \ (int (*)(struct pnode *, char *, size_t))_sysio_do_enosys #define _sysio_incore_dirop_read \ - (int (*)(struct inode *, \ - struct ioctx *))_sysio_do_eisdir + (int (*)(struct ioctx *))_sysio_do_eisdir #define _sysio_incore_dirop_write \ - (int (*)(struct inode *, \ - struct ioctx *))_sysio_do_eisdir + (int (*)(struct ioctx *))_sysio_do_eisdir #define _sysio_incore_dirop_pos \ - (_SYSIO_OFF_T (*)(struct inode *, \ + (_SYSIO_OFF_T (*)(struct pnode *, \ _SYSIO_OFF_T))_sysio_do_eisdir #define _sysio_incore_dirop_iodone \ (int (*)(struct ioctx *))_sysio_do_illop #define _sysio_incore_dirop_fcntl \ - (int (*)(struct inode *, int, va_list, int *))_sysio_do_eisdir + (int (*)(struct pnode *, int, va_list, int *))_sysio_do_eisdir #define _sysio_incore_dirop_ioctl \ - (int (*)(struct inode *, \ + (int (*)(struct pnode *, \ unsigned long int, \ va_list))_sysio_do_eisdir @@ -217,7 +212,7 @@ static int _sysio_incore_filop_lookup(st struct intent *intnt, const char *path); #define _sysio_incore_filop_filldirentries \ - (ssize_t (*)(struct inode *, \ + (ssize_t (*)(struct pnode *, \ _SYSIO_OFF_T *, \ char *, \ size_t))_sysio_do_illop @@ -497,7 +492,6 @@ incore_directory_new(struct incore_files &incore_dir_template, sizeof(incore_dir_template)); de = icino->ici_data; - de->d_ino = st->st_ino; de = (struct intnl_dirent *)((char *)de + #ifdef _DIRENT_HAVE_D_OFF @@ -506,7 +500,7 @@ incore_directory_new(struct incore_files de->d_reclen #endif ); - de->d_ino = parent->ici_st.st_ino; + de->d_ino = st->st_ino; /* * Set creation time to modify time set by truncate. @@ -656,6 +650,7 @@ _sysio_incore_fsswop_mount(const char *s err = _sysio_mounti(fs, rooti, flags, tocover, &mnt); if (err) goto error; + I_PUT(rooti); *mntp = mnt; @@ -665,7 +660,7 @@ error: if (mnt && _sysio_do_unmount(mnt) != 0) abort(); if (rooti) - I_RELE(rooti); + I_PUT(rooti); if (fs) { FS_RELE(fs); goto out; @@ -891,32 +886,26 @@ _sysio_incore_filop_lookup(struct pnode static int _sysio_incore_inop_getattr(struct pnode *pno, - struct inode *ino, struct intnl_stat *stbuf) { struct incore_inode *icino; - if (!ino) - ino = pno->p_base->pb_ino; - icino = I2IC(ino); + icino = I2IC(pno->p_base->pb_ino); *stbuf = icino->ici_st; return 0; } static int _sysio_incore_inop_setattr(struct pnode *pno, - struct inode *ino, unsigned mask, struct intnl_stat *stbuf) { struct incore_inode *icino; int err; - if (!ino) - ino = pno->p_base->pb_ino; - if (!ino) + if (!pno->p_base->pb_ino) return -EBADF; - icino = I2IC(ino); + icino = I2IC(pno->p_base->pb_ino); err = 0; if (mask & SETATTR_LEN) { @@ -939,7 +928,7 @@ _sysio_incore_inop_setattr(struct pnode icino->ici_st.st_gid = stbuf->st_gid; icino->ici_st.st_ctime = time(NULL); - ino->i_stbuf = icino->ici_st; + pno->p_base->pb_ino->i_stbuf = icino->ici_st; out: return err; } @@ -988,12 +977,12 @@ incore_directory_enumerate(struct intnl_ } static ssize_t -_sysio_incore_dirop_filldirentries(struct inode *ino, +_sysio_incore_dirop_filldirentries(struct pnode *pno, _SYSIO_OFF_T *posp, char *buf, size_t nbytes) { - struct incore_inode *icino = I2IC(ino); + struct incore_inode *icino = I2IC(pno->p_base->pb_ino); off_t off; struct intnl_dirent *de; struct copy_info copy_info; @@ -1220,9 +1209,9 @@ _sysio_incore_dirop_mkdir(struct pnode * I_RELE(ino); _sysio_i_gone(ino); return err; - } + } else + I_PUT(ino); - pno->p_base->pb_ino = ino; return 0; } @@ -1303,7 +1292,7 @@ _sysio_incore_dirop_rmdir(struct pnode * } static int -incore_create(struct pnode *pno, struct intnl_stat *stat) +incore_create(struct pnode *pno, struct intnl_stat *stat, struct inode **inop) { struct inode *dino, *ino; struct incore_inode *icino; @@ -1347,7 +1336,7 @@ incore_create(struct pnode *pno, struct return err; } - pno->p_base->pb_ino = ino; + *inop = ino; return 0; } @@ -1356,6 +1345,8 @@ _sysio_incore_inop_open(struct pnode *pn { struct intnl_stat stat; ino_t inum; + int err; + struct inode *ino; /* * File exists. Nothing to do. @@ -1383,11 +1374,16 @@ _sysio_incore_inop_open(struct pnode *pn stat.st_ctime = stat.st_mtime = stat.st_atime = 0; stat.st_ino = inum; - return incore_create(pno, &stat); + err = incore_create(pno, &stat, &ino); + if (err) + return err; + assert(ino); + I_PUT(ino); + return 0; } static int -_sysio_incore_inop_close(struct inode *ino __IS_UNUSED) +_sysio_incore_inop_close(struct pnode *pno __IS_UNUSED) { return 0; @@ -1496,7 +1492,6 @@ _sysio_incore_dirop_unlink(struct pnode static int doio(ssize_t (*f)(void *, size_t, _SYSIO_OFF_T, struct incore_inode *), - struct inode *ino, struct ioctx *ioctx) { @@ -1504,7 +1499,7 @@ doio(ssize_t (*f)(void *, size_t, _SYSIO _sysio_doio(ioctx->ioctx_xtv, ioctx->ioctx_xtvlen, ioctx->ioctx_iov, ioctx->ioctx_iovlen, (ssize_t (*)(void *, size_t, _SYSIO_OFF_T, void *))f, - I2IC(ino)); + I2IC(ioctx->ioctx_pno->p_base->pb_ino)); if (ioctx->ioctx_cc < 0) { ioctx->ioctx_errno = -ioctx->ioctx_cc; ioctx->ioctx_cc = -1; @@ -1534,11 +1529,11 @@ incore_read(void *buf, size_t nbytes, } static int -_sysio_incore_filop_read(struct inode *ino, struct ioctx *ioctx) +_sysio_incore_filop_read(struct ioctx *ioctx) { - return doio(incore_read, ino, ioctx); + return doio(incore_read, ioctx); } static ssize_t @@ -1573,18 +1568,17 @@ incore_write(const void *buf, size_t nby } static int -_sysio_incore_filop_write(struct inode *ino, struct ioctx *ioctx) +_sysio_incore_filop_write(struct ioctx *ioctx) { return doio((ssize_t (*)(void *, size_t, _SYSIO_OFF_T, struct incore_inode *))incore_write, - ino, ioctx); } static _SYSIO_OFF_T -_sysio_incore_filop_pos(struct inode *ino __IS_UNUSED, _SYSIO_OFF_T off) +_sysio_incore_filop_pos(struct pnode *pno __IS_UNUSED, _SYSIO_OFF_T off) { return off; @@ -1601,7 +1595,7 @@ _sysio_incore_filop_iodone(struct ioctx } static int -_sysio_incore_filop_fcntl(struct inode *ino __IS_UNUSED, +_sysio_incore_filop_fcntl(struct pnode *pno __IS_UNUSED, int cmd __IS_UNUSED, va_list ap __IS_UNUSED, int *rtn) @@ -1615,7 +1609,7 @@ _sysio_incore_filop_fcntl(struct inode * } static int -_sysio_incore_inop_sync(struct inode *ino __IS_UNUSED) +_sysio_incore_inop_sync(struct pnode *pno __IS_UNUSED) { /* @@ -1625,7 +1619,7 @@ _sysio_incore_inop_sync(struct inode *in } static int -_sysio_incore_filop_ioctl(struct inode *ino __IS_UNUSED, +_sysio_incore_filop_ioctl(struct pnode *pno __IS_UNUSED, unsigned long int request __IS_UNUSED, va_list ap __IS_UNUSED) { @@ -1642,6 +1636,8 @@ _sysio_incore_dirop_mknod(struct pnode * mode_t m; struct intnl_stat stat; ino_t inum; + int err; + struct inode *ino; assert(!pno->p_base->pb_ino); @@ -1677,13 +1673,16 @@ _sysio_incore_dirop_mknod(struct pnode * stat.st_ctime = stat.st_mtime = stat.st_atime = 0; stat.st_ino = inum; - return incore_create(pno, &stat); + err = incore_create(pno, &stat, &ino); + if (err) + return err; + I_PUT(ino); + return 0; } #ifdef _HAVE_STATVFS static int _sysio_incore_inop_statvfs(struct pnode *pno, - struct inode *ino __IS_UNUSED, struct intnl_statvfs *buf) { struct filesys *fs; |
From: Lee W. <lw...@us...> - 2008-12-06 22:16:39
|
Update of /cvsroot/libsysio/libsysio/src In directory ddv4jf1.ch3.sourceforge.com:/tmp/cvs-serv26562/src Modified Files: init.c inode.c mount.c namei.c Log Message: In do_mnt(), must put the directory being covered whether the mount succeded or not. Fixed. Index: init.c =================================================================== RCS file: /cvsroot/libsysio/libsysio/src/init.c,v retrieving revision 1.43 retrieving revision 1.44 diff -u -w -b -B -p -r1.43 -r1.44 --- init.c 6 Dec 2008 18:30:49 -0000 1.43 +++ init.c 6 Dec 2008 21:56:25 -0000 1.44 @@ -573,6 +573,7 @@ do_mnt(char *args) char *ty, *name; unsigned long flags; struct pnode *dir; + int err; len = strlen(args); if (_sysio_get_args(args, v) - args != (ssize_t )len || @@ -606,13 +607,14 @@ do_mnt(char *args) if (!(dir = _sysio_cwd) && !(dir = _sysio_root)) return -ENOENT; P_GET(dir); - return _sysio_mount(dir, + err = _sysio_mount(dir, ty, v[1].ovi_value, name, flags, v[3].ovi_value); P_PUT(dir); + return err; } Index: inode.c =================================================================== RCS file: /cvsroot/libsysio/libsysio/src/inode.c,v retrieving revision 1.46 retrieving revision 1.47 diff -u -w -b -B -p -r1.46 -r1.47 --- inode.c 26 Jul 2008 01:31:40 -0000 1.46 +++ inode.c 6 Dec 2008 21:56:25 -0000 1.47 @@ -603,7 +603,7 @@ _sysio_pb_gone(struct pnode_base *pb) if (ino) { I_RELE(ino); - if (!ino->i_ref) + if (!(ino->i_ref || ino->i_immune)) _sysio_i_gone(ino); else I_UNLOCK(ino); Index: mount.c =================================================================== RCS file: /cvsroot/libsysio/libsysio/src/mount.c,v retrieving revision 1.31 retrieving revision 1.32 diff -u -w -b -B -p -r1.31 -r1.32 --- mount.c 18 Jun 2008 15:50:39 -0000 1.31 +++ mount.c 6 Dec 2008 21:56:25 -0000 1.32 @@ -398,7 +398,6 @@ _sysio_mount(struct pnode *cwd, tocover, &mnt); } - if (err) P_PUT(tocover); return err; } @@ -746,6 +745,7 @@ _sysio_automount(struct pnode *mntpno) err = parse_automount_spec(buf, &fstype, &source, &opts); if (err) goto out; + flags = 0; if (opts) opts = parse_opts(opts, &flags); Index: namei.c =================================================================== RCS file: /cvsroot/libsysio/libsysio/src/namei.c,v retrieving revision 1.32 retrieving revision 1.33 diff -u -w -b -B -p -r1.32 -r1.33 --- namei.c 4 Nov 2008 22:04:47 -0000 1.32 +++ namei.c 6 Dec 2008 21:56:25 -0000 1.33 @@ -355,9 +355,9 @@ _sysio_path_walk(struct pnode *parent, s NULL, NULL, 1); - assert(!err || (err && !pno)); } if (!err && (err = _sysio_automount(pno)) == 0) { + struct pnode *covered; /* * All went well. Need to switch * parent pno and ino to the @@ -371,8 +371,10 @@ _sysio_path_walk(struct pnode *parent, s * The alternative could get us into an * infinite loop. */ - nd->nd_pno = nd->nd_pno->p_cover; + covered = nd->nd_pno; + nd->nd_pno = covered->p_cover; P_GET(nd->nd_pno); + P_PUT(covered); ino = nd->nd_pno->p_base->pb_ino; assert(ino); |
From: Lee W. <lw...@us...> - 2008-12-06 18:47:22
|
Update of /cvsroot/libsysio/libsysio/include In directory ddv4jf1.ch3.sourceforge.com:/tmp/cvs-serv11611 Modified Files: inode.h Log Message: Fixed INT_READLINK. It was mapping to some sort of half-create plus a setattr. Index: inode.h =================================================================== RCS file: /cvsroot/libsysio/libsysio/include/inode.h,v retrieving revision 1.44 retrieving revision 1.45 diff -u -w -b -B -p -r1.44 -r1.45 --- inode.h 5 Dec 2008 20:25:06 -0000 1.44 +++ inode.h 6 Dec 2008 18:47:14 -0000 1.45 @@ -569,8 +569,8 @@ struct intent { #define INT_SETATTR 0x02 /* set attrs */ #define INT_UPDPARENT 0x04 /* insert/delete */ #define INT_OPEN 0x08 /* open */ -#define INT_CREAT (INT_UPDPARENT|0x10) /* insert */ -#define INT_READLINK 0x12 /* readlink */ +#define INT_CREAT (0x10|INT_UPDPARENT) /* creat obj */ +#define INT_READLINK 0x20 /* readlink */ #define INTENT_INIT(intnt, mask, arg1, arg2) \ do { \ |
From: Lee W. <lw...@us...> - 2008-12-06 18:30:56
|
Update of /cvsroot/libsysio/libsysio/src In directory ddv4jf1.ch3.sourceforge.com:/tmp/cvs-serv10149 Modified Files: init.c Log Message: Ficxed a bug in do_open(). It could do an improper release under many circumstances. Index: init.c =================================================================== RCS file: /cvsroot/libsysio/libsysio/src/init.c,v retrieving revision 1.42 retrieving revision 1.43 diff -u -w -b -B -p -r1.42 -r1.43 --- init.c 15 Oct 2008 22:01:01 -0000 1.42 +++ init.c 6 Dec 2008 18:30:49 -0000 1.43 @@ -748,11 +748,11 @@ do_open(char *args) err = -ENOMEM; break; } + pno = NULL; err = _sysio_fd_set(fil, fd, 1); if (err < 0) break; - P_RELE(pno); - return 0; + err = 0; } while (0); if (fil) FIL_PUT(fil); |
From: Lee W. <lw...@us...> - 2008-12-06 18:29:21
|
Update of /cvsroot/libsysio/libsysio/src In directory ddv4jf1.ch3.sourceforge.com:/tmp/cvs-serv9917 Modified Files: file.c Log Message: Simplified _sysio_fd_close_all. It was duplicating _sysio_fd_close, I think improperly. Index: file.c =================================================================== RCS file: /cvsroot/libsysio/libsysio/src/file.c,v retrieving revision 1.24 retrieving revision 1.25 diff -u -w -b -B -p -r1.24 -r1.25 --- file.c 11 Jul 2008 18:23:57 -0000 1.24 +++ file.c 6 Dec 2008 18:29:13 -0000 1.25 @@ -341,11 +341,7 @@ _sysio_fd_close_all() fd++, filp++) { if (!*filp) continue; - FIL_LOCK(*filp); - P_RELE((*filp)->f_pno); - FIL_RELE(*filp); - FIL_UNLOCK(*filp); - *filp = NULL; + (void )_sysio_fd_close(fd); } /* |
From: Lee W. <lw...@us...> - 2008-12-06 18:22:36
|
Update of /cvsroot/libsysio/libsysio/src In directory ddv4jf1.ch3.sourceforge.com:/tmp/cvs-serv9324 Modified Files: open.c Log Message: Fixed a bug in _sysio_open; After calling the driver open, successfully, it was taking an extra, unneeded, reference. As well, in _sysio_open, after the driver does it's open, we want to make sure there is an inode present; Next thing we will probably do is install the thing into the open file table. Added a validate, then. Index: open.c =================================================================== RCS file: /cvsroot/libsysio/libsysio/src/open.c,v retrieving revision 1.33 retrieving revision 1.34 diff -u -w -b -B -p -r1.33 -r1.34 --- open.c 15 Oct 2008 22:01:01 -0000 1.33 +++ open.c 6 Dec 2008 18:22:27 -0000 1.34 @@ -96,7 +97,7 @@ _sysio_open(struct pnode *pno, int flags return -EROFS; err = _sysio_p_validate(pno->p_parent, NULL, NULL); if (!err && (err = PNOP_OPEN(pno, flags, mode)) == 0) - I_REF(pno->p_base->pb_ino); + err = _sysio_p_validate(pno, NULL, NULL); } else if ((flags & (O_CREAT|O_EXCL)) == (O_CREAT|O_EXCL)) err = -EEXIST; else if (!pno->p_base->pb_ino) |
From: Lee W. <lw...@us...> - 2008-12-05 20:25:12
|
Update of /cvsroot/libsysio/libsysio/include In directory ddv4jf1.ch3.sourceforge.com:/tmp/cvs-serv27935 Modified Files: inode.h Log Message: The I_GONE macro was really just doing only creating a zombie inode. With this change, it's really gone now. Index: inode.h =================================================================== RCS file: /cvsroot/libsysio/libsysio/include/inode.h,v retrieving revision 1.43 retrieving revision 1.44 diff -u -w -b -B -p -r1.43 -r1.44 --- inode.h 26 Jul 2008 01:33:14 -0000 1.43 +++ inode.h 5 Dec 2008 20:25:06 -0000 1.44 @@ -246,8 +246,7 @@ struct inode { #define I_GONE(_ino) \ do { \ _I_CHECK_LOCK((_ino), 1); \ - _sysio_i_undead(_ino); \ - I_PUT(_ino); \ + _sysio_i_gone(_ino); \ } while (0) /* |
From: Ruth K. <rk...@us...> - 2008-11-04 22:25:37
|
Update of /cvsroot/libsysio/libsysio/src In directory ddv4jf1.ch3.sourceforge.com:/tmp/cvs-serv21459 Modified Files: Tag: RELEASE_1_2 namei.c Log Message: fix for cray Bug 745866 stat call on broken symlink fails Index: namei.c =================================================================== RCS file: /cvsroot/libsysio/libsysio/src/namei.c,v retrieving revision 1.19 retrieving revision 1.19.2.1 diff -u -w -b -B -p -r1.19 -r1.19.2.1 --- namei.c 8 Feb 2006 17:17:43 -0000 1.19 +++ namei.c 4 Nov 2008 22:25:26 -0000 1.19.2.1 @@ -262,7 +262,7 @@ _sysio_path_walk(struct pnode *parent, s * Handle symbolic links with recursion. Yuck! */ ND_INIT(&nameidata, - (nd->nd_flags | ND_NEGOK), + nd->nd_flags, lpath, nd->nd_root, !next.len ? nd->nd_intent : NULL); |
From: Ruth K. <rk...@us...> - 2008-11-04 22:10:43
|
Update of /cvsroot/libsysio/libsysio/src In directory ddv4jf1.ch3.sourceforge.com:/tmp/cvs-serv19029 Modified Files: Tag: RELEASE_1_3 namei.c Log Message: fix for cray Bug 745866 stat call on broken symlink fails Index: namei.c =================================================================== RCS file: /cvsroot/libsysio/libsysio/src/namei.c,v retrieving revision 1.26 retrieving revision 1.26.2.1 diff -u -w -b -B -p -r1.26 -r1.26.2.1 --- namei.c 1 May 2007 16:33:53 -0000 1.26 +++ namei.c 4 Nov 2008 22:10:34 -0000 1.26.2.1 @@ -268,7 +268,7 @@ _sysio_path_walk(struct pnode *parent, s * Handle symbolic links with recursion. Yuck! */ ND_INIT(&nameidata, - (nd->nd_flags | ND_NEGOK), + nd->nd_flags, lpath, nd->nd_root, !next.len ? nd->nd_intent : NULL); |
From: Ruth K. <rk...@us...> - 2008-11-04 22:05:00
|
Update of /cvsroot/libsysio/libsysio/src In directory ddv4jf1.ch3.sourceforge.com:/tmp/cvs-serv18082 Modified Files: namei.c Log Message: fix for cray Bug 745866 stat call on broken symlink fails Index: namei.c =================================================================== RCS file: /cvsroot/libsysio/libsysio/src/namei.c,v retrieving revision 1.31 retrieving revision 1.32 diff -u -w -b -B -p -r1.31 -r1.32 --- namei.c 15 Oct 2008 22:01:01 -0000 1.31 +++ namei.c 4 Nov 2008 22:04:47 -0000 1.32 @@ -311,7 +311,7 @@ _sysio_path_walk(struct pnode *parent, s P_REF(nd->nd_pno); P_PUT(nd->nd_pno); ND_INIT(&nameidata, - (nd->nd_flags | ND_NEGOK), + nd->nd_flags, lpath, nd->nd_root, !next.len ? nd->nd_intent : NULL); |
From: Ruth K. <rk...@us...> - 2008-10-15 22:52:27
|
Update of /cvsroot/libsysio/libsysio/src In directory ddv4jf1.ch3.sourceforge.com:/tmp/cvs-serv28417 Modified Files: module.mk Log Message: remove stray FILE_SUPPORT definition left over from lustre hack Index: module.mk =================================================================== RCS file: /cvsroot/libsysio/libsysio/src/module.mk,v retrieving revision 1.18 retrieving revision 1.19 diff -u -w -b -B -p -r1.18 -r1.19 --- module.mk 15 Oct 2008 22:01:01 -0000 1.18 +++ module.mk 15 Oct 2008 22:52:19 -0000 1.19 @@ -10,8 +10,6 @@ else TRACING_SRCS = endif -FILE_SUPPORT = src/file.c - if WITH_STATVFS STATVFS_SRCS = src/statvfs.c else @@ -20,7 +18,7 @@ endif SRCDIR_SRCS = src/access.c src/chdir.c src/chmod.c \ src/chown.c src/dev.c src/dup.c src/fcntl.c \ - src/fs.c src/fsync.c \ + src/file.c src/fs.c src/fsync.c \ src/getdirentries.c src/init.c src/inode.c \ src/ioctl.c src/ioctx.c src/iowait.c \ src/link.c src/lseek.c src/mkdir.c \ @@ -30,6 +28,6 @@ SRCDIR_SRCS = src/access.c src/chdir.c s src/stddir.c src/readdir.c src/readdir64.c \ src/symlink.c src/readlink.c \ src/truncate.c src/unlink.c src/utime.c \ - $(FILE_SUPPORT) $(TRACING_SRCS) src/cprintf.c src/tree.c + $(TRACING_SRCS) src/cprintf.c src/tree.c SRCDIR_EXTRA = src/module.mk |
From: Ruth K. <rk...@us...> - 2008-10-15 22:01:18
|
Update of /cvsroot/libsysio/libsysio/tests In directory ddv4jf1.ch3.sourceforge.com:/tmp/cvs-serv25646/tests Modified Files: Makefile.am README Log Message: Removing obsolete code related to cplant yod, lustre hack, and sockets driver. Index: Makefile.am =================================================================== RCS file: /cvsroot/libsysio/libsysio/tests/Makefile.am,v retrieving revision 1.30 retrieving revision 1.31 diff -u -w -b -B -p -r1.30 -r1.31 --- Makefile.am 2 Jul 2007 18:58:18 -0000 1.30 +++ Makefile.am 15 Oct 2008 22:01:01 -0000 1.31 @@ -27,16 +27,7 @@ INCORE_DRIVER_NAME= INCORE_DRIVER_CFLAGS= endif -if WITH_CPLANT_YOD -YOD_DRIVER_NAME=yod -YOD_DRIVER_CFLAGS= -DCPLANT_YOD -else -YOD_DRIVER_NAME= -YOD_DRIVER_CFLAGS= -endif - -DRIVERS=$(NATIVE_DRIVER_NAME) $(INCORE_DRIVER_NAME) $(YOD_DRIVER_NAME) \ - $(STFD_DEV_NAME) +DRIVERS=$(NATIVE_DRIVER_NAME) $(INCORE_DRIVER_NAME) $(STFD_DEV_NAME) CMNSRC=startup.c drv_init_all.c drv_data.c @@ -44,7 +35,7 @@ BUILT_SOURCES=drv_data.c CFL=$(AM_CFLAGS) $(AM_CPPFLAGS) \ $(NATIVE_DRIVER_CFLAGS) $(INCORE_DRIVER_CFLAGS) \ - $(STDFD_DEV_CFLAGS) $(YOD_DRIVER_CFLAGS) + $(STDFD_DEV_CFLAGS) LIBS=$(LIBBUILD_DIR)/libsysio.a Index: README =================================================================== RCS file: /cvsroot/libsysio/libsysio/tests/README,v retrieving revision 1.3 retrieving revision 1.4 diff -u -w -b -B -p -r1.3 -r1.4 --- README 18 Aug 2003 15:52:20 -0000 1.3 +++ README 15 Oct 2008 22:01:01 -0000 1.4 @@ -17,8 +17,7 @@ are ran with the test_all.pl script. He of the scripts. All scripts take an optional "-alpha" arg for running the scripts in an alpha/cplant environment. The alpha arg makes certain assumptions about the running of the -environment; for example, it does not initilization and it -starts off the test driver with yod. +environment; for example, it does not do initilization. test_copy.pl <src> <dest> : This copies a file from src to dest. : It runs a system cmp to verify that |
From: Ruth K. <rk...@us...> - 2008-10-15 22:01:11
|
Update of /cvsroot/libsysio/libsysio In directory ddv4jf1.ch3.sourceforge.com:/tmp/cvs-serv25646 Modified Files: Makefile.am Rules.make configure.in Log Message: Removing obsolete code related to cplant yod, lustre hack, and sockets driver. Index: Makefile.am =================================================================== RCS file: /cvsroot/libsysio/libsysio/Makefile.am,v retrieving revision 1.17 retrieving revision 1.18 diff -u -w -b -B -p -r1.17 -r1.18 --- Makefile.am 17 Jun 2008 17:18:56 -0000 1.17 +++ Makefile.am 15 Oct 2008 22:01:01 -0000 1.18 @@ -13,8 +13,6 @@ include $(top_srcdir)/dev/module.mk include $(top_srcdir)/dev/stdfd/module.mk include $(top_srcdir)/drivers/incore/module.mk include $(top_srcdir)/drivers/native/module.mk -include $(top_srcdir)/drivers/yod/module.mk -include $(top_srcdir)/drivers/sockets/module.mk lib_LIBRARIES = ${LIBBUILD_DIR}/libsysio.a @@ -42,42 +40,19 @@ else OPTIONAL_NATIVE_SRCS = endif -if WITH_SOCKETS_DRIVER -OPTIONAL_SOCKETS_SRCS = $(SOCKETS_SRCS) -else -OPTIONAL_SOCKETS_SRCS = -endif - -if WITH_CPLANT_YOD -OPTIONAL_YOD_SRCS = $(YOD_SRCS) -else -OPTIONAL_YOD_SRCS = -endif - -if WITH_LUSTRE_HACK -# it would be better that let configure script check this -OPTIONAL_LUSTRE_CFLAGS = -fPIC -endif - -AM_CFLAGS = $(OPTIONAL_LUSTRE_CFLAGS) - __LIBBUILD_DIR__libsysio_a_SOURCES = \ $(SRCDIR_SRCS) \ $(THREAD_MODEL_POSIX_SRCS) \ $(OPTIONAL_STDDEV_SRCS) \ $(OPTIONAL_STDFD_SRCS) \ $(OPTIONAL_INCORE_SRCS) \ - $(OPTIONAL_SOCKETS_SRCS) \ - $(OPTIONAL_NATIVE_SRCS) \ - $(OPTIONAL_YOD_SRCS) + $(OPTIONAL_NATIVE_SRCS) include $(top_srcdir)/Rules.make EXTRA_DIST = Rules.make misc/init-env.sh $(TESTS_EXTRA) $(SRCDIR_EXTRA) \ $(INCLUDE_EXTRA) $(STDDEV_EXTRA) $(STDFD_EXTRA) $(INCORE_EXTRA) \ - $(SOCKETS_EXTRA) $(NATIVE_EXTRA) $(YOD_EXTRA) - -AM_CPPFLAGS += ${YOD_DRIVER_FLAGS} + $(NATIVE_EXTRA) really-clean: testsclean maintainer-clean -rm -rf autom4te-2.53.cache Index: Rules.make =================================================================== RCS file: /cvsroot/libsysio/libsysio/Rules.make,v retrieving revision 1.15 retrieving revision 1.16 diff -u -w -b -B -p -r1.15 -r1.16 --- Rules.make 17 Jun 2008 17:18:56 -0000 1.15 +++ Rules.make 15 Oct 2008 22:01:01 -0000 1.16 @@ -9,12 +9,6 @@ else STDEV_DEV_CPPFLAGS = endif -if WITH_SOCKETS_DRIVER -SOCKETS_CPPFLAGS=-DWITH_SOCKETS=1 -else -SOCKETS_CPPFLAGS= -endif - DEV_CPPFLAGS = $(STDFD_DEV_CPPFLAGS) $(STDDEV_DEV_CPPFLAGS) if WITH_THREAD_MODEL_POSIX @@ -26,6 +20,6 @@ endif AM_CPPFLAGS = \ $(THREAD_MODEL_POSIX_COMPILER_FLAGS) \ $(TRACING) \ - $(AUTOMOUNT) $(ZERO_SUM_MEMORY) $(DEV_CPPFLAGS) $(SOCKETS_CPPFLAGS) \ + $(AUTOMOUNT) $(ZERO_SUM_MEMORY) $(DEV_CPPFLAGS) \ $(DEFER_INIT_CWD) $(SYSIO_LABEL_NAMES) $(_HAVE_STATVFS) \ -I$(top_srcdir)/include Index: configure.in =================================================================== RCS file: /cvsroot/libsysio/libsysio/configure.in,v retrieving revision 1.42 retrieving revision 1.43 diff -u -w -b -B -p -r1.42 -r1.43 --- configure.in 11 Jul 2008 18:25:05 -0000 1.42 +++ configure.in 15 Oct 2008 22:01:01 -0000 1.43 @@ -148,63 +148,6 @@ AC_ARG_WITH(tracing, AM_CONDITIONAL(WITH_TRACING, test x$with_tracing = xyes) AC_SUBST(TRACING) -AC_ARG_WITH(cplant_yod, - AC_HELP_STRING([--with-cplant-yod],[build cplant yod I/O driver]), - [ case "${withval}" in - yes) if test x${with_stdfd_dev} != xyes; then - with_stdfd_dev=yes - AM_CONDITIONAL(WITH_STDFD_DEV, test x$with_stdfd_dev = xyes) - fi ;; - no) ;; - *) AC_MSG_ERROR(bad value ${withval} for --with-cplant-yod);; - esac], - [with_cplant_yod=no]) -AM_CONDITIONAL(WITH_CPLANT_YOD, test x$with_cplant_yod = xyes) - -AC_ARG_WITH(cplant_tests, - AC_HELP_STRING([--with-cplant-tests=<cplant-build-path>], - [build libsysio tests for cplant platform]), - [ case "${withval}" in - yes) AC_MSG_ERROR(need path to compiler for --with-cplant-tests);; - no) with_cplant_tests=no;; - *) CC=${withval} - CCDEPMODE=${CC} - CPP="${CC} -E" - AC_CHECK_FILE(${CC}, - [ if test x${with_cplant_yod} != xyes; then - with_cplant_yod=yes - AM_CONDITIONAL(WITH_CPLANT_YOD, test x$with_cplant_yod = xyes) - fi], - [ AC_MSG_ERROR(path not found ${CC} for --with-cplant-tests) ]);; - esac], - [with_cplant_tests=no]) -AM_CONDITIONAL(WITH_CPLANT_TESTS, test x$with_cplant_tests != xno) - -AC_ARG_WITH(sockets, - AC_HELP_STRING([--with-sockets], - [build sockets interface driver (EXPERIMENTAL)]), - [ case "${withval}" in - yes) AC_MSG_ERROR(the sockets driver is broken right now);; - no) ;; - *) AC_MSG_ERROR(bad value ${withval} for --with-sockets) ;; - esac], - [with_sockets=no]) -AM_CONDITIONAL(WITH_SOCKETS_DRIVER, test x$with_sockets = xyes) - -AC_ARG_WITH(lustre-hack, - AC_HELP_STRING([--with-lustre-hack], - [have hacking code which needed to support liblustre driver (EXPERIMENTAL)]), - [ case "${withval}" in - yes) ;; - no) ;; - *) AC_MSG_ERROR(bad value ${withval} for --with-lustre-hack) ;; - esac], - [with_lustre_hack=no]) -AM_CONDITIONAL(WITH_LUSTRE_HACK, test x$with_lustre_hack = xyes) -if test x$with_lustre_hack = xyes; then - AC_DEFINE(HAVE_LUSTRE_HACK) -fi - AC_ARG_WITH(alternate-symbols, AC_HELP_STRING([--with-alternate-symbols@<:@=<qualifier>@:>@], [Prepend standard, public, symbols with a unique qualifer]), @@ -416,8 +359,6 @@ EOF done]) if test $sysio_asm_global_directive = UNKNOWN; then AC_MSG_ERROR(cannot determine asm global directive) -#else -# AC_DEFINE_UNQUOTED(ASM_GLOBAL_DIRECTIVE, ${sysio_asm_global_directive}) fi AC_CACHE_CHECK(for .set assembler directive, @@ -441,9 +382,6 @@ EOF sysio_asm_set_directive=no fi rm -f conftest*]) -#if test $sysio_asm_set_directive = yes; then -# AC_DEFINE(HAVE_ASM_SET_DIRECTIVE) -#fi AC_CACHE_CHECK(for assembler .weak directive, sysio_asm_weak_directive, [dnl |