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

Commit e57980be authored by qctecmdr's avatar qctecmdr Committed by Gerrit - the friendly Code Review server
Browse files

Merge "msm: kgsl: Only read throttle counters if GMU is enabled"

parents efda6da2 a54ebbb3
Loading
Loading
Loading
Loading
+3 −0
Original line number Diff line number Diff line
@@ -1449,6 +1449,9 @@ static int64_t a6xx_read_throttling_counters(struct adreno_device *adreno_dev)
	struct kgsl_device *device = KGSL_DEVICE(adreno_dev);
	struct gmu_device *gmu = KGSL_GMU_DEVICE(device);

	if (!gmu_core_isenabled(device))
		return 0;

	for (i = 0; i < ARRAY_SIZE(counts); i++) {
		if (!adreno_dev->gpmu_throttle_counters[i])
			counts[i] = 0;