提交 a63b53e1 编写于 作者: J Junlin Yang 提交者: Greg Kroah-Hartman

usb: typec: tcpci_maxim: remove redundant assignment

PTR_ERR(chip->tcpci) has been used as a return value,
it is not necessary to assign it to ret, so remove it.
Reviewed-by: NGuenter Roeck <linux@roeck-us.net>
Reviewed-by: NHeikki Krogerus <heikki.krogerus@linux.intel.com>
Signed-off-by: NJunlin Yang <yangjunlin@yulong.com>
Link: https://lore.kernel.org/r/20210124143853.1630-1-angkery@163.comSigned-off-by: NGreg Kroah-Hartman <gregkh@linuxfoundation.org>
上级 f75a1025
......@@ -458,7 +458,6 @@ static int max_tcpci_probe(struct i2c_client *client, const struct i2c_device_id
chip->tcpci = tcpci_register_port(chip->dev, &chip->data);
if (IS_ERR(chip->tcpci)) {
dev_err(&client->dev, "TCPCI port registration failed");
ret = PTR_ERR(chip->tcpci);
return PTR_ERR(chip->tcpci);
}
chip->port = tcpci_get_tcpm_port(chip->tcpci);
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册