iommu_gas: Fix a recent regression with IOMMU_MF_CANSPLIT
As of19bb5a7244
, the IOMMU_MF_CANSPLIT case in iommu_gas_match_one() must take into account the specified offset. Otherwise, the recently changed end calculation in iommu_gas_match_insert() could produce an end address that crosses the specified boundary by one page. Reviewed by: dougm MFC with:19bb5a7244
This commit is contained in:
parent
841719c08f
commit
7b39a9bc1d
@ -350,7 +350,7 @@ iommu_gas_match_one(struct iommu_gas_match_args *a, iommu_gaddr_t beg,
|
||||
* the next entry, then we do not have gap. Ignore for now.
|
||||
*/
|
||||
if ((a->gas_flags & IOMMU_MF_CANSPLIT) != 0) {
|
||||
a->size = bs - a->entry->start;
|
||||
a->size = bs - a->entry->start - a->offset;
|
||||
return (true);
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user