mirror of
https://gitlab.os-k.eu/os-k-team/os-k.git
synced 2023-08-25 14:03:10 +02:00
Merging ok !
This commit is contained in:
parent
8cb110059a
commit
a098510b91
@ -54,7 +54,6 @@ struct MemoryMap_t {
|
||||
MapEntry_t entry[MAX_ENTRIES];
|
||||
} __attribute__((packed));
|
||||
|
||||
<<<<<<< HEAD
|
||||
|
||||
|
||||
// -------------------------------------------------------------------------- //
|
||||
@ -71,6 +70,6 @@ size_t MmGetAvailZoneSize(void *start);
|
||||
|
||||
//
|
||||
// Returns the first available memory zone from the start address pointer
|
||||
void MmGetFirstAvailZone(void *start);
|
||||
void *MmGetFirstAvailZone(void *start);
|
||||
|
||||
// -------------------------------------------------------------------------- //
|
||||
|
@ -42,11 +42,11 @@ void BtInitBootInfo(multiboot_info_t *mbi)
|
||||
//Retrieves the bootloader flags to ensure infos are valid
|
||||
BtGetBootInfo(btldr).grubFlags = mbi->flags;
|
||||
|
||||
if (GetBootInfo(btldr).grubFlags & MULTIBOOT_INFO_BOOT_LOADER_NAME) {
|
||||
GetBootInfo(btldr).grubName = (char*)(ullong)(mbi->boot_loader_name);
|
||||
GetBootInfo(btldr).kernelAddr = (void*)&MB_header;
|
||||
GetBootInfo(btldr).kernelEndAddr = (void*)&kernelEnd;
|
||||
GetBootInfo(btldr).valid = 1;
|
||||
if (BtGetBootInfo(btldr).grubFlags & MULTIBOOT_INFO_BOOT_LOADER_NAME) {
|
||||
BtGetBootInfo(btldr).grubName = (char*)(ullong)(mbi->boot_loader_name);
|
||||
BtGetBootInfo(btldr).kernelAddr = (void*)&MB_header;
|
||||
BtGetBootInfo(btldr).kernelEndAddr = (void*)&kernelEnd;
|
||||
BtGetBootInfo(btldr).valid = 1;
|
||||
}
|
||||
if (BtGetBootInfo(btldr).grubFlags & MULTIBOOT_INFO_MODS) {
|
||||
BtGetBootInfo(btldr).modulesCount = mbi->mods_count;
|
||||
@ -138,8 +138,8 @@ noreturn void BtStartKern(multiboot_info_t *mbInfo, int mbMagic)
|
||||
mapBad
|
||||
);
|
||||
|
||||
KernLog("[Init] TEST First zone from %p : %p\n", (void*)0xB8010, GetFirstAvailZone((void*)0xB8010));
|
||||
KernLog("[Init] TEST Size of zone : %u Kio\n\n", GetAvailZoneSize(GetFirstAvailZone((void*)0xB8010)) / KB);
|
||||
KernLog("[Init] TEST First zone from %p : %p\n", (void*)0xB8010, MmGetFirstAvailZone((void*)0xB8010));
|
||||
KernLog("[Init] TEST Size of zone : %u Kio\n\n", MmGetAvailZoneSize(MmGetFirstAvailZone((void*)0xB8010)) / KB);
|
||||
|
||||
|
||||
|
||||
|
@ -126,7 +126,7 @@ void *MmGetFirstAvailZone(void *start) {
|
||||
|
||||
// Because the kernel is the kernel
|
||||
if ((ullong)start < (ullong)BtGetBootInfo(btldr).kernelEndAddr) {
|
||||
return GetFirstAvailZone(BtGetBootInfo(btldr).kernelEndAddr);
|
||||
return MmGetFirstAvailZone(BtGetBootInfo(btldr).kernelEndAddr);
|
||||
}
|
||||
|
||||
// Search the zone where the start address is
|
||||
|
Loading…
Reference in New Issue
Block a user