|
AquilaOS documentation
How it works, and its code
|
Go to the source code of this file.
Data Structures | |
| struct | vcache |
| A filesystem's vnode cache (fs/vcache.c): its vnodes in memory, by their inode number, so that a file has one vnode however it's reached. More... | |
Functions | |
| void | vcache_init (struct vcache *vcache) |
| Sets up an empty vnode cache. | |
| int | vcache_insert (struct vcache *vcache, struct vnode *vnode) |
| Adds a vnode to a cache. | |
| int | vcache_remove (struct vcache *vcache, struct vnode *vnode) |
| Takes a vnode out of a cache. | |
| struct vnode * | vcache_find (struct vcache *vcache, ino_t ino) |
| Finds the cached vnode of an inode. | |
Finds the cached vnode of an inode.
| vcache | the cache |
| ino | the inode number |
Definition at line 80 of file vcache.c.
References hashmap_node::entry, hashmap_node::hash, vcache::hashmap, vnode::ino, NULL, and vcache_find().
Referenced by ext2_inode_build(), minix_inode_build(), procfs_close(), procfs_vget(), and vcache_find().
| void vcache_init | ( | struct vcache * | vcache | ) |
Sets up an empty vnode cache.
| vcache | the cache |
Definition at line 25 of file vcache.c.
References vcache::hashmap, vcache_eq(), and vcache_init().
Referenced by ext2_load(), minix_load(), procfs_init(), vcache_init(), and vcache_insert().
Adds a vnode to a cache.
| vcache | the cache, set up on first use |
| vnode | the vnode |
Definition at line 37 of file vcache.c.
References vcache::hashmap, vnode::ino, vcache_init(), and vcache_insert().
Referenced by ext2_inode_build(), minix_inode_build(), procfs_vget(), and vcache_insert().
Takes a vnode out of a cache.
| vcache | the cache |
| vnode | the vnode |
Definition at line 56 of file vcache.c.
References hashmap_node::hash, vcache::hashmap, vnode::ino, and vcache_remove().
Referenced by ext2_close(), procfs_close(), and vcache_remove().