diff options
Diffstat (limited to 'src/kernel/mem.h')
-rw-r--r-- | src/kernel/mem.h | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/src/kernel/mem.h b/src/kernel/mem.h index 106db90..5c0d387 100644 --- a/src/kernel/mem.h +++ b/src/kernel/mem.h @@ -35,7 +35,11 @@ struct mmap_entry { struct mmap_entry *next; }; +#define MMAP_SIZE 65536 struct mmap_entry *mmap_start; +struct mmap_entry mmap_bss[MMAP_SIZE]; +uint32_t mmap_bitmap[MMAP_SIZE / 32]; +#define unmark_entry(entry) mmap_bitmap[((entry) - mmap_bss) >> 5] ^= 1 << (((entry) - mmap_bss) & 0x0000001f); void *allocate_block(uint32_t size, uint16_t proc_n); void deallocate_block(void *start); |