[PATCH 1/2] ASoC: AD1980/AD73311: make sure to set dev member

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



The codec driver should initialize snd_soc_codec's dev member to the
appropriate device when setting up the device, but these codecs weren't.

Signed-off-by: Mike Frysinger <vapier@xxxxxxxxxx>
---
 sound/soc/codecs/ad1980.c  |    1 +
 sound/soc/codecs/ad73311.c |    1 +
 2 files changed, 2 insertions(+), 0 deletions(-)

diff --git a/sound/soc/codecs/ad1980.c b/sound/soc/codecs/ad1980.c
index d7440a9..0477a91 100644
--- a/sound/soc/codecs/ad1980.c
+++ b/sound/soc/codecs/ad1980.c
@@ -203,6 +203,7 @@ static int ad1980_soc_probe(struct platform_device *pdev)
 	codec->reg_cache_size = sizeof(u16) * ARRAY_SIZE(ad1980_reg);
 	codec->reg_cache_step = 2;
 	codec->name = "AD1980";
+	codec->dev = &pdev->dev;
 	codec->owner = THIS_MODULE;
 	codec->dai = &ad1980_dai;
 	codec->num_dai = 1;
diff --git a/sound/soc/codecs/ad73311.c b/sound/soc/codecs/ad73311.c
index e61dac5..6e18149 100644
--- a/sound/soc/codecs/ad73311.c
+++ b/sound/soc/codecs/ad73311.c
@@ -50,6 +50,7 @@ static int ad73311_soc_probe(struct platform_device *pdev)
 		return -ENOMEM;
 	mutex_init(&codec->mutex);
 	codec->name = "AD73311";
+	codec->dev = &pdev->dev;
 	codec->owner = THIS_MODULE;
 	codec->dai = &ad73311_dai;
 	codec->num_dai = 1;
-- 
1.6.5.rc2

_______________________________________________
Alsa-devel mailing list
Alsa-devel@xxxxxxxxxxxxxxxx
http://mailman.alsa-project.org/mailman/listinfo/alsa-devel

[Index of Archives]     [ALSA User]     [Linux Audio Users]     [Kernel Archive]     [Asterisk PBX]     [Photo Sharing]     [Linux Sound]     [Video 4 Linux]     [Gimp]     [Yosemite News]

  Powered by Linux