---
name: "region_intersects"
section: "9"
platform: "linux"
package: "linux-manual-4.9"
version: "4.9.228-1"
release: "Debian 9 (Stretch)"
platforms: ["linux"]
url: "https://new.carta.tech/region_intersects"
---

# region\_intersects(9)

determine intersection of region with known resources

## NAME

region\_intersects - determine intersection of region with known resources

## SYNOPSIS

**int region\_intersects(resource\_size\_t** *start***, size\_t** *size***, unsigned long** *flags***, unsigned long** *desc***);**

## ARGUMENTS

*start*

region start address

*size*

size of region

*flags*

flags of resource (in iomem\_resource)

*desc*

descriptor of resource (in iomem\_resource) or IORES\_DESC\_NONE

## DESCRIPTION

Check if the specified region partially overlaps or fully eclipses a resource identified by *flags* and *desc* (optional with IORES\_DESC\_NONE). Return REGION\_DISJOINT if the region does not overlap *flags*/*desc*, return REGION\_MIXED if the region overlaps *flags*/*desc* and another resource, and return REGION\_INTERSECTS if the region overlaps *flags*/*desc* 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.

## COPYRIGHT
