template <typename T = VmAddressRegionOrMapping>
class RegionList
Defined at line 279 of file ../../zircon/kernel/vm/include/vm/vm_address_region.h
A list of regions ordered by virtual address. Templated to allow for test code to avoid needing
to instantiate 'real' VmAddressRegionOrMapping instances.
Public Methods
fbl::RefPtr<T> RemoveRegion (T * region)
Remove *region* from the list, returns the removed region.
Defined at line 293 of file ../../zircon/kernel/vm/include/vm/vm_address_region.h
typename ChildList::iterator LeftOf (T * region)
Request the region to the left or right of the given region.
Defined at line 296 of file ../../zircon/kernel/vm/include/vm/vm_address_region.h
typename ChildList::iterator RightOf (T * region)
Defined at line 297 of file ../../zircon/kernel/vm/include/vm/vm_address_region.h
typename ChildList::const_iterator Root ()
Defined at line 298 of file ../../zircon/kernel/vm/include/vm/vm_address_region.h
void InsertRegion (fbl::RefPtr<T> region)
Insert *region* to the region list.
Defined at line 301 of file ../../zircon/kernel/vm/include/vm/vm_address_region.h
template <typename S>
ktl::conditional_t<ktl::is_const_v<S>, const T, T> * FindRegion (S * self, vaddr_t addr)
Use a static template to allow for returning a const and non-const pointer depending on the
constness of self.
Defined at line 306 of file ../../zircon/kernel/vm/include/vm/vm_address_region.h
const T * FindRegion (vaddr_t addr)
Find the region that covers addr, returns nullptr if not found.
Defined at line 327 of file ../../zircon/kernel/vm/include/vm/vm_address_region.h
T * FindRegion (vaddr_t addr)
Defined at line 328 of file ../../zircon/kernel/vm/include/vm/vm_address_region.h
template <typename S>
ktl::conditional_t<ktl::is_const_v<S>, typename ChildList::const_iterator, typename ChildList::iterator> IncludeOrHigher (S * self, vaddr_t base)
Defined at line 331 of file ../../zircon/kernel/vm/include/vm/vm_address_region.h
typename ChildList::iterator IncludeOrHigher (vaddr_t base)
Find the region that contains |base|, or if that doesn't exist, the first region that contains
an address greater than |base|.
Defined at line 351 of file ../../zircon/kernel/vm/include/vm/vm_address_region.h
typename ChildList::const_iterator IncludeOrHigher (vaddr_t base)
Defined at line 352 of file ../../zircon/kernel/vm/include/vm/vm_address_region.h
typename ChildList::iterator UpperBound (vaddr_t base)
Defined at line 356 of file ../../zircon/kernel/vm/include/vm/vm_address_region.h
typename ChildList::const_iterator UpperBound (vaddr_t base)
Defined at line 357 of file ../../zircon/kernel/vm/include/vm/vm_address_region.h
bool IsRangeAvailable (vaddr_t base, size_t size)
Check whether it would be valid to create a child in the range [base, base+size).
Defined at line 362 of file ../../zircon/kernel/vm/include/vm/vm_address_region.h
fit::result<FindSpotAtIndexFailed, vaddr_t> FindSpotAtIndex (vaddr_t target_index, uint8_t align_pow2, size_t size, vaddr_t parent_base, size_t parent_size, vaddr_t upper_limit)
Defined at line 403 of file ../../zircon/kernel/vm/include/vm/vm_address_region.h
zx_status_t GetAllocSpot (vaddr_t * alloc_spot, uint8_t align_pow2, uint8_t entropy, size_t size, vaddr_t parent_base, size_t parent_size, crypto::Prng * prng, vaddr_t upper_limit)
Get the allocation spot that is free and large enough for the aligned size.
Defined at line 552 of file ../../zircon/kernel/vm/include/vm/vm_address_region.h
bool IsEmpty ()
Returns whether the region list is empty.
Defined at line 606 of file ../../zircon/kernel/vm/include/vm/vm_address_region.h
T & front ()
Returns the iterator points to the first element of the list.
Defined at line 609 of file ../../zircon/kernel/vm/include/vm/vm_address_region.h
typename ChildList::iterator begin ()
Defined at line 611 of file ../../zircon/kernel/vm/include/vm/vm_address_region.h
typename ChildList::const_iterator begin ()
Defined at line 613 of file ../../zircon/kernel/vm/include/vm/vm_address_region.h
typename ChildList::const_iterator cbegin ()
Defined at line 615 of file ../../zircon/kernel/vm/include/vm/vm_address_region.h
typename ChildList::iterator end ()
Defined at line 617 of file ../../zircon/kernel/vm/include/vm/vm_address_region.h
typename ChildList::const_iterator end ()
Defined at line 619 of file ../../zircon/kernel/vm/include/vm/vm_address_region.h
typename ChildList::const_iterator cend ()
Defined at line 621 of file ../../zircon/kernel/vm/include/vm/vm_address_region.h
size_t size_slow ()
Defined at line 623 of file ../../zircon/kernel/vm/include/vm/vm_address_region.h