Thread (3 messages) flat view 3 messages, 3 authors, 2021-06-03

Re: [PATCH net-next] net: ks8851: Make ks8851_read_selftest() return void

From: Andrew Lunn <andrew@lunn.ch>
Date: 2021-06-03 17:02:27
Also in: lkml

On Thu, Jun 03, 2021 at 09:56:13AM -0700, Nathan Chancellor wrote:
clang points out that ret in ks8851_read_selftest() is set but unused:

drivers/net/ethernet/micrel/ks8851_common.c:1028:6: warning: variable
'ret' set but not used [-Wunused-but-set-variable]
        int ret = 0;
            ^
1 warning generated.

The return code of this function has never been checked so just remove
ret and make the function return void.

Fixes: 3ba81f3ece3c ("net: Micrel KS8851 SPI network driver")
Suggested-by: Andrew Lunn <andrew@lunn.ch>
Signed-off-by: Nathan Chancellor <nathan@kernel.org>
Reviewed-by: Andrew Lunn <andrew@lunn.ch>

    Andrew
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help