Skip to contentSkip to conversation

dlm: clear recovery flags

PATCH In review David Teigland 2 participants 3 messages Jun 2, 2005

lore
Share & tools
lore
#0 lore raw

PATCH 6/9 dlm: clear recovery flags

At the start of recovery, all the recovery flags are cleared from the previous recovery. Two of them weren't being cleared.

drivers/dlm/member.c +2 -0
Index: linux/drivers/dlm/member.c
===================================================================
@@ -276,6 +276,8 @@
 	 */
 
 	dlm_recoverd_suspend(ls);
+	clear_bit(LSFL_LOCKS_VALID, &ls->ls_flags);
+	clear_bit(LSFL_ALL_LOCKS_VALID, &ls->ls_flags);
 	clear_bit(LSFL_DIR_VALID, &ls->ls_flags);
 	clear_bit(LSFL_ALL_DIR_VALID, &ls->ls_flags);
 	clear_bit(LSFL_NODES_VALID, &ls->ls_flags);

--

#1 lore raw
Quoted 11 lines · David Teigland

plain text document attachment (clear-recovery-flags.patch) At the start of recovery, all the recovery flags are cleared from the previous recovery. Two of them weren't being cleared.

Index: linux/drivers/dlm/member.c
===================================================================

drivers/dlm/member.c line 283

Quoted 8 lines
drivers/dlm/member.c +2 -0
@@ -276,6 +276,8 @@
 	 */
 
 	dlm_recoverd_suspend(ls);
+	clear_bit(LSFL_LOCKS_VALID, &ls->ls_flags);
+	clear_bit(LSFL_ALL_LOCKS_VALID, &ls->ls_flags);
 	clear_bit(LSFL_DIR_VALID, &ls->ls_flags);
 	clear_bit(LSFL_ALL_DIR_VALID, &ls->ls_flags);
 	clear_bit(LSFL_NODES_VALID, &ls->ls_flags);

btw do these need to be atomic? right now these are atomic ops and thus very expensive... you might want to switch to nonatomic variants if that's not needed.

#2 lore raw
Quoted 10 lines · Arjan van de Ven

drivers/dlm/member.c line 283

Quoted 5 lines · David Teigland
drivers/dlm/member.c +2 -0
+	clear_bit(LSFL_LOCKS_VALID, &ls->ls_flags);
+	clear_bit(LSFL_ALL_LOCKS_VALID, &ls->ls_flags);
 	clear_bit(LSFL_DIR_VALID, &ls->ls_flags);
 	clear_bit(LSFL_ALL_DIR_VALID, &ls->ls_flags);
 	clear_bit(LSFL_NODES_VALID, &ls->ls_flags);

btw do these need to be atomic? right now these are atomic ops and thus very expensive... you might want to switch to nonatomic variants if that's not needed.

No they don't, I didn't know about the __ non-atomics. I'll go through and switch, thanks.

Dave