aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/video/omap2
diff options
context:
space:
mode:
authorRicardo Neri <ricardo.neri@ti.com>2011-11-22 21:09:41 -0500
committerTomi Valkeinen <tomi.valkeinen@ti.com>2012-01-05 03:34:47 -0500
commitb17ce117322a446f13716132e47b672d7bf25a30 (patch)
tree3d0a89f0bad270f99e9ed61a72a64f0fd8373033 /drivers/video/omap2
parent7282f1b7c9b5210114ce1ebb0ea5fe8a63fd5778 (diff)
ASoC: OMAP: HDMI: Introduce driver data for audio codec
Under the new DSS architecture for HDMI, there is a clear separation between general DSS code and HDMI IP-specific data. Functions that require access to the HDMI driver IP-specific data receive an hdmi_ip_data structure. The ASoC codec require access to such IP-specific data. Then, instead of accessing it directly, it will be passed as codec driver data. This also helps to have a clear separation between DSS and ASoC portions of the code. Signed-off-by: Ricardo Neri <ricardo.neri@ti.com> Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com>
Diffstat (limited to 'drivers/video/omap2')
-rw-r--r--drivers/video/omap2/dss/hdmi.c9
1 files changed, 9 insertions, 0 deletions
diff --git a/drivers/video/omap2/dss/hdmi.c b/drivers/video/omap2/dss/hdmi.c
index b064762b6994..3c96d771e2c9 100644
--- a/drivers/video/omap2/dss/hdmi.c
+++ b/drivers/video/omap2/dss/hdmi.c
@@ -705,7 +705,16 @@ static int hdmi_audio_startup(struct snd_pcm_substream *substream,
705 return 0; 705 return 0;
706} 706}
707 707
708static int hdmi_audio_codec_probe(struct snd_soc_codec *codec)
709{
710 struct hdmi_ip_data *priv = &hdmi.ip_data;
711
712 snd_soc_codec_set_drvdata(codec, priv);
713 return 0;
714}
715
708static struct snd_soc_codec_driver hdmi_audio_codec_drv = { 716static struct snd_soc_codec_driver hdmi_audio_codec_drv = {
717 .probe = hdmi_audio_codec_probe,
709}; 718};
710 719
711static struct snd_soc_dai_ops hdmi_audio_codec_ops = { 720static struct snd_soc_dai_ops hdmi_audio_codec_ops = {