Hi Charles > > for_each_rtdcom(rtd, rtdcom) { > > component = rtdcom->component; > > > > - if (!component->driver->ops || > > - !component->driver->ops->ioctl) > > - continue; > > - > > + ret = snd_soc_component_ioctl(component, substream, cmd, arg); > > /* FIXME: use 1st ioctl */ > > - return component->driver->ops->ioctl(substream, cmd, arg); > > + if (ret != -ENOTSUPP) > > + return ret; > > This feels a little forced, and also changes behaviour if any > ioctl callbacks already report -ENOTSUPP. > > I wonder if for some/all of these functions it might be worth > abstracting them at a higher level so the whole for_each_rtdcom > loop moves into the helper function similar to what I did with > compress stuff, for example in these patches: > > 1e57b82891ad ("ASoC: compress: Add helper functions for component open/free") > 4ef0ecb80e34 ("ASoC: compress: Add helper functions for component trigger/set_params") Thank you for your feedback. It sounds nice idea for me. will fix in v2 Thank you for your help !! Best regards --- Kuninori Morimoto _______________________________________________ Alsa-devel mailing list Alsa-devel@xxxxxxxxxxxxxxxx https://mailman.alsa-project.org/mailman/listinfo/alsa-devel