提交 b25b750d 编写于 作者: M Mathieu Malaterre 提交者: Ulf Hansson

mmc: block: propagate correct returned value in mmc_rpmb_ioctl

In commit 97548575 ("mmc: block: Convert RPMB to a character device") a
new function `mmc_rpmb_ioctl` was added. The final return is simply
returning a value of `0` instead of propagating the correct return code.

Discovered during a compilation with W=1, silence the following gcc warning

drivers/mmc/core/block.c:2470:6: warning: variable ‘ret’ set but not used
[-Wunused-but-set-variable]
Signed-off-by: NMathieu Malaterre <malat@debian.org>
Reviewed-by: NShawn Lin <shawn.lin@rock-chips.com>
Fixes: 97548575 ("mmc: block: Convert RPMB to a character device")
Cc: stable@vger.kernel.org # v4.15+
Signed-off-by: NUlf Hansson <ulf.hansson@linaro.org>
上级 6da6c0db
......@@ -2485,7 +2485,7 @@ static long mmc_rpmb_ioctl(struct file *filp, unsigned int cmd,
break;
}
return 0;
return ret;
}
#ifdef CONFIG_COMPAT
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册