aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/devfreq/devfreq.c
diff options
context:
space:
mode:
authorChanwoo Choi <cw00.choi@samsung.com>2025-02-07 16:13:50 -1000
committerChanwoo Choi <cw00.choi@samsung.com>2025-07-14 20:04:17 +0900
commit78c5845fbbf6aaeb9959c5fbaee5cc53ef5f38c2 (patch)
tree027d68733eeadbdab841448c31ec74890d322672 /drivers/devfreq/devfreq.c
parentPM / devfreq: Check governor before using governor->name (diff)
downloadlinux-78c5845fbbf6aaeb9959c5fbaee5cc53ef5f38c2.tar.gz
linux-78c5845fbbf6aaeb9959c5fbaee5cc53ef5f38c2.zip
PM / devfreq: Fix a index typo in trans_stat
Fixes: 4920ee6dcfaf ("PM / devfreq: Convert to use sysfs_emit_at() API") Signed-off-by: pls <pleasurefish@126.com> Link: https://patchwork.kernel.org/project/linux-pm/patch/20250515143100.17849-1-chanwoo@kernel.org/ Signed-off-by: Chanwoo Choi <cw00.choi@samsung.com>
Diffstat (limited to 'drivers/devfreq/devfreq.c')
-rw-r--r--drivers/devfreq/devfreq.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/devfreq/devfreq.c b/drivers/devfreq/devfreq.c
index 46f3a8053197..c5f5960e643b 100644
--- a/drivers/devfreq/devfreq.c
+++ b/drivers/devfreq/devfreq.c
@@ -1733,7 +1733,7 @@ static ssize_t trans_stat_show(struct device *dev,
for (i = 0; i < max_state; i++) {
if (len >= PAGE_SIZE - 1)
break;
- if (df->freq_table[2] == df->previous_freq)
+ if (df->freq_table[i] == df->previous_freq)
len += sysfs_emit_at(buf, len, "*");
else
len += sysfs_emit_at(buf, len, " ");