ALSA: control: TLV data is unavailable at initial state of user-defined element set
authorTakashi Sakamoto <o-takashi@sakamocchi.jp>
Thu, 24 Aug 2017 01:46:16 +0000 (10:46 +0900)
committerTakashi Iwai <tiwai@suse.de>
Thu, 24 Aug 2017 07:15:15 +0000 (09:15 +0200)
commitb8e2204b25a50e389dfb50eeff163fa796a8ec6e
tree4b98f2401b794547bc54c77a0605fac2a0b64e78
parentda4288287b68fe6902629f4e5306aba2a554bc4b
ALSA: control: TLV data is unavailable at initial state of user-defined element set

For user-defined element set, in its initial state, TLV data is not
registered. It's firstly available when any application register it by
an additional operation. However, in current implementation, it's available
in its initial state. As a result, applications get -ENXIO to read it.

This commit controls its readability to manage info flags properly. In an
initial state, elements don't have SND_CTL_ELEM_ACCESS_TLV_READ flag. Once
TLV write operation is executed, they get the flag.

Signed-off-by: Takashi Sakamoto <o-takashi@sakamocchi.jp>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
sound/core/control.c