Skip to content

Commit 0afc0de

Browse files
Martin Brandenburgtorvalds
authored andcommitted
orangefs: use list_for_each_entry_safe in purge_waiting_ops
set_op_state_purged can delete the op. Signed-off-by: Martin Brandenburg <[email protected]> Cc: [email protected] Signed-off-by: Linus Torvalds <[email protected]>
1 parent 7222708 commit 0afc0de

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

fs/orangefs/waitqueue.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -29,10 +29,10 @@ static void orangefs_clean_up_interrupted_operation(struct orangefs_kernel_op_s
2929
*/
3030
void purge_waiting_ops(void)
3131
{
32-
struct orangefs_kernel_op_s *op;
32+
struct orangefs_kernel_op_s *op, *tmp;
3333

3434
spin_lock(&orangefs_request_list_lock);
35-
list_for_each_entry(op, &orangefs_request_list, list) {
35+
list_for_each_entry_safe(op, tmp, &orangefs_request_list, list) {
3636
gossip_debug(GOSSIP_WAIT_DEBUG,
3737
"pvfs2-client-core: purging op tag %llu %s\n",
3838
llu(op->tag),

0 commit comments

Comments
 (0)