Skip to content

Commit

Permalink
video: fbdev: sh_mobile_lcdcfb: Fix ROP3 sysfs attribute parsing
Browse files Browse the repository at this point in the history
The ROP3 attribute is expressed as an integer in the 0-255 range. Remove
the wrong conversion to boolean when parsing it.

Reported-by: Dan Carpenter <dan.carpenter@oracle.com>
Signed-off-by: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com>
Acked-by: Geert Uytterhoeven <geert+renesas@glider.be>
Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com>
  • Loading branch information
Laurent Pinchart authored and Tomi Valkeinen committed Mar 20, 2015
1 parent b3924dd commit 14048ff
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion drivers/video/fbdev/sh_mobile_lcdcfb.c
Original file line number Diff line number Diff line change
Expand Up @@ -1461,7 +1461,7 @@ overlay_rop3_store(struct device *dev, struct device_attribute *attr,
unsigned int rop3;
char *endp;

rop3 = !!simple_strtoul(buf, &endp, 10);
rop3 = simple_strtoul(buf, &endp, 10);
if (isspace(*endp))
endp++;

Expand Down

0 comments on commit 14048ff

Please sign in to comment.