Lines Matching refs:efw
118 copy_resp_to_buf(struct snd_efw *efw, void *data, size_t length, int *rcode) in copy_resp_to_buf() argument
126 spin_lock(&efw->lock); in copy_resp_to_buf()
128 if (efw->push_ptr < efw->pull_ptr) in copy_resp_to_buf()
129 capacity = (unsigned int)(efw->pull_ptr - efw->push_ptr); in copy_resp_to_buf()
132 (unsigned int)(efw->push_ptr - efw->pull_ptr); in copy_resp_to_buf()
143 (unsigned int)(efw->push_ptr - efw->resp_buf); in copy_resp_to_buf()
146 memcpy(efw->push_ptr, data, till_end); in copy_resp_to_buf()
148 efw->push_ptr += till_end; in copy_resp_to_buf()
149 if (efw->push_ptr >= efw->resp_buf + snd_efw_resp_buf_size) in copy_resp_to_buf()
150 efw->push_ptr -= snd_efw_resp_buf_size; in copy_resp_to_buf()
157 wake_up(&efw->hwdep_wait); in copy_resp_to_buf()
161 spin_unlock_irq(&efw->lock); in copy_resp_to_buf()
169 struct snd_efw *efw; in handle_resp_for_user() local
175 efw = instances[i]; in handle_resp_for_user()
176 if (efw == NULL) in handle_resp_for_user()
178 device = fw_parent_device(efw->unit); in handle_resp_for_user()
191 copy_resp_to_buf(efw, data, length, rcode); in handle_resp_for_user()
258 void snd_efw_transaction_add_instance(struct snd_efw *efw) in snd_efw_transaction_add_instance() argument
267 instances[i] = efw; in snd_efw_transaction_add_instance()
274 void snd_efw_transaction_remove_instance(struct snd_efw *efw) in snd_efw_transaction_remove_instance() argument
281 if (instances[i] != efw) in snd_efw_transaction_remove_instance()