[PATCH] staging: speakup: replace simple_strtoul with kstrtou8

From: Marcin Ciupak
Date: Thu Mar 02 2017 - 12:25:34 EST


Replace simple_strtoul with kstrtou8.
simple_strtoul is marked for obsoletion.

Signed-off-by: Marcin Ciupak <marcin.s.ciupak@xxxxxxxxx>
---
drivers/staging/speakup/varhandlers.c | 5 ++---
1 file changed, 2 insertions(+), 3 deletions(-)

diff --git a/drivers/staging/speakup/varhandlers.c b/drivers/staging/speakup/varhandlers.c
index cc984196020f..c219db745865 100644
--- a/drivers/staging/speakup/varhandlers.c
+++ b/drivers/staging/speakup/varhandlers.c
@@ -323,11 +323,10 @@ char *spk_strlwr(char *s)

char *spk_s2uchar(char *start, char *dest)
{
- int val;
+ int ret;

- val = simple_strtoul(skip_spaces(start), &start, 10);
+ ret = kstrtou8(skip_spaces(start), 10, dest);
if (*start == ',')
start++;
- *dest = (u_char)val;
return start;
}
--
2.11.1