ALSA: usb-audio: Add audigy2nx resume support

Rewrite the code to handle LEDs on audigy2nx and co for supporting the
proper resume.  A new internal helper function
add_single_ctl_with_resume() is introduced to manage the
usb_mixer_elem_list more easily.

Also while we're at it, move audigy2nx_leds[] in usb_mixer_interface
struct into the private_value of each kctl, too.

Signed-off-by: Takashi Iwai <tiwai@suse.de>
This commit is contained in:
Takashi Iwai
2014-11-18 12:58:51 +01:00
parent 3360b84b8e
commit 9cf3689bfe
2 changed files with 92 additions and 57 deletions

View File

@@ -23,7 +23,6 @@ struct usb_mixer_interface {
struct usb_ctrlrequest *rc_setup_packet;
u8 rc_buffer[6];
u8 audigy2nx_leds[3];
u8 xonar_u1_status;
};