kernel/inc/mm/region.h

29 lines
1.1 KiB
C

// This file is part of noxos and licensed under the MIT open source license
#ifndef NOX_REGION_H
#define NOX_REGION_H
#include "utils/stdtypes.h"
#define KERNEL_START_ADDRESS (uint64_t)&_kernel_start
#define KERNEL_END_ADDRESS (uint64_t)&_kernel_end
#define MEM_REGION_THREAD_OFFSET 0x100000000
#define MEM_REGION_PROCESS 0x0000000000000000
#define MEM_REGION_PROCESS_EXEC 0x0000010000000000
#define MEM_REGION_PROCESS_THREAD_BASE 0x0000010100000000
#define MEM_REGION_PROCESS_USABLE 0x0000080000000000
#define MEM_REGION_KERNEL 0x0000800000000000
#define MEM_REGION_KERNEL_DRIVERS 0xFFFFE80000000000 // size: up to 8 TB
#define MEM_REGION_KERNEL_STACK_DUMMY 0xFFFFF00000000000 // size: 4 KB
#define MEM_REGION_KERNEL_HEAP 0xFFFFF80000000000 // size: up to 8 TB
#define MEM_REGION_KERNEL_THREAD_BASE 0xFFFFFF0000000000 // size: up to 1022 GB
#define MEM_REGION_KERNEL_EXEC 0xFFFFFFFF80000000 // size: up to 2 GB
extern uint64_t _kernel_start;
extern uint64_t _kernel_end;
#endif //NOX_REGION_H