Whamcloud - gitweb
LU-12381 ko2iblnd: ignore down interfaces 98/35098/4
authorJames Simmons <uja.ornl@yahoo.com>
Mon, 10 Jun 2019 13:58:29 +0000 (09:58 -0400)
committerOleg Drokin <green@whamcloud.com>
Sun, 16 Jun 2019 03:26:06 +0000 (03:26 +0000)
The for_each_netdev() loop in kiblnd_create_dev() scans for all
network devices on a system. Currently the code exit when an
network device is down but the device could be something besides
an IB device. Instead of exiting just ignore any device that is
down.

Test-Parameters: trivial

Fixes: c4b39bf56bbc ("LU-11893 o2iblnd: add secondary IP address handling")
Change-Id: I0a3bf808d849cd00711b6ef2e4e5bbd876b64903
Signed-off-by: James Simmons <uja.ornl@yahoo.com>
Reviewed-on: https://review.whamcloud.com/35098
Tested-by: Jenkins
Reviewed-by: Chris Horn <hornc@cray.com>
Tested-by: Maloo <maloo@whamcloud.com>
Reviewed-by: Andreas Dilger <adilger@whamcloud.com>
Reviewed-by: Amir Shehata <ashehata@whamcloud.com>
Reviewed-by: Oleg Drokin <green@whamcloud.com>
lnet/klnds/o2iblnd/o2iblnd.c

index 6da280e..68b9da5 100644 (file)
@@ -2888,16 +2888,16 @@ kiblnd_create_dev(char *ifname)
 
                flags = dev_get_flags(netdev);
                if (!(flags & IFF_UP)) {
-                       CERROR("Can't query IPoIB interface %s: it's down\n",
-                              netdev->name);
-                       goto unlock;
+                       CWARN("Can't query IPoIB interface %s: it's down\n",
+                             netdev->name);
+                       continue;
                }
 
                in_dev = __in_dev_get_rtnl(netdev);
                if (!in_dev) {
                        CWARN("Interface %s has no IPv4 status.\n",
                              netdev->name);
-                       goto unlock;
+                       continue;
                }
 
                for_ifa(in_dev)