* [PATCH] ASoC: fix simple_return.cocci warnings [not found] <201504281230.EVsrh0Ze%fengguang.wu@intel.com> @ 2015-04-28 4:20 ` kbuild test robot 2015-04-30 20:22 ` Mark Brown 2015-04-28 4:20 ` kbuild test robot 1 sibling, 1 reply; 5+ messages in thread From: kbuild test robot @ 2015-04-28 4:20 UTC (permalink / raw) To: Lars-Peter Clausen Cc: kbuild-all, Mark Brown, Liam Girdwood, Jaroslav Kysela, Takashi Iwai, alsa-devel, linux-kernel sound/soc/codecs/adau1977.c:496:5-8: WARNING: end returns can be simpified Simplify a trivial if-return sequence. Possibly combine with a preceding function call. Generated by: scripts/coccinelle/misc/simple_return.cocci CC: Lars-Peter Clausen <lars@metafoo.de> Signed-off-by: Fengguang Wu <fengguang.wu@intel.com> --- adau1977.c | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) --- a/sound/soc/codecs/adau1977.c +++ b/sound/soc/codecs/adau1977.c @@ -493,10 +493,7 @@ static int adau1977_set_bias_level(struc break; } - if (ret) - return ret; - - return 0; + return ret; } static int adau1977_set_tdm_slot(struct snd_soc_dai *dai, unsigned int tx_mask, ^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: [PATCH] ASoC: fix simple_return.cocci warnings 2015-04-28 4:20 ` [PATCH] ASoC: fix simple_return.cocci warnings kbuild test robot @ 2015-04-30 20:22 ` Mark Brown 0 siblings, 0 replies; 5+ messages in thread From: Mark Brown @ 2015-04-30 20:22 UTC (permalink / raw) To: kbuild test robot Cc: Lars-Peter Clausen, kbuild-all, Liam Girdwood, Jaroslav Kysela, Takashi Iwai, alsa-devel, linux-kernel [-- Attachment #1: Type: text/plain, Size: 359 bytes --] On Tue, Apr 28, 2015 at 12:20:32PM +0800, kbuild test robot wrote: > sound/soc/codecs/adau1977.c:496:5-8: WARNING: end returns can be simpified > > Simplify a trivial if-return sequence. Possibly combine with a > preceding function call. > Generated by: scripts/coccinelle/misc/simple_return.cocci This doesn't apply against current code either. [-- Attachment #2: Digital signature --] [-- Type: application/pgp-signature, Size: 473 bytes --] ^ permalink raw reply [flat|nested] 5+ messages in thread
* [PATCH] ASoC: fix simple_return.cocci warnings [not found] <201504281230.EVsrh0Ze%fengguang.wu@intel.com> 2015-04-28 4:20 ` [PATCH] ASoC: fix simple_return.cocci warnings kbuild test robot @ 2015-04-28 4:20 ` kbuild test robot 2015-04-30 20:21 ` Mark Brown 2015-04-30 20:21 ` Mark Brown 1 sibling, 2 replies; 5+ messages in thread From: kbuild test robot @ 2015-04-28 4:20 UTC (permalink / raw) To: Lars-Peter Clausen Cc: kbuild-all, Mark Brown, Liam Girdwood, Jaroslav Kysela, Takashi Iwai, alsa-devel, linux-kernel sound/soc/codecs/ssm2518.c:521:5-8: WARNING: end returns can be simpified Simplify a trivial if-return sequence. Possibly combine with a preceding function call. Generated by: scripts/coccinelle/misc/simple_return.cocci CC: Lars-Peter Clausen <lars@metafoo.de> Signed-off-by: Fengguang Wu <fengguang.wu@intel.com> --- ssm2518.c | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) --- a/sound/soc/codecs/ssm2518.c +++ b/sound/soc/codecs/ssm2518.c @@ -518,10 +518,7 @@ static int ssm2518_set_bias_level(struct break; } - if (ret) - return ret; - - return 0; + return ret; } static int ssm2518_set_tdm_slot(struct snd_soc_dai *dai, unsigned int tx_mask, ^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: [PATCH] ASoC: fix simple_return.cocci warnings 2015-04-28 4:20 ` kbuild test robot @ 2015-04-30 20:21 ` Mark Brown 2015-04-30 20:21 ` Mark Brown 1 sibling, 0 replies; 5+ messages in thread From: Mark Brown @ 2015-04-30 20:21 UTC (permalink / raw) To: kbuild test robot Cc: Lars-Peter Clausen, kbuild-all, Liam Girdwood, Jaroslav Kysela, Takashi Iwai, alsa-devel, linux-kernel [-- Attachment #1: Type: text/plain, Size: 327 bytes --] On Tue, Apr 28, 2015 at 12:20:32PM +0800, kbuild test robot wrote: > sound/soc/codecs/ssm2518.c:521:5-8: WARNING: end returns can be simpified > > Simplify a trivial if-return sequence. Possibly combine with a > preceding function call. > Generated by: scripts/coccinelle/misc/simple_return.cocci Applied, thanks. [-- Attachment #2: Digital signature --] [-- Type: application/pgp-signature, Size: 473 bytes --] ^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: [PATCH] ASoC: fix simple_return.cocci warnings 2015-04-28 4:20 ` kbuild test robot 2015-04-30 20:21 ` Mark Brown @ 2015-04-30 20:21 ` Mark Brown 1 sibling, 0 replies; 5+ messages in thread From: Mark Brown @ 2015-04-30 20:21 UTC (permalink / raw) To: kbuild test robot Cc: Lars-Peter Clausen, kbuild-all, Liam Girdwood, Jaroslav Kysela, Takashi Iwai, alsa-devel, linux-kernel [-- Attachment #1: Type: text/plain, Size: 393 bytes --] On Tue, Apr 28, 2015 at 12:20:32PM +0800, kbuild test robot wrote: > sound/soc/codecs/ssm2518.c:521:5-8: WARNING: end returns can be simpified > > Simplify a trivial if-return sequence. Possibly combine with a > preceding function call. > Generated by: scripts/coccinelle/misc/simple_return.cocci Oops, sorry - doesn't apply against current code (fat fingered my initial apply). [-- Attachment #2: Digital signature --] [-- Type: application/pgp-signature, Size: 473 bytes --] ^ permalink raw reply [flat|nested] 5+ messages in thread
end of thread, other threads:[~2015-04-30 20:22 UTC | newest]
Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
[not found] <201504281230.EVsrh0Ze%fengguang.wu@intel.com>
2015-04-28 4:20 ` [PATCH] ASoC: fix simple_return.cocci warnings kbuild test robot
2015-04-30 20:22 ` Mark Brown
2015-04-28 4:20 ` kbuild test robot
2015-04-30 20:21 ` Mark Brown
2015-04-30 20:21 ` Mark Brown
This is a public inbox, see mirroring instructions for how to clone and mirror all data and code used for this inbox