Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 45300
b: refs/heads/master
c: c8af57e
h: refs/heads/master
v: v3
  • Loading branch information
Matthijs van Otterdijk authored and Linus Torvalds committed Jan 6, 2007
1 parent cd2cd72 commit 4339b15
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 4 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 73b8ed29ab3f6ad7204b4e61cfa87dc0c28d3019
refs/heads/master: c8af57eb76fbd70c7f5b421b065fd55d096e2bff
9 changes: 6 additions & 3 deletions trunk/drivers/acpi/toshiba_acpi.c
Original file line number Diff line number Diff line change
Expand Up @@ -321,13 +321,16 @@ static int set_lcd_status(struct backlight_device *bd)
static unsigned long write_lcd(const char *buffer, unsigned long count)
{
int value;
int ret = count;
int ret;

if (sscanf(buffer, " brightness : %i", &value) == 1 &&
value >= 0 && value < HCI_LCD_BRIGHTNESS_LEVELS)
value >= 0 && value < HCI_LCD_BRIGHTNESS_LEVELS) {
ret = set_lcd(value);
else
if (ret == 0)
ret = count;
} else {
ret = -EINVAL;
}
return ret;
}

Expand Down

0 comments on commit 4339b15

Please sign in to comment.