-
Notifications
You must be signed in to change notification settings - Fork 17
/
Copy pathFILES
44 lines (32 loc) · 1.32 KB
/
FILES
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
The source organization is inspired by the ones in Linux and OpenBSD.
More suggestions are welcome.
The sources are separated into: bootloader, drivers, kernel, C library, and
userspace programs.
./:
No separate files other than Makefile or autotools-related stuff (if any)
should really be placed here, I guess?
bios:
Place everything prior to bootloader (e.g. BIOS, bootROM, etc.) there.
boot:
Place bootloader-related source codes and headers there.
doc:
Place documentations there, if any.
drivers:
Place driver-specific sources and headers there.
Both bootloader and kernel may need to play with drivers.
kern:
Place all kernel-specific source codes and headers (including but not limited
to: memory allocator, exception handler, scheduler) there.
include:
Place all generic C Library headers (e.g. stdio.h, stdlib.h, assert.h) there.
Component-specific headers should be placed inside directories such as
kern/include etc.
General architecture-specific headers are placed inside include/arch/$ARCH/asm.
lib:
Place all generic C Library sources (e.g. sprintf(3), strlcpy(3), memset(3)),
and C Runtime sources (crt0.S and other sources for statically linking user
programs) there.
tools:
Native tools (e.g. kernel installers), if any, should be put there.
user:
Place all sources for userspace programs (e.g. init(1), sh(1)) there.