Lines Matching refs:dac
83 struct hal2_codec dac; member
303 if (hal2->dac.pbus.pbus->pbdma_ctrl & HPC3_PDMACTRL_INT) { in hal2_interrupt()
304 snd_pcm_period_elapsed(hal2->dac.substream); in hal2_interrupt()
335 unsigned int master = hal2->dac.master; in hal2_set_dac_rate()
336 int inc = hal2->dac.inc; in hal2_set_dac_rate()
337 int mod = hal2->dac.mod; in hal2_set_dac_rate()
358 struct hal2_pbus *pbus = &hal2->dac.pbus; in hal2_setup_dac()
365 sample_size = 2 * hal2->dac.voices; in hal2_setup_dac()
385 | (hal2->dac.voices << H2I_C1_DATAT_SHIFT)); in hal2_setup_dac()
415 struct hal2_pbus *pbus = &hal2->dac.pbus; in hal2_start_dac()
417 pbus->pbus->pbdma_dptr = hal2->dac.desc_dma; in hal2_start_dac()
435 hal2->dac.pbus.pbus->pbdma_ctrl = HPC3_PDMACTRL_LD; in hal2_stop_dac()
517 return hal2_alloc_dmabuf(hal2, &hal2->dac, DMA_TO_DEVICE); in hal2_playback_open()
524 hal2_free_dmabuf(hal2, &hal2->dac, DMA_TO_DEVICE); in hal2_playback_close()
532 struct hal2_codec *dac = &hal2->dac; in hal2_playback_prepare() local
534 dac->voices = runtime->channels; in hal2_playback_prepare()
535 dac->sample_rate = hal2_compute_rate(dac, runtime->rate); in hal2_playback_prepare()
536 memset(&dac->pcm_indirect, 0, sizeof(dac->pcm_indirect)); in hal2_playback_prepare()
537 dac->pcm_indirect.hw_buffer_size = H2_BUF_SIZE; in hal2_playback_prepare()
538 dac->pcm_indirect.hw_queue_size = H2_BUF_SIZE / 2; in hal2_playback_prepare()
539 dac->pcm_indirect.hw_io = dac->buffer_dma; in hal2_playback_prepare()
540 dac->pcm_indirect.sw_buffer_size = snd_pcm_lib_buffer_bytes(substream); in hal2_playback_prepare()
541 dac->substream = substream; in hal2_playback_prepare()
567 struct hal2_codec *dac = &hal2->dac; in hal2_playback_pointer() local
569 return snd_pcm_indirect_playback_pointer(substream, &dac->pcm_indirect, in hal2_playback_pointer()
570 dac->pbus.pbus->pbdma_bptr); in hal2_playback_pointer()
577 unsigned char *buf = hal2->dac.buffer + rec->hw_data; in hal2_playback_transfer()
581 hal2->dac.buffer_dma + rec->hw_data, bytes, in hal2_playback_transfer()
589 struct hal2_codec *dac = &hal2->dac; in hal2_playback_ack() local
592 &dac->pcm_indirect, in hal2_playback_ack()
799 hal2_init_codec(&hal2->dac, hpc3, 0); in hal2_create()
825 hpc3->pbus_dmacfg[hal2->dac.pbus.pbusnr][0] = 0x8208844; in hal2_create()