mirror of
https://github.com/linux-msm/laptops-kernel.git
synced 2026-08-13 14:19:53 -07:00
ASoC: intel: convert not to use asoc_xxx()
ASoC is now unified asoc_xxx() into snd_soc_xxx(). This patch convert asoc_xxx() to snd_soc_xxx(). Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com> Link: https://lore.kernel.org/r/87zg19fo4o.wl-kuninori.morimoto.gx@renesas.com Signed-off-by: Mark Brown <broonie@kernel.org>
This commit is contained in:
@@ -273,7 +273,7 @@ static int sst_platform_init_stream(struct snd_pcm_substream *substream)
|
||||
{
|
||||
struct sst_runtime_stream *stream =
|
||||
substream->runtime->private_data;
|
||||
struct snd_soc_pcm_runtime *rtd = asoc_substream_to_rtd(substream);
|
||||
struct snd_soc_pcm_runtime *rtd = snd_soc_substream_to_rtd(substream);
|
||||
int ret_val;
|
||||
|
||||
dev_dbg(rtd->dev, "setting buffer ptr param\n");
|
||||
@@ -593,7 +593,7 @@ static int sst_soc_trigger(struct snd_soc_component *component,
|
||||
int ret_val = 0, str_id;
|
||||
struct sst_runtime_stream *stream;
|
||||
int status;
|
||||
struct snd_soc_pcm_runtime *rtd = asoc_substream_to_rtd(substream);
|
||||
struct snd_soc_pcm_runtime *rtd = snd_soc_substream_to_rtd(substream);
|
||||
|
||||
dev_dbg(rtd->dev, "%s called\n", __func__);
|
||||
if (substream->pcm->internal)
|
||||
@@ -641,7 +641,7 @@ static snd_pcm_uframes_t sst_soc_pointer(struct snd_soc_component *component,
|
||||
struct sst_runtime_stream *stream;
|
||||
int ret_val, status;
|
||||
struct pcm_stream_info *str_info;
|
||||
struct snd_soc_pcm_runtime *rtd = asoc_substream_to_rtd(substream);
|
||||
struct snd_soc_pcm_runtime *rtd = snd_soc_substream_to_rtd(substream);
|
||||
|
||||
stream = substream->runtime->private_data;
|
||||
status = sst_get_stream_status(stream);
|
||||
@@ -671,7 +671,7 @@ static snd_pcm_sframes_t sst_soc_delay(struct snd_soc_component *component,
|
||||
static int sst_soc_pcm_new(struct snd_soc_component *component,
|
||||
struct snd_soc_pcm_runtime *rtd)
|
||||
{
|
||||
struct snd_soc_dai *dai = asoc_rtd_to_cpu(rtd, 0);
|
||||
struct snd_soc_dai *dai = snd_soc_rtd_to_cpu(rtd, 0);
|
||||
struct snd_pcm *pcm = rtd->pcm;
|
||||
|
||||
if (dai->driver->playback.channels_min ||
|
||||
@@ -762,7 +762,7 @@ static int sst_soc_prepare(struct device *dev)
|
||||
|
||||
/* set the SSPs to idle */
|
||||
for_each_card_rtds(drv->soc_card, rtd) {
|
||||
struct snd_soc_dai *dai = asoc_rtd_to_cpu(rtd, 0);
|
||||
struct snd_soc_dai *dai = snd_soc_rtd_to_cpu(rtd, 0);
|
||||
|
||||
if (snd_soc_dai_active(dai)) {
|
||||
send_ssp_cmd(dai, dai->name, 0);
|
||||
@@ -783,7 +783,7 @@ static void sst_soc_complete(struct device *dev)
|
||||
|
||||
/* restart SSPs */
|
||||
for_each_card_rtds(drv->soc_card, rtd) {
|
||||
struct snd_soc_dai *dai = asoc_rtd_to_cpu(rtd, 0);
|
||||
struct snd_soc_dai *dai = snd_soc_rtd_to_cpu(rtd, 0);
|
||||
|
||||
if (snd_soc_dai_active(dai)) {
|
||||
sst_handle_vb_timer(dai, true);
|
||||
|
||||
@@ -103,8 +103,8 @@ static int broadwell_ssp0_fixup(struct snd_soc_pcm_runtime *rtd,
|
||||
static int bdw_rt5650_hw_params(struct snd_pcm_substream *substream,
|
||||
struct snd_pcm_hw_params *params)
|
||||
{
|
||||
struct snd_soc_pcm_runtime *rtd = asoc_substream_to_rtd(substream);
|
||||
struct snd_soc_dai *codec_dai = asoc_rtd_to_codec(rtd, 0);
|
||||
struct snd_soc_pcm_runtime *rtd = snd_soc_substream_to_rtd(substream);
|
||||
struct snd_soc_dai *codec_dai = snd_soc_rtd_to_codec(rtd, 0);
|
||||
int ret;
|
||||
|
||||
/* Workaround: set codec PLL to 19.2MHz that PLL source is
|
||||
@@ -167,7 +167,7 @@ static int bdw_rt5650_init(struct snd_soc_pcm_runtime *rtd)
|
||||
{
|
||||
struct bdw_rt5650_priv *bdw_rt5650 =
|
||||
snd_soc_card_get_drvdata(rtd->card);
|
||||
struct snd_soc_dai *codec_dai = asoc_rtd_to_codec(rtd, 0);
|
||||
struct snd_soc_dai *codec_dai = snd_soc_rtd_to_codec(rtd, 0);
|
||||
struct snd_soc_component *component = codec_dai->component;
|
||||
int ret;
|
||||
|
||||
|
||||
@@ -153,8 +153,8 @@ static int broadwell_ssp0_fixup(struct snd_soc_pcm_runtime *rtd,
|
||||
static int bdw_rt5677_hw_params(struct snd_pcm_substream *substream,
|
||||
struct snd_pcm_hw_params *params)
|
||||
{
|
||||
struct snd_soc_pcm_runtime *rtd = asoc_substream_to_rtd(substream);
|
||||
struct snd_soc_dai *codec_dai = asoc_rtd_to_codec(rtd, 0);
|
||||
struct snd_soc_pcm_runtime *rtd = snd_soc_substream_to_rtd(substream);
|
||||
struct snd_soc_dai *codec_dai = snd_soc_rtd_to_codec(rtd, 0);
|
||||
int ret;
|
||||
|
||||
ret = snd_soc_dai_set_sysclk(codec_dai, RT5677_SCLK_S_MCLK, 24576000,
|
||||
@@ -170,8 +170,8 @@ static int bdw_rt5677_hw_params(struct snd_pcm_substream *substream,
|
||||
static int bdw_rt5677_dsp_hw_params(struct snd_pcm_substream *substream,
|
||||
struct snd_pcm_hw_params *params)
|
||||
{
|
||||
struct snd_soc_pcm_runtime *rtd = asoc_substream_to_rtd(substream);
|
||||
struct snd_soc_dai *codec_dai = asoc_rtd_to_codec(rtd, 0);
|
||||
struct snd_soc_pcm_runtime *rtd = snd_soc_substream_to_rtd(substream);
|
||||
struct snd_soc_dai *codec_dai = snd_soc_rtd_to_codec(rtd, 0);
|
||||
int ret;
|
||||
|
||||
ret = snd_soc_dai_set_sysclk(codec_dai, RT5677_SCLK_S_PLL1, 24576000,
|
||||
@@ -227,7 +227,7 @@ static int bdw_rt5677_init(struct snd_soc_pcm_runtime *rtd)
|
||||
{
|
||||
struct bdw_rt5677_priv *bdw_rt5677 =
|
||||
snd_soc_card_get_drvdata(rtd->card);
|
||||
struct snd_soc_component *component = asoc_rtd_to_codec(rtd, 0)->component;
|
||||
struct snd_soc_component *component = snd_soc_rtd_to_codec(rtd, 0)->component;
|
||||
struct snd_soc_dapm_context *dapm = snd_soc_component_get_dapm(component);
|
||||
int ret;
|
||||
|
||||
|
||||
@@ -61,7 +61,7 @@ static const struct snd_soc_dapm_route card_routes[] = {
|
||||
|
||||
static int codec_link_init(struct snd_soc_pcm_runtime *rtd)
|
||||
{
|
||||
struct snd_soc_component *codec = asoc_rtd_to_codec(rtd, 0)->component;
|
||||
struct snd_soc_component *codec = snd_soc_rtd_to_codec(rtd, 0)->component;
|
||||
int ret;
|
||||
|
||||
ret = snd_soc_card_jack_new_pins(rtd->card, "Headset", SND_JACK_HEADSET | SND_JACK_BTN_0,
|
||||
@@ -75,7 +75,7 @@ static int codec_link_init(struct snd_soc_pcm_runtime *rtd)
|
||||
|
||||
static void codec_link_exit(struct snd_soc_pcm_runtime *rtd)
|
||||
{
|
||||
struct snd_soc_component *codec = asoc_rtd_to_codec(rtd, 0)->component;
|
||||
struct snd_soc_component *codec = snd_soc_rtd_to_codec(rtd, 0)->component;
|
||||
|
||||
snd_soc_component_set_jack(codec, NULL, NULL);
|
||||
}
|
||||
@@ -98,8 +98,8 @@ static int codec_link_hw_params_fixup(struct snd_soc_pcm_runtime *rtd,
|
||||
static int codec_link_hw_params(struct snd_pcm_substream *substream,
|
||||
struct snd_pcm_hw_params *params)
|
||||
{
|
||||
struct snd_soc_pcm_runtime *rtd = asoc_substream_to_rtd(substream);
|
||||
struct snd_soc_dai *codec_dai = asoc_rtd_to_codec(rtd, 0);
|
||||
struct snd_soc_pcm_runtime *rtd = snd_soc_substream_to_rtd(substream);
|
||||
struct snd_soc_dai *codec_dai = snd_soc_rtd_to_codec(rtd, 0);
|
||||
int ret;
|
||||
|
||||
ret = snd_soc_dai_set_sysclk(codec_dai, RT286_SCLK_S_PLL, 24000000, SND_SOC_CLOCK_IN);
|
||||
|
||||
@@ -226,8 +226,8 @@ static int broxton_ssp_fixup(struct snd_soc_pcm_runtime *rtd,
|
||||
static int broxton_da7219_codec_init(struct snd_soc_pcm_runtime *rtd)
|
||||
{
|
||||
int ret;
|
||||
struct snd_soc_dai *codec_dai = asoc_rtd_to_codec(rtd, 0);
|
||||
struct snd_soc_component *component = asoc_rtd_to_codec(rtd, 0)->component;
|
||||
struct snd_soc_dai *codec_dai = snd_soc_rtd_to_codec(rtd, 0);
|
||||
struct snd_soc_component *component = snd_soc_rtd_to_codec(rtd, 0)->component;
|
||||
int clk_freq;
|
||||
|
||||
/* Configure sysclk for codec */
|
||||
@@ -275,7 +275,7 @@ static int broxton_da7219_codec_init(struct snd_soc_pcm_runtime *rtd)
|
||||
static int broxton_hdmi_init(struct snd_soc_pcm_runtime *rtd)
|
||||
{
|
||||
struct bxt_card_private *ctx = snd_soc_card_get_drvdata(rtd->card);
|
||||
struct snd_soc_dai *dai = asoc_rtd_to_codec(rtd, 0);
|
||||
struct snd_soc_dai *dai = snd_soc_rtd_to_codec(rtd, 0);
|
||||
struct bxt_hdmi_pcm *pcm;
|
||||
|
||||
pcm = devm_kzalloc(rtd->card->dev, sizeof(*pcm), GFP_KERNEL);
|
||||
@@ -293,7 +293,7 @@ static int broxton_hdmi_init(struct snd_soc_pcm_runtime *rtd)
|
||||
static int broxton_da7219_fe_init(struct snd_soc_pcm_runtime *rtd)
|
||||
{
|
||||
struct snd_soc_dapm_context *dapm;
|
||||
struct snd_soc_component *component = asoc_rtd_to_cpu(rtd, 0)->component;
|
||||
struct snd_soc_component *component = snd_soc_rtd_to_cpu(rtd, 0)->component;
|
||||
|
||||
dapm = snd_soc_component_get_dapm(component);
|
||||
snd_soc_dapm_ignore_suspend(dapm, "Reference Capture");
|
||||
|
||||
@@ -155,7 +155,7 @@ static const struct snd_soc_dapm_route geminilake_rt298_map[] = {
|
||||
static int broxton_rt298_fe_init(struct snd_soc_pcm_runtime *rtd)
|
||||
{
|
||||
struct snd_soc_dapm_context *dapm;
|
||||
struct snd_soc_component *component = asoc_rtd_to_cpu(rtd, 0)->component;
|
||||
struct snd_soc_component *component = snd_soc_rtd_to_cpu(rtd, 0)->component;
|
||||
|
||||
dapm = snd_soc_component_get_dapm(component);
|
||||
snd_soc_dapm_ignore_suspend(dapm, "Reference Capture");
|
||||
@@ -165,7 +165,7 @@ static int broxton_rt298_fe_init(struct snd_soc_pcm_runtime *rtd)
|
||||
|
||||
static int broxton_rt298_codec_init(struct snd_soc_pcm_runtime *rtd)
|
||||
{
|
||||
struct snd_soc_component *component = asoc_rtd_to_codec(rtd, 0)->component;
|
||||
struct snd_soc_component *component = snd_soc_rtd_to_codec(rtd, 0)->component;
|
||||
int ret = 0;
|
||||
|
||||
ret = snd_soc_card_jack_new_pins(rtd->card, "Headset",
|
||||
@@ -186,7 +186,7 @@ static int broxton_rt298_codec_init(struct snd_soc_pcm_runtime *rtd)
|
||||
static int broxton_hdmi_init(struct snd_soc_pcm_runtime *rtd)
|
||||
{
|
||||
struct bxt_rt286_private *ctx = snd_soc_card_get_drvdata(rtd->card);
|
||||
struct snd_soc_dai *dai = asoc_rtd_to_codec(rtd, 0);
|
||||
struct snd_soc_dai *dai = snd_soc_rtd_to_codec(rtd, 0);
|
||||
struct bxt_hdmi_pcm *pcm;
|
||||
|
||||
pcm = devm_kzalloc(rtd->card->dev, sizeof(*pcm), GFP_KERNEL);
|
||||
@@ -224,8 +224,8 @@ static int broxton_ssp5_fixup(struct snd_soc_pcm_runtime *rtd,
|
||||
static int broxton_rt298_hw_params(struct snd_pcm_substream *substream,
|
||||
struct snd_pcm_hw_params *params)
|
||||
{
|
||||
struct snd_soc_pcm_runtime *rtd = asoc_substream_to_rtd(substream);
|
||||
struct snd_soc_dai *codec_dai = asoc_rtd_to_codec(rtd, 0);
|
||||
struct snd_soc_pcm_runtime *rtd = snd_soc_substream_to_rtd(substream);
|
||||
struct snd_soc_dai *codec_dai = snd_soc_rtd_to_codec(rtd, 0);
|
||||
int ret;
|
||||
|
||||
ret = snd_soc_dai_set_sysclk(codec_dai, RT298_SCLK_S_PLL,
|
||||
|
||||
@@ -70,7 +70,7 @@ static const struct acpi_gpio_mapping byt_cht_cx2072x_acpi_gpios[] = {
|
||||
static int byt_cht_cx2072x_init(struct snd_soc_pcm_runtime *rtd)
|
||||
{
|
||||
struct snd_soc_card *card = rtd->card;
|
||||
struct snd_soc_component *codec = asoc_rtd_to_codec(rtd, 0)->component;
|
||||
struct snd_soc_component *codec = snd_soc_rtd_to_codec(rtd, 0)->component;
|
||||
int ret;
|
||||
|
||||
if (devm_acpi_dev_add_driver_gpios(codec->dev,
|
||||
@@ -80,7 +80,7 @@ static int byt_cht_cx2072x_init(struct snd_soc_pcm_runtime *rtd)
|
||||
card->dapm.idle_bias_off = true;
|
||||
|
||||
/* set the default PLL rate, the clock is handled by the codec driver */
|
||||
ret = snd_soc_dai_set_sysclk(asoc_rtd_to_codec(rtd, 0), CX2072X_MCLK_EXTERNAL_PLL,
|
||||
ret = snd_soc_dai_set_sysclk(snd_soc_rtd_to_codec(rtd, 0), CX2072X_MCLK_EXTERNAL_PLL,
|
||||
19200000, SND_SOC_CLOCK_IN);
|
||||
if (ret) {
|
||||
dev_err(rtd->dev, "Could not set sysclk\n");
|
||||
@@ -97,7 +97,7 @@ static int byt_cht_cx2072x_init(struct snd_soc_pcm_runtime *rtd)
|
||||
|
||||
snd_soc_component_set_jack(codec, &byt_cht_cx2072x_headset, NULL);
|
||||
|
||||
snd_soc_dai_set_bclk_ratio(asoc_rtd_to_codec(rtd, 0), 50);
|
||||
snd_soc_dai_set_bclk_ratio(snd_soc_rtd_to_codec(rtd, 0), 50);
|
||||
|
||||
return 0;
|
||||
}
|
||||
@@ -123,7 +123,7 @@ static int byt_cht_cx2072x_fixup(struct snd_soc_pcm_runtime *rtd,
|
||||
* with explicit setting to I2S 2ch 24-bit. The word length is set with
|
||||
* dai_set_tdm_slot() since there is no other API exposed
|
||||
*/
|
||||
ret = snd_soc_dai_set_fmt(asoc_rtd_to_cpu(rtd, 0),
|
||||
ret = snd_soc_dai_set_fmt(snd_soc_rtd_to_cpu(rtd, 0),
|
||||
SND_SOC_DAIFMT_I2S |
|
||||
SND_SOC_DAIFMT_NB_NF |
|
||||
SND_SOC_DAIFMT_BP_FP);
|
||||
@@ -132,7 +132,7 @@ static int byt_cht_cx2072x_fixup(struct snd_soc_pcm_runtime *rtd,
|
||||
return ret;
|
||||
}
|
||||
|
||||
ret = snd_soc_dai_set_tdm_slot(asoc_rtd_to_cpu(rtd, 0), 0x3, 0x3, 2, 24);
|
||||
ret = snd_soc_dai_set_tdm_slot(snd_soc_rtd_to_cpu(rtd, 0), 0x3, 0x3, 2, 24);
|
||||
if (ret < 0) {
|
||||
dev_err(rtd->dev, "can't set I2S config, err %d\n", ret);
|
||||
return ret;
|
||||
|
||||
@@ -78,7 +78,7 @@ static int codec_fixup(struct snd_soc_pcm_runtime *rtd,
|
||||
* with explicit setting to I2S 2ch 24-bit. The word length is set with
|
||||
* dai_set_tdm_slot() since there is no other API exposed
|
||||
*/
|
||||
ret = snd_soc_dai_set_fmt(asoc_rtd_to_cpu(rtd, 0),
|
||||
ret = snd_soc_dai_set_fmt(snd_soc_rtd_to_cpu(rtd, 0),
|
||||
SND_SOC_DAIFMT_I2S |
|
||||
SND_SOC_DAIFMT_NB_NF |
|
||||
SND_SOC_DAIFMT_BP_FP);
|
||||
@@ -87,7 +87,7 @@ static int codec_fixup(struct snd_soc_pcm_runtime *rtd,
|
||||
return ret;
|
||||
}
|
||||
|
||||
ret = snd_soc_dai_set_tdm_slot(asoc_rtd_to_cpu(rtd, 0), 0x3, 0x3, 2, 24);
|
||||
ret = snd_soc_dai_set_tdm_slot(snd_soc_rtd_to_cpu(rtd, 0), 0x3, 0x3, 2, 24);
|
||||
if (ret < 0) {
|
||||
dev_err(rtd->dev, "can't set I2S config, err %d\n", ret);
|
||||
return ret;
|
||||
@@ -105,8 +105,8 @@ static int aif1_startup(struct snd_pcm_substream *substream)
|
||||
static int aif1_hw_params(struct snd_pcm_substream *substream,
|
||||
struct snd_pcm_hw_params *params)
|
||||
{
|
||||
struct snd_soc_pcm_runtime *rtd = asoc_substream_to_rtd(substream);
|
||||
struct snd_soc_dai *codec_dai = asoc_rtd_to_codec(rtd, 0);
|
||||
struct snd_soc_pcm_runtime *rtd = snd_soc_substream_to_rtd(substream);
|
||||
struct snd_soc_dai *codec_dai = snd_soc_rtd_to_codec(rtd, 0);
|
||||
int ret;
|
||||
|
||||
ret = snd_soc_dai_set_sysclk(codec_dai, DA7213_CLKSRC_MCLK,
|
||||
@@ -126,8 +126,8 @@ static int aif1_hw_params(struct snd_pcm_substream *substream,
|
||||
|
||||
static int aif1_hw_free(struct snd_pcm_substream *substream)
|
||||
{
|
||||
struct snd_soc_pcm_runtime *rtd = asoc_substream_to_rtd(substream);
|
||||
struct snd_soc_dai *codec_dai = asoc_rtd_to_codec(rtd, 0);
|
||||
struct snd_soc_pcm_runtime *rtd = snd_soc_substream_to_rtd(substream);
|
||||
struct snd_soc_dai *codec_dai = snd_soc_rtd_to_codec(rtd, 0);
|
||||
int ret;
|
||||
|
||||
ret = snd_soc_dai_set_pll(codec_dai, 0,
|
||||
|
||||
@@ -157,7 +157,7 @@ static struct snd_soc_jack_pin byt_cht_es8316_jack_pins[] = {
|
||||
|
||||
static int byt_cht_es8316_init(struct snd_soc_pcm_runtime *runtime)
|
||||
{
|
||||
struct snd_soc_component *codec = asoc_rtd_to_codec(runtime, 0)->component;
|
||||
struct snd_soc_component *codec = snd_soc_rtd_to_codec(runtime, 0)->component;
|
||||
struct snd_soc_card *card = runtime->card;
|
||||
struct byt_cht_es8316_private *priv = snd_soc_card_get_drvdata(card);
|
||||
const struct snd_soc_dapm_route *custom_map;
|
||||
@@ -212,7 +212,7 @@ static int byt_cht_es8316_init(struct snd_soc_pcm_runtime *runtime)
|
||||
if (ret)
|
||||
dev_err(card->dev, "unable to enable MCLK\n");
|
||||
|
||||
ret = snd_soc_dai_set_sysclk(asoc_rtd_to_codec(runtime, 0), 0, 19200000,
|
||||
ret = snd_soc_dai_set_sysclk(snd_soc_rtd_to_codec(runtime, 0), 0, 19200000,
|
||||
SND_SOC_CLOCK_IN);
|
||||
if (ret < 0) {
|
||||
dev_err(card->dev, "can't set codec clock %d\n", ret);
|
||||
@@ -262,7 +262,7 @@ static int byt_cht_es8316_codec_fixup(struct snd_soc_pcm_runtime *rtd,
|
||||
* with explicit setting to I2S 2ch 24-bit. The word length is set with
|
||||
* dai_set_tdm_slot() since there is no other API exposed
|
||||
*/
|
||||
ret = snd_soc_dai_set_fmt(asoc_rtd_to_cpu(rtd, 0),
|
||||
ret = snd_soc_dai_set_fmt(snd_soc_rtd_to_cpu(rtd, 0),
|
||||
SND_SOC_DAIFMT_I2S |
|
||||
SND_SOC_DAIFMT_NB_NF |
|
||||
SND_SOC_DAIFMT_BP_FP
|
||||
@@ -272,7 +272,7 @@ static int byt_cht_es8316_codec_fixup(struct snd_soc_pcm_runtime *rtd,
|
||||
return ret;
|
||||
}
|
||||
|
||||
ret = snd_soc_dai_set_tdm_slot(asoc_rtd_to_cpu(rtd, 0), 0x3, 0x3, 2, bits);
|
||||
ret = snd_soc_dai_set_tdm_slot(snd_soc_rtd_to_cpu(rtd, 0), 0x3, 0x3, 2, bits);
|
||||
if (ret < 0) {
|
||||
dev_err(rtd->dev, "can't set I2S config, err %d\n", ret);
|
||||
return ret;
|
||||
|
||||
@@ -58,7 +58,7 @@ static int codec_fixup(struct snd_soc_pcm_runtime *rtd,
|
||||
* with explicit setting to I2S 2ch 24-bit. The word length is set with
|
||||
* dai_set_tdm_slot() since there is no other API exposed
|
||||
*/
|
||||
ret = snd_soc_dai_set_fmt(asoc_rtd_to_cpu(rtd, 0),
|
||||
ret = snd_soc_dai_set_fmt(snd_soc_rtd_to_cpu(rtd, 0),
|
||||
SND_SOC_DAIFMT_I2S |
|
||||
SND_SOC_DAIFMT_NB_NF |
|
||||
SND_SOC_DAIFMT_BP_FP);
|
||||
@@ -68,7 +68,7 @@ static int codec_fixup(struct snd_soc_pcm_runtime *rtd,
|
||||
return ret;
|
||||
}
|
||||
|
||||
ret = snd_soc_dai_set_tdm_slot(asoc_rtd_to_cpu(rtd, 0), 0x3, 0x3, 2, 24);
|
||||
ret = snd_soc_dai_set_tdm_slot(snd_soc_rtd_to_cpu(rtd, 0), 0x3, 0x3, 2, 24);
|
||||
if (ret < 0) {
|
||||
dev_err(rtd->dev, "can't set I2S config, err %d\n", ret);
|
||||
return ret;
|
||||
|
||||
@@ -525,8 +525,8 @@ static int byt_rt5640_hp_elitepad_1000g2_jack2_check(void *data)
|
||||
static int byt_rt5640_aif1_hw_params(struct snd_pcm_substream *substream,
|
||||
struct snd_pcm_hw_params *params)
|
||||
{
|
||||
struct snd_soc_pcm_runtime *rtd = asoc_substream_to_rtd(substream);
|
||||
struct snd_soc_dai *dai = asoc_rtd_to_codec(rtd, 0);
|
||||
struct snd_soc_pcm_runtime *rtd = snd_soc_substream_to_rtd(substream);
|
||||
struct snd_soc_dai *dai = snd_soc_rtd_to_codec(rtd, 0);
|
||||
|
||||
return byt_rt5640_prepare_and_enable_pll1(dai, params_rate(params));
|
||||
}
|
||||
@@ -1229,7 +1229,7 @@ static int byt_rt5640_init(struct snd_soc_pcm_runtime *runtime)
|
||||
struct snd_soc_card *card = runtime->card;
|
||||
struct byt_rt5640_private *priv = snd_soc_card_get_drvdata(card);
|
||||
struct rt5640_set_jack_data *jack_data = &priv->jack_data;
|
||||
struct snd_soc_component *component = asoc_rtd_to_codec(runtime, 0)->component;
|
||||
struct snd_soc_component *component = snd_soc_rtd_to_codec(runtime, 0)->component;
|
||||
const struct snd_soc_dapm_route *custom_map = NULL;
|
||||
int num_routes = 0;
|
||||
int ret;
|
||||
@@ -1447,7 +1447,7 @@ static int byt_rt5640_codec_fixup(struct snd_soc_pcm_runtime *rtd,
|
||||
* with explicit setting to I2S 2ch. The word length is set with
|
||||
* dai_set_tdm_slot() since there is no other API exposed
|
||||
*/
|
||||
ret = snd_soc_dai_set_fmt(asoc_rtd_to_cpu(rtd, 0),
|
||||
ret = snd_soc_dai_set_fmt(snd_soc_rtd_to_cpu(rtd, 0),
|
||||
SND_SOC_DAIFMT_I2S |
|
||||
SND_SOC_DAIFMT_NB_NF |
|
||||
SND_SOC_DAIFMT_BP_FP);
|
||||
@@ -1456,7 +1456,7 @@ static int byt_rt5640_codec_fixup(struct snd_soc_pcm_runtime *rtd,
|
||||
return ret;
|
||||
}
|
||||
|
||||
ret = snd_soc_dai_set_tdm_slot(asoc_rtd_to_cpu(rtd, 0), 0x3, 0x3, 2, bits);
|
||||
ret = snd_soc_dai_set_tdm_slot(snd_soc_rtd_to_cpu(rtd, 0), 0x3, 0x3, 2, bits);
|
||||
if (ret < 0) {
|
||||
dev_err(rtd->dev, "can't set I2S config, err %d\n", ret);
|
||||
return ret;
|
||||
|
||||
@@ -344,8 +344,8 @@ static struct snd_soc_jack_pin bytcr_jack_pins[] = {
|
||||
static int byt_rt5651_aif1_hw_params(struct snd_pcm_substream *substream,
|
||||
struct snd_pcm_hw_params *params)
|
||||
{
|
||||
struct snd_soc_pcm_runtime *rtd = asoc_substream_to_rtd(substream);
|
||||
struct snd_soc_dai *codec_dai = asoc_rtd_to_codec(rtd, 0);
|
||||
struct snd_soc_pcm_runtime *rtd = snd_soc_substream_to_rtd(substream);
|
||||
struct snd_soc_dai *codec_dai = snd_soc_rtd_to_codec(rtd, 0);
|
||||
snd_pcm_format_t format = params_format(params);
|
||||
int rate = params_rate(params);
|
||||
int bclk_ratio;
|
||||
@@ -563,7 +563,7 @@ static int byt_rt5651_add_codec_device_props(struct device *i2c_dev,
|
||||
static int byt_rt5651_init(struct snd_soc_pcm_runtime *runtime)
|
||||
{
|
||||
struct snd_soc_card *card = runtime->card;
|
||||
struct snd_soc_component *codec = asoc_rtd_to_codec(runtime, 0)->component;
|
||||
struct snd_soc_component *codec = snd_soc_rtd_to_codec(runtime, 0)->component;
|
||||
struct byt_rt5651_private *priv = snd_soc_card_get_drvdata(card);
|
||||
const struct snd_soc_dapm_route *custom_map;
|
||||
int num_routes;
|
||||
@@ -703,7 +703,7 @@ static int byt_rt5651_codec_fixup(struct snd_soc_pcm_runtime *rtd,
|
||||
* with explicit setting to I2S 2ch. The word length is set with
|
||||
* dai_set_tdm_slot() since there is no other API exposed
|
||||
*/
|
||||
ret = snd_soc_dai_set_fmt(asoc_rtd_to_cpu(rtd, 0),
|
||||
ret = snd_soc_dai_set_fmt(snd_soc_rtd_to_cpu(rtd, 0),
|
||||
SND_SOC_DAIFMT_I2S |
|
||||
SND_SOC_DAIFMT_NB_NF |
|
||||
SND_SOC_DAIFMT_BP_FP
|
||||
@@ -714,7 +714,7 @@ static int byt_rt5651_codec_fixup(struct snd_soc_pcm_runtime *rtd,
|
||||
return ret;
|
||||
}
|
||||
|
||||
ret = snd_soc_dai_set_tdm_slot(asoc_rtd_to_cpu(rtd, 0), 0x3, 0x3, 2, bits);
|
||||
ret = snd_soc_dai_set_tdm_slot(snd_soc_rtd_to_cpu(rtd, 0), 0x3, 0x3, 2, bits);
|
||||
if (ret < 0) {
|
||||
dev_err(rtd->dev, "can't set I2S config, err %d\n", ret);
|
||||
return ret;
|
||||
|
||||
@@ -201,7 +201,7 @@ static int byt_wm5102_init(struct snd_soc_pcm_runtime *runtime)
|
||||
{
|
||||
struct snd_soc_card *card = runtime->card;
|
||||
struct byt_wm5102_private *priv = snd_soc_card_get_drvdata(card);
|
||||
struct snd_soc_component *component = asoc_rtd_to_codec(runtime, 0)->component;
|
||||
struct snd_soc_component *component = snd_soc_rtd_to_codec(runtime, 0)->component;
|
||||
int ret, jack_type;
|
||||
|
||||
card->dapm.idle_bias_off = true;
|
||||
@@ -269,7 +269,7 @@ static int byt_wm5102_codec_fixup(struct snd_soc_pcm_runtime *rtd,
|
||||
* with explicit setting to I2S 2ch 16-bit. The word length is set with
|
||||
* dai_set_tdm_slot() since there is no other API exposed
|
||||
*/
|
||||
ret = snd_soc_dai_set_fmt(asoc_rtd_to_cpu(rtd, 0),
|
||||
ret = snd_soc_dai_set_fmt(snd_soc_rtd_to_cpu(rtd, 0),
|
||||
SND_SOC_DAIFMT_I2S |
|
||||
SND_SOC_DAIFMT_NB_NF |
|
||||
SND_SOC_DAIFMT_BP_FP);
|
||||
@@ -278,7 +278,7 @@ static int byt_wm5102_codec_fixup(struct snd_soc_pcm_runtime *rtd,
|
||||
return ret;
|
||||
}
|
||||
|
||||
ret = snd_soc_dai_set_tdm_slot(asoc_rtd_to_cpu(rtd, 0), 0x3, 0x3, 2, 16);
|
||||
ret = snd_soc_dai_set_tdm_slot(snd_soc_rtd_to_cpu(rtd, 0), 0x3, 0x3, 2, 16);
|
||||
if (ret) {
|
||||
dev_err(rtd->dev, "Error setting I2S config: %d\n", ret);
|
||||
return ret;
|
||||
|
||||
@@ -112,8 +112,8 @@ static const struct snd_kcontrol_new cht_mc_controls[] = {
|
||||
static int cht_aif1_hw_params(struct snd_pcm_substream *substream,
|
||||
struct snd_pcm_hw_params *params)
|
||||
{
|
||||
struct snd_soc_pcm_runtime *rtd = asoc_substream_to_rtd(substream);
|
||||
struct snd_soc_dai *codec_dai = asoc_rtd_to_codec(rtd, 0);
|
||||
struct snd_soc_pcm_runtime *rtd = snd_soc_substream_to_rtd(substream);
|
||||
struct snd_soc_dai *codec_dai = snd_soc_rtd_to_codec(rtd, 0);
|
||||
int ret;
|
||||
|
||||
ret = snd_soc_dai_set_sysclk(codec_dai, M98090_REG_SYSTEM_CLOCK,
|
||||
@@ -258,7 +258,7 @@ static int cht_codec_fixup(struct snd_soc_pcm_runtime *rtd,
|
||||
int ret = 0;
|
||||
unsigned int fmt = 0;
|
||||
|
||||
ret = snd_soc_dai_set_tdm_slot(asoc_rtd_to_cpu(rtd, 0), 0x3, 0x3, 2, 16);
|
||||
ret = snd_soc_dai_set_tdm_slot(snd_soc_rtd_to_cpu(rtd, 0), 0x3, 0x3, 2, 16);
|
||||
if (ret < 0) {
|
||||
dev_err(rtd->dev, "can't set cpu_dai slot fmt: %d\n", ret);
|
||||
return ret;
|
||||
@@ -266,7 +266,7 @@ static int cht_codec_fixup(struct snd_soc_pcm_runtime *rtd,
|
||||
|
||||
fmt = SND_SOC_DAIFMT_I2S | SND_SOC_DAIFMT_NB_NF | SND_SOC_DAIFMT_BP_FP;
|
||||
|
||||
ret = snd_soc_dai_set_fmt(asoc_rtd_to_cpu(rtd, 0), fmt);
|
||||
ret = snd_soc_dai_set_fmt(snd_soc_rtd_to_cpu(rtd, 0), fmt);
|
||||
if (ret < 0) {
|
||||
dev_err(rtd->dev, "can't set cpu_dai set fmt: %d\n", ret);
|
||||
return ret;
|
||||
|
||||
@@ -72,8 +72,8 @@ static const struct snd_kcontrol_new cht_mc_controls[] = {
|
||||
static int cht_aif1_hw_params(struct snd_pcm_substream *substream,
|
||||
struct snd_pcm_hw_params *params)
|
||||
{
|
||||
struct snd_soc_pcm_runtime *rtd = asoc_substream_to_rtd(substream);
|
||||
struct snd_soc_dai *codec_dai = asoc_rtd_to_codec(rtd, 0);
|
||||
struct snd_soc_pcm_runtime *rtd = snd_soc_substream_to_rtd(substream);
|
||||
struct snd_soc_dai *codec_dai = snd_soc_rtd_to_codec(rtd, 0);
|
||||
int ret;
|
||||
|
||||
ret = snd_soc_dai_set_sysclk(codec_dai, NAU8824_CLK_FLL_FS, 0,
|
||||
@@ -96,7 +96,7 @@ static int cht_codec_init(struct snd_soc_pcm_runtime *runtime)
|
||||
{
|
||||
struct cht_mc_private *ctx = snd_soc_card_get_drvdata(runtime->card);
|
||||
struct snd_soc_jack *jack = &ctx->jack;
|
||||
struct snd_soc_dai *codec_dai = asoc_rtd_to_codec(runtime, 0);
|
||||
struct snd_soc_dai *codec_dai = snd_soc_rtd_to_codec(runtime, 0);
|
||||
struct snd_soc_component *component = codec_dai->component;
|
||||
int ret, jack_type;
|
||||
|
||||
@@ -145,7 +145,7 @@ static int cht_codec_fixup(struct snd_soc_pcm_runtime *rtd,
|
||||
params_set_format(params, SNDRV_PCM_FORMAT_S24_LE);
|
||||
|
||||
/* TDM 4 slots 24 bit, set Rx & Tx bitmask to 4 active slots */
|
||||
ret = snd_soc_dai_set_tdm_slot(asoc_rtd_to_codec(rtd, 0), 0xf, 0x1, 4, 24);
|
||||
ret = snd_soc_dai_set_tdm_slot(snd_soc_rtd_to_codec(rtd, 0), 0xf, 0x1, 4, 24);
|
||||
if (ret < 0) {
|
||||
dev_err(rtd->dev, "can't set codec TDM slot %d\n", ret);
|
||||
return ret;
|
||||
|
||||
@@ -207,8 +207,8 @@ static struct snd_soc_jack_pin cht_bsw_jack_pins[] = {
|
||||
static int cht_aif1_hw_params(struct snd_pcm_substream *substream,
|
||||
struct snd_pcm_hw_params *params)
|
||||
{
|
||||
struct snd_soc_pcm_runtime *rtd = asoc_substream_to_rtd(substream);
|
||||
struct snd_soc_dai *codec_dai = asoc_rtd_to_codec(rtd, 0);
|
||||
struct snd_soc_pcm_runtime *rtd = snd_soc_substream_to_rtd(substream);
|
||||
struct snd_soc_dai *codec_dai = snd_soc_rtd_to_codec(rtd, 0);
|
||||
int ret;
|
||||
|
||||
/* set codec PLL source to the 19.2MHz platform clock (MCLK) */
|
||||
@@ -252,7 +252,7 @@ static int cht_codec_init(struct snd_soc_pcm_runtime *runtime)
|
||||
{
|
||||
struct snd_soc_card *card = runtime->card;
|
||||
struct cht_mc_private *ctx = snd_soc_card_get_drvdata(runtime->card);
|
||||
struct snd_soc_component *component = asoc_rtd_to_codec(runtime, 0)->component;
|
||||
struct snd_soc_component *component = snd_soc_rtd_to_codec(runtime, 0)->component;
|
||||
int jack_type;
|
||||
int ret;
|
||||
|
||||
@@ -359,7 +359,7 @@ static int cht_codec_fixup(struct snd_soc_pcm_runtime *rtd,
|
||||
* with explicit setting to I2S 2ch 16-bit. The word length is set with
|
||||
* dai_set_tdm_slot() since there is no other API exposed
|
||||
*/
|
||||
ret = snd_soc_dai_set_fmt(asoc_rtd_to_cpu(rtd, 0),
|
||||
ret = snd_soc_dai_set_fmt(snd_soc_rtd_to_cpu(rtd, 0),
|
||||
SND_SOC_DAIFMT_I2S |
|
||||
SND_SOC_DAIFMT_NB_NF |
|
||||
SND_SOC_DAIFMT_BP_FP
|
||||
@@ -369,7 +369,7 @@ static int cht_codec_fixup(struct snd_soc_pcm_runtime *rtd,
|
||||
return ret;
|
||||
}
|
||||
|
||||
ret = snd_soc_dai_set_fmt(asoc_rtd_to_codec(rtd, 0),
|
||||
ret = snd_soc_dai_set_fmt(snd_soc_rtd_to_codec(rtd, 0),
|
||||
SND_SOC_DAIFMT_I2S |
|
||||
SND_SOC_DAIFMT_NB_NF |
|
||||
SND_SOC_DAIFMT_BC_FC
|
||||
@@ -379,7 +379,7 @@ static int cht_codec_fixup(struct snd_soc_pcm_runtime *rtd,
|
||||
return ret;
|
||||
}
|
||||
|
||||
ret = snd_soc_dai_set_tdm_slot(asoc_rtd_to_cpu(rtd, 0), 0x3, 0x3, 2, 16);
|
||||
ret = snd_soc_dai_set_tdm_slot(snd_soc_rtd_to_cpu(rtd, 0), 0x3, 0x3, 2, 16);
|
||||
if (ret < 0) {
|
||||
dev_err(rtd->dev, "can't set I2S config, err %d\n", ret);
|
||||
return ret;
|
||||
@@ -393,7 +393,7 @@ static int cht_codec_fixup(struct snd_soc_pcm_runtime *rtd,
|
||||
/*
|
||||
* Default mode for SSP configuration is TDM 4 slot
|
||||
*/
|
||||
ret = snd_soc_dai_set_fmt(asoc_rtd_to_codec(rtd, 0),
|
||||
ret = snd_soc_dai_set_fmt(snd_soc_rtd_to_codec(rtd, 0),
|
||||
SND_SOC_DAIFMT_DSP_B |
|
||||
SND_SOC_DAIFMT_IB_NF |
|
||||
SND_SOC_DAIFMT_BC_FC);
|
||||
@@ -403,7 +403,7 @@ static int cht_codec_fixup(struct snd_soc_pcm_runtime *rtd,
|
||||
}
|
||||
|
||||
/* TDM 4 slots 24 bit, set Rx & Tx bitmask to 4 active slots */
|
||||
ret = snd_soc_dai_set_tdm_slot(asoc_rtd_to_codec(rtd, 0), 0xF, 0xF, 4, 24);
|
||||
ret = snd_soc_dai_set_tdm_slot(snd_soc_rtd_to_codec(rtd, 0), 0xF, 0xF, 4, 24);
|
||||
if (ret < 0) {
|
||||
dev_err(rtd->dev, "can't set codec TDM slot %d\n", ret);
|
||||
return ret;
|
||||
|
||||
@@ -155,8 +155,8 @@ static const struct snd_kcontrol_new cht_mc_controls[] = {
|
||||
static int cht_aif1_hw_params(struct snd_pcm_substream *substream,
|
||||
struct snd_pcm_hw_params *params)
|
||||
{
|
||||
struct snd_soc_pcm_runtime *rtd = asoc_substream_to_rtd(substream);
|
||||
struct snd_soc_dai *codec_dai = asoc_rtd_to_codec(rtd, 0);
|
||||
struct snd_soc_pcm_runtime *rtd = snd_soc_substream_to_rtd(substream);
|
||||
struct snd_soc_dai *codec_dai = snd_soc_rtd_to_codec(rtd, 0);
|
||||
int ret;
|
||||
|
||||
/* set codec PLL source to the 19.2MHz platform clock (MCLK) */
|
||||
@@ -188,7 +188,7 @@ static const struct acpi_gpio_mapping cht_rt5672_gpios[] = {
|
||||
static int cht_codec_init(struct snd_soc_pcm_runtime *runtime)
|
||||
{
|
||||
int ret;
|
||||
struct snd_soc_dai *codec_dai = asoc_rtd_to_codec(runtime, 0);
|
||||
struct snd_soc_dai *codec_dai = snd_soc_rtd_to_codec(runtime, 0);
|
||||
struct snd_soc_component *component = codec_dai->component;
|
||||
struct cht_mc_private *ctx = snd_soc_card_get_drvdata(runtime->card);
|
||||
|
||||
@@ -297,7 +297,7 @@ static int cht_codec_fixup(struct snd_soc_pcm_runtime *rtd,
|
||||
* board. Since we only support 2 channels anyways, there is no need
|
||||
* for TDM on any cht-bsw-rt5672 designs. So we use I2S 2ch everywhere.
|
||||
*/
|
||||
ret = snd_soc_dai_set_fmt(asoc_rtd_to_cpu(rtd, 0),
|
||||
ret = snd_soc_dai_set_fmt(snd_soc_rtd_to_cpu(rtd, 0),
|
||||
SND_SOC_DAIFMT_I2S |
|
||||
SND_SOC_DAIFMT_NB_NF |
|
||||
SND_SOC_DAIFMT_BP_FP);
|
||||
@@ -306,7 +306,7 @@ static int cht_codec_fixup(struct snd_soc_pcm_runtime *rtd,
|
||||
return ret;
|
||||
}
|
||||
|
||||
ret = snd_soc_dai_set_tdm_slot(asoc_rtd_to_cpu(rtd, 0), 0x3, 0x3, 2, bits);
|
||||
ret = snd_soc_dai_set_tdm_slot(snd_soc_rtd_to_cpu(rtd, 0), 0x3, 0x3, 2, bits);
|
||||
if (ret < 0) {
|
||||
dev_err(rtd->dev, "can't set I2S config, err %d\n", ret);
|
||||
return ret;
|
||||
|
||||
@@ -135,7 +135,7 @@ static struct snd_soc_jack_pin jack_pins[] = {
|
||||
static int cml_rt5682_codec_init(struct snd_soc_pcm_runtime *rtd)
|
||||
{
|
||||
struct card_private *ctx = snd_soc_card_get_drvdata(rtd->card);
|
||||
struct snd_soc_component *component = asoc_rtd_to_codec(rtd, 0)->component;
|
||||
struct snd_soc_component *component = snd_soc_rtd_to_codec(rtd, 0)->component;
|
||||
struct snd_soc_jack *jack;
|
||||
int ret;
|
||||
|
||||
@@ -175,7 +175,7 @@ static int cml_rt5682_codec_init(struct snd_soc_pcm_runtime *rtd)
|
||||
|
||||
static void cml_rt5682_codec_exit(struct snd_soc_pcm_runtime *rtd)
|
||||
{
|
||||
struct snd_soc_component *component = asoc_rtd_to_codec(rtd, 0)->component;
|
||||
struct snd_soc_component *component = snd_soc_rtd_to_codec(rtd, 0)->component;
|
||||
|
||||
snd_soc_component_set_jack(component, NULL, NULL);
|
||||
}
|
||||
@@ -212,8 +212,8 @@ static int cml_rt1011_spk_init(struct snd_soc_pcm_runtime *rtd)
|
||||
static int cml_rt5682_hw_params(struct snd_pcm_substream *substream,
|
||||
struct snd_pcm_hw_params *params)
|
||||
{
|
||||
struct snd_soc_pcm_runtime *rtd = asoc_substream_to_rtd(substream);
|
||||
struct snd_soc_dai *codec_dai = asoc_rtd_to_codec(rtd, 0);
|
||||
struct snd_soc_pcm_runtime *rtd = snd_soc_substream_to_rtd(substream);
|
||||
struct snd_soc_dai *codec_dai = snd_soc_rtd_to_codec(rtd, 0);
|
||||
int clk_id, clk_freq, pll_out, ret;
|
||||
|
||||
clk_id = RT5682_PLL1_S_MCLK;
|
||||
@@ -245,7 +245,7 @@ static int cml_rt5682_hw_params(struct snd_pcm_substream *substream,
|
||||
static int cml_rt1011_hw_params(struct snd_pcm_substream *substream,
|
||||
struct snd_pcm_hw_params *params)
|
||||
{
|
||||
struct snd_soc_pcm_runtime *rtd = asoc_substream_to_rtd(substream);
|
||||
struct snd_soc_pcm_runtime *rtd = snd_soc_substream_to_rtd(substream);
|
||||
struct snd_soc_dai *codec_dai;
|
||||
struct snd_soc_card *card = rtd->card;
|
||||
int srate, i, ret = 0;
|
||||
@@ -369,7 +369,7 @@ static int sof_card_late_probe(struct snd_soc_card *card)
|
||||
static int hdmi_init(struct snd_soc_pcm_runtime *rtd)
|
||||
{
|
||||
struct card_private *ctx = snd_soc_card_get_drvdata(rtd->card);
|
||||
struct snd_soc_dai *dai = asoc_rtd_to_codec(rtd, 0);
|
||||
struct snd_soc_dai *dai = snd_soc_rtd_to_codec(rtd, 0);
|
||||
struct hdmi_pcm *pcm;
|
||||
|
||||
pcm = devm_kzalloc(rtd->card->dev, sizeof(*pcm), GFP_KERNEL);
|
||||
|
||||
@@ -74,7 +74,7 @@ struct sof_hdmi_pcm {
|
||||
static int hdmi_init(struct snd_soc_pcm_runtime *rtd)
|
||||
{
|
||||
struct sof_card_private *ctx = snd_soc_card_get_drvdata(rtd->card);
|
||||
struct snd_soc_dai *dai = asoc_rtd_to_codec(rtd, 0);
|
||||
struct snd_soc_dai *dai = snd_soc_rtd_to_codec(rtd, 0);
|
||||
struct sof_hdmi_pcm *pcm;
|
||||
|
||||
pcm = devm_kzalloc(rtd->card->dev, sizeof(*pcm), GFP_KERNEL);
|
||||
@@ -109,8 +109,8 @@ static int card_late_probe(struct snd_soc_card *card)
|
||||
static int rt5660_hw_params(struct snd_pcm_substream *substream,
|
||||
struct snd_pcm_hw_params *params)
|
||||
{
|
||||
struct snd_soc_pcm_runtime *rtd = asoc_substream_to_rtd(substream);
|
||||
struct snd_soc_dai *codec_dai = asoc_rtd_to_codec(rtd, 0);
|
||||
struct snd_soc_pcm_runtime *rtd = snd_soc_substream_to_rtd(substream);
|
||||
struct snd_soc_dai *codec_dai = snd_soc_rtd_to_codec(rtd, 0);
|
||||
int ret;
|
||||
|
||||
ret = snd_soc_dai_set_sysclk(codec_dai,
|
||||
@@ -267,7 +267,7 @@ static void hdmi_link_init(struct snd_soc_card *card,
|
||||
* hdmi codec is not supported
|
||||
*/
|
||||
for (i = HDMI_LINK_START; i <= HDMI_LINE_END; i++)
|
||||
card->dai_link[i].codecs[0] = asoc_dummy_dlc;
|
||||
card->dai_link[i].codecs[0] = snd_soc_dummy_dlc;
|
||||
}
|
||||
|
||||
static int snd_ehl_rt5660_probe(struct platform_device *pdev)
|
||||
|
||||
@@ -152,8 +152,8 @@ static int geminilake_ssp_fixup(struct snd_soc_pcm_runtime *rtd,
|
||||
static int geminilake_rt5682_codec_init(struct snd_soc_pcm_runtime *rtd)
|
||||
{
|
||||
struct glk_card_private *ctx = snd_soc_card_get_drvdata(rtd->card);
|
||||
struct snd_soc_component *component = asoc_rtd_to_codec(rtd, 0)->component;
|
||||
struct snd_soc_dai *codec_dai = asoc_rtd_to_codec(rtd, 0);
|
||||
struct snd_soc_component *component = snd_soc_rtd_to_codec(rtd, 0)->component;
|
||||
struct snd_soc_dai *codec_dai = snd_soc_rtd_to_codec(rtd, 0);
|
||||
struct snd_soc_jack *jack;
|
||||
int pll_id, pll_source, clk_id, ret;
|
||||
|
||||
@@ -215,8 +215,8 @@ static int geminilake_rt5682_codec_init(struct snd_soc_pcm_runtime *rtd)
|
||||
static int geminilake_rt5682_hw_params(struct snd_pcm_substream *substream,
|
||||
struct snd_pcm_hw_params *params)
|
||||
{
|
||||
struct snd_soc_pcm_runtime *rtd = asoc_substream_to_rtd(substream);
|
||||
struct snd_soc_dai *codec_dai = asoc_rtd_to_codec(rtd, 0);
|
||||
struct snd_soc_pcm_runtime *rtd = snd_soc_substream_to_rtd(substream);
|
||||
struct snd_soc_dai *codec_dai = snd_soc_rtd_to_codec(rtd, 0);
|
||||
int ret;
|
||||
|
||||
/* Set valid bitmask & configuration for I2S in 24 bit */
|
||||
@@ -236,7 +236,7 @@ static struct snd_soc_ops geminilake_rt5682_ops = {
|
||||
static int geminilake_hdmi_init(struct snd_soc_pcm_runtime *rtd)
|
||||
{
|
||||
struct glk_card_private *ctx = snd_soc_card_get_drvdata(rtd->card);
|
||||
struct snd_soc_dai *dai = asoc_rtd_to_codec(rtd, 0);
|
||||
struct snd_soc_dai *dai = snd_soc_rtd_to_codec(rtd, 0);
|
||||
struct glk_hdmi_pcm *pcm;
|
||||
|
||||
pcm = devm_kzalloc(rtd->card->dev, sizeof(*pcm), GFP_KERNEL);
|
||||
@@ -253,7 +253,7 @@ static int geminilake_hdmi_init(struct snd_soc_pcm_runtime *rtd)
|
||||
|
||||
static int geminilake_rt5682_fe_init(struct snd_soc_pcm_runtime *rtd)
|
||||
{
|
||||
struct snd_soc_component *component = asoc_rtd_to_cpu(rtd, 0)->component;
|
||||
struct snd_soc_component *component = snd_soc_rtd_to_cpu(rtd, 0)->component;
|
||||
struct snd_soc_dapm_context *dapm;
|
||||
int ret;
|
||||
|
||||
|
||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user