Input: ili210x - fix permissions on "calibrate" attribute
authorDmitry Torokhov <dmitry.torokhov@gmail.com>
Tue, 2 Aug 2016 17:31:43 +0000 (10:31 -0700)
committerWilly Tarreau <w@1wt.eu>
Fri, 10 Feb 2017 10:03:32 +0000 (11:03 +0100)
commit b27c0d0c3bf3073e8ae19875eb1d3755c5e8c072 upstream.

"calibrate" attribute does not provide "show" methods and thus we should
not mark it as readable.

Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
Signed-off-by: Willy Tarreau <w@1wt.eu>
drivers/input/touchscreen/ili210x.c

index 1418bdda61bbdde36df38a88eb434be57e3db6ab..ceaa790b71a29de85b2e969fd85c228124c518f1 100644 (file)
@@ -169,7 +169,7 @@ static ssize_t ili210x_calibrate(struct device *dev,
 
        return count;
 }
-static DEVICE_ATTR(calibrate, 0644, NULL, ili210x_calibrate);
+static DEVICE_ATTR(calibrate, S_IWUSR, NULL, ili210x_calibrate);
 
 static struct attribute *ili210x_attributes[] = {
        &dev_attr_calibrate.attr,