diff options
Diffstat (limited to 'drivers/input/input-polldev.c')
-rw-r--r-- | drivers/input/input-polldev.c | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/drivers/input/input-polldev.c b/drivers/input/input-polldev.c index b253973881b8..1986a52a7ab9 100644 --- a/drivers/input/input-polldev.c +++ b/drivers/input/input-polldev.c @@ -83,10 +83,12 @@ static ssize_t input_polldev_set_poll(struct device *dev, { struct input_polled_dev *polldev = dev_get_drvdata(dev); struct input_dev *input = polldev->input; - unsigned long interval; + unsigned int interval; + int err; - if (strict_strtoul(buf, 0, &interval)) - return -EINVAL; + err = kstrtouint(buf, 0, &interval); + if (err) + return err; if (interval < polldev->poll_interval_min) return -EINVAL; |