X-Git-Url: https://scm.lunaixsky.com/lunaix-os.git/blobdiff_plain/095a899a9749b85443e546b1062026747445658c..c166bd62fbb907f95f79f621e2a2fb4fdde08e01:/lunaix-os/includes/lunaix/boot_generic.h diff --git a/lunaix-os/includes/lunaix/boot_generic.h b/lunaix-os/includes/lunaix/boot_generic.h index a229c45..dca7b9a 100644 --- a/lunaix-os/includes/lunaix/boot_generic.h +++ b/lunaix-os/includes/lunaix/boot_generic.h @@ -69,6 +69,25 @@ boot_end(struct boot_handoff*); void boot_cleanup(); + +static inline bool +free_memregion(struct boot_mmapent* mmapent) +{ + return !mmapent->type; +} + +static inline bool +reserved_memregion(struct boot_mmapent* mmapent) +{ + return !!(mmapent->type & BOOT_MMAP_RSVD); +} + +static inline bool +reclaimable_memregion(struct boot_mmapent* mmapent) +{ + return !!(mmapent->type & BOOT_MMAP_RCLM); +} + #endif #endif /* __LUNAIX_BOOT_GENERIC_H */