Access Flags

The access flag is the bit-flags which specifies the access type of the given control. The default access type is SNDRV_CTL_ELEM_ACCESS_READWRITE, which means both read and write are allowed to this control. When the access flag is omitted (i.e. = 0), it is regarded as READWRITE access as default.

When the control is read-only, pass SNDRV_CTL_ELEM_ACCESS_READ instead. In this case, you don't have to define put callback. Similarly, when the control is write-only (although it's a rare case), you can use WRITE flag instead, and you don't need get callback.

If the control value changes frequently (e.g. the VU meter), VOLATILE flag should be given. This means that the control may be changed without notification. Applications should poll such a control constantly.

When the control is inactive, set INACTIVE flag, too. There are LOCK and OWNER flags for changing the write permissions.