diff options
author | Daniel Mack <daniel@caiaq.de> | 2010-05-31 15:35:37 +0400 |
---|---|---|
committer | Takashi Iwai <tiwai@suse.de> | 2010-05-31 20:15:57 +0400 |
commit | a6a3325913efbe35a10e87fd3e9c3ce621fd32c7 (patch) | |
tree | 4b3300083115516ff8fff200da4d4300dea3b853 /sound/usb/mixer.h | |
parent | dcbe7bcfa32c5bc4f9bb6c75d4d41bb4db8c36fc (diff) | |
download | linux-a6a3325913efbe35a10e87fd3e9c3ce621fd32c7.tar.xz |
ALSA: usb-audio: support partially write-protected UAC2 controls
So far, UAC2 controls are marked read-only if any of the channels are
marked read-only in the descriptors. Change this behaviour and
- mark them writeable unless all channels are read-only
- store the read-only mask in usb_mixer_elem_info and
- check the mask again in set_cur_mix_value(), and bail out for
write-protected channels.
Signed-off-by: Daniel Mack <daniel@caiaq.de>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Diffstat (limited to 'sound/usb/mixer.h')
-rw-r--r-- | sound/usb/mixer.h | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/sound/usb/mixer.h b/sound/usb/mixer.h index 130123854a6c..a7cf1007fbb0 100644 --- a/sound/usb/mixer.h +++ b/sound/usb/mixer.h @@ -34,6 +34,8 @@ struct usb_mixer_elem_info { unsigned int id; unsigned int control; /* CS or ICN (high byte) */ unsigned int cmask; /* channel mask bitmap: 0 = master */ + unsigned int ch_readonly; + unsigned int master_readonly; int channels; int val_type; int min, max, res; |