All of lore.kernel.org
 help / color / mirror / Atom feed
From: Richard Fitzgerald <rf@opensource.cirrus.com>
To: <broonie@kernel.org>
Cc: <alsa-devel@alsa-project.org>, <linux-kernel@vger.kernel.org>,
	<patches@opensource.cirrus.com>,
	Simon Trimmer <simont@opensource.cirrus.com>,
	Richard Fitzgerald <rf@opensource.cirrus.com>
Subject: [PATCH 5/5] ASoC: cs35l56: Don't return a value from cs35l56_remove()
Date: Fri, 14 Apr 2023 14:37:53 +0100	[thread overview]
Message-ID: <20230414133753.653139-6-rf@opensource.cirrus.com> (raw)
In-Reply-To: <20230414133753.653139-1-rf@opensource.cirrus.com>

From: Simon Trimmer <simont@opensource.cirrus.com>

cs35l56_remove() always returns 0. Two of the functions that call
it are void and the other one should only return 0. So there's no
point returning anything from cs35l56_remove().

Signed-off-by: Simon Trimmer <simont@opensource.cirrus.com>
Signed-off-by: Richard Fitzgerald <rf@opensource.cirrus.com>
---
 sound/soc/codecs/cs35l56-sdw.c | 4 +++-
 sound/soc/codecs/cs35l56.c     | 4 +---
 sound/soc/codecs/cs35l56.h     | 2 +-
 3 files changed, 5 insertions(+), 5 deletions(-)

diff --git a/sound/soc/codecs/cs35l56-sdw.c b/sound/soc/codecs/cs35l56-sdw.c
index e759347423cf..2cde78605ba9 100644
--- a/sound/soc/codecs/cs35l56-sdw.c
+++ b/sound/soc/codecs/cs35l56-sdw.c
@@ -527,7 +527,9 @@ static int cs35l56_sdw_remove(struct sdw_slave *peripheral)
 	sdw_read_no_pm(peripheral, CS35L56_SDW_GEN_INT_STAT_1);
 	sdw_write_no_pm(peripheral, CS35L56_SDW_GEN_INT_STAT_1, 0xFF);
 
-	return cs35l56_remove(cs35l56);
+	cs35l56_remove(cs35l56);
+
+	return 0;
 }
 
 static const struct dev_pm_ops cs35l56_sdw_pm = {
diff --git a/sound/soc/codecs/cs35l56.c b/sound/soc/codecs/cs35l56.c
index 5f66a8e20b2d..0f4a94b02ef8 100644
--- a/sound/soc/codecs/cs35l56.c
+++ b/sound/soc/codecs/cs35l56.c
@@ -1590,7 +1590,7 @@ int cs35l56_init(struct cs35l56_private *cs35l56)
 }
 EXPORT_SYMBOL_NS_GPL(cs35l56_init, SND_SOC_CS35L56_CORE);
 
-int cs35l56_remove(struct cs35l56_private *cs35l56)
+void cs35l56_remove(struct cs35l56_private *cs35l56)
 {
 	cs35l56->init_done = false;
 
@@ -1613,8 +1613,6 @@ int cs35l56_remove(struct cs35l56_private *cs35l56)
 
 	gpiod_set_value_cansleep(cs35l56->reset_gpio, 0);
 	regulator_bulk_disable(ARRAY_SIZE(cs35l56->supplies), cs35l56->supplies);
-
-	return 0;
 }
 EXPORT_SYMBOL_NS_GPL(cs35l56_remove, SND_SOC_CS35L56_CORE);
 
diff --git a/sound/soc/codecs/cs35l56.h b/sound/soc/codecs/cs35l56.h
index 09762e70ce81..1f7894662fcb 100644
--- a/sound/soc/codecs/cs35l56.h
+++ b/sound/soc/codecs/cs35l56.h
@@ -76,6 +76,6 @@ irqreturn_t cs35l56_irq(int irq, void *data);
 int cs35l56_irq_request(struct cs35l56_private *cs35l56, int irq);
 int cs35l56_common_probe(struct cs35l56_private *cs35l56);
 int cs35l56_init(struct cs35l56_private *cs35l56);
-int cs35l56_remove(struct cs35l56_private *cs35l56);
+void cs35l56_remove(struct cs35l56_private *cs35l56);
 
 #endif /* ifndef CS35L56_H */
-- 
2.30.2


  parent reply	other threads:[~2023-04-14 13:38 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-04-14 13:37 [PATCH 0/5] ASoC: cs35l56: Code improvements Richard Fitzgerald
2023-04-14 13:37 ` [PATCH 1/5] ASoC: cs35l56: Rework IRQ allocation Richard Fitzgerald
2023-04-14 13:37 ` Richard Fitzgerald via Alsa-devel
2023-04-14 13:37 ` [PATCH 2/5] ASoC: cs35l56: Allow a wider range for reset pulse width Richard Fitzgerald
2023-04-14 13:37 ` Richard Fitzgerald via Alsa-devel
2023-04-14 13:37 ` [PATCH 3/5] ASoC: cs35l56: Wait for init_complete in cs35l56_component_probe() Richard Fitzgerald via Alsa-devel
2023-04-14 13:37 ` Richard Fitzgerald
2023-04-14 13:37 ` [PATCH 4/5] ASoC: cs35l56: Remove redundant dsp_ready_completion Richard Fitzgerald
2023-04-14 13:37 ` Richard Fitzgerald via Alsa-devel
2023-04-14 13:37 ` [PATCH 5/5] ASoC: cs35l56: Don't return a value from cs35l56_remove() Richard Fitzgerald via Alsa-devel
2023-04-14 13:37 ` Richard Fitzgerald [this message]
2023-04-17 20:27 ` [PATCH 0/5] ASoC: cs35l56: Code improvements Mark Brown

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20230414133753.653139-6-rf@opensource.cirrus.com \
    --to=rf@opensource.cirrus.com \
    --cc=alsa-devel@alsa-project.org \
    --cc=broonie@kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=patches@opensource.cirrus.com \
    --cc=simont@opensource.cirrus.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.