PatchworkOS  966e257
A non-POSIX operating system.
Loading...
Searching...
No Matches
ramfs.h
Go to the documentation of this file.
1#pragma once
2
3#include <kernel/fs/dentry.h>
4#include <kernel/fs/inode.h>
6
7#include <boot/boot_info.h>
8
9#include <sys/io.h>
10#include <sys/list.h>
11
12/**
13 * @brief RAM filesystem.
14 * @defgroup kernel_fs_ramfs RAMFS
15 * @ingroup kernel_fs
16 *
17 * A simple in-memory filesystem thats loaded from the bootloader. All data is lost when the system is powered off or
18 * rebooted.
19 *
20 * @{
21 */
22
23/**
24 * @brief The name of the ramfs filesystem.
25 */
26#define RAMFS_NAME "ramfs"
27
28/**
29 * @brief Superblock private data for ramfs.
30 */
31typedef struct
32{
33 list_t dentrys; // We store all dentries in here to keep them in memory.
36
37/**
38 * @brief Registers the ramfs filesystem and mounts it as the root filesystem.
39 */
40void ramfs_init(void);
41
42/** @} */
void ramfs_init(void)
Registers the ramfs filesystem and mounts it as the root filesystem.
Definition ramfs.c:327
A doubly linked list.
Definition list.h:49
A simple ticket lock implementation.
Definition lock.h:43
Superblock private data for ramfs.
Definition ramfs.h:32