mirror of
https://github.com/RGBCube/serenity
synced 2025-07-27 00:07:36 +00:00
Kernel: Implement very simple kernel module loading
It's now possible to load a .o file into the kernel via a syscall. The kernel will perform all the necessary ELF relocations, and then call the "module_init" symbol in the loaded module.
This commit is contained in:
parent
c10a5ac4ad
commit
6b150c794a
11 changed files with 198 additions and 3 deletions
|
@ -99,6 +99,8 @@ CXX_OBJS = \
|
|||
init.o \
|
||||
kprintf.o
|
||||
|
||||
MODULE_OBJS = TestModule.o
|
||||
|
||||
OBJS = $(CXX_OBJS) Arch/i386/Boot/boot.ao
|
||||
|
||||
KERNEL = kernel
|
||||
|
@ -109,7 +111,7 @@ CXXFLAGS += -I../Toolchain/Local/i686-pc-serenity/include/c++/8.3.0/i686-pc-sere
|
|||
DEFINES += -DKERNEL
|
||||
LDFLAGS += -Ttext 0x100000 -Wl,-T linker.ld -nostdlib
|
||||
|
||||
all: $(KERNEL) kernel.map
|
||||
all: $(KERNEL) $(MODULE_OBJS) kernel.map
|
||||
|
||||
kernel.map: kernel
|
||||
@echo "MKMAP $@"; sh mkmap.sh
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue