Lines Matching refs:hinfo
276 struct hda_pcm_stream *hinfo) in hinfo_to_pcm_index() argument
282 if (get_pcm_rec(spec, pcm_idx)->stream == hinfo) in hinfo_to_pcm_index()
285 codec_warn(codec, "HDMI: hinfo %p not tied to a PCM\n", hinfo); in hinfo_to_pcm_index()
290 struct hda_pcm_stream *hinfo) in hinfo_to_pin_index() argument
299 per_pin->pcm->pcm->stream == hinfo) in hinfo_to_pin_index()
303 codec_dbg(codec, "HDMI: hinfo %p (pcm %d) not registered\n", hinfo, in hinfo_to_pin_index()
304 hinfo_to_pcm_index(codec, hinfo)); in hinfo_to_pin_index()
1191 static int hdmi_pcm_open_no_pin(struct hda_pcm_stream *hinfo, in hdmi_pcm_open_no_pin() argument
1201 pcm_idx = hinfo_to_pcm_index(codec, hinfo); in hdmi_pcm_open_no_pin()
1211 hinfo->nid = per_cvt->cvt_nid; in hdmi_pcm_open_no_pin()
1219 hinfo->channels_min = per_cvt->channels_min; in hdmi_pcm_open_no_pin()
1220 hinfo->channels_max = per_cvt->channels_max; in hdmi_pcm_open_no_pin()
1221 hinfo->rates = per_cvt->rates; in hdmi_pcm_open_no_pin()
1222 hinfo->formats = per_cvt->formats; in hdmi_pcm_open_no_pin()
1223 hinfo->maxbps = per_cvt->maxbps; in hdmi_pcm_open_no_pin()
1226 runtime->hw.channels_min = hinfo->channels_min; in hdmi_pcm_open_no_pin()
1227 runtime->hw.channels_max = hinfo->channels_max; in hdmi_pcm_open_no_pin()
1228 runtime->hw.formats = hinfo->formats; in hdmi_pcm_open_no_pin()
1229 runtime->hw.rates = hinfo->rates; in hdmi_pcm_open_no_pin()
1239 static int hdmi_pcm_open(struct hda_pcm_stream *hinfo, in hdmi_pcm_open() argument
1252 pcm_idx = hinfo_to_pcm_index(codec, hinfo); in hdmi_pcm_open()
1257 pin_idx = hinfo_to_pin_index(codec, hinfo); in hdmi_pcm_open()
1262 err = hdmi_pcm_open_no_pin(hinfo, codec, substream); in hdmi_pcm_open()
1277 hinfo->nid = per_cvt->cvt_nid; in hdmi_pcm_open()
1294 hinfo->channels_min = per_cvt->channels_min; in hdmi_pcm_open()
1295 hinfo->channels_max = per_cvt->channels_max; in hdmi_pcm_open()
1296 hinfo->rates = per_cvt->rates; in hdmi_pcm_open()
1297 hinfo->formats = per_cvt->formats; in hdmi_pcm_open()
1298 hinfo->maxbps = per_cvt->maxbps; in hdmi_pcm_open()
1303 snd_hdmi_eld_update_pcm_info(&eld->info, hinfo); in hdmi_pcm_open()
1304 if (hinfo->channels_min > hinfo->channels_max || in hdmi_pcm_open()
1305 !hinfo->rates || !hinfo->formats) { in hdmi_pcm_open()
1307 hinfo->nid = 0; in hdmi_pcm_open()
1315 runtime->hw.channels_min = hinfo->channels_min; in hdmi_pcm_open()
1316 runtime->hw.channels_max = hinfo->channels_max; in hdmi_pcm_open()
1317 runtime->hw.formats = hinfo->formats; in hdmi_pcm_open()
1318 runtime->hw.rates = hinfo->rates; in hdmi_pcm_open()
1424 struct hda_pcm_stream *hinfo; in hdmi_pcm_setup_pin() local
1438 hinfo = pcm->stream; in hdmi_pcm_setup_pin()
1441 per_pin->cvt_nid = hinfo->nid; in hdmi_pcm_setup_pin()
1443 mux_idx = hdmi_get_pin_cvt_mux(spec, per_pin, hinfo->nid); in hdmi_pcm_setup_pin()
1451 snd_hda_spdif_ctls_assign(codec, per_pin->pcm_idx, hinfo->nid); in hdmi_pcm_setup_pin()
1453 non_pcm = check_non_pcm_per_cvt(codec, hinfo->nid); in hdmi_pcm_setup_pin()
2069 static int generic_hdmi_playback_pcm_prepare(struct hda_pcm_stream *hinfo, in generic_hdmi_playback_pcm_prepare() argument
2075 hda_nid_t cvt_nid = hinfo->nid; in generic_hdmi_playback_pcm_prepare()
2085 pin_idx = hinfo_to_pin_index(codec, hinfo); in generic_hdmi_playback_pcm_prepare()
2151 static int generic_hdmi_playback_pcm_cleanup(struct hda_pcm_stream *hinfo, in generic_hdmi_playback_pcm_cleanup() argument
2155 snd_hda_codec_cleanup_stream(codec, hinfo->nid); in generic_hdmi_playback_pcm_cleanup()
2159 static int hdmi_pcm_close(struct hda_pcm_stream *hinfo, in hdmi_pcm_close() argument
2171 if (hinfo->nid) { in hdmi_pcm_close()
2172 pcm_idx = hinfo_to_pcm_index(codec, hinfo); in hdmi_pcm_close()
2177 cvt_idx = cvt_nid_to_cvt_index(codec, hinfo->nid); in hdmi_pcm_close()
2184 hinfo->nid = 0; in hdmi_pcm_close()
2190 pin_idx = hinfo_to_pin_index(codec, hinfo); in hdmi_pcm_close()
3366 static int simple_playback_pcm_open(struct hda_pcm_stream *hinfo, in simple_playback_pcm_open() argument
3399 static int simple_playback_pcm_close(struct hda_pcm_stream *hinfo, in simple_playback_pcm_close() argument
3407 static int simple_playback_pcm_prepare(struct hda_pcm_stream *hinfo, in simple_playback_pcm_prepare() argument
3505 static int nvhdmi_8ch_7x_pcm_close(struct hda_pcm_stream *hinfo, in nvhdmi_8ch_7x_pcm_close() argument
3530 static int nvhdmi_8ch_7x_pcm_prepare(struct hda_pcm_stream *hinfo, in nvhdmi_8ch_7x_pcm_prepare() argument
3942 static int tegra_hdmi_pcm_prepare(struct hda_pcm_stream *hinfo, in tegra_hdmi_pcm_prepare() argument
3950 err = generic_hdmi_playback_pcm_prepare(hinfo, codec, stream_tag, in tegra_hdmi_pcm_prepare()
3956 tegra_hdmi_set_format(codec, hinfo->nid, format); in tegra_hdmi_pcm_prepare()
3961 static int tegra_hdmi_pcm_cleanup(struct hda_pcm_stream *hinfo, in tegra_hdmi_pcm_cleanup() argument
3966 tegra_hdmi_set_format(codec, hinfo->nid, 0); in tegra_hdmi_pcm_cleanup()
3968 return generic_hdmi_playback_pcm_cleanup(hinfo, codec, substream); in tegra_hdmi_pcm_cleanup()