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

Commit 66d800e7 authored by Mao Jinlong's avatar Mao Jinlong
Browse files

coresight: tgu: Correct the check of timer_refcnt



timer_refcnt should be checked instead of select_refcnt when
set timer.

Change-Id: I6bd1803ad4cd60c4f688948c513129f48497829c
Signed-off-by: default avatarMao Jinlong <jinlmao@codeaurora.org>
parent 262faf13
Loading
Loading
Loading
Loading
+1 −1
Original line number Original line Diff line number Diff line
@@ -327,7 +327,7 @@ static ssize_t set_timer_store(struct device *dev, struct device_attribute
	unsigned long value;
	unsigned long value;
	int step;
	int step;


	if (drvdata->select_refcnt >= MAX_TIMER_COUNTER_SETS) {
	if (drvdata->timer_refcnt >= MAX_TIMER_COUNTER_SETS) {
		dev_err(drvdata->dev, " Too many groups are being configured\n");
		dev_err(drvdata->dev, " Too many groups are being configured\n");
		return -EINVAL;
		return -EINVAL;
	}
	}