]> git.karo-electronics.de Git - karo-tx-linux.git/commitdiff
leds: lm355x: Fix up world writable sysfs file
authorAxel Lin <axel.lin@ingics.com>
Mon, 29 Oct 2012 08:40:21 +0000 (01:40 -0700)
committerBryan Wu <roc@roc-samos.(none)>
Thu, 1 Nov 2012 22:48:02 +0000 (15:48 -0700)
We don't need the sysfs file to be world writable or group writable.
This file is write-only, change it to S_IWUSR (0200).

Signed-off-by: Axel Lin <axel.lin@ingics.com>
Acked-by: G.Shark Jeong <gshark.jeong@gmail.com>
Signed-off-by: Bryan Wu <cooloney@gmail.com>
drivers/leds/leds-lm355x.c

index 8f4e8e21ddb5136ce4e5a2c0404a3ab7d9130bc5..6bc029255e5b169c9e8dc56fadef99c73127d35f 100644 (file)
@@ -411,7 +411,7 @@ out:
        return ret;
 }
 
-static DEVICE_ATTR(pattern, 0666, NULL, lm3556_indicator_pattern_store);
+static DEVICE_ATTR(pattern, S_IWUSR, NULL, lm3556_indicator_pattern_store);
 
 static const struct regmap_config lm355x_regmap = {
        .reg_bits = 8,