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

Commit 9432d187 authored by Linux Build Service Account's avatar Linux Build Service Account Committed by Gerrit - the friendly Code Review server
Browse files

Merge "msm: kgsl: Check for SMMU v2 version only once"

parents 689245f0 1f5dfcc2
Loading
Loading
Loading
Loading
+5 −7
Original line number Diff line number Diff line
@@ -281,17 +281,15 @@ static inline int _kgsl_msm_checks_iommu_v2(void)
#endif

#if !defined(CONFIG_MSM_IOMMU_V0) && defined(CONFIG_OF)
static int soc_supports_v2 = -1;
static inline int kgsl_msm_supports_iommu_v2(void)
{
	static int soc_supports_v2 = -1;

	if (soc_supports_v2 != -1)
		return soc_supports_v2;
	if (_kgsl_msm_checks_iommu_v2()) {
		soc_supports_v2 = 1;
		return 1;
	}
	return 0;

	soc_supports_v2 = _kgsl_msm_checks_iommu_v2();

	return soc_supports_v2;
}
#else
static inline int kgsl_msm_supports_iommu_v2(void)