Message ID | 1655560330-30743-11-git-send-email-jsimmons@infradead.org (mailing list archive) |
---|---|
State | Not Applicable |
Headers | show |
Series | lustre: sync to OpenSFS June 15, 2022 | expand |
diff --git a/net/lnet/klnds/o2iblnd/o2iblnd.c b/net/lnet/klnds/o2iblnd/o2iblnd.c index 8dce4179..65bc89b 100644 --- a/net/lnet/klnds/o2iblnd/o2iblnd.c +++ b/net/lnet/klnds/o2iblnd/o2iblnd.c @@ -2609,6 +2609,12 @@ static void kiblnd_shutdown(struct lnet_ni *ni) list_del(&net->ibn_list); write_unlock_irqrestore(g_lock, flags); + wake_up_all(&kiblnd_data.kib_connd_waitq); + wait_var_event_warning(&net->ibn_nconns, + atomic_read(&net->ibn_nconns) == 0, + "%s: waiting for %d conns to clean\n", + libcfs_nidstr(&ni->ni_nid), + atomic_read(&net->ibn_nconns)); /* fall through */ case IBLND_INIT_NOTHING: