提交 cdf5e551 编写于 作者: J Johannes Thumshirn 提交者: Greg Kroah-Hartman

staging: line6: pcm.c: Changed simple_strtoul to kstrtoint

Changed call to simple_strtoul to kstrtoint in pcm_set_impulse_volume(...)
Signed-off-by: NJohannes Thumshirn <morbidrsa@googlemail.com>
Reviewed-by: NStefan Hajnoczi <stefanha@gmail.com>
Signed-off-by: NGreg Kroah-Hartman <gregkh@linuxfoundation.org>
上级 d7de9935
......@@ -48,7 +48,13 @@ static ssize_t pcm_set_impulse_volume(struct device *dev,
const char *buf, size_t count)
{
struct snd_line6_pcm *line6pcm = dev2pcm(dev);
int value = simple_strtoul(buf, NULL, 10);
int value;
int rv;
rv = kstrtoint(buf, 10, &value);
if (rv < 0)
return rv;
line6pcm->impulse_volume = value;
if (value > 0)
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册