diff --git a/src/sys/ubixfs/dirCache.c b/src/sys/ubixfs/dirCache.c index 49a946e..ffa10ee 100644 --- a/src/sys/ubixfs/dirCache.c +++ b/src/sys/ubixfs/dirCache.c @@ -35,7 +35,7 @@ struct cacheNode * -ubixfs_dirCacheFind(struct cacheNode * head, char * name) { +ubixfs_cacheFind(struct cacheNode * head, char * name) { struct cacheNode * tmp = head; struct directoryEntry * dirList = NULL; unsigned int i = 0x0; @@ -73,7 +73,7 @@ if (*nextDir != '\0') { while (tmp != NULL) { if (strcmp(tmp->name, dirName) == 0) - return ubixfs_dirCacheFind(tmp->subDirsHead, nextDir); + return ubixfs_cacheFind(tmp->subDirsHead, nextDir); tmp = tmp->next; } /* while */ tmp = tmp->parent; @@ -82,7 +82,7 @@ dirList = (struct directoryEntry *)tmp->info; for (i = 0; i < tmp->dirListEntryCount; i++) { if (strcmp(dirList[i].fileName, nextDir) == 0) { - tmp = ubixfs_dirCacheAdd(tmp, ubixfs_dirCacheNew(dirList[i].fileName)); + tmp = ubixfs_cacheAdd(tmp, ubixfs_dirCacheNew(dirList[i].fileName)); } /* if */ } /* for */ @@ -153,7 +153,7 @@ * will be caught with the above checks */ /* if (tmp->subDirsHead != NULL) */ - ubixfs_dirCacheDelete(&tmp->subDirsHead); + ubixfs_CacheDelete(&tmp->subDirsHead); kfree(tmp->info); kfree(tmp->name); @@ -177,7 +177,7 @@ #endif struct cacheNode * -ubixfs_dirCacheAdd(struct cacheNode *node, struct cacheNode * newNode) { +ubixfs_CacheAdd(struct cacheNode *node, struct cacheNode * newNode) { struct cacheNode * tmp; assert(node); @@ -192,15 +192,23 @@ node->subDirsHead = newNode; tmp = node->subDirsHead; return tmp; -} /* ubixfs_dirCacheAdd */ +} /* ubixfs_cacheAdd */ /*** $Log$ + Revision 1.9 2004/07/21 22:00:04 flameshadow + chg: ubixfws_dirCacheAdd now returns a pointer to the node it added + chg: minor fix in ubixfs_dirCacheFind() + Revision 1.6 2004/07/21 14:43:14 flameshadow add: added cwc (current working container) to the osInfo strut Revision 1.5 2004/07/20 19:21:30 reddawg You like leaving out $Log$ + You like leaving out Revision 1.9 2004/07/21 22:00:04 flameshadow + You like leaving out chg: ubixfws_dirCacheAdd now returns a pointer to the node it added + You like leaving out chg: minor fix in ubixfs_dirCacheFind() + You like leaving out You like leaving out Revision 1.6 2004/07/21 14:43:14 flameshadow You like leaving out add: added cwc (current working container) to the osInfo strut You like leaving out so i don't know what is going on eh? diff --git a/src/sys/ubixfs/ubixfs.c b/src/sys/ubixfs/ubixfs.c index 9afcf3e..7cb464e 100644 --- a/src/sys/ubixfs/ubixfs.c +++ b/src/sys/ubixfs/ubixfs.c @@ -109,7 +109,7 @@ mp->diskLabel->partitions[mp->partition].pBatSize); /* mji */ - fsInfo->dirCache = ubixfs_dirCacheNew("/"); + fsInfo->dirCache = ubixfs_cacheNew("/"); assert(fsInfo->dirCache); /* mji */ fsInfo->dirCache->info = (struct directoryEntry *)kmalloc(0x4000); /* allocate root dir */ @@ -120,7 +120,7 @@ 0x4000 / 512); /* mji */ - //UBU dircache the ubixfs fs info struct fsInfo ->(pointer to) your rootdir thing like fsInfo->rootDirCache=ubifs_dirCacheNode(blah); + //UBU dircache the ubixfs fs info struct fsInfo ->(pointer to) your rootdir thing like fsInfo->rootDirCache=ubixfs_cacheNode(blah); kprintf(" Offset: [%i], Partition: [%i]\n", mp->diskLabel->partitions[mp->partition].pOffset,mp->partition); kprintf("UbixFS Initialized\n"); @@ -429,6 +429,9 @@ /*** $Log$ + Revision 1.27 2004/07/21 21:08:05 flameshadow + add: added provisions for file caching + Revision 1.26 2004/07/20 23:21:31 flameshadow syncing