Re: [PATCH] can: mcp251xfd: remove useless code in mcp251xfd_chip_softreset

2020-11-17 Thread Marc Kleine-Budde
On Tue, Nov 17, 2020 at 05:29:12PM +0800, xiakaixu1...@gmail.com wrote: > From: Kaixu Xia > > It would directly return if the variable err equals to 0 or other errors. > Only when the err equals to -ETIMEDOUT it can reach the 'if (err)' > statement, so the 'if (err)' and last 'return -ETIMEDOUT'

[PATCH] can: mcp251xfd: remove useless code in mcp251xfd_chip_softreset

2020-11-17 Thread xiakaixu1987
From: Kaixu Xia It would directly return if the variable err equals to 0 or other errors. Only when the err equals to -ETIMEDOUT it can reach the 'if (err)' statement, so the 'if (err)' and last 'return -ETIMEDOUT' statements are useless. Romove them. Reported-by: Tosk Robot Signed-off-by: Kaix