Subject: Re: powerpc/iommu: avoid derefence before pointer check

From: Michael Ellerman <[email-masked]>
Date: Thu, 20 Sep 2018 14:20:59 +1000 (AEST)

On Tue, 2018-08-21 at 18:44:48 UTC, Breno Leitao wrote:
> The tbl pointer is being derefenced by IOMMU_PAGE_SIZE prior the check if
> it is not NULL.
> 
> Just moving the dereference code to after the check, where there will be
> guarantee that 'tbl' will not be NULL.
> 
> CC: Alistair Popple <[email-masked]>
> Signed-off-by: Breno Leitao <[email-masked]>

Applied to powerpc next, thanks.

https://git.kernel.org/powerpc/c/984ecdd68de0fa1f63ce205d6c19ef

cheers