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

Commit 7fbf1bb0 authored by Tomi Valkeinen's avatar Tomi Valkeinen
Browse files

OMAP: OMAPFB: string parsing cleanups



Use strtobool instead of kstrtoint when parsing bool from sysfs.

Signed-off-by: default avatarTomi Valkeinen <tomi.valkeinen@ti.com>
parent e3a26aec
Loading
Loading
Loading
Loading
+2 −4
Original line number Diff line number Diff line
@@ -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;