Whamcloud - gitweb
LU-11297 lnet: MR Routing Feature
[fs/lustre-release.git] / lnet / lnet / router_proc.c
index 8d6b040..23ec36e 100644 (file)
@@ -689,11 +689,7 @@ proc_lnet_nis(struct ctl_table *table, int write, void __user *buffer,
                        int j;
 
                        if (the_lnet.ln_routing)
-                               last_alive = now - ni->ni_last_alive;
-
-                       /* @lo forever alive */
-                       if (ni->ni_net->net_lnd->lnd_type == LOLND)
-                               last_alive = 0;
+                               last_alive = now - ni->ni_net->net_last_alive;
 
                        lnet_ni_lock(ni);
                        LASSERT(ni->ni_status != NULL);
@@ -701,6 +697,12 @@ proc_lnet_nis(struct ctl_table *table, int write, void __user *buffer,
                                LNET_NI_STATUS_UP) ? "up" : "down";
                        lnet_ni_unlock(ni);
 
+                       /* @lo forever alive */
+                       if (ni->ni_net->net_lnd->lnd_type == LOLND) {
+                               last_alive = 0;
+                               stat = "up";
+                       }
+
                        /* we actually output credits information for
                         * TX queue of each partition */
                        cfs_percpt_for_each(tq, i, ni->ni_tx_queues) {