diff options
Diffstat (limited to 'sound/soc/tegra/tegra20_i2s.c')
-rw-r--r-- | sound/soc/tegra/tegra20_i2s.c | 15 |
1 files changed, 10 insertions, 5 deletions
diff --git a/sound/soc/tegra/tegra20_i2s.c b/sound/soc/tegra/tegra20_i2s.c index caa772de5a18..8b1ceb82c86f 100644 --- a/sound/soc/tegra/tegra20_i2s.c +++ b/sound/soc/tegra/tegra20_i2s.c | |||
@@ -276,6 +276,10 @@ static const struct snd_soc_dai_driver tegra20_i2s_dai_template = { | |||
276 | .symmetric_rates = 1, | 276 | .symmetric_rates = 1, |
277 | }; | 277 | }; |
278 | 278 | ||
279 | static const struct snd_soc_component_driver tegra20_i2s_component = { | ||
280 | .name = DRV_NAME, | ||
281 | }; | ||
282 | |||
279 | static bool tegra20_i2s_wr_rd_reg(struct device *dev, unsigned int reg) | 283 | static bool tegra20_i2s_wr_rd_reg(struct device *dev, unsigned int reg) |
280 | { | 284 | { |
281 | switch (reg) { | 285 | switch (reg) { |
@@ -419,7 +423,8 @@ static int tegra20_i2s_platform_probe(struct platform_device *pdev) | |||
419 | goto err_pm_disable; | 423 | goto err_pm_disable; |
420 | } | 424 | } |
421 | 425 | ||
422 | ret = snd_soc_register_dai(&pdev->dev, &i2s->dai); | 426 | ret = snd_soc_register_component(&pdev->dev, &tegra20_i2s_component, |
427 | &i2s->dai, 1); | ||
423 | if (ret) { | 428 | if (ret) { |
424 | dev_err(&pdev->dev, "Could not register DAI: %d\n", ret); | 429 | dev_err(&pdev->dev, "Could not register DAI: %d\n", ret); |
425 | ret = -ENOMEM; | 430 | ret = -ENOMEM; |
@@ -429,13 +434,13 @@ static int tegra20_i2s_platform_probe(struct platform_device *pdev) | |||
429 | ret = tegra_pcm_platform_register(&pdev->dev); | 434 | ret = tegra_pcm_platform_register(&pdev->dev); |
430 | if (ret) { | 435 | if (ret) { |
431 | dev_err(&pdev->dev, "Could not register PCM: %d\n", ret); | 436 | dev_err(&pdev->dev, "Could not register PCM: %d\n", ret); |
432 | goto err_unregister_dai; | 437 | goto err_unregister_component; |
433 | } | 438 | } |
434 | 439 | ||
435 | return 0; | 440 | return 0; |
436 | 441 | ||
437 | err_unregister_dai: | 442 | err_unregister_component: |
438 | snd_soc_unregister_dai(&pdev->dev); | 443 | snd_soc_unregister_component(&pdev->dev); |
439 | err_suspend: | 444 | err_suspend: |
440 | if (!pm_runtime_status_suspended(&pdev->dev)) | 445 | if (!pm_runtime_status_suspended(&pdev->dev)) |
441 | tegra20_i2s_runtime_suspend(&pdev->dev); | 446 | tegra20_i2s_runtime_suspend(&pdev->dev); |
@@ -456,7 +461,7 @@ static int tegra20_i2s_platform_remove(struct platform_device *pdev) | |||
456 | tegra20_i2s_runtime_suspend(&pdev->dev); | 461 | tegra20_i2s_runtime_suspend(&pdev->dev); |
457 | 462 | ||
458 | tegra_pcm_platform_unregister(&pdev->dev); | 463 | tegra_pcm_platform_unregister(&pdev->dev); |
459 | snd_soc_unregister_dai(&pdev->dev); | 464 | snd_soc_unregister_component(&pdev->dev); |
460 | 465 | ||
461 | clk_put(i2s->clk_i2s); | 466 | clk_put(i2s->clk_i2s); |
462 | 467 | ||