aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/iommu/tegra-smmu.c
diff options
context:
space:
mode:
authorHiroshi DOYU <hdoyu@nvidia.com>2012-07-02 07:26:37 -0400
committerJoerg Roedel <joerg.roedel@amd.com>2012-07-17 05:25:04 -0400
commit0bdbf4ccef4f87016e2fa0c0b34f7a025f364c3d (patch)
tree72ea55136f83fdfc6dafceb4ee7f9e32bde5259a /drivers/iommu/tegra-smmu.c
parentff7636292aac6cae2ee3a553d5424ea49c8a8263 (diff)
iommu/tegra: smmu: Remove unnecessary sanity check at alloc_pdir()
alloc_pdir() is called with smmu->as[?].pdir_page == NULL. No need to check pdir_page again inside alloc_pdir(). Signed-off-by: Hiroshi DOYU <hdoyu@nvidia.com> Acked-by: Stephen Warren <swarren@wwwdotorg.org> Signed-off-by: Joerg Roedel <joerg.roedel@amd.com>
Diffstat (limited to 'drivers/iommu/tegra-smmu.c')
-rw-r--r--drivers/iommu/tegra-smmu.c3
1 files changed, 0 insertions, 3 deletions
diff --git a/drivers/iommu/tegra-smmu.c b/drivers/iommu/tegra-smmu.c
index becfc614cf94..68441fcca261 100644
--- a/drivers/iommu/tegra-smmu.c
+++ b/drivers/iommu/tegra-smmu.c
@@ -562,9 +562,6 @@ static int alloc_pdir(struct smmu_as *as)
562 u32 val; 562 u32 val;
563 struct smmu_device *smmu = as->smmu; 563 struct smmu_device *smmu = as->smmu;
564 564
565 if (as->pdir_page)
566 return 0;
567
568 as->pte_count = devm_kzalloc(smmu->dev, 565 as->pte_count = devm_kzalloc(smmu->dev,
569 sizeof(as->pte_count[0]) * SMMU_PDIR_COUNT, GFP_KERNEL); 566 sizeof(as->pte_count[0]) * SMMU_PDIR_COUNT, GFP_KERNEL);
570 if (!as->pte_count) { 567 if (!as->pte_count) {