public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
* [PATCH] ASoC: ak4458: Remove useless return variable
@ 2025-04-16  4:10 Chen Ni
  2025-04-16  6:49 ` Andy Shevchenko
  2025-04-16 18:54 ` Mark Brown
  0 siblings, 2 replies; 3+ messages in thread
From: Chen Ni @ 2025-04-16  4:10 UTC (permalink / raw)
  To: lgirdwood, broonie, perex, tiwai, ckeepax, andriy.shevchenko,
	heiko, shengjiu.wang
  Cc: linux-sound, linux-kernel, Chen Ni

Remove unnecessary return variable and compress the return logic.

Signed-off-by: Chen Ni <nichen@iscas.ac.cn>
---
 sound/soc/codecs/ak4458.c | 10 +++-------
 1 file changed, 3 insertions(+), 7 deletions(-)

diff --git a/sound/soc/codecs/ak4458.c b/sound/soc/codecs/ak4458.c
index 5f3a68dfe7bd..6f648186408c 100644
--- a/sound/soc/codecs/ak4458.c
+++ b/sound/soc/codecs/ak4458.c
@@ -586,13 +586,9 @@ static const struct snd_pcm_hw_constraint_list ak4458_rate_constraints = {
 static int ak4458_startup(struct snd_pcm_substream *substream,
 			  struct snd_soc_dai *dai)
 {
-	int ret;
-
-	ret = snd_pcm_hw_constraint_list(substream->runtime, 0,
-					 SNDRV_PCM_HW_PARAM_RATE,
-					 &ak4458_rate_constraints);
-
-	return ret;
+	return snd_pcm_hw_constraint_list(substream->runtime, 0,
+					  SNDRV_PCM_HW_PARAM_RATE,
+					  &ak4458_rate_constraints);
 }
 
 static const struct snd_soc_dai_ops ak4458_dai_ops = {
-- 
2.25.1


^ permalink raw reply related	[flat|nested] 3+ messages in thread

* Re: [PATCH] ASoC: ak4458: Remove useless return variable
  2025-04-16  4:10 [PATCH] ASoC: ak4458: Remove useless return variable Chen Ni
@ 2025-04-16  6:49 ` Andy Shevchenko
  2025-04-16 18:54 ` Mark Brown
  1 sibling, 0 replies; 3+ messages in thread
From: Andy Shevchenko @ 2025-04-16  6:49 UTC (permalink / raw)
  To: Chen Ni
  Cc: lgirdwood, broonie, perex, tiwai, ckeepax, heiko, shengjiu.wang,
	linux-sound, linux-kernel

On Wed, Apr 16, 2025 at 12:10:23PM +0800, Chen Ni wrote:
> Remove unnecessary return variable and compress the return logic.

Makes code cleaner and shorter, definitely a win.
Reviewed-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>

-- 
With Best Regards,
Andy Shevchenko



^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: [PATCH] ASoC: ak4458: Remove useless return variable
  2025-04-16  4:10 [PATCH] ASoC: ak4458: Remove useless return variable Chen Ni
  2025-04-16  6:49 ` Andy Shevchenko
@ 2025-04-16 18:54 ` Mark Brown
  1 sibling, 0 replies; 3+ messages in thread
From: Mark Brown @ 2025-04-16 18:54 UTC (permalink / raw)
  To: lgirdwood, perex, tiwai, ckeepax, andriy.shevchenko, heiko,
	shengjiu.wang, Chen Ni
  Cc: linux-sound, linux-kernel

On Wed, 16 Apr 2025 12:10:23 +0800, Chen Ni wrote:
> Remove unnecessary return variable and compress the return logic.
> 
> 

Applied to

   https://git.kernel.org/pub/scm/linux/kernel/git/broonie/sound.git for-next

Thanks!

[1/1] ASoC: ak4458: Remove useless return variable
      commit: 65bd426bace60540c5b6710890800abb1accc5ce

All being well this means that it will be integrated into the linux-next
tree (usually sometime in the next 24 hours) and sent to Linus during
the next merge window (or sooner if it is a bug fix), however if
problems are discovered then the patch may be dropped or reverted.

You may get further e-mails resulting from automated or manual testing
and review of the tree, please engage with people reporting problems and
send followup patches addressing any issues that are reported if needed.

If any updates are required or you are submitting further changes they
should be sent as incremental updates against current git, existing
patches will not be replaced.

Please add any relevant lists and maintainers to the CCs when replying
to this mail.

Thanks,
Mark


^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2025-04-16 18:54 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2025-04-16  4:10 [PATCH] ASoC: ak4458: Remove useless return variable Chen Ni
2025-04-16  6:49 ` Andy Shevchenko
2025-04-16 18:54 ` Mark Brown

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox