diff mbox

[1/1] ASoC: da7210: Remove unnecessary regmap_exit call

Message ID 1354522423-28874-1-git-send-email-sachin.kamat@linaro.org
State Accepted
Headers show

Commit Message

Sachin Kamat Dec. 3, 2012, 8:13 a.m. UTC
Use of devm_regmap_init_spi does not require an explicit
regmap_exit call.

Signed-off-by: Sachin Kamat <sachin.kamat@linaro.org>
---
 sound/soc/codecs/da7210.c |   11 +----------
 1 files changed, 1 insertions(+), 10 deletions(-)

Comments

Mark Brown Dec. 3, 2012, 8:25 a.m. UTC | #1
On Mon, Dec 03, 2012 at 01:43:43PM +0530, Sachin Kamat wrote:
> Use of devm_regmap_init_spi does not require an explicit
> regmap_exit call.

Applied, thanks.
diff mbox

Patch

diff --git a/sound/soc/codecs/da7210.c b/sound/soc/codecs/da7210.c
index ab1ee5b..843c1eb 100644
--- a/sound/soc/codecs/da7210.c
+++ b/sound/soc/codecs/da7210.c
@@ -1337,24 +1337,15 @@  static int __devinit da7210_spi_probe(struct spi_device *spi)
 	if (ret != 0)
 		dev_warn(&spi->dev, "Failed to apply regmap patch: %d\n", ret);
 
-	ret =  snd_soc_register_codec(&spi->dev,
+	ret = snd_soc_register_codec(&spi->dev,
 			&soc_codec_dev_da7210, &da7210_dai, 1);
-	if (ret < 0)
-		goto err_regmap;
-
-	return ret;
-
-err_regmap:
-	regmap_exit(da7210->regmap);
 
 	return ret;
 }
 
 static int __devexit da7210_spi_remove(struct spi_device *spi)
 {
-	struct da7210_priv *da7210 = spi_get_drvdata(spi);
 	snd_soc_unregister_codec(&spi->dev);
-	regmap_exit(da7210->regmap);
 	return 0;
 }