|
ginnOS
The reference: libc, the libraries and the kernel
|
#include "common/stdint.h"Go to the source code of this file.
Macros | |
| #define | USER_SPACE_START 0x00001000u |
| ginnOS virtual memory layout constants. | |
| #define | USER_SPACE_END 0xC0000000u |
| #define | KERNEL_PHYS_BASE 0x00010000u |
| #define | LOW_MEMORY_END 0x00100000u |
| #define | USER_LOAD_ADDR 0x00400000u |
| #define | USER_STACK_TOP 0xBFFFF000u |
| #define | USER_STACK_MAX 0x01000000u |
| #define | USER_STACK_LIMIT (USER_STACK_TOP - USER_STACK_MAX) |
| #define | USER_STACK_SIZE 0x00004000u |
| #define | USER_STACK_BASE (USER_STACK_TOP - USER_STACK_SIZE) |
| #define | KERNEL_VIRT_BASE 0xC0000000u |
| #define | PHYS_MAP_SIZE 0x20000000u |
| #define | KSTACK_REGION_BASE 0xE0000000u |
| #define | MMIO_REGION_BASE 0xF0000000u |
| #define | MMIO_REGION_END 0xF4000000u |
| #define | USER_MMAP_BASE 0x40000000u |
| #define | USER_MMAP_END 0xB0000000u |
| #define USER_SPACE_START 0x00001000u |
ginnOS virtual memory layout constants.
every address space (i686, 4 GiB): 0x00000000 - 0x00000FFF : null guard (never mapped) 0x00400000 - ... : user program text/data/bss (linker/user.ld) ... - ... : user heap (grows up via sbrk from the ELF end) 0x40000000 - 0xAFFFFFFF : user mmap region 0xBEFFF000 - 0xBFFFEFFF : user stack (up to 16 MiB, grows down on demand) 0xBFFFF000 - 0xBFFFFFFF : user stack guard (never mapped) 0xC0000000 - 0xDFFFFFFF : kernel: direct map of RAM (phys_to_virt) 0xE0000000 - ... : kernel stacks (kstack.h) 0xF0000000 - 0xF3FFFFFF : kernel MMIO window (ioremap)
the user half (below 0xC0000000) is per process; the kernel half is shared by every address space and supervisor-only.
| #define USER_SPACE_END 0xC0000000u |
| #define KERNEL_PHYS_BASE 0x00010000u |
| #define LOW_MEMORY_END 0x00100000u |
| #define USER_LOAD_ADDR 0x00400000u |
| #define USER_STACK_TOP 0xBFFFF000u |
| #define USER_STACK_MAX 0x01000000u |
| #define USER_STACK_LIMIT (USER_STACK_TOP - USER_STACK_MAX) |
| #define USER_STACK_SIZE 0x00004000u |
| #define USER_STACK_BASE (USER_STACK_TOP - USER_STACK_SIZE) |
| #define KERNEL_VIRT_BASE 0xC0000000u |
| #define PHYS_MAP_SIZE 0x20000000u |
| #define KSTACK_REGION_BASE 0xE0000000u |
| #define MMIO_REGION_BASE 0xF0000000u |
| #define MMIO_REGION_END 0xF4000000u |
| #define USER_MMAP_BASE 0x40000000u |
| #define USER_MMAP_END 0xB0000000u |