Skip to content

Commit

Permalink
iommu/arm-smmu: fix compilation issue when !CONFIG_ARM_AMBA
Browse files Browse the repository at this point in the history
If !CONFIG_ARM_AMBA, we shouldn't try to register ourselves with the
amba_bustype.

Signed-off-by: Will Deacon <will.deacon@arm.com>
  • Loading branch information
Will Deacon committed Feb 10, 2014
1 parent 57ca90f commit d123cf8
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions drivers/iommu/arm-smmu.c
Original file line number Diff line number Diff line change
Expand Up @@ -2004,8 +2004,10 @@ static int __init arm_smmu_init(void)
if (!iommu_present(&platform_bus_type))
bus_set_iommu(&platform_bus_type, &arm_smmu_ops);

#ifdef CONFIG_ARM_AMBA
if (!iommu_present(&amba_bustype))
bus_set_iommu(&amba_bustype, &arm_smmu_ops);
#endif

return 0;
}
Expand Down

0 comments on commit d123cf8

Please sign in to comment.