c1ad0fc5/1/2026, 8:41:11 PM
~kernel/pmm.h
.m
Objective-C
(text/x-objectivec)
#ifndef PMM_H
#define PMM_H

#include <stdint.h>

#define PAGE_SIZE 4096

/* Initialize the physical memory manager (optional) */
void pmm_init(void);

/* Allocate a single page (4 KiB). Returns NULL on failure. */
void *pmm_alloc_page(void);

/* Free a previously allocated page. */
void pmm_free_page(void *page);

/* Existing bump allocator (kept for compatibility) */
void *kalloc(uint64_t bytes);

#endif /* PMM_H */