Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

nfc: st21nfca: remove redundant assignment to variable i

Variable i is being assigned a value that is never read, the
assignment is redundant and can be removed. Cleans up clang-scan
build warning:

drivers/nfc/st21nfca/i2c.c:319:4: warning: Value stored to 'i'
is never read [deadcode.DeadStores]
i = 0;

Signed-off-by: Colin Ian King <colin.i.king@gmail.com>
Reviewed-by: Krzysztof Kozlowski <krzysztof.kozlowski@canonical.com>
Link: https://lore.kernel.org/r/20211230161230.428457-1-colin.i.king@gmail.com
Signed-off-by: Jakub Kicinski <kuba@kernel.org>

authored by

Colin Ian King and committed by
Jakub Kicinski
314fbde9 aec53e60

+1 -3
+1 -3
drivers/nfc/st21nfca/i2c.c
··· 315 315 skb_pull(skb, 1); 316 316 317 317 r = check_crc(skb->data, skb->len); 318 - if (r != 0) { 319 - i = 0; 318 + if (r != 0) 320 319 return -EBADMSG; 321 - } 322 320 323 321 /* remove headbyte */ 324 322 skb_pull(skb, 1);