Skip to content

Commit

Permalink
Staging: asus_oled: fix up my fixup for some sysfs attribute permissions
Browse files Browse the repository at this point in the history
They should be writable by root, not readable.
Doh, stupid me with the wrong flags.

Reported-by: Jonathan Cameron <jic23@cam.ac.uk>
Cc: Jakub Schmidtke <sjakub@gmail.com>
Cc: stable <stable@kernel.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
  • Loading branch information
Greg Kroah-Hartman committed Nov 18, 2010
1 parent 73e1cc4 commit 515b498
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions drivers/staging/asus_oled/asus_oled.c
Original file line number Diff line number Diff line change
Expand Up @@ -620,13 +620,13 @@ static ssize_t class_set_picture(struct device *device,

#define ASUS_OLED_DEVICE_ATTR(_file) dev_attr_asus_oled_##_file

static DEVICE_ATTR(asus_oled_enabled, S_IRUSR | S_IRUGO,
static DEVICE_ATTR(asus_oled_enabled, S_IWUSR | S_IRUGO,
get_enabled, set_enabled);
static DEVICE_ATTR(asus_oled_picture, S_IRUSR , NULL, set_picture);
static DEVICE_ATTR(asus_oled_picture, S_IWUSR , NULL, set_picture);

static DEVICE_ATTR(enabled, S_IRUSR | S_IRUGO,
static DEVICE_ATTR(enabled, S_IWUSR | S_IRUGO,
class_get_enabled, class_set_enabled);
static DEVICE_ATTR(picture, S_IRUSR, NULL, class_set_picture);
static DEVICE_ATTR(picture, S_IWUSR, NULL, class_set_picture);

static int asus_oled_probe(struct usb_interface *interface,
const struct usb_device_id *id)
Expand Down

0 comments on commit 515b498

Please sign in to comment.