macintosh/ams: 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>
Signed-off-by: Benjamin Herrenschmidt <benh@kernel.crashing.org>
This commit is contained in:
Jingoo Han 2013-07-19 16:16:56 +09:00 committed by Benjamin Herrenschmidt
parent 7191b61575
commit 7033b64b48
1 changed files with 5 additions and 1 deletions

View File

@ -118,8 +118,12 @@ static ssize_t ams_input_store_joystick(struct device *dev,
{
unsigned long enable;
int error = 0;
int ret;
if (strict_strtoul(buf, 0, &enable) || enable > 1)
ret = kstrtoul(buf, 0, &enable);
if (ret)
return ret;
if (enable > 1)
return -EINVAL;
mutex_lock(&ams_input_mutex);