提交 7fbf1bb0 编写于 作者: T Tomi Valkeinen

OMAP: OMAPFB: string parsing cleanups

Use strtobool instead of kstrtoint when parsing bool from sysfs.
Signed-off-by: NTomi Valkeinen <tomi.valkeinen@ti.com>
上级 e3a26aec
......@@ -104,16 +104,14 @@ static ssize_t store_mirror(struct device *dev,
{
struct fb_info *fbi = dev_get_drvdata(dev);
struct omapfb_info *ofbi = FB2OFB(fbi);
int mirror;
bool mirror;
int r;
struct fb_var_screeninfo new_var;
r = kstrtoint(buf, 0, &mirror);
r = strtobool(buf, &mirror);
if (r)
return r;
mirror = !!mirror;
if (!lock_fb_info(fbi))
return -ENODEV;
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册