class VmEnumerator
Defined at line 1355 of file ../../zircon/kernel/vm/include/vm/vm_address_region.h
Interface for walking a VmAspace-rooted VmAddressRegion/VmMapping tree.
Override this class and pass an instance to VmAddressRegion::EnumerateChildren().
VmAddressRegion::EnumerateChildren() will call the On* methods in depth-first pre-order.
ZX_ERR_NEXT and ZX_ERR_STOP can be used to control iteration, with any other status becoming the
return value of this method. The root VmAspace's lock is held during the traversal and passed in
to the callbacks as |guard|. A callback is permitted to temporarily drop the lock, using
|CallUnlocked|, although doing so invalidates the pointers and to use them without the lock held,
of after it is reacquired, they should first be turned into a RefPtr, with the caveat that they
might now refer to a dead, aka unmapped, object.
Public Methods
zx_status_t OnVmAddressRegion (VmAddressRegion * vmar, uint depth, Guard<CriticalMutex> & guard)
|depth| will be 0 for the root VmAddressRegion.
Defined at line 1358 of file ../../zircon/kernel/vm/include/vm/vm_address_region.h
zx_status_t OnVmMapping (VmMapping * map, VmAddressRegion * vmar, uint depth, Guard<CriticalMutex> & guard)
|vmar| is the parent of |map|.
Defined at line 1364 of file ../../zircon/kernel/vm/include/vm/vm_address_region.h
Protected Methods
void VmEnumerator ()
Defined at line 1371 of file ../../zircon/kernel/vm/include/vm/vm_address_region.h
void ~VmEnumerator ()
Defined at line 1372 of file ../../zircon/kernel/vm/include/vm/vm_address_region.h