Commit c7df94c6 authored by Dan Carpenter's avatar Dan Carpenter Committed by Linus Walleij

pinctrl: imx: remove an unnecessary NULL check

The address of "ipctl->pin_regs[pin_id]" can't be NULL.  It's the offset
into an array in the middle of a struct.  This patch removes the check.
Signed-off-by: default avatarDan Carpenter <dan.carpenter@oracle.com>
Acked-by: default avatarDong Aisheng <aisheng.dong@nxp.com>
Signed-off-by: default avatarLinus Walleij <linus.walleij@linaro.org>
parent 5e73de34
......@@ -449,7 +449,7 @@ static void imx_pinconf_dbg_show(struct pinctrl_dev *pctldev,
}
} else {
pin_reg = &ipctl->pin_regs[pin_id];
if (!pin_reg || pin_reg->conf_reg == -1) {
if (pin_reg->conf_reg == -1) {
seq_puts(s, "N/A");
return;
}
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment