mm/damon/sysfs: return 'err' value when call kstrtoul() failed
authorXin Hao <xhao@linux.alibaba.com>
Tue, 20 Sep 2022 16:35:30 +0000 (16:35 +0000)
committerAndrew Morton <akpm@linux-foundation.org>
Mon, 3 Oct 2022 21:03:31 +0000 (14:03 -0700)
commit30b6242c49cd2a98def3bb2feee68d82a0e9686b
treebeeff618d66f78bb386546388bddb42510263f41
parenta57ae9ef9e1a20b68ae841a8cab7aff3f000ed9d
mm/damon/sysfs: return 'err' value when call kstrtoul() failed

We had better return the 'err' value when calling kstrtoul() failed, so
the user will know why it really fails, there do little change, let it
return the 'err' value when failed.

Link: https://lkml.kernel.org/r/6329ebe0.050a0220.ec4bd.297cSMTPIN_ADDED_BROKEN@mx.google.com
Suggested-by: SeongJae Park <sj@kernel.org>
Signed-off-by: Xin Hao <xhao@linux.alibaba.com>
Reviewed-by: SeongJae Park <sj@kernel.org>
Signed-off-by: SeongJae Park <sj@kernel.org>
Reviewed-by: Xin Hao <xhao@linux.alibaba.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
mm/damon/sysfs.c