misc: replace strict_strtoul() with kstrtoul()

The usage of strict_strtoul() is not preferred, because
strict_strtoul() is obsolete. Thus, kstrtoul() should be
used.

Signed-off-by: Jingoo Han <jg1.han@samsung.com>
Reviewed-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
This commit is contained in:
Jingoo Han
2013-06-04 13:15:16 +09:00
committed by Greg Kroah-Hartman
parent 4cd5773a2a
commit f7b41276b6
14 changed files with 153 additions and 82 deletions

View File

@@ -46,8 +46,9 @@ static int compass_store(struct device *dev, const char *buf, size_t count,
int ret;
unsigned long val;
if (strict_strtoul(buf, 10, &val))
return -EINVAL;
ret = kstrtoul(buf, 10, &val);
if (ret)
return ret;
if (val >= strlen(map))
return -EINVAL;
mutex_lock(&compass_mutex);