Discussion:
[PATCH] staging: speakup: replace simple_strtoul with kstrtoul
Samuel Thibault
2018-08-07 18:57:33 UTC
Permalink
simple_strtoul is obsolete, replace with kstrtoul.
Issue found by checkpatch.
kstrtoul can't replace simple_strtoul, their APIs are really not the
same.

Samuel
---
drivers/staging/speakup/kobjects.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/staging/speakup/kobjects.c b/drivers/staging/speakup/kobjects.c
index 08f11cc..33459c0 100644
--- a/drivers/staging/speakup/kobjects.c
+++ b/drivers/staging/speakup/kobjects.c
@@ -154,7 +154,7 @@ static ssize_t chars_chartab_store(struct kobject *kobj,
continue;
}
- index = simple_strtoul(cp, &temp, 10);
+ index = kstrtoul(cp, &temp, 10);
if (index > 255) {
rejected++;
cp = linefeed + 1;
--
2.7.4
--
Samuel
Q: How do you play religious roulette?
A: You stand around in a circle and blaspheme and see who gets struck by lightning first.
Loading...