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

Commit 96434f4e authored by Kyle Yan's avatar Kyle Yan Committed by Gerrit - the friendly Code Review server
Browse files

Merge "iommu: arm-smmu: Allow configurations with zero clocks" into msm-4.8

parents 8d77fbb0 f0c58e12
Loading
Loading
Loading
Loading
+3 −1
Original line number Diff line number Diff line
@@ -3097,8 +3097,10 @@ static int arm_smmu_init_clocks(struct arm_smmu_device *smmu)
	smmu->num_clocks =
		of_property_count_strings(dev->of_node, "clock-names");

	if (smmu->num_clocks < 1)
	if (smmu->num_clocks < 1) {
		smmu->num_clocks = 0;
		return 0;
	}

	smmu->clocks = devm_kzalloc(
		dev, sizeof(*smmu->clocks) * smmu->num_clocks,