Name

region_intersects — determine intersection of region with known resources

Synopsis

int region_intersects (resource_size_t start,
 size_t size,
 const char * name);
 

Arguments

start

region start address

size

size of region

name

name of resource (in iomem_resource)

Description

Check if the specified region partially overlaps or fully eclipses a resource identified by name. Return REGION_DISJOINT if the region does not overlap name, return REGION_MIXED if the region overlaps type and another resource, and return REGION_INTERSECTS if the region overlaps type and no other defined resource. Note, that REGION_INTERSECTS is also returned in the case when the specified region overlaps RAM and undefined memory holes.

region_intersect is used by memory remapping functions to ensure the user is not remapping RAM and is a vast speed up over walking through the resource table page by page.