Skip to content

Commit

Permalink
dm ebs: avoid double unlikely() notation when using IS_ERR()
Browse files Browse the repository at this point in the history
The definition of IS_ERR() already applies the unlikely() notation
when checking the error status of the passed pointer. For this
reason there is no need to have the same notation outside of
IS_ERR() itself.

Clean up code by removing redundant notation.

Signed-off-by: Antonio Quartulli <a@unstable.cc>
Signed-off-by: Mike Snitzer <snitzer@redhat.com>
  • Loading branch information
Antonio Quartulli authored and Mike Snitzer committed Dec 21, 2020
1 parent 252bd12 commit 52252ad
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion drivers/md/dm-ebs-target.c
Original file line number Diff line number Diff line change
Expand Up @@ -86,7 +86,7 @@ static int __ebs_rw_bvec(struct ebs_c *ec, int rw, struct bio_vec *bv, struct bv
else
ba = dm_bufio_new(ec->bufio, block, &b);

if (unlikely(IS_ERR(ba))) {
if (IS_ERR(ba)) {
/*
* Carry on with next buffer, if any, to issue all possible
* data but return error.
Expand Down

0 comments on commit 52252ad

Please sign in to comment.