Lines Matching refs:i2s_priv

123 	struct mtk_afe_i2s_priv *i2s_priv;  in mt8183_i2s_hd_get()  local
125 i2s_priv = get_i2s_priv_by_name(afe, kcontrol->id.name); in mt8183_i2s_hd_get()
127 if (!i2s_priv) { in mt8183_i2s_hd_get()
132 ucontrol->value.integer.value[0] = i2s_priv->low_jitter_en; in mt8183_i2s_hd_get()
142 struct mtk_afe_i2s_priv *i2s_priv; in mt8183_i2s_hd_set() local
151 i2s_priv = get_i2s_priv_by_name(afe, kcontrol->id.name); in mt8183_i2s_hd_set()
153 if (!i2s_priv) { in mt8183_i2s_hd_set()
158 change = i2s_priv->low_jitter_en != hd_en; in mt8183_i2s_hd_set()
159 i2s_priv->low_jitter_en = hd_en; in mt8183_i2s_hd_set()
303 struct mtk_afe_i2s_priv *i2s_priv; in mtk_mclk_en_event() local
305 i2s_priv = get_i2s_priv_by_name(afe, w->name); in mtk_mclk_en_event()
307 if (!i2s_priv) { in mtk_mclk_en_event()
314 mt8183_mck_enable(afe, i2s_priv->mclk_id, i2s_priv->mclk_rate); in mtk_mclk_en_event()
317 i2s_priv->mclk_rate = 0; in mtk_mclk_en_event()
318 mt8183_mck_disable(afe, i2s_priv->mclk_id); in mtk_mclk_en_event()
421 struct mtk_afe_i2s_priv *i2s_priv; in mtk_afe_i2s_share_connect() local
423 i2s_priv = get_i2s_priv_by_name(afe, sink->name); in mtk_afe_i2s_share_connect()
425 if (!i2s_priv) { in mtk_afe_i2s_share_connect()
430 if (i2s_priv->share_i2s_id < 0) in mtk_afe_i2s_share_connect()
433 return i2s_priv->share_i2s_id == get_i2s_id_by_name(afe, source->name); in mtk_afe_i2s_share_connect()
442 struct mtk_afe_i2s_priv *i2s_priv; in mtk_afe_i2s_hd_connect() local
444 i2s_priv = get_i2s_priv_by_name(afe, sink->name); in mtk_afe_i2s_hd_connect()
446 if (!i2s_priv) { in mtk_afe_i2s_hd_connect()
453 return i2s_priv->low_jitter_en; in mtk_afe_i2s_hd_connect()
456 if (i2s_priv->share_i2s_id < 0) in mtk_afe_i2s_hd_connect()
459 if (i2s_priv->share_i2s_id == get_i2s_id_by_name(afe, source->name)) in mtk_afe_i2s_hd_connect()
460 return i2s_priv->low_jitter_en; in mtk_afe_i2s_hd_connect()
471 struct mtk_afe_i2s_priv *i2s_priv; in mtk_afe_i2s_apll_connect() local
475 i2s_priv = get_i2s_priv_by_name(afe, w->name); in mtk_afe_i2s_apll_connect()
477 if (!i2s_priv) { in mtk_afe_i2s_apll_connect()
486 i2s_need_apll = mt8183_get_apll_by_rate(afe, i2s_priv->rate); in mtk_afe_i2s_apll_connect()
497 struct mtk_afe_i2s_priv *i2s_priv; in mtk_afe_i2s_mclk_connect() local
499 i2s_priv = get_i2s_priv_by_name(afe, sink->name); in mtk_afe_i2s_mclk_connect()
501 if (!i2s_priv) { in mtk_afe_i2s_mclk_connect()
508 return (i2s_priv->mclk_rate > 0) ? 1 : 0; in mtk_afe_i2s_mclk_connect()
511 if (i2s_priv->share_i2s_id < 0) in mtk_afe_i2s_mclk_connect()
514 if (i2s_priv->share_i2s_id == get_i2s_id_by_name(afe, source->name)) in mtk_afe_i2s_mclk_connect()
515 return (i2s_priv->mclk_rate > 0) ? 1 : 0; in mtk_afe_i2s_mclk_connect()
526 struct mtk_afe_i2s_priv *i2s_priv; in mtk_afe_mclk_apll_connect() local
529 i2s_priv = get_i2s_priv_by_name(afe, w->name); in mtk_afe_mclk_apll_connect()
531 if (!i2s_priv) { in mtk_afe_mclk_apll_connect()
539 return (i2s_priv->mclk_apll == cur_apll) ? 1 : 0; in mtk_afe_mclk_apll_connect()
701 struct mtk_afe_i2s_priv *i2s_priv = afe_priv->dai_priv[i2s_id]; in mtk_dai_i2s_config() local
710 if (i2s_priv) { in mtk_dai_i2s_config()
711 i2s_priv->rate = rate; in mtk_dai_i2s_config()
713 if (i2s_priv->use_eiaj) in mtk_dai_i2s_config()
766 if (i2s_priv && i2s_priv->share_i2s_id >= 0) in mtk_dai_i2s_config()
767 ret = mtk_dai_i2s_config(afe, params, i2s_priv->share_i2s_id); in mtk_dai_i2s_config()
786 struct mtk_afe_i2s_priv *i2s_priv = afe_priv->dai_priv[dai->id]; in mtk_dai_i2s_set_sysclk() local
790 if (!i2s_priv) { in mtk_dai_i2s_set_sysclk()
814 i2s_priv->mclk_rate = freq; in mtk_dai_i2s_set_sysclk()
815 i2s_priv->mclk_apll = apll; in mtk_dai_i2s_set_sysclk()
817 if (i2s_priv->share_i2s_id > 0) { in mtk_dai_i2s_set_sysclk()
820 share_i2s_priv = afe_priv->dai_priv[i2s_priv->share_i2s_id]; in mtk_dai_i2s_set_sysclk()
827 share_i2s_priv->mclk_rate = i2s_priv->mclk_rate; in mtk_dai_i2s_set_sysclk()
828 share_i2s_priv->mclk_apll = i2s_priv->mclk_apll; in mtk_dai_i2s_set_sysclk()
838 struct mtk_afe_i2s_priv *i2s_priv; in mtk_dai_i2s_set_fmt() local
852 i2s_priv = afe_priv->dai_priv[dai->id]; in mtk_dai_i2s_set_fmt()
856 i2s_priv->use_eiaj = 1; in mtk_dai_i2s_set_fmt()
859 i2s_priv->use_eiaj = 0; in mtk_dai_i2s_set_fmt()
1017 struct mtk_afe_i2s_priv *i2s_priv; in mt8183_dai_i2s_set_priv() local
1021 i2s_priv = devm_kzalloc(afe->dev, in mt8183_dai_i2s_set_priv()
1024 if (!i2s_priv) in mt8183_dai_i2s_set_priv()
1027 memcpy(i2s_priv, &mt8183_i2s_priv[i], in mt8183_dai_i2s_set_priv()
1030 afe_priv->dai_priv[mt8183_i2s_priv[i].id] = i2s_priv; in mt8183_dai_i2s_set_priv()