]> git.karo-electronics.de Git - linux-beck.git/commitdiff
OMAP: DSS2: OMAPFB: Fix sysfs mirror input check
authorJani Nikula <ext-jani.1.nikula@nokia.com>
Tue, 1 Jun 2010 15:08:18 +0000 (18:08 +0300)
committerTomi Valkeinen <tomi.valkeinen@nokia.com>
Thu, 5 Aug 2010 13:52:10 +0000 (16:52 +0300)
Using bool silently converted input to 0 or 1, making the range check
useless. Use unsigned long instead, and convert to bool later. Found by
Coverity.

Signed-off-by: Jani Nikula <ext-jani.1.nikula@nokia.com>
Signed-off-by: Tomi Valkeinen <tomi.valkeinen@nokia.com>
drivers/video/omap2/omapfb/omapfb-sysfs.c

index 51c13c366bf3c5041cc8efd620f29bf43da00f86..6f9c72cd6bb0e52675375e4cd4c2bd168e175701 100644 (file)
@@ -102,7 +102,7 @@ static ssize_t store_mirror(struct device *dev,
 {
        struct fb_info *fbi = dev_get_drvdata(dev);
        struct omapfb_info *ofbi = FB2OFB(fbi);
-       bool mirror;
+       unsigned long mirror;
        int r;
        struct fb_var_screeninfo new_var;