提交 47fff9fd 编写于 作者: L Lee Jones 提交者: Bjorn Andersson

remoteproc: debugfs: Return error on invalid 'count' value

If 'count' value is invalid, return -EINVAL.
Signed-off-by: NLee Jones <lee.jones@linaro.org>
[bjorn: changed commit message]
Signed-off-by: NBjorn Andersson <bjorn.andersson@linaro.org>
上级 99c429cb
......@@ -157,7 +157,7 @@ rproc_recovery_write(struct file *filp, const char __user *user_buf,
int ret;
if (count < 1 || count > sizeof(buf))
return count;
return -EINVAL;
ret = copy_from_user(buf, user_buf, count);
if (ret)
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册