Skip to content

Commit

Permalink
dlm: return -ENOENT if no comm was found
Browse files Browse the repository at this point in the history
Currently if no comm can be found dlm_comm_seq() returns -EEXIST which
means entry already exists for a lookup it makes no sense to return
-EEXIST. We change it to -ENOENT. There is no user that will evaluate
the return value on a specific value so this should be fine.

Signed-off-by: Alexander Aring <[email protected]>
Signed-off-by: David Teigland <[email protected]>
  • Loading branch information
Alexander Aring authored and teigland committed Dec 19, 2024
1 parent 57cdd1a commit 6784ed9
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion fs/dlm/config.c
Original file line number Diff line number Diff line change
Expand Up @@ -935,7 +935,7 @@ int dlm_comm_seq(int nodeid, uint32_t *seq, bool locked)
mutex_unlock(&clusters_root.subsys.su_mutex);
}
if (!cm)
return -EEXIST;
return -ENOENT;

*seq = cm->seq;
put_comm(cm);
Expand Down

0 comments on commit 6784ed9

Please sign in to comment.