提交 0b8cb621 编写于 作者: D Daniel Serpell 提交者: Matthew Garrett

sony-laptop: Fix reporting of gfx_switch_status

Signed-off-by: NDaniel Serpell <daniel.serpell@gmail.com>
Signed-off-by: NMattia Dongili <malattia@linux.it>
Signed-off-by: NMatthew Garrett <matthew.garrett@nebula.com>
上级 03a174b3
......@@ -2440,7 +2440,10 @@ static ssize_t sony_nc_gfx_switch_status_show(struct device *dev,
if (pos < 0)
return pos;
return snprintf(buffer, PAGE_SIZE, "%s\n", pos ? "speed" : "stamina");
return snprintf(buffer, PAGE_SIZE, "%s\n",
pos == SPEED ? "speed" :
pos == STAMINA ? "stamina" :
pos == AUTO ? "auto" : "unknown");
}
static int sony_nc_gfx_switch_setup(struct platform_device *pd,
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册