staging: sm750fb: compress return logic
authorElizabeth Ferdman <gnudevliz@gmail.com>
Wed, 12 Oct 2016 02:29:20 +0000 (19:29 -0700)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Sun, 16 Oct 2016 08:26:19 +0000 (10:26 +0200)
commitbe704e58328d4c488677c59e04dd9cec2d9515a2
tree4d8930bb487d8226512c7a90ada4eaa008b5c7ef
parentefe9bc08bf479b1baacc63554042c5dd11fecd9e
staging: sm750fb: compress return logic

Using Coccinelle script, compress return logic to return a value
directly rather than doing an assignment and returning the variable.
Remove unnecessary variable declaration by hand.

Coccinelle script:

@@
local idexpression ret;
expression e;
@@

-ret =
+return
     e;
-return ret;

Signed-off-by: Elizabeth Ferdman <gnudevliz@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/staging/sm750fb/sm750.c