Lines Matching +full:designware +full:- +full:i2s

1 // SPDX-License-Identifier: GPL-2.0
3 * dw-hdmi-i2s-audio.c
9 #include <linux/dma-mapping.h>
15 #include <sound/hdmi-codec.h>
17 #include "dw-hdmi.h"
18 #include "dw-hdmi-audio.h"
20 #define DRIVER_NAME "dw-hdmi-i2s-audio"
25 struct dw_hdmi *hdmi = audio->hdmi; in hdmi_write()
27 audio->write(hdmi, val, offset); in hdmi_write()
32 struct dw_hdmi *hdmi = audio->hdmi; in hdmi_read()
34 return audio->read(hdmi, offset); in hdmi_read()
42 struct dw_hdmi *hdmi = audio->hdmi; in dw_hdmi_i2s_hw_params()
47 /* it cares I2S only */ in dw_hdmi_i2s_hw_params()
48 if (fmt->bit_clk_provider | fmt->frame_clk_provider) { in dw_hdmi_i2s_hw_params()
50 return -EINVAL; in dw_hdmi_i2s_hw_params()
60 /* Enable the required i2s lanes */ in dw_hdmi_i2s_hw_params()
61 switch (hparms->channels) { in dw_hdmi_i2s_hw_params()
70 /* Fall-thru */ in dw_hdmi_i2s_hw_params()
73 switch (hparms->sample_width) { in dw_hdmi_i2s_hw_params()
83 switch (fmt->fmt) { in dw_hdmi_i2s_hw_params()
101 return -EINVAL; in dw_hdmi_i2s_hw_params()
104 dw_hdmi_set_sample_rate(hdmi, hparms->sample_rate); in dw_hdmi_i2s_hw_params()
105 dw_hdmi_set_channel_status(hdmi, hparms->iec.status); in dw_hdmi_i2s_hw_params()
106 dw_hdmi_set_channel_count(hdmi, hparms->channels); in dw_hdmi_i2s_hw_params()
107 dw_hdmi_set_channel_allocation(hdmi, hparms->cea.channel_allocation); in dw_hdmi_i2s_hw_params()
119 struct dw_hdmi *hdmi = audio->hdmi; in dw_hdmi_i2s_audio_startup()
129 struct dw_hdmi *hdmi = audio->hdmi; in dw_hdmi_i2s_audio_shutdown()
140 eld = audio->get_eld(audio->hdmi); in dw_hdmi_i2s_get_eld()
167 return -EINVAL; in dw_hdmi_i2s_get_dai_id()
175 struct dw_hdmi *hdmi = audio->hdmi; in dw_hdmi_i2s_hook_plugged_cb()
191 struct dw_hdmi_i2s_audio_data *audio = pdev->dev.platform_data; in snd_dw_hdmi_probe()
198 pdata.i2s = 1; in snd_dw_hdmi_probe()
203 pdevinfo.parent = pdev->dev.parent; in snd_dw_hdmi_probe()
214 dev_set_drvdata(&pdev->dev, platform); in snd_dw_hdmi_probe()
221 struct platform_device *platform = dev_get_drvdata(&pdev->dev); in snd_dw_hdmi_remove()
236 MODULE_DESCRIPTION("Synopsis Designware HDMI I2S ALSA SoC interface");