Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 293187
b: refs/heads/master
c: 7aca69f
h: refs/heads/master
i:
  293185: 1d0dc2f
  293183: 87c198d
v: v3
  • Loading branch information
Liam Girdwood authored and Mark Brown committed Jan 20, 2012
1 parent 75b94c6 commit b209ae6
Show file tree
Hide file tree
Showing 2 changed files with 20 additions and 2 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 08656910bb80882aaad739faea6dac3a0818f71c
refs/heads/master: 7aca69f9fe8f04ca37a01e2540960c53b24e3223
20 changes: 19 additions & 1 deletion trunk/sound/soc/soc-utils.c
Original file line number Diff line number Diff line change
Expand Up @@ -89,14 +89,32 @@ static struct snd_soc_platform_driver dummy_platform = {
.ops = &dummy_dma_ops,
};

static struct snd_soc_codec_driver dummy_codec;
static struct snd_soc_dai_driver dummy_dai = {
.name = "snd-soc-dummy-dai",
};

static __devinit int snd_soc_dummy_probe(struct platform_device *pdev)
{
return snd_soc_register_platform(&pdev->dev, &dummy_platform);
int ret;

ret = snd_soc_register_codec(&pdev->dev, &dummy_codec, &dummy_dai, 1);
if (ret < 0)
return ret;

ret = snd_soc_register_platform(&pdev->dev, &dummy_platform);
if (ret < 0) {
snd_soc_unregister_codec(&pdev->dev);
return ret;
}

return ret;
}

static __devexit int snd_soc_dummy_remove(struct platform_device *pdev)
{
snd_soc_unregister_platform(&pdev->dev);
snd_soc_unregister_codec(&pdev->dev);

return 0;
}
Expand Down

0 comments on commit b209ae6

Please sign in to comment.