Home
last modified time | relevance | path

Searched refs:efw (Results 1 – 9 of 9) sorted by relevance

/Linux-v4.19/sound/firewire/fireworks/
Dfireworks_stream.c13 init_stream(struct snd_efw *efw, struct amdtp_stream *stream) in init_stream() argument
20 if (stream == &efw->tx_stream) { in init_stream()
21 conn = &efw->out_conn; in init_stream()
25 conn = &efw->in_conn; in init_stream()
30 err = cmp_connection_init(conn, efw->unit, c_dir, 0); in init_stream()
34 err = amdtp_am824_init(stream, efw->unit, s_dir, CIP_BLOCKING); in init_stream()
44 stop_stream(struct snd_efw *efw, struct amdtp_stream *stream) in stop_stream() argument
49 if (stream == &efw->tx_stream) in stop_stream()
50 cmp_connection_break(&efw->out_conn); in stop_stream()
52 cmp_connection_break(&efw->in_conn); in stop_stream()
[all …]
Dfireworks.c73 get_hardware_info(struct snd_efw *efw) in get_hardware_info() argument
75 struct fw_device *fw_dev = fw_parent_device(efw->unit); in get_hardware_info()
84 err = snd_efw_command_get_hwinfo(efw, hwinfo); in get_hardware_info()
92 efw->firmware_version = hwinfo->arm_version; in get_hardware_info()
94 strcpy(efw->card->driver, "Fireworks"); in get_hardware_info()
95 strcpy(efw->card->shortname, hwinfo->model_name); in get_hardware_info()
96 strcpy(efw->card->mixername, hwinfo->model_name); in get_hardware_info()
97 snprintf(efw->card->longname, sizeof(efw->card->longname), in get_hardware_info()
101 dev_name(&efw->unit->device), 100 << fw_dev->max_speed); in get_hardware_info()
104 efw->resp_addr_changable = true; in get_hardware_info()
[all …]
Dfireworks_midi.c13 struct snd_efw *efw = substream->rmidi->private_data; in midi_capture_open() local
16 err = snd_efw_stream_lock_try(efw); in midi_capture_open()
20 mutex_lock(&efw->mutex); in midi_capture_open()
21 efw->capture_substreams++; in midi_capture_open()
22 err = snd_efw_stream_start_duplex(efw, 0); in midi_capture_open()
23 mutex_unlock(&efw->mutex); in midi_capture_open()
25 snd_efw_stream_lock_release(efw); in midi_capture_open()
33 struct snd_efw *efw = substream->rmidi->private_data; in midi_playback_open() local
36 err = snd_efw_stream_lock_try(efw); in midi_playback_open()
40 mutex_lock(&efw->mutex); in midi_playback_open()
[all …]
Dfireworks_hwdep.c23 hwdep_read_resp_buf(struct snd_efw *efw, char __user *buf, long remained, in hwdep_read_resp_buf() argument
42 spin_lock_irq(&efw->lock); in hwdep_read_resp_buf()
49 pull_ptr = efw->pull_ptr; in hwdep_read_resp_buf()
51 while (efw->push_ptr != pull_ptr) { in hwdep_read_resp_buf()
62 (unsigned int)(pull_ptr - efw->resp_buf); in hwdep_read_resp_buf()
65 spin_unlock_irq(&efw->lock); in hwdep_read_resp_buf()
70 spin_lock_irq(&efw->lock); in hwdep_read_resp_buf()
73 if (pull_ptr >= efw->resp_buf + snd_efw_resp_buf_size) in hwdep_read_resp_buf()
91 efw->pull_ptr = pull_ptr; in hwdep_read_resp_buf()
93 spin_unlock_irq(&efw->lock); in hwdep_read_resp_buf()
[all …]
Dfireworks_pcm.c133 pcm_init_hw_params(struct snd_efw *efw, in pcm_init_hw_params() argument
143 s = &efw->tx_stream; in pcm_init_hw_params()
144 pcm_channels = efw->pcm_capture_channels; in pcm_init_hw_params()
147 s = &efw->rx_stream; in pcm_init_hw_params()
148 pcm_channels = efw->pcm_playback_channels; in pcm_init_hw_params()
152 runtime->hw.rates = efw->supported_sampling_rate, in pcm_init_hw_params()
176 struct snd_efw *efw = substream->private_data; in pcm_open() local
181 err = snd_efw_stream_lock_try(efw); in pcm_open()
185 err = pcm_init_hw_params(efw, substream); in pcm_open()
189 err = snd_efw_command_get_clock_source(efw, &clock_source); in pcm_open()
[all …]
Dfireworks_proc.c31 struct snd_efw *efw = entry->private_data; in proc_read_hwinfo() local
39 if (snd_efw_command_get_hwinfo(efw, hwinfo) < 0) in proc_read_hwinfo()
108 struct snd_efw *efw = entry->private_data; in proc_read_clock() local
112 if (snd_efw_command_get_clock_source(efw, &clock_source) < 0) in proc_read_clock()
115 if (snd_efw_command_get_sampling_rate(efw, &sampling_rate) < 0) in proc_read_clock()
131 struct snd_efw *efw = entry->private_data; in proc_read_phys_meters() local
139 (efw->phys_in + efw->phys_out) * sizeof(u32); in proc_read_phys_meters()
144 err = snd_efw_command_get_phys_meters(efw, meters, size); in proc_read_phys_meters()
151 max = min(efw->phys_out, meters->out_meters); in proc_read_phys_meters()
154 for (g = 0; g < efw->phys_out_grp_count; g++) { in proc_read_phys_meters()
[all …]
Dfireworks.h122 void snd_efw_transaction_add_instance(struct snd_efw *efw);
123 void snd_efw_transaction_remove_instance(struct snd_efw *efw);
195 int snd_efw_command_set_resp_addr(struct snd_efw *efw,
197 int snd_efw_command_set_tx_mode(struct snd_efw *efw,
199 int snd_efw_command_get_hwinfo(struct snd_efw *efw,
201 int snd_efw_command_get_phys_meters(struct snd_efw *efw,
204 int snd_efw_command_get_clock_source(struct snd_efw *efw,
206 int snd_efw_command_get_sampling_rate(struct snd_efw *efw, unsigned int *rate);
207 int snd_efw_command_set_sampling_rate(struct snd_efw *efw, unsigned int rate);
209 int snd_efw_stream_init_duplex(struct snd_efw *efw);
[all …]
Dfireworks_command.c102 efw_transaction(struct snd_efw *efw, unsigned int category, in efw_transaction() argument
123 spin_lock(&efw->lock); in efw_transaction()
124 if ((efw->seqnum < KERNEL_SEQNUM_MIN) || in efw_transaction()
125 (efw->seqnum >= KERNEL_SEQNUM_MAX - 2)) in efw_transaction()
126 efw->seqnum = KERNEL_SEQNUM_MIN; in efw_transaction()
128 efw->seqnum += 2; in efw_transaction()
129 seqnum = efw->seqnum; in efw_transaction()
130 spin_unlock(&efw->lock); in efw_transaction()
145 err = snd_efw_transaction_run(efw->unit, buf, cmd_bytes, in efw_transaction()
155 dev_err(&efw->unit->device, "EFW command failed [%u/%u]: %s\n", in efw_transaction()
[all …]
Dfireworks_transaction.c119 copy_resp_to_buf(struct snd_efw *efw, void *data, size_t length, int *rcode) in copy_resp_to_buf() argument
127 spin_lock_irq(&efw->lock); in copy_resp_to_buf()
129 if (efw->push_ptr < efw->pull_ptr) in copy_resp_to_buf()
130 capacity = (unsigned int)(efw->pull_ptr - efw->push_ptr); in copy_resp_to_buf()
133 (unsigned int)(efw->push_ptr - efw->pull_ptr); in copy_resp_to_buf()
144 (unsigned int)(efw->push_ptr - efw->resp_buf); in copy_resp_to_buf()
147 memcpy(efw->push_ptr, data, till_end); in copy_resp_to_buf()
149 efw->push_ptr += till_end; in copy_resp_to_buf()
150 if (efw->push_ptr >= efw->resp_buf + snd_efw_resp_buf_size) in copy_resp_to_buf()
151 efw->push_ptr -= snd_efw_resp_buf_size; in copy_resp_to_buf()
[all …]