AquilaOS documentation
How it works, and its code
Toggle main menu visibility
Loading...
Searching...
No Matches
module.c
Go to the documentation of this file.
1
7
8
#include <
core/system.h
>
9
#include <
core/module.h
>
10
11
/* A module's init function. */
12
typedef
void (*
__ctor
)(void);
13
14
extern
__ctor
__minit
[],
__minit_end
[];
15
21
int
modules_init
(
void
)
22
{
23
printk
(
"kernel: loading builtin modules\n"
);
24
25
for
(
__ctor
*f =
__minit
; f <
__minit_end
; ++f) {
26
if
(*f)
27
(*f)();
28
}
29
30
return
0;
31
}
system.h
__ctor
void(*) __ctor(void)
Definition
module.c:12
__minit_end
__ctor __minit_end[]
Definition
module.c:14
modules_init
int modules_init(void)
Runs the init function of every built-in module, at boot.
Definition
module.c:21
__minit
__ctor __minit[]
module.h
printk
int printk(const char *fmt,...)
Writes a kernel message, to the message buffer and the consoles.
Definition
printk.c:249
kernel
core
module.c
Generated by
1.18.0