Alsa-Devel Archive on lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] ALSA: hda/cs35l56: Do some clean up on probe error
@ 2023-07-27  7:16 Dan Carpenter
  2023-07-27  9:51 ` Richard Fitzgerald
  2023-07-27  9:54 ` Takashi Iwai
  0 siblings, 2 replies; 3+ messages in thread
From: Dan Carpenter @ 2023-07-27  7:16 UTC (permalink / raw)
  To: Simon Trimmer
  Cc: James Schulman, David Rhodes, Richard Fitzgerald, Jaroslav Kysela,
	Takashi Iwai, Mark Brown, alsa-devel, patches, kernel-janitors

Smatch complains that this return should be a goto:

    sound/pci/hda/cs35l56_hda.c:910 cs35l56_hda_common_probe()
    warn: missing unwind goto?

The goto error disables cansleep so that seems reasonable.

Fixes: 73cfbfa9caea ("ALSA: hda/cs35l56: Add driver for Cirrus Logic CS35L56 amplifier")
Signed-off-by: Dan Carpenter <dan.carpenter@linaro.org>
---
 sound/pci/hda/cs35l56_hda.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/sound/pci/hda/cs35l56_hda.c b/sound/pci/hda/cs35l56_hda.c
index 71e95e64f8a4..4c3279f61b94 100644
--- a/sound/pci/hda/cs35l56_hda.c
+++ b/sound/pci/hda/cs35l56_hda.c
@@ -907,7 +907,7 @@ int cs35l56_hda_common_probe(struct cs35l56_hda *cs35l56, int id)
 
 	ret = cs35l56_set_patch(&cs35l56->base);
 	if (ret)
-		return ret;
+		goto err;
 
 	regcache_mark_dirty(cs35l56->base.regmap);
 	regcache_sync(cs35l56->base.regmap);
-- 
2.39.2


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

end of thread, other threads:[~2023-07-27  9:56 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2023-07-27  7:16 [PATCH] ALSA: hda/cs35l56: Do some clean up on probe error Dan Carpenter
2023-07-27  9:51 ` Richard Fitzgerald
2023-07-27  9:54 ` Takashi Iwai

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