#include <ubixfs.h>
Inheritance diagram for UbixFS:

Public Member Functions | |
| UbixFS (device_t *) | |
| UbixFS (void) | |
| virtual int | vfs_close (fileDescriptor *) |
| virtual int | vfs_closedir (DIR *) |
| virtual int | vfs_format (device_t *) |
| virtual int | vfs_init (void) |
| virtual int | vfs_mkdir (const char *, mode_t) |
| virtual void * | vfs_mknod (const char *, mode_t) |
| virtual int | vfs_open (const char *, fileDescriptor *, int,...) |
| virtual int | vfs_opendir (DIR *, const char *) |
| virtual int | vfs_purge (void) |
| virtual size_t | vfs_read (fileDescriptor *, void *, off_t, size_t) |
| virtual int | vfs_readdir (DIR *, struct dirent *) |
| virtual int | vfs_rename (const char *, const char *) |
| virtual int | vfs_rmdir (const char *) |
| virtual int | vfs_stop (void) |
| virtual int | vfs_sync (void) |
| virtual int | vfs_unlink (const char *) |
| virtual size_t | vfs_write (fileDescriptor *, void *, off_t, size_t) |
| virtual | ~UbixFS (void) |
Protected Member Functions | |
| blockRun | get8FreeBlocks (uInt32) |
| blockRun | getFreeBlock (void) |
| blockRun | getFreeBlock (uInt32) |
| blockRun | getFreeBlock (blockRun) |
| uInt32 | getNextAG (void) |
| void * | mknod (const char *, ubixfsInode *, mode_t) |
| void | printFreeBlockList (uInt32) |
| void | printSuperBlock (void) |
| void | setFreeBlock (blockRun) |
Protected Attributes | |
| device_t * | device |
| signed char * | freeBlockList |
| vfs_abstract * | next |
| vfs_abstract * | prev |
| fileDescriptor * | root |
| diskSuperBlock * | superBlock |
Friends | |
| class | bTree |
Definition at line 132 of file ubixfs.h.
| UbixFS::UbixFS | ( | void | ) |
| UbixFS::UbixFS | ( | device_t * | ) |
Definition at line 21 of file ubixfs.cpp.
References dev, freeBlockList, NULL, root, and superBlock.
| UbixFS::~UbixFS | ( | void | ) | [virtual] |
| blockRun UbixFS::getFreeBlock | ( | void | ) | [protected] |
Definition at line 777 of file ubixfs.cpp.
References getNextAG().
Referenced by getFreeBlock(), mknod(), and vfs_write().
Definition at line 616 of file ubixfs.cpp.
References freeBlockList, getFreeBlock(), NULL, and superBlock.
| uInt32 UbixFS::getNextAG | ( | void | ) | [protected] |
| void * UbixFS::mknod | ( | const char * | , | |
| ubixfsInode * | , | |||
| mode_t | ||||
| ) | [protected] |
Definition at line 835 of file ubixfs.cpp.
References assert, getFreeBlock(), getgid(), getuid(), MAX_FILENAME_LENGTH, memset(), NULL, strncpy(), superBlock, and UBIXFS_INODE_MAGIC.
Referenced by vfs_mkdir(), and vfs_mknod().
| void UbixFS::printFreeBlockList | ( | uInt32 | ) | [protected] |
| void UbixFS::printSuperBlock | ( | void | ) | [protected] |
| void UbixFS::setFreeBlock | ( | blockRun | ) | [protected] |
| virtual int vfs_abstract::vfs_close | ( | fileDescriptor * | ) | [inline, virtual, inherited] |
Definition at line 18 of file fsAbstract.h.
| virtual int vfs_abstract::vfs_closedir | ( | DIR * | ) | [inline, virtual, inherited] |
Definition at line 26 of file fsAbstract.h.
| int UbixFS::vfs_format | ( | device_t * | ) | [virtual] |
Reimplemented from vfs_abstract.
Definition at line 118 of file ubixfs.cpp.
References assert, dev, bTreeHeader::firstDeleted, bTreeHeader::firstNodeOffset, getgid(), getuid(), INODE_DIRECTORY, memset(), NULL, strcpy(), bTreeHeader::treeDepth, bTreeHeader::treeLeafCount, bTreeHeader::treeWidth, UBIXFS_INODE_MAGIC, UBIXFS_MAGIC1, UBIXFS_MAGIC2, and UBIXFS_MAGIC3.
Referenced by main().
| int UbixFS::vfs_init | ( | void | ) | [virtual] |
Reimplemented from vfs_abstract.
Definition at line 50 of file ubixfs.cpp.
References assert, bTree, freeBlockList, fileDescriptor::inode, memset(), NULL, printSuperBlock(), root, strcmp(), superBlock, UBIXFS_CLEAN, UBIXFS_MAGIC1, UBIXFS_MAGIC2, and UBIXFS_MAGIC3.
Referenced by main().
| int UbixFS::vfs_mkdir | ( | const char * | , | |
| mode_t | ||||
| ) | [virtual] |
Reimplemented from vfs_abstract.
Definition at line 891 of file ubixfs.cpp.
References assert, fileDescriptor::inode, INODE_DIRECTORY, MAX_FILENAME_LENGTH, memset(), mknod(), name, NULL, root, strlen(), and strncpy().
Referenced by main().
| void * UbixFS::vfs_mknod | ( | const char * | , | |
| mode_t | ||||
| ) | [virtual] |
| int UbixFS::vfs_open | ( | const char * | , | |
| fileDescriptor * | , | |||
| int | , | |||
| ... | ||||
| ) | [virtual] |
Reimplemented from vfs_abstract.
Definition at line 310 of file ubixfs.cpp.
References fileDescriptor::inode, NULL, fileDescriptor::offset, and fileDescriptor::size.
| virtual int vfs_abstract::vfs_opendir | ( | DIR * | , | |
| const char * | ||||
| ) | [inline, virtual, inherited] |
Definition at line 25 of file fsAbstract.h.
| virtual int vfs_abstract::vfs_purge | ( | void | ) | [inline, virtual, inherited] |
Definition at line 35 of file fsAbstract.h.
| size_t UbixFS::vfs_read | ( | fileDescriptor * | , | |
| void * | , | |||
| off_t | , | |||
| size_t | ||||
| ) | [virtual] |
Reimplemented from vfs_abstract.
Definition at line 321 of file ubixfs.cpp.
References assert, fileDescriptor::inode, NULL, NUM_DIRECT_BLOCKS, and superBlock.
| virtual int vfs_abstract::vfs_readdir | ( | DIR * | , | |
| struct dirent * | ||||
| ) | [inline, virtual, inherited] |
Definition at line 29 of file fsAbstract.h.
| virtual int vfs_abstract::vfs_rename | ( | const char * | , | |
| const char * | ||||
| ) | [inline, virtual, inherited] |
Definition at line 41 of file fsAbstract.h.
| virtual int vfs_abstract::vfs_rmdir | ( | const char * | ) | [inline, virtual, inherited] |
Definition at line 28 of file fsAbstract.h.
| int UbixFS::vfs_stop | ( | void | ) | [virtual] |
Reimplemented from vfs_abstract.
Definition at line 557 of file ubixfs.cpp.
References freeBlockList, fileDescriptor::inode, NULL, root, superBlock, and vfs_sync().
Referenced by main().
| int UbixFS::vfs_sync | ( | void | ) | [virtual] |
Reimplemented from vfs_abstract.
Definition at line 588 of file ubixfs.cpp.
References freeBlockList, NULL, and superBlock.
Referenced by vfs_stop().
| virtual int vfs_abstract::vfs_unlink | ( | const char * | ) | [inline, virtual, inherited] |
Definition at line 40 of file fsAbstract.h.
| size_t UbixFS::vfs_write | ( | fileDescriptor * | , | |
| void * | , | |||
| off_t | , | |||
| size_t | ||||
| ) | [virtual] |
Reimplemented from vfs_abstract.
Definition at line 387 of file ubixfs.cpp.
References assert, getFreeBlock(), fileDescriptor::inode, NULL, NUM_DIRECT_BLOCKS, and superBlock.
friend class bTree [friend] |
device_t* vfs_abstract::device [protected, inherited] |
Definition at line 14 of file fsAbstract.h.
signed char* UbixFS::freeBlockList [protected] |
Definition at line 134 of file ubixfs.h.
Referenced by get8FreeBlocks(), getFreeBlock(), printFreeBlockList(), setFreeBlock(), UbixFS(), vfs_init(), vfs_stop(), vfs_sync(), and ~UbixFS().
vfs_abstract* vfs_abstract::next [protected, inherited] |
Definition at line 13 of file fsAbstract.h.
vfs_abstract* vfs_abstract::prev [protected, inherited] |
Definition at line 12 of file fsAbstract.h.
fileDescriptor* UbixFS::root [protected] |
Definition at line 136 of file ubixfs.h.
Referenced by UbixFS(), vfs_init(), vfs_mkdir(), and vfs_stop().
diskSuperBlock* UbixFS::superBlock [protected] |
Definition at line 135 of file ubixfs.h.
Referenced by get8FreeBlocks(), getFreeBlock(), getNextAG(), mknod(), printFreeBlockList(), printSuperBlock(), setFreeBlock(), UbixFS(), vfs_init(), vfs_read(), vfs_stop(), vfs_sync(), and vfs_write().
1.4.7