提交 b4859f3e 编写于 作者: D Dan Carpenter 提交者: Linus Walleij

pinctrl: imx: off by one in imx_pinconf_group_dbg_show()

The > should really be >= here.  It's harmless because
pinctrl_generic_get_group() will return a NULL if group is invalid.

Fixes: ae75ff81 ("pinctrl: pinctrl-imx: add imx pinctrl core driver")
Reported-by: NDong Aisheng <aisheng.dong@nxp.com>
Signed-off-by: NDan Carpenter <dan.carpenter@oracle.com>
Signed-off-by: NLinus Walleij <linus.walleij@linaro.org>
上级 a8cfcf15
......@@ -383,7 +383,7 @@ static void imx_pinconf_group_dbg_show(struct pinctrl_dev *pctldev,
const char *name;
int i, ret;
if (group > pctldev->num_groups)
if (group >= pctldev->num_groups)
return;
seq_puts(s, "\n");
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册