Skip to content

Commit e759eb3

Browse files
Alexander Aringteigland
authored andcommitted
dlm: be sure we reset all nodes at forced shutdown
In case we running in a force shutdown in either midcomms or lowcomms implementation we will make sure we reset all per midcomms node information. Fixes: 63e711b ("fs: dlm: create midcomms nodes when configure") Signed-off-by: Alexander Aring <[email protected]> Signed-off-by: David Teigland <[email protected]>
1 parent 2776635 commit e759eb3

File tree

1 file changed

+8
-2
lines changed

1 file changed

+8
-2
lines changed

fs/dlm/midcomms.c

Lines changed: 8 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1405,10 +1405,16 @@ void dlm_midcomms_shutdown(void)
14051405
midcomms_shutdown(node);
14061406
}
14071407
}
1408-
srcu_read_unlock(&nodes_srcu, idx);
1409-
mutex_unlock(&close_lock);
14101408

14111409
dlm_lowcomms_shutdown();
1410+
1411+
for (i = 0; i < CONN_HASH_SIZE; i++) {
1412+
hlist_for_each_entry_rcu(node, &node_hash[i], hlist) {
1413+
midcomms_node_reset(node);
1414+
}
1415+
}
1416+
srcu_read_unlock(&nodes_srcu, idx);
1417+
mutex_unlock(&close_lock);
14121418
}
14131419

14141420
int dlm_midcomms_close(int nodeid)

0 commit comments

Comments
 (0)