diff options
author | Sachin Kamat <sachin.kamat@linaro.org> | 2013-09-17 09:53:59 +0530 |
---|---|---|
committer | Mark Brown <broonie@linaro.org> | 2013-09-19 14:57:37 +0100 |
commit | 67a48b8181b0c981c59acf06f056e00184d3debd (patch) | |
tree | a86e805cd9afd2dcb5b7d891412b30c680fb536f | |
parent | 33c89c30afd7b6a309638d8d9b88481118d0a3ec (diff) |
ASoC: omap-twl4030: Use devm_snd_soc_register_card
devm_snd_soc_register_card makes code simpler.
Signed-off-by: Sachin Kamat <sachin.kamat@linaro.org>
Signed-off-by: Mark Brown <broonie@linaro.org>
-rw-r--r-- | sound/soc/omap/omap-twl4030.c | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/sound/soc/omap/omap-twl4030.c b/sound/soc/omap/omap-twl4030.c index 2a9324f794d..6a8d6b5f160 100644 --- a/sound/soc/omap/omap-twl4030.c +++ b/sound/soc/omap/omap-twl4030.c @@ -338,9 +338,9 @@ static int omap_twl4030_probe(struct platform_device *pdev) } snd_soc_card_set_drvdata(card, priv); - ret = snd_soc_register_card(card); + ret = devm_snd_soc_register_card(&pdev->dev, card); if (ret) { - dev_err(&pdev->dev, "snd_soc_register_card() failed: %d\n", + dev_err(&pdev->dev, "devm_snd_soc_register_card() failed: %d\n", ret); return ret; } @@ -357,7 +357,6 @@ static int omap_twl4030_remove(struct platform_device *pdev) snd_soc_jack_free_gpios(&priv->hs_jack, ARRAY_SIZE(hs_jack_gpios), hs_jack_gpios); - snd_soc_unregister_card(card); return 0; } |