Bitmap allocator
include/mem/bitmap.h View source View on GitHubFunctions
Section titled “Functions”bitmap_alloc_pages
Section titled “bitmap_alloc_pages”paddr_t bitmap_alloc_pages(uint64_t count, enum alloc_flags f); bitmap_free_pages
Section titled “bitmap_free_pages”void bitmap_free_pages(paddr_t addr, uint64_t count); set_bit
Section titled “set_bit”__no_sanitize_address set_bit(uint64_t index); clear_bit
Section titled “clear_bit”__no_sanitize_address clear_bit(uint64_t index); test_bit
Section titled “test_bit”__no_sanitize_address test_bit(uint64_t index); Variables
Section titled “Variables”boot_bitmap
Section titled “boot_bitmap”extern uint8_t boot_bitmap[BOOT_BITMAP_SIZE]; bitmap
Section titled “bitmap”extern uint8_t *bitmap; bitmap_size
Section titled “bitmap_size”extern uint64_t bitmap_size; Macros
Section titled “Macros”BOOT_BITMAP_SIZE
Section titled “BOOT_BITMAP_SIZE”#define BOOT_BITMAP_SIZE ((1024 * 1024 * 128) / PAGE_SIZE / 8)