diff options
author | Takashi Iwai <tiwai@suse.de> | 2010-05-20 06:00:43 -0400 |
---|---|---|
committer | Takashi Iwai <tiwai@suse.de> | 2010-05-20 06:00:43 -0400 |
commit | d71f4cece4bd97d05592836202fc04ff2e7817e3 (patch) | |
tree | 6c877c7a938758b1323d9c97d46b9c536e618c69 /sound/soc/codecs/wm8400.c | |
parent | 19008bdacb9f7841166ebafe0aef361ee582ffbf (diff) | |
parent | ad8332c1302bcb4f80d593fd3eb477be9d7f5604 (diff) |
Merge branch 'topic/asoc' into for-linus
Conflicts:
sound/soc/codecs/ad1938.c
Diffstat (limited to 'sound/soc/codecs/wm8400.c')
-rw-r--r-- | sound/soc/codecs/wm8400.c | 16 |
1 files changed, 8 insertions, 8 deletions
diff --git a/sound/soc/codecs/wm8400.c b/sound/soc/codecs/wm8400.c index 6acc885cf9b7..7f5d080536a0 100644 --- a/sound/soc/codecs/wm8400.c +++ b/sound/soc/codecs/wm8400.c | |||
@@ -77,7 +77,7 @@ struct wm8400_priv { | |||
77 | static inline unsigned int wm8400_read(struct snd_soc_codec *codec, | 77 | static inline unsigned int wm8400_read(struct snd_soc_codec *codec, |
78 | unsigned int reg) | 78 | unsigned int reg) |
79 | { | 79 | { |
80 | struct wm8400_priv *wm8400 = codec->private_data; | 80 | struct wm8400_priv *wm8400 = snd_soc_codec_get_drvdata(codec); |
81 | 81 | ||
82 | if (reg == WM8400_INTDRIVBITS) | 82 | if (reg == WM8400_INTDRIVBITS) |
83 | return wm8400->fake_register; | 83 | return wm8400->fake_register; |
@@ -91,7 +91,7 @@ static inline unsigned int wm8400_read(struct snd_soc_codec *codec, | |||
91 | static int wm8400_write(struct snd_soc_codec *codec, unsigned int reg, | 91 | static int wm8400_write(struct snd_soc_codec *codec, unsigned int reg, |
92 | unsigned int value) | 92 | unsigned int value) |
93 | { | 93 | { |
94 | struct wm8400_priv *wm8400 = codec->private_data; | 94 | struct wm8400_priv *wm8400 = snd_soc_codec_get_drvdata(codec); |
95 | 95 | ||
96 | if (reg == WM8400_INTDRIVBITS) { | 96 | if (reg == WM8400_INTDRIVBITS) { |
97 | wm8400->fake_register = value; | 97 | wm8400->fake_register = value; |
@@ -102,7 +102,7 @@ static int wm8400_write(struct snd_soc_codec *codec, unsigned int reg, | |||
102 | 102 | ||
103 | static void wm8400_codec_reset(struct snd_soc_codec *codec) | 103 | static void wm8400_codec_reset(struct snd_soc_codec *codec) |
104 | { | 104 | { |
105 | struct wm8400_priv *wm8400 = codec->private_data; | 105 | struct wm8400_priv *wm8400 = snd_soc_codec_get_drvdata(codec); |
106 | 106 | ||
107 | wm8400_reset_codec_reg_cache(wm8400->wm8400); | 107 | wm8400_reset_codec_reg_cache(wm8400->wm8400); |
108 | } | 108 | } |
@@ -926,7 +926,7 @@ static int wm8400_set_dai_sysclk(struct snd_soc_dai *codec_dai, | |||
926 | int clk_id, unsigned int freq, int dir) | 926 | int clk_id, unsigned int freq, int dir) |
927 | { | 927 | { |
928 | struct snd_soc_codec *codec = codec_dai->codec; | 928 | struct snd_soc_codec *codec = codec_dai->codec; |
929 | struct wm8400_priv *wm8400 = codec->private_data; | 929 | struct wm8400_priv *wm8400 = snd_soc_codec_get_drvdata(codec); |
930 | 930 | ||
931 | wm8400->sysclk = freq; | 931 | wm8400->sysclk = freq; |
932 | return 0; | 932 | return 0; |
@@ -1015,7 +1015,7 @@ static int wm8400_set_dai_pll(struct snd_soc_dai *codec_dai, int pll_id, | |||
1015 | unsigned int freq_out) | 1015 | unsigned int freq_out) |
1016 | { | 1016 | { |
1017 | struct snd_soc_codec *codec = codec_dai->codec; | 1017 | struct snd_soc_codec *codec = codec_dai->codec; |
1018 | struct wm8400_priv *wm8400 = codec->private_data; | 1018 | struct wm8400_priv *wm8400 = snd_soc_codec_get_drvdata(codec); |
1019 | struct fll_factors factors; | 1019 | struct fll_factors factors; |
1020 | int ret; | 1020 | int ret; |
1021 | u16 reg; | 1021 | u16 reg; |
@@ -1204,7 +1204,7 @@ static int wm8400_mute(struct snd_soc_dai *dai, int mute) | |||
1204 | static int wm8400_set_bias_level(struct snd_soc_codec *codec, | 1204 | static int wm8400_set_bias_level(struct snd_soc_codec *codec, |
1205 | enum snd_soc_bias_level level) | 1205 | enum snd_soc_bias_level level) |
1206 | { | 1206 | { |
1207 | struct wm8400_priv *wm8400 = codec->private_data; | 1207 | struct wm8400_priv *wm8400 = snd_soc_codec_get_drvdata(codec); |
1208 | u16 val; | 1208 | u16 val; |
1209 | int ret; | 1209 | int ret; |
1210 | 1210 | ||
@@ -1467,7 +1467,7 @@ static int wm8400_codec_probe(struct platform_device *dev) | |||
1467 | return -ENOMEM; | 1467 | return -ENOMEM; |
1468 | 1468 | ||
1469 | codec = &priv->codec; | 1469 | codec = &priv->codec; |
1470 | codec->private_data = priv; | 1470 | snd_soc_codec_set_drvdata(codec, priv); |
1471 | codec->control_data = dev_get_drvdata(&dev->dev); | 1471 | codec->control_data = dev_get_drvdata(&dev->dev); |
1472 | priv->wm8400 = dev_get_drvdata(&dev->dev); | 1472 | priv->wm8400 = dev_get_drvdata(&dev->dev); |
1473 | 1473 | ||
@@ -1530,7 +1530,7 @@ err: | |||
1530 | 1530 | ||
1531 | static int __exit wm8400_codec_remove(struct platform_device *dev) | 1531 | static int __exit wm8400_codec_remove(struct platform_device *dev) |
1532 | { | 1532 | { |
1533 | struct wm8400_priv *priv = wm8400_codec->private_data; | 1533 | struct wm8400_priv *priv = snd_soc_codec_get_drvdata(wm8400_codec); |
1534 | u16 reg; | 1534 | u16 reg; |
1535 | 1535 | ||
1536 | snd_soc_unregister_dai(&wm8400_dai); | 1536 | snd_soc_unregister_dai(&wm8400_dai); |