From: Greg Kroah-Hartman Date: Tue, 16 Nov 2010 19:21:03 +0000 (-0800) Subject: Staging: samsung-laptop: fix up some sysfs attribute permissions X-Git-Tag: v2.6.35.10~35 X-Git-Url: https://git.karo-electronics.de/?a=commitdiff_plain;h=ac0d92d5f069c3db8796a0cc9c75ea7e6be5e4a8;p=karo-tx-linux.git Staging: samsung-laptop: fix up some sysfs attribute permissions commit 90c05b97fdec8d2196e420d98f774bab731af7aa upstream. They should not be writable by any user Reported-by: Linus Torvalds Signed-off-by: Greg Kroah-Hartman Signed-off-by: Andi Kleen --- diff --git a/drivers/staging/samsung-laptop/samsung-laptop.c b/drivers/staging/samsung-laptop/samsung-laptop.c index eb44b60e1eb5..28700b498273 100644 --- a/drivers/staging/samsung-laptop/samsung-laptop.c +++ b/drivers/staging/samsung-laptop/samsung-laptop.c @@ -356,7 +356,7 @@ static ssize_t set_silent_state(struct device *dev, } return count; } -static DEVICE_ATTR(silent, S_IWUGO | S_IRUGO, +static DEVICE_ATTR(silent, S_IRUSR | S_IRUGO, get_silent_state, set_silent_state);