IBNOS
Functions | Variables
filesystem.c File Reference
#include <process/filesystem.h>
#include <process/object.h>
#include <memory/allocator.h>
#include <console/console.h>
#include <util/list.h>
#include <util/util.h>
Include dependency graph for filesystem.c:

Go to the source code of this file.

Functions

struct directory * directoryCreate (struct directory *parent, char *name, uint32_t nameLength)
 Creates a new kernel directory object. More...
 
struct file * fileCreate (struct directory *parent, char *name, uint32_t nameLength, uint8_t *staticBuffer, uint32_t staticSize)
 Creates a new kernel file object. More...
 
struct openedFile * fileOpen (struct file *file)
 Creates a new kernel openedFile object. More...
 
struct openedDirectory * directoryOpen (struct directory *directory)
 Creates a new kernel openedDirectory object. More...
 
void fileSystemInit (void *addr, uint32_t length)
 Initializes the root file system. More...
 
struct directory * fileSystemIsValidDirectory (struct object *obj)
 Checks if a given object is of the type directory and casts it if possible. More...
 
struct file * fileSystemIsValidFile (struct object *obj)
 Checks if a given object is of the type file and casts it if possible. More...
 
struct directory * fileSystemGetRoot ()
 Returns a reference to the root node of the file system. More...
 
struct directory * fileSystemSearchDirectory (struct directory *directory, char *path, uint32_t pathLength, bool create)
 Opens or creates a directory. More...
 
struct file * fileSystemSearchFile (struct directory *directory, char *path, uint32_t pathLength, bool create)
 Opens or creates a file. More...
 

Variables

struct directory * fileSystemRoot