class PmmChecker
Defined at line 38 of file ../../zircon/kernel/vm/include/vm/pmm_checker.h
|PmmChecker| is used to detect memory corruption. It is logically part of |PmmNode|.
Usage is as follows:
PmmChecker checker;
// Check only the first 16 bytes of each page.
checker.SetFillSize(16);
// For all free pages...
for (...) {
checker.FillPattern(page);
}
// Now that all free pages have been filled with a pattern, we can arm the checker.
checker.Arm();
...
checker.AssertPattern(page);
Public Members
static CheckFailAction kDefaultAction
static const uint8_t kDefaultActionRaw
Public Methods
bool IsValidFillSize (size_t fill_size)
Returns true if |fill_size| is a valid value. Valid values are mutliples of 8 between 8 and
kPageSize, inclusive.
Defined at line 14 of file ../../zircon/kernel/vm/pmm_checker.cc
bool IsArmed ()
Returns true if armed.
Defined at line 18 of file ../../zircon/kernel/vm/pmm_checker.cc
void PrintStatus (FILE * f)
Defined at line 20 of file ../../zircon/kernel/vm/pmm_checker.cc