Skip to content

Commit

Permalink
leds: flash: Remove checking for state < 1 in flash_strobe_store()
Browse files Browse the repository at this point in the history
Strobe state variable is declared as unsigned long, remove
the check for values less than zero then.

Signed-off-by: Jacek Anaszewski <[email protected]>
Reported-by: David Binderman <[email protected]>
  • Loading branch information
janaszewski committed Jan 4, 2016
1 parent 77e7915 commit abc1963
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion drivers/leds/led-class-flash.c
Original file line number Diff line number Diff line change
Expand Up @@ -108,7 +108,7 @@ static ssize_t flash_strobe_store(struct device *dev,
if (ret)
goto unlock;

if (state < 0 || state > 1) {
if (state > 1) {
ret = -EINVAL;
goto unlock;
}
Expand Down

0 comments on commit abc1963

Please sign in to comment.