axle OS
x86_32 UNIX-like hobby OS
src
kernel
util
vfs
initrd.h
1
#ifndef INITRD_H
2
#define INITRD_H
3
4
#include <std/common.h>
5
#include "fs.h"
6
7
#define HEADER_MAGIC 0xBF
8
9
typedef
struct
{
10
uint32_t nfiles;
//# of files in ramdisk
11
}
initrd_header_t
;
12
13
typedef
struct
{
14
uint8_t magic;
//magic number
15
int8_t name[64];
//filename
16
uint32_t offset;
//offset in initrd that file starts
17
uint32_t length;
//length of file
18
}
initrd_file_header_t
;
19
20
//initializes initial ramdisk
21
//gets passed address of multiboot module,
22
//and returns completed filesystem node
23
fs_node_t
* initrd_install(uint32_t location);
24
25
#endif
fs_node
Definition:
fs.h:31
initrd_file_header_t
Definition:
initrd.h:13
initrd_header_t
Definition:
initrd.h:9
Generated by
1.8.14