]> git.baikalelectronics.ru Git - kernel.git/commit
staging: ks7010: remove switch statement
authorTobin C. Harding <me@tobin.cc>
Mon, 27 Feb 2017 03:14:47 +0000 (14:14 +1100)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Mon, 6 Mar 2017 08:17:05 +0000 (09:17 +0100)
commit396ef92d012ceb797c9dd2c7ef7b3258691b0bb0
treec8cca2e022fc4667f8c148684f4fcb6025eb59aa
parent14e473d56456ff7f68b91ab9c16c298746a2d6a5
staging: ks7010: remove switch statement

Switch statement uses one [trivial] case and a default case holding
bulk of code. We can swap the switch statement with an if/return
statement as replacement for the original switch. This can be done
without changing the program logic.

Remove switch statement. Use original switch parameter as conditional
and return if conditional evaluates to true. Reduce level of
indentation. Do not change the program logic.

Signed-off-by: Tobin C. Harding <me@tobin.cc>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/staging/ks7010/ks7010_sdio.c