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

Commit 1e4a5e3b authored by Prakash Gupta's avatar Prakash Gupta Committed by Gerrit - the friendly Code Review server
Browse files

iommu: arm-smmu: fix NULL pointer dereference



Fix NULL ptr deference issue in arm_smmu_iova_to_pte().

Change-Id: I628a41c0bf3a402403514b6d71b3bc47d52fb3c5
Signed-off-by: default avatarPrakash Gupta <guptap@codeaurora.org>
parent 973bbae0
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -2979,7 +2979,7 @@ static uint64_t arm_smmu_iova_to_pte(struct iommu_domain *domain,
	struct arm_smmu_domain *smmu_domain = to_smmu_domain(domain);
	struct io_pgtable_ops *ops = smmu_domain->pgtbl_ops;

	if (!ops)
	if (!ops || !ops->iova_to_pte)
		return 0;

	spin_lock_irqsave(&smmu_domain->cb_lock, flags);