[alsa-devel] Hardware-specific IOCTLs

Clemens Ladisch clemens at ladisch.de
Fri Jan 13 18:31:18 CET 2012


Ivan Bublikov wrote:
> As an HDA codec vendor, I want to be able to control some functionality
> in my codec, that is not present in codecs from other vendors.  [...]
> I can register an IOCTL handler using snd_ctl_register_ioctl.

This functions is for ioctl calls on the ctl device, which is global
for one sound card and is not appropriate if one wants to address
something like a PCM device or a codec.

For a HDA codec, use a hwdep device.

> My difficulty is how to define a code for my IOCTL and avoid
> a conflict with the common code in the future.

Pick something not yet allocated in Documentation/ioctl/ioctl-number.txt.


Regards,
Clemens


More information about the Alsa-devel mailing list