提交 6cfbcf2f 编写于 作者: N Namjae Jeon

ksmbd: remove unneeded NULL check in for_each_netdev

netdev can never be NULL in for_each_netdev loop.
This patch remove unneeded NULL check.
Reported-by: NCoverity Scan <scan-admin@coverity.com>
Signed-off-by: NNamjae Jeon <namjae.jeon@samsung.com>
Signed-off-by: NSteve French <stfrench@microsoft.com>
上级 4951a84f
......@@ -7004,11 +7004,6 @@ static int fsctl_query_iface_info_ioctl(struct ksmbd_conn *conn,
rtnl_lock();
for_each_netdev(&init_net, netdev) {
if (unlikely(!netdev)) {
rtnl_unlock();
return -EINVAL;
}
if (netdev->type == ARPHRD_LOOPBACK)
continue;
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册