diff options
author | Jingoo Han <jg1.han@samsung.com> | 2013-07-19 03:16:56 -0400 |
---|---|---|
committer | Benjamin Herrenschmidt <benh@kernel.crashing.org> | 2013-08-14 00:57:43 -0400 |
commit | 7033b64b48a3eafdd5d5f541ff6ccb96f69d9911 (patch) | |
tree | 8f3d7a812f6f4463a5ae7100d768160cd0ec8817 /drivers/macintosh | |
parent | 7191b615759ec10cab9eea43be5ecc42cda82364 (diff) |
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>
Diffstat (limited to 'drivers/macintosh')
-rw-r--r-- | drivers/macintosh/ams/ams-input.c | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/drivers/macintosh/ams/ams-input.c b/drivers/macintosh/ams/ams-input.c index b27e530a87a4..2edae7dfcab2 100644 --- a/drivers/macintosh/ams/ams-input.c +++ b/drivers/macintosh/ams/ams-input.c | |||
@@ -118,8 +118,12 @@ static ssize_t ams_input_store_joystick(struct device *dev, | |||
118 | { | 118 | { |
119 | unsigned long enable; | 119 | unsigned long enable; |
120 | int error = 0; | 120 | int error = 0; |
121 | int ret; | ||
121 | 122 | ||
122 | if (strict_strtoul(buf, 0, &enable) || enable > 1) | 123 | ret = kstrtoul(buf, 0, &enable); |
124 | if (ret) | ||
125 | return ret; | ||
126 | if (enable > 1) | ||
123 | return -EINVAL; | 127 | return -EINVAL; |
124 | 128 | ||
125 | mutex_lock(&ams_input_mutex); | 129 | mutex_lock(&ams_input_mutex); |