This is always set in msm_gpu_init(), and can never be NULL.

Reported-by: Dan Carpenter <dan.carpen...@linaro.org>
Signed-off-by: Rob Clark <robin.cl...@oss.qualcomm.com>
---
 drivers/gpu/drm/msm/msm_iommu.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/gpu/drm/msm/msm_iommu.c b/drivers/gpu/drm/msm/msm_iommu.c
index 55c29f49b788..cefa50192391 100644
--- a/drivers/gpu/drm/msm/msm_iommu.c
+++ b/drivers/gpu/drm/msm/msm_iommu.c
@@ -768,7 +768,7 @@ struct msm_mmu *msm_iommu_gpu_new(struct device *dev, 
struct msm_gpu *gpu, unsig
                return mmu;
 
        iommu = to_msm_iommu(mmu);
-       if (adreno_smmu && adreno_smmu->cookie) {
+       if (adreno_smmu->cookie) {
                const struct io_pgtable_cfg *cfg =
                        adreno_smmu->get_ttbr1_cfg(adreno_smmu->cookie);
                size_t tblsz = get_tblsz(cfg);
-- 
2.50.1

Reply via email to