Skip to content
Commit c0981afd authored by Wambui Karuga's avatar Wambui Karuga Committed by Greg Kroah-Hartman
Browse files

staging: kpc2000: Remove unnecessary return variable



Remove unnecessary variable `val` in kp_spi_read_reg() that only holds
the return value from readq().
Issue found by coccinelle using the script:

@@
local idexpression ret;
expression e;
@@

-ret =
+return
     e;
-return ret;

Signed-off-by: default avatarWambui Karuga <wambui.karugax@gmail.com>
Acked-by: default avatarJulia Lawall <julia.lawall@lip6.fr>
Link: https://lore.kernel.org/r/20191009170703.GA2869@wambui


Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
parent d49d1c76
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please to comment