UbixOS V2 2.0

Functions
directory.c File Reference
`#include <ubixfs/ubixfs.h>`
`#include <vfs/file.h>`
`#include <vfs/mount.h>`
`#include <lib/kmalloc.h>`
`#include <lib/kprintf.h>`
`#include <string.h>`
Include dependency graph for directory.c:

Go to the source code of this file.

## Functions
int | addDirEntry (struct directoryEntry *dir, fileDescriptor_t *fd)
dirList_t | ubixFSLoadDir (char *data)
int | ubixFSmkDir (char *directory, fileDescriptor_t *fd)

## Function Documentation

## ◆ addDirEntry()

int addDirEntry | ( | struct directoryEntry * | dir,
|  | fileDescriptor_t * | fd
| ) |  |

Definition at line 64 of file directory.c.

References kmalloc(), kprintf(), memcpy(), fileDescriptor::offset, readUbixFS(), fileDescriptor::size, and writeUbixFS().

Referenced by ubixFSmkDir().

Here is the call graph for this function:

## ◆ ubixFSLoadDir()

dirList_t ubixFSLoadDir | ( | char * | data | ) |

Definition at line 39 of file directory.c.

References directoryList::dirName, kmalloc(), and sprintf().

Here is the call graph for this function:

## ◆ ubixFSmkDir()

int ubixFSmkDir | ( | char * | directory,
|  | fileDescriptor_t * | fd
| ) |  |

Definition at line 92 of file directory.c.

References addDirEntry(), directoryEntry::attributes, ubixFSInfo::blockAllocationTable, blockSize, vfs_mountPoint::device, device_node::devInfo, vfs_mountPoint::diskLabel, directoryEntry::fileName, vfs_mountPoint::fsInfo, getFreeBlocks(), device_interface::info, kfree(), kmalloc(), fileDescriptor::mp, vfs_mountPoint::partition, ubixDiskLabel::partitions, directoryEntry::permissions, ubixDiskLabel::ubixPartitions::pOffset, blockAllocationTableEntry::realSector, directoryEntry::size, sprintf(), directoryEntry::startCluster, typeDirectory, UBIXFS_BLOCKSIZE_BYTES, and device_interface::write.

Here is the call graph for this function: