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

Commit 13c375eb 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: Fix the busy counter initialization sequence"

parents 9092179a 76aedcac
Loading
Loading
Loading
Loading
+7 −8
Original line number Diff line number Diff line
@@ -2722,6 +2722,13 @@ static inline s64 adreno_ticks_to_us(u32 ticks, u32 freq)
	return ticks / freq;
}

/**
 * adreno_power_stats() - Reads the counters needed for freq decisions
 * @device: Pointer to device whose counters are read
 * @stats: Pointer to stats set that needs updating
 * Power: The caller is expected to be in a clock enabled state as this
 * function does reg reads
 */
static void adreno_power_stats(struct kgsl_device *device,
				struct kgsl_power_stats *stats)
{
@@ -2732,14 +2739,6 @@ static void adreno_power_stats(struct kgsl_device *device,

	memset(stats, 0, sizeof(*stats));

	/*
	 * If we're not currently active, there shouldn't have been
	 * any cycles since the last time this function was called.
	 */

	if (device->state != KGSL_STATE_ACTIVE)
		return;

	/* Get the busy cycles counted since the counter was last reset */
	gpudev->busy_cycles(adreno_dev, &busy_data);