public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
* [PATCH] backlight: lm3639_bl: Fix up world writable sysfs file
@ 2012-10-29  8:38 Axel Lin
  2012-10-29 11:02 ` gshark
  0 siblings, 1 reply; 2+ messages in thread
From: Axel Lin @ 2012-10-29  8:38 UTC (permalink / raw)
  To: Andrew Morton; +Cc: G.Shark Jeong, Richard Purdie, Daniel Jeong, linux-kernel

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>
---
 drivers/video/backlight/lm3639_bl.c |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/video/backlight/lm3639_bl.c b/drivers/video/backlight/lm3639_bl.c
index 585949b..6f7a20e 100644
--- a/drivers/video/backlight/lm3639_bl.c
+++ b/drivers/video/backlight/lm3639_bl.c
@@ -214,7 +214,7 @@ out_input:
 
 }
 
-static DEVICE_ATTR(bled_mode, 0666, NULL, lm3639_bled_mode_store);
+static DEVICE_ATTR(bled_mode, S_IWUSR, NULL, lm3639_bled_mode_store);
 
 /* torch */
 static void lm3639_torch_brightness_set(struct led_classdev *cdev,
-- 
1.7.9.5




^ permalink raw reply related	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2012-10-29 11:02 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2012-10-29  8:38 [PATCH] backlight: lm3639_bl: Fix up world writable sysfs file Axel Lin
2012-10-29 11:02 ` gshark

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox