Lines Matching refs:plugin
63 struct mixer_plugin *plugin; member
71 struct mixer_plugin *plugin = plug_data->plugin; in mixer_plug_get_elem_id() local
74 if (offset >= plugin->num_controls) { in mixer_plug_get_elem_id()
80 ctl = plugin->controls + offset; in mixer_plug_get_elem_id()
138 void mixer_plug_notifier_cb(struct mixer_plugin *plugin) in mixer_plug_notifier_cb() argument
140 plugin->event_cnt++; in mixer_plug_notifier_cb()
141 eventfd_write(plugin->eventfd, 1); in mixer_plug_notifier_cb()
149 struct mixer_plugin *plugin = plug_data->plugin; in mixer_plug_read_event() local
153 result = plug_data->ops->read_event(plugin, ev, size); in mixer_plug_read_event()
156 plugin->event_cnt -= result / sizeof(struct snd_ctl_event); in mixer_plug_read_event()
157 if (plugin->event_cnt == 0) in mixer_plug_read_event()
158 eventfd_read(plugin->eventfd, &evfd); in mixer_plug_read_event()
167 struct mixer_plugin *plugin = plug_data->plugin; in mixer_plug_subscribe_events() local
171 *subscribe = plugin->subscribed; in mixer_plug_subscribe_events()
175 if (*subscribe && !plugin->subscribed) { in mixer_plug_subscribe_events()
176 plug_data->ops->subscribe_events(plugin, &mixer_plug_notifier_cb); in mixer_plug_subscribe_events()
177 } else if (plugin->subscribed && !*subscribe) { in mixer_plug_subscribe_events()
178 plug_data->ops->subscribe_events(plugin, NULL); in mixer_plug_subscribe_events()
180 if (plugin->event_cnt) in mixer_plug_subscribe_events()
181 eventfd_read(plugin->eventfd, &evfd); in mixer_plug_subscribe_events()
183 plugin->event_cnt = 0; in mixer_plug_subscribe_events()
186 plugin->subscribed = *subscribe; in mixer_plug_subscribe_events()
193 struct mixer_plugin *plugin = plug_data->plugin; in mixer_plug_get_poll_fd() local
195 if (plugin->eventfd != -1) { in mixer_plug_get_poll_fd()
196 pfd[count].fd = plugin->eventfd; in mixer_plug_get_poll_fd()
205 struct mixer_plugin *plugin = plug_data->plugin; in mixer_plug_tlv_write() local
209 ctl = plugin->controls + tlv->numid; in mixer_plug_tlv_write()
212 return val_tlv->put(plugin, ctl, tlv); in mixer_plug_tlv_write()
218 struct mixer_plugin *plugin = plug_data->plugin; in mixer_plug_tlv_read() local
222 ctl = plugin->controls + tlv->numid; in mixer_plug_tlv_read()
225 return val_tlv->get(plugin, ctl, tlv); in mixer_plug_tlv_read()
231 struct mixer_plugin *plugin = plug_data->plugin; in mixer_plug_elem_write() local
239 ctl = plugin->controls + ev->id.numid; in mixer_plug_elem_write()
241 return ctl->put(plugin, ctl, ev); in mixer_plug_elem_write()
247 struct mixer_plugin *plugin = plug_data->plugin; in mixer_plug_elem_read() local
255 ctl = plugin->controls + ev->id.numid; in mixer_plug_elem_read()
257 return ctl->get(plugin, ctl, ev); in mixer_plug_elem_read()
264 struct mixer_plugin *plugin = plug_data->plugin; in mixer_plug_get_elem_info() local
273 ctl = plugin->controls + einfo->id.numid; in mixer_plug_get_elem_info()
305 struct mixer_plugin *plugin = plug_data->plugin; in mixer_plug_get_elem_list() local
310 elist->count = plugin->num_controls; in mixer_plug_get_elem_list()
340 struct mixer_plugin *plugin = plug_data->plugin; in mixer_plug_close() local
343 if (plugin->event_cnt) in mixer_plug_close()
344 eventfd_read(plugin->eventfd, &evfd); in mixer_plug_close()
346 plug_data->ops->close(&plugin); in mixer_plug_close()
409 struct mixer_plugin *plugin = NULL; in mixer_plugin_open() local
450 ret = plug_data->ops->open(&plugin, card); in mixer_plugin_open()
457 plug_data->plugin = plugin; in mixer_plugin_open()
460 plugin->eventfd = eventfd(0, 0); in mixer_plugin_open()