diff options
author | Mark Brown <broonie@opensource.wolfsonmicro.com> | 2008-11-18 17:11:38 -0500 |
---|---|---|
committer | Mark Brown <broonie@opensource.wolfsonmicro.com> | 2008-11-21 09:12:10 -0500 |
commit | dee89c4d94433520e4e3977ae203d4cfbfe385fb (patch) | |
tree | bdbe4c54cd9789b02a6d0bf5f75a47b8721e073e /sound/soc/codecs/cs4270.c | |
parent | a47cbe7263236691ee0bbc392f7fd4ec0da1159f (diff) |
ASoC: Merge snd_soc_ops into snd_soc_dai_ops
Liam Girdwood's ASoC v2 work avoids having two different ops structures
for DAIs by merging the members of struct snd_soc_ops into struct
snd_soc_dai_ops, allowing per DAI configuration for everything.
Backport this change.
This paves the way for future work allowing any combination of DAIs to
be connected rather than having fixed purpose CODEC and CPU DAIs and
only allowing CODEC<->CPU interconnections.
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Diffstat (limited to 'sound/soc/codecs/cs4270.c')
-rw-r--r-- | sound/soc/codecs/cs4270.c | 11 |
1 files changed, 6 insertions, 5 deletions
diff --git a/sound/soc/codecs/cs4270.c b/sound/soc/codecs/cs4270.c index 0ff476d7057c..7507d468b200 100644 --- a/sound/soc/codecs/cs4270.c +++ b/sound/soc/codecs/cs4270.c | |||
@@ -360,13 +360,14 @@ static int cs4270_i2c_write(struct snd_soc_codec *codec, unsigned int reg, | |||
360 | /* | 360 | /* |
361 | * Program the CS4270 with the given hardware parameters. | 361 | * Program the CS4270 with the given hardware parameters. |
362 | * | 362 | * |
363 | * The .dai_ops functions are used to provide board-specific data, like | 363 | * The .ops functions are used to provide board-specific data, like |
364 | * input frequencies, to this driver. This function takes that information, | 364 | * input frequencies, to this driver. This function takes that information, |
365 | * combines it with the hardware parameters provided, and programs the | 365 | * combines it with the hardware parameters provided, and programs the |
366 | * hardware accordingly. | 366 | * hardware accordingly. |
367 | */ | 367 | */ |
368 | static int cs4270_hw_params(struct snd_pcm_substream *substream, | 368 | static int cs4270_hw_params(struct snd_pcm_substream *substream, |
369 | struct snd_pcm_hw_params *params) | 369 | struct snd_pcm_hw_params *params, |
370 | struct snd_soc_dai *dai) | ||
370 | { | 371 | { |
371 | struct snd_soc_pcm_runtime *rtd = substream->private_data; | 372 | struct snd_soc_pcm_runtime *rtd = substream->private_data; |
372 | struct snd_soc_device *socdev = rtd->socdev; | 373 | struct snd_soc_device *socdev = rtd->socdev; |
@@ -710,10 +711,10 @@ static int cs4270_probe(struct platform_device *pdev) | |||
710 | if (codec->control_data) { | 711 | if (codec->control_data) { |
711 | /* Initialize codec ops */ | 712 | /* Initialize codec ops */ |
712 | cs4270_dai.ops.hw_params = cs4270_hw_params; | 713 | cs4270_dai.ops.hw_params = cs4270_hw_params; |
713 | cs4270_dai.dai_ops.set_sysclk = cs4270_set_dai_sysclk; | 714 | cs4270_dai.ops.set_sysclk = cs4270_set_dai_sysclk; |
714 | cs4270_dai.dai_ops.set_fmt = cs4270_set_dai_fmt; | 715 | cs4270_dai.ops.set_fmt = cs4270_set_dai_fmt; |
715 | #ifdef CONFIG_SND_SOC_CS4270_HWMUTE | 716 | #ifdef CONFIG_SND_SOC_CS4270_HWMUTE |
716 | cs4270_dai.dai_ops.digital_mute = cs4270_mute; | 717 | cs4270_dai.ops.digital_mute = cs4270_mute; |
717 | #endif | 718 | #endif |
718 | } else | 719 | } else |
719 | printk(KERN_INFO "cs4270: no I2C device found, " | 720 | printk(KERN_INFO "cs4270: no I2C device found, " |