Lines Matching refs:emu
40 struct snd_emu8000 *emu; member
68 emu8k_open_dram_for_pcm(struct snd_emu8000 *emu, int channels) in emu8k_open_dram_for_pcm() argument
73 snd_emux_lock_voice(emu->emu, 0); in emu8k_open_dram_for_pcm()
75 snd_emux_lock_voice(emu->emu, 1); in emu8k_open_dram_for_pcm()
80 snd_emux_lock_voice(emu->emu, i); in emu8k_open_dram_for_pcm()
85 snd_emu8000_dma_chan(emu, i, mode); in emu8k_open_dram_for_pcm()
89 EMU8000_VTFT_WRITE(emu, 30, 0); in emu8k_open_dram_for_pcm()
90 EMU8000_PSST_WRITE(emu, 30, 0x1d8); in emu8k_open_dram_for_pcm()
91 EMU8000_CSL_WRITE(emu, 30, 0x1e0); in emu8k_open_dram_for_pcm()
92 EMU8000_CCCA_WRITE(emu, 30, 0x1d8); in emu8k_open_dram_for_pcm()
93 EMU8000_VTFT_WRITE(emu, 31, 0); in emu8k_open_dram_for_pcm()
94 EMU8000_PSST_WRITE(emu, 31, 0x1d8); in emu8k_open_dram_for_pcm()
95 EMU8000_CSL_WRITE(emu, 31, 0x1e0); in emu8k_open_dram_for_pcm()
96 EMU8000_CCCA_WRITE(emu, 31, 0x1d8); in emu8k_open_dram_for_pcm()
104 snd_emu8000_write_wait(struct snd_emu8000 *emu, int can_schedule) in snd_emu8000_write_wait() argument
106 while ((EMU8000_SMALW_READ(emu) & 0x80000000) != 0) { in snd_emu8000_write_wait()
119 emu8k_close_dram(struct snd_emu8000 *emu) in emu8k_close_dram() argument
124 snd_emux_unlock_voice(emu->emu, i); in emu8k_close_dram()
126 snd_emu8000_dma_chan(emu, i, EMU8000_RAM_CLOSE); in emu8k_close_dram()
127 snd_emux_unlock_voice(emu->emu, i); in emu8k_close_dram()
173 int val = EMU8000_CCCA_READ(rec->emu, ch) & 0xfffffff; in emu8k_get_curpos()
218 struct snd_emu8000 *emu = snd_pcm_substream_chip(subs); in emu8k_pcm_open() local
226 rec->emu = emu; in emu8k_pcm_open()
234 runtime->hw.buffer_bytes_max = emu->mem_size - LOOP_BLANK_SIZE * 3; in emu8k_pcm_open()
271 struct snd_emu8000 *hw = rec->emu; in setup_voice()
325 struct snd_emu8000 *hw = rec->emu; in start_voice()
360 struct snd_emu8000 *hw = rec->emu; in stop_voice()
437 struct snd_emu8000 *emu = (rec)->emu; \
439 snd_emu8000_write_wait(emu, 1); \
440 EMU8000_SMALW_WRITE(emu, offset); \
445 EMU8000_SMLD_WRITE(emu, sval); \
494 struct snd_emu8000 *emu = rec->emu; \
496 snd_emu8000_write_wait(emu, 1); \
497 EMU8000_SMALW_WRITE(emu, pos + rec->loop_start[0]); \
499 EMU8000_SMARW_WRITE(emu, pos + rec->loop_start[1]); \
504 EMU8000_SMLD_WRITE(emu, sval); \
508 EMU8000_SMRD_WRITE(emu, sval); \
569 snd_util_mem_free(rec->emu->memhdr, rec->block); in emu8k_pcm_hw_params()
574 rec->block = snd_util_mem_alloc(rec->emu->memhdr, rec->allocated_bytes); in emu8k_pcm_hw_params()
596 emu8k_close_dram(rec->emu); in emu8k_pcm_hw_free()
597 snd_util_mem_free(rec->emu->memhdr, rec->block); in emu8k_pcm_hw_free()
628 snd_emux_terminate_all(rec->emu->emu); in emu8k_pcm_prepare()
629 err = emu8k_open_dram_for_pcm(rec->emu, rec->voices); in emu8k_pcm_prepare()
635 snd_emu8000_write_wait(rec->emu, 0); in emu8k_pcm_prepare()
636 EMU8000_SMALW_WRITE(rec->emu, rec->offset); in emu8k_pcm_prepare()
638 EMU8000_SMLD_WRITE(rec->emu, 0); in emu8k_pcm_prepare()
640 EMU8000_SMALW_WRITE(rec->emu, rec->loop_start[ch] + rec->buf_size); in emu8k_pcm_prepare()
642 EMU8000_SMLD_WRITE(rec->emu, 0); in emu8k_pcm_prepare()
677 struct snd_emu8000 *emu = pcm->private_data; in snd_emu8000_pcm_free() local
678 emu->pcm = NULL; in snd_emu8000_pcm_free()
681 int snd_emu8000_pcm_new(struct snd_card *card, struct snd_emu8000 *emu, int index) in snd_emu8000_pcm_new() argument
689 pcm->private_data = emu; in snd_emu8000_pcm_new()
692 emu->pcm = pcm; in snd_emu8000_pcm_new()