My Kernel v0.1.0
vnode_operations Struct Reference

Vector table for operations performed on a single virtual node.

#include <vfs.h>

Data Fields

vnode_t *(* lookup )(vnode_t *, const path_segment_t *)
 Find a child node (by name) inside a directory node. More...
 
vnode_t *(* create )(vnode_t *node, const char *name, vnode_type)
 Add a new child to the vnode.
 
error_t(* remove )(vnode_t *node, const char *child)
 Remove a child from a directory.
 
struct file *(* open )(vnode_t *vnode)
 Create a new opened file corresponding to this vnode

 
void(* release )(vnode_t *node)
 Called by the VFS driver before deleting a vnode (optional). More...
 

Field Documentation

◆ lookup

vnode_t *(* vnode_operations::lookup) (vnode_t *, const path_segment_t *)
Warning
The node returned by this function MUST be released afterwards using vfs_vnode_release (subject to change in the future).

◆ release

void(* vnode_operations::release) (vnode_t *node)

This is responsible for freeing/updating any necessary internal structures before deleting a vnode.


The documentation for this struct was generated from the following file: