aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/leds/ledtrig-timer.c
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/leds/ledtrig-timer.c')
-rw-r--r--drivers/leds/ledtrig-timer.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/drivers/leds/ledtrig-timer.c b/drivers/leds/ledtrig-timer.c
index 3b83406de752..82b77bd482ff 100644
--- a/drivers/leds/ledtrig-timer.c
+++ b/drivers/leds/ledtrig-timer.c
@@ -22,6 +22,7 @@
22#include <linux/timer.h> 22#include <linux/timer.h>
23#include <linux/ctype.h> 23#include <linux/ctype.h>
24#include <linux/leds.h> 24#include <linux/leds.h>
25#include <linux/slab.h>
25#include "leds.h" 26#include "leds.h"
26 27
27struct timer_trig_data { 28struct timer_trig_data {
@@ -83,7 +84,7 @@ static ssize_t led_delay_on_store(struct device *dev,
83 unsigned long state = simple_strtoul(buf, &after, 10); 84 unsigned long state = simple_strtoul(buf, &after, 10);
84 size_t count = after - buf; 85 size_t count = after - buf;
85 86
86 if (*after && isspace(*after)) 87 if (isspace(*after))
87 count++; 88 count++;
88 89
89 if (count == size) { 90 if (count == size) {
@@ -127,7 +128,7 @@ static ssize_t led_delay_off_store(struct device *dev,
127 unsigned long state = simple_strtoul(buf, &after, 10); 128 unsigned long state = simple_strtoul(buf, &after, 10);
128 size_t count = after - buf; 129 size_t count = after - buf;
129 130
130 if (*after && isspace(*after)) 131 if (isspace(*after))
131 count++; 132 count++;
132 133
133 if (count == size) { 134 if (count == size) {