From mboxrd@z Thu Jan 1 00:00:00 1970 From: Joerg Roedel Subject: Re: [PATCH RESEND] iommu/iova: Extend cached node lookup condition Date: Tue, 15 Nov 2016 12:40:09 +0100 Message-ID: <20161115114008.GB24857@8bytes.org> References: <1b035087a5a3ca8de9daf10bf067f3bd5c0e6f61.1478889292.git.robin.murphy@arm.com> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Return-path: Content-Disposition: inline In-Reply-To: <1b035087a5a3ca8de9daf10bf067f3bd5c0e6f61.1478889292.git.robin.murphy-5wv7dgnIgG8@public.gmane.org> List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: iommu-bounces-cunTk1MwBs9QetFLy7KEm3xJsTq8ys+cHZ5vskTnxNA@public.gmane.org Errors-To: iommu-bounces-cunTk1MwBs9QetFLy7KEm3xJsTq8ys+cHZ5vskTnxNA@public.gmane.org To: Robin Murphy Cc: iommu-cunTk1MwBs9QetFLy7KEm3xJsTq8ys+cHZ5vskTnxNA@public.gmane.org List-Id: iommu@lists.linux-foundation.org On Fri, Nov 11, 2016 at 06:35:46PM +0000, Robin Murphy wrote: > When searching for a free IOVA range, we optimise the tree traversal > by starting from the cached32_node, instead of the last node, when > limit_pfn is equal to dma_32bit_pfn. However, if limit_pfn happens to > be smaller, then we'll go ahead and start from the top even though > dma_32bit_pfn is still a more suitable upper bound. Since this is > clearly a silly thing to do, adjust the lookup condition appropriately. > > Signed-off-by: Robin Murphy > --- > drivers/iommu/iova.c | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) Applied, thanks.