Skip to content

Commit

Permalink
NFC: microread: Remove redundant assignment to variable err
Browse files Browse the repository at this point in the history
In the case MICROREAD_CB_TYPE_READER_ALL clang reports a dead code
warning. The error code assigned to variable err is already passed
to async_cb(). The assignment is redundant and can be removed.

Addresses-Coverity: ("Unused value")
Signed-off-by: Nigel Christian <nigel.l.christian@gmail.com>
Reviewed-by: Krzysztof Kozlowski <krzysztof.kozlowski@canonical.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
  • Loading branch information
Nigel Christian authored and David S. Miller committed Jun 1, 2021
1 parent 686e846 commit e5432cc
Showing 1 changed file with 0 additions and 1 deletion.
1 change: 0 additions & 1 deletion drivers/nfc/microread/microread.c
Original file line number Diff line number Diff line change
Expand Up @@ -364,7 +364,6 @@ static void microread_im_transceive_cb(void *context, struct sk_buff *skb,
case MICROREAD_CB_TYPE_READER_ALL:
if (err == 0) {
if (skb->len == 0) {
err = -EPROTO;
kfree_skb(skb);
info->async_cb(info->async_cb_context, NULL,
-EPROTO);
Expand Down

0 comments on commit e5432cc

Please sign in to comment.