]> git.baikalelectronics.ru Git - kernel.git/commit
staging: mt7621-mmc: Fix ret.cooci warnings
authorBhanusree Pola <bhanusreemahesh@gmail.com>
Sun, 17 Mar 2019 11:01:33 +0000 (16:31 +0530)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Mon, 18 Mar 2019 06:47:53 +0000 (07:47 +0100)
commitd645c7879f4b0223f402a4396ae45b91053bc356
tree8667bb71090a8ad278249a0f176060d0795b9b82
parent1758ff64d8be4c0df422bb8e4eeaf36c5b858bd8
staging: mt7621-mmc: Fix ret.cooci warnings

Return the value directly instead of storing it in local variable err.
Remove the unused local variable err.
The semantic patch that fixes the first part of the problem is as follows

// <smpl>
@@
local idexpression ret;
expression e;
@@

-ret =
+return
     e;
-return ret;
// </smpl>

Signed-off-by: Bhanusree Pola <bhanusreemahesh@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/staging/mt7621-mmc/sd.c