]> git.baikalelectronics.ru Git - kernel.git/commit
sky2: Remove redundant assignment and parentheses
authorluo penghao <cgel.zte@gmail.com>
Thu, 28 Oct 2021 03:15:51 +0000 (03:15 +0000)
committerDavid S. Miller <davem@davemloft.net>
Thu, 28 Oct 2021 13:39:06 +0000 (14:39 +0100)
commit170d2054e8e96318989770c94ab1a6fba3d611c0
treed6df0e4a6fa722ad35b522efa5b843ec7478a75d
parent0879e8f18459f5ab2d9239c53b4d83f9182a1dbb
sky2: Remove redundant assignment and parentheses

The variable err will be reassigned on subsequent branches, and this
assignment does not perform related value operations. This will cause
the double parentheses to be redundant, so the inner parentheses should
be deleted.

clang_analyzer complains as follows:

drivers/net/ethernet/marvell/sky2.c:4988: warning:

Although the value stored to 'err' is used in the enclosing expression,
the value is never actually read from 'err'.

Changes in v2:

modify title category:octeontx2-af to sky2.
delete the inner parentheses.

Reported-by: Zeal Robot <zealci@zte.com.cn>
Signed-off-by: luo penghao <luo.penghao@zte.com.cn>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/ethernet/marvell/sky2.c