Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit e0a42e4f authored by Hiroshi DOYU's avatar Hiroshi DOYU
Browse files

omap iommu: Exit iteration if no possibility of available area



Searching avaialable spaces should be stopped as soon as it turns out
that there's no possibility with the rest of it.

Signed-off-by: default avatarHiroshi DOYU <Hiroshi.DOYU@nokia.com>
parent fa460b88
Loading
Loading
Loading
Loading
+4 −1
Original line number Diff line number Diff line
@@ -287,7 +287,10 @@ static struct iovm_struct *alloc_iovm_area(struct iommu *obj, u32 da,
	prev_end = 0;
	list_for_each_entry(tmp, &obj->mmap, list) {

		if ((prev_end < start) && (start + bytes < tmp->da_start))
		if (prev_end >= start)
			break;

		if (start + bytes < tmp->da_start)
			goto found;

		if (flags & IOVMF_DA_ANON)