Commit 6cfbcf2f authored by Namjae Jeon's avatar 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: default avatarCoverity Scan <scan-admin@coverity.com>
Signed-off-by: default avatarNamjae Jeon <namjae.jeon@samsung.com>
Signed-off-by: default avatarSteve French <stfrench@microsoft.com>
parent 4951a84f
...@@ -7004,11 +7004,6 @@ static int fsctl_query_iface_info_ioctl(struct ksmbd_conn *conn, ...@@ -7004,11 +7004,6 @@ static int fsctl_query_iface_info_ioctl(struct ksmbd_conn *conn,
rtnl_lock(); rtnl_lock();
for_each_netdev(&init_net, netdev) { for_each_netdev(&init_net, netdev) {
if (unlikely(!netdev)) {
rtnl_unlock();
return -EINVAL;
}
if (netdev->type == ARPHRD_LOOPBACK) if (netdev->type == ARPHRD_LOOPBACK)
continue; continue;
......
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