diff options
| author | Michal Idziorek <m.i@gmx.at> | 2014-09-05 09:34:53 +0200 |
|---|---|---|
| committer | Michal Idziorek <m.i@gmx.at> | 2014-09-05 09:34:53 +0200 |
| commit | c245268812a63bae0610de9a416dc7de97edde07 (patch) | |
| tree | 1f3707e9d53fbf1d3265feb138d499a58b03cf69 /kernel/kernel.c | |
| parent | b75c10c9d8c7405ba2f89724b485154d5201c404 (diff) | |
Moved kernel and reclaimed ACPI memory
finally our 2 stage bootloader also works with LBA loading via BIOS
Diffstat (limited to 'kernel/kernel.c')
| -rw-r--r-- | kernel/kernel.c | 25 |
1 files changed, 12 insertions, 13 deletions
diff --git a/kernel/kernel.c b/kernel/kernel.c index 0feca14..45f798d 100644 --- a/kernel/kernel.c +++ b/kernel/kernel.c @@ -108,18 +108,6 @@ void kernel_main(uint32_t initial_stack, int mp) int_init(0x08); // - // Memory Init - // - // after this is set up we can allocate and deallocate blocks - // of physical memory :) - // - // we know that here, the bootloader placed the mamory map and - // the number of entries. - // - mem_init(0x7c00+1,*((uint16_t *)(0x7c00))); - - - // // Gather Info about other processors. (APs) // ACPI or MP // @@ -130,10 +118,21 @@ void kernel_main(uint32_t initial_stack, int mp) if(!mp_find(&procdata)) panic(FOOLOS_MODULE_NAME,"ACPI and MP search failed! I do not want to continue!"); + // + // Memory Init + // + // after this is set up we can allocate and deallocate blocks + // of physical memory :) + // + // we know that here, the bootloader placed the mamory map and + // the number of entries. + // + mem_init(0x7c00+1,*((uint16_t *)(0x7c00))); + // // Start the other Processors (also before paging !) // - smp_start_aps(&procdata,0x80000); // starts at 0x90000 +// smp_start_aps(&procdata,0x80000); // starts at 0x90000 // but it will be copied over mbr // |
