From 4592599af36f50ed2d3502ed1b2374f5af6cb1ae Mon Sep 17 00:00:00 2001 From: Andrey Ryabinin Date: Mon, 27 Jan 2014 17:06:59 -0800 Subject: dynamic_debug: replace obselete simple_strtoul() with kstrtouint() Signed-off-by: Andrey Ryabinin Cc: Jason Baron Signed-off-by: Andrew Morton Signed-off-by: Linus Torvalds --- lib/dynamic_debug.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) (limited to 'lib/dynamic_debug.c') diff --git a/lib/dynamic_debug.c b/lib/dynamic_debug.c index e488d9a03adc..7288e38e1757 100644 --- a/lib/dynamic_debug.c +++ b/lib/dynamic_debug.c @@ -268,14 +268,12 @@ static int ddebug_tokenize(char *buf, char *words[], int maxwords) */ static inline int parse_lineno(const char *str, unsigned int *val) { - char *end = NULL; BUG_ON(str == NULL); if (*str == '\0') { *val = 0; return 0; } - *val = simple_strtoul(str, &end, 10); - if (end == NULL || end == str || *end != '\0') { + if (kstrtouint(str, 10, val) < 0) { pr_err("bad line-number: %s\n", str); return -EINVAL; } -- cgit v1.2.3