diff options
author | Sunil Mushran <sunil.mushran@oracle.com> | 2010-10-08 02:00:16 +0200 |
---|---|---|
committer | Sunil Mushran <sunil.mushran@oracle.com> | 2010-10-08 02:00:16 +0200 |
commit | 0e105d37c2adb19cb777aa6701a866f211764a30 (patch) | |
tree | 288022158da0392b240484784db4aaca0a44915d /fs/ocfs2/cluster/tcp.c | |
parent | ocfs2/cluster: Print messages when adding/removing nodes (diff) | |
download | linux-0e105d37c2adb19cb777aa6701a866f211764a30.tar.xz linux-0e105d37c2adb19cb777aa6701a866f211764a30.zip |
ocfs2/cluster: Check slots for unconfigured live nodes
o2hb currently checks slots for configured nodes only. This patch makes
it check the slots for the live nodes too to take care of a race in which
a node is removed from the configuration but not from the live map.
Signed-off-by: Sunil Mushran <sunil.mushran@oracle.com>
Diffstat (limited to 'fs/ocfs2/cluster/tcp.c')
-rw-r--r-- | fs/ocfs2/cluster/tcp.c | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/fs/ocfs2/cluster/tcp.c b/fs/ocfs2/cluster/tcp.c index cbe2f057cc28..9aa426e42123 100644 --- a/fs/ocfs2/cluster/tcp.c +++ b/fs/ocfs2/cluster/tcp.c @@ -1696,6 +1696,9 @@ static void o2net_hb_node_down_cb(struct o2nm_node *node, int node_num, { o2quo_hb_down(node_num); + if (!node) + return; + if (node_num != o2nm_this_node()) o2net_disconnect_node(node); @@ -1709,6 +1712,8 @@ static void o2net_hb_node_up_cb(struct o2nm_node *node, int node_num, o2quo_hb_up(node_num); + BUG_ON(!node); + /* ensure an immediate connect attempt */ nn->nn_last_connect_attempt = jiffies - (msecs_to_jiffies(o2net_reconnect_delay()) + 1); |