PMAP_IS_MODIFIED(9)

πŸ’– PMAP_IS_MODIFIED πŸ’–

okay bestie, welcome to PMAP_IS_MODIFIED(9), straight out of the Kernel Developer's Manual ✨ this one's short and sweet and it's literally just about asking the kernel questions about physical pages 🫢


🌸 NAME 🌸

pmap_is_modified, pmap_ts_modified β€” return information about physical pages

(yes, the NAME line really does say pmap_ts_modified while the rest of the page is out here living its life as pmap_ts_referenced β€” not me fact-checking the manpage, we just report what it says πŸ’…)


✨ SYNOPSIS ✨

#include <sys/param.h>
#include <vm/vm.h>
#include <vm/pmap.h>

boolean_t
pmap_is_modified(vm_page_t m);

int
pmap_ts_referenced(vm_page_t m);

look at those includes, so tidy, so organized πŸŽ€


πŸ¦‹ DESCRIPTION πŸ¦‹

The pmap_is_modified() and pmap_ts_referenced() functions return information about physical pages. that's it. that's the whole description. short king energy πŸ‘‘


πŸ’… RETURN VALUES πŸ’…

The pmap_is_modified() function returns the status of the β€œpage modified” bit for the physical page m. so like… is it modified or not, bestie, the bit has answers πŸ’–

The pmap_ts_referenced() function returns a count of reference bits for a page m, clearing those bits. and here's the important part, no cap: it is not necessary for every reference bit to be cleared, but it is necessary that 0 only be returned when there are no remaining reference bits set on the page. read that one twice, it's giving rules πŸ”₯


🌈 SEE ALSO 🌈

go read those too, they're iconic πŸ’œ


πŸ‘‘ AUTHORS πŸ‘‘

This manual page was written by Bruce M Simpson <bms@spc.org>. thank you king, we appreciate you 🫢


and that's the whole vibe, bestie πŸŽ€ this beauty came from Debian, dated July 17, 2014 β€” yeah it's a 2014 baby and it still ate πŸ’–βœ¨ slay, periodt 🌸

πŸ“¦ where this page comes from