HomeFreeBSD

kern: physmem: don't create a new exregion for different flags...

Description

kern: physmem: don't create a new exregion for different flags...

... if the region we're adding is an exact match to one that we already
have. Simply extend the flags of the existing entry as needed so that
we don't end up with duplicate regions.

It could be that we got the exclusion through two different means, e.g.,
FDT memreserve and the EFI memory map, and we may derive different
characteristics from each. Apply the most restrictive set to the
region.

Reported by: Mark Millard <marklmi yahoo com>
Reviewed by: mhorne

(cherry picked from commit cc0fe048ec39636216ed59fa47eb311b2537cfc5)

Details

Provenance
kevansAuthored on Mar 10 2023, 5:27 AM
Parents
rGd18524b6f720: grep: remove tautological condition
Branches
Unknown
Tags
Unknown