Lines Matching refs:apcm
220 struct azx_pcm *apcm = snd_pcm_substream_chip(substream); in azx_cc_read() local
221 struct azx *chip = apcm->chip; in azx_cc_read()
263 struct azx_pcm *apcm = snd_pcm_substream_chip(substream); in to_hda_pcm_stream() local
264 return &apcm->info->stream[substream->stream]; in to_hda_pcm_stream()
270 struct azx_pcm *apcm = snd_pcm_substream_chip(substream); in azx_adjust_codec_delay() local
277 codec_frames = hinfo->ops.get_delay(hinfo, apcm->codec, substream); in azx_adjust_codec_delay()
406 struct azx_pcm *apcm = snd_pcm_substream_chip(substream); in azx_pcm_close() local
408 struct azx *chip = apcm->chip; in azx_pcm_close()
419 hinfo->ops.close(hinfo, apcm->codec, substream); in azx_pcm_close()
420 snd_hda_power_down(apcm->codec); in azx_pcm_close()
422 snd_hda_codec_pcm_put(apcm->info); in azx_pcm_close()
429 struct azx_pcm *apcm = snd_pcm_substream_chip(substream); in azx_pcm_hw_params() local
430 struct azx *chip = apcm->chip; in azx_pcm_hw_params()
448 struct azx_pcm *apcm = snd_pcm_substream_chip(substream); in azx_pcm_hw_free() local
450 struct azx *chip = apcm->chip; in azx_pcm_hw_free()
465 snd_hda_codec_cleanup(apcm->codec, hinfo, substream); in azx_pcm_hw_free()
475 struct azx_pcm *apcm = snd_pcm_substream_chip(substream); in azx_pcm_prepare() local
476 struct azx *chip = apcm->chip; in azx_pcm_prepare()
483 snd_hda_spdif_out_of_nid(apcm->codec, hinfo->nid); in azx_pcm_prepare()
493 format_val = snd_hda_calc_stream_format(apcm->codec, in azx_pcm_prepare()
550 err = snd_hda_codec_prepare(apcm->codec, hinfo, stream_tag, in azx_pcm_prepare()
562 struct azx_pcm *apcm = snd_pcm_substream_chip(substream); in azx_pcm_trigger() local
563 struct azx *chip = apcm->chip; in azx_pcm_trigger()
717 struct azx_pcm *apcm = snd_pcm_substream_chip(substream); in azx_get_position() local
723 delay += hinfo->ops.get_delay(hinfo, apcm->codec, in azx_get_position()
735 struct azx_pcm *apcm = snd_pcm_substream_chip(substream); in azx_pcm_pointer() local
736 struct azx *chip = apcm->chip; in azx_pcm_pointer()
800 struct azx_pcm *apcm = snd_pcm_substream_chip(substream); in azx_pcm_open() local
802 struct azx *chip = apcm->chip; in azx_pcm_open()
809 snd_hda_codec_pcm_get(apcm->info); in azx_pcm_open()
848 snd_hda_power_up(apcm->codec); in azx_pcm_open()
850 err = hinfo->ops.open(hinfo, apcm->codec, substream); in azx_pcm_open()
865 hinfo->ops.close(hinfo, apcm->codec, substream); in azx_pcm_open()
888 snd_hda_power_down(apcm->codec); in azx_pcm_open()
891 snd_hda_codec_pcm_put(apcm->info); in azx_pcm_open()
898 struct azx_pcm *apcm = snd_pcm_substream_chip(substream); in azx_pcm_mmap() local
899 struct azx *chip = apcm->chip; in azx_pcm_mmap()
921 struct azx_pcm *apcm = pcm->private_data; in azx_pcm_free() local
922 if (apcm) { in azx_pcm_free()
923 list_del(&apcm->list); in azx_pcm_free()
924 apcm->info->pcm = NULL; in azx_pcm_free()
925 kfree(apcm); in azx_pcm_free()
936 struct azx_pcm *apcm; in azx_attach_pcm_stream() local
941 list_for_each_entry(apcm, &chip->pcm_list, list) { in azx_attach_pcm_stream()
942 if (apcm->pcm->device == pcm_dev) { in azx_attach_pcm_stream()
955 apcm = kzalloc(sizeof(*apcm), GFP_KERNEL); in azx_attach_pcm_stream()
956 if (apcm == NULL) in azx_attach_pcm_stream()
958 apcm->chip = chip; in azx_attach_pcm_stream()
959 apcm->pcm = pcm; in azx_attach_pcm_stream()
960 apcm->codec = codec; in azx_attach_pcm_stream()
961 apcm->info = cpcm; in azx_attach_pcm_stream()
962 pcm->private_data = apcm; in azx_attach_pcm_stream()
966 list_add_tail(&apcm->list, &chip->pcm_list); in azx_attach_pcm_stream()