UbixOS V2 2.0

Functions | Variables
kmod.c File Reference
`#include <sys/types.h>`
`#include <ubixos/kmod.h>`
`#include <ubixos/sched.h>`
`#include <sys/elf.h>`
`#include <ubixos/kpanic.h>`
`#include <ubixos/lists.h>`
`#include <ubixos/spinlock.h>`
`#include <lib/kprintf.h>`
`#include <lib/kmalloc.h>`
`#include <vfs/vfs.h>`
`#include <vmm/vmm.h>`
`#include <string.h>`
`#include <assert.h>`
Include dependency graph for kmod.c:

Go to the source code of this file.

## Functions
uInt32 | kmod_add (const char *kmod_file, const char *name)
uInt32 | kmod_load (const char *kmod_file)

## Variables
List_t * | List = 0x0

## Function Documentation

## ◆ kmod_add()

uInt32 kmod_add | ( | const char * | kmod_file,
|  | const char * | name
| ) |  |

Definition at line 45 of file kmod.c.

References CreateItem(), _item_t::data, InitializeList(), InsertItemAtFront(), kmalloc(), kmod_load(), kprintf(), List, and NULL.

Here is the call graph for this function:

## ◆ kmod_load()

uInt32 kmod_load | ( | const char * | kmod_file | ) |

Definition at line 70 of file kmod.c.

References _current, assert, ELF32_R_SYM, ELF32_R_TYPE, elfGetRelType(), fclose(), fopen(), fread(), fseek(), taskStruct::id, kfree(), kmalloc(), kpanic(), kprintf(), LD_START, memset(), PAGE_DEFAULT, PT_DYNAMIC, PT_GNU_STACK, PT_LOAD, R_386_32, R_386_PC32, R_386_RELATIVE, strcmp(), vmm_findFreePage(), and vmm_remapPage().

Referenced by kmod_add().

Here is the call graph for this function:

## Variable Documentation

## ◆ List

List_t* List = 0x0

Definition at line 43 of file kmod.c.

Referenced by kmod_add().