提交 b3552d6a 编写于 作者: J Jakub Kicinski 提交者: Paolo Abeni

eth: dpaa2-mac: remove a dead-code NULL check on fwnode parent

Since commit 4e30e98c ("dpaa2-mac: return -EPROBE_DEFER from dpaa2_mac_open in case the fwnode is not set")
@parent can't be NULL after the if. It's either the address
of the ->fwnode of @dpmacs or @fwnode in case of ACPI.
Signed-off-by: NJakub Kicinski <kuba@kernel.org>
Link: https://lore.kernel.org/r/20220506200029.852310-1-kuba@kernel.orgSigned-off-by: NPaolo Abeni <pabeni@redhat.com>
上级 9eab75d4
......@@ -108,9 +108,6 @@ static struct fwnode_handle *dpaa2_mac_get_node(struct device *dev,
return ERR_PTR(-EPROBE_DEFER);
}
if (!parent)
return NULL;
fwnode_for_each_child_node(parent, child) {
err = -EINVAL;
if (is_acpi_device_node(child))
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册