Skip to contentSkip to conversation

usb-audio: Set correct type for some UAC2 mixer controls.

PATCH In review Johan Rastén 2 participants 4 messages Jun 11, 2015 Sound

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 usb-audio: Set correct type for some UAC2 mixer controls.

Changed ctl type for Input Gain Control and Input Gain Pad Control to USB_MIXER_S16 as per section 5.2.5.7.11-12 in the USB Audio Class 2.0 definition.

sound/usb/mixer.c +3 -3
index 8b7e391..6b3acba 100644
@@ -809,12 +809,12 @@ static struct usb_feature_control_info audio_feature_info[] = {
 	{ "Tone Control - Treble",	USB_MIXER_S8 },
 	{ "Graphic Equalizer",		USB_MIXER_S8 }, /* FIXME: not implemeted yet */
 	{ "Auto Gain Control",		USB_MIXER_BOOLEAN },
-	{ "Delay Control",		USB_MIXER_U16 },
+	{ "Delay Control",		USB_MIXER_U16 }, /* FIXME: U32 in UAC2 */
 	{ "Bass Boost",			USB_MIXER_BOOLEAN },
 	{ "Loudness",			USB_MIXER_BOOLEAN },
 	/* UAC2 specific */
-	{ "Input Gain Control",		USB_MIXER_U16 },
-	{ "Input Gain Pad Control",	USB_MIXER_BOOLEAN },
+	{ "Input Gain Control",		USB_MIXER_S16 },
+	{ "Input Gain Pad Control",	USB_MIXER_S16 },
 	{ "Phase Inverter Control",	USB_MIXER_BOOLEAN },
 };
 
Signature · 6 lines
2.1.4

_______________________________________________
Alsa-devel mailing list
[email protected]
http://mailman.alsa-project.org/mailman/listinfo/alsa-devel
#1 lore raw

At Thu, 11 Jun 2015 10:04:51 +0200,

Quoted 6 lines · Johan Rastén

Changed ctl type for Input Gain Control and Input Gain Pad Control to USB_MIXER_S16 as per section 5.2.5.7.11-12 in the USB Audio Class 2.0 definition.

Do you have a device that actually uses these stuff? I'm asking whether this fix any real device, or just hypothetical. In the former case, it should go to 4.1. For the latter, we can postpone to 4.2.

thanks,

Takashi

Quoted 23 lines
sound/usb/mixer.c +3 -3
index 8b7e391..6b3acba 100644
@@ -809,12 +809,12 @@ static struct usb_feature_control_info audio_feature_info[] = {
 	{ "Tone Control - Treble",	USB_MIXER_S8 },
 	{ "Graphic Equalizer",		USB_MIXER_S8 }, /* FIXME: not implemeted yet */
 	{ "Auto Gain Control",		USB_MIXER_BOOLEAN },
-	{ "Delay Control",		USB_MIXER_U16 },
+	{ "Delay Control",		USB_MIXER_U16 }, /* FIXME: U32 in UAC2 */
 	{ "Bass Boost",			USB_MIXER_BOOLEAN },
 	{ "Loudness",			USB_MIXER_BOOLEAN },
 	/* UAC2 specific */
-	{ "Input Gain Control",		USB_MIXER_U16 },
-	{ "Input Gain Pad Control",	USB_MIXER_BOOLEAN },
+	{ "Input Gain Control",		USB_MIXER_S16 },
+	{ "Input Gain Pad Control",	USB_MIXER_S16 },
 	{ "Phase Inverter Control",	USB_MIXER_BOOLEAN },
 };
 
Signature · 1 line
2.1.4

_______________________________________________
Alsa-devel mailing list
[email protected]
http://mailman.alsa-project.org/mailman/listinfo/alsa-devel

#2 lore raw

The Asus Xonar U7 has an input gain pad control, but audio capture is still broken with this patch so no hurry.

//Johan

Quoted 39 lines · Takashi Iwai

At Thu, 11 Jun 2015 10:04:51 +0200,

Quoted 6 lines · Johan Rastén

Changed ctl type for Input Gain Control and Input Gain Pad Control to USB_MIXER_S16 as per section 5.2.5.7.11-12 in the USB Audio Class 2.0 definition.

Do you have a device that actually uses these stuff? I'm asking whether this fix any real device, or just hypothetical. In the former case, it should go to 4.1. For the latter, we can postpone to 4.2.

thanks,

Takashi

Quoted 20 lines
sound/usb/mixer.c +3 -3
index 8b7e391..6b3acba 100644
@@ -809,12 +809,12 @@ static struct usb_feature_control_info audio_feature_info[] = {
      { "Tone Control - Treble",      USB_MIXER_S8 },
      { "Graphic Equalizer",          USB_MIXER_S8 }, /* FIXME: not implemeted yet */
      { "Auto Gain Control",          USB_MIXER_BOOLEAN },
-     { "Delay Control",              USB_MIXER_U16 },
+     { "Delay Control",              USB_MIXER_U16 }, /* FIXME: U32 in UAC2 */
      { "Bass Boost",                 USB_MIXER_BOOLEAN },
      { "Loudness",                   USB_MIXER_BOOLEAN },
      /* UAC2 specific */
-     { "Input Gain Control",         USB_MIXER_U16 },
-     { "Input Gain Pad Control",     USB_MIXER_BOOLEAN },
+     { "Input Gain Control",         USB_MIXER_S16 },
+     { "Input Gain Pad Control",     USB_MIXER_S16 },
      { "Phase Inverter Control",     USB_MIXER_BOOLEAN },
 };
 
Quoted 3 lines
Quoted 3 lines

--
2.1.4

_______________________________________________
Alsa-devel mailing list
[email protected]
http://mailman.alsa-project.org/mailman/listinfo/alsa-devel

#3 lore raw

At Thu, 11 Jun 2015 11:26:26 +0200,

Quoted 3 lines · Johan Aires Rastén

The Asus Xonar U7 has an input gain pad control, but audio capture is still broken with this patch so no hurry.

OK, then I'm going to queue this to for-next branch.

thanks,

Takashi

Quoted 44 lines

//Johan

Quoted 39 lines · Takashi Iwai

At Thu, 11 Jun 2015 10:04:51 +0200,

Quoted 6 lines · Johan Rastén

Changed ctl type for Input Gain Control and Input Gain Pad Control to USB_MIXER_S16 as per section 5.2.5.7.11-12 in the USB Audio Class 2.0 definition.

Do you have a device that actually uses these stuff? I'm asking whether this fix any real device, or just hypothetical. In the former case, it should go to 4.1. For the latter, we can postpone to 4.2.

thanks,

Takashi

Quoted 20 lines
sound/usb/mixer.c +3 -3
index 8b7e391..6b3acba 100644
@@ -809,12 +809,12 @@ static struct usb_feature_control_info audio_feature_info[] = {
      { "Tone Control - Treble",      USB_MIXER_S8 },
      { "Graphic Equalizer",          USB_MIXER_S8 }, /* FIXME: not implemeted yet */
      { "Auto Gain Control",          USB_MIXER_BOOLEAN },
-     { "Delay Control",              USB_MIXER_U16 },
+     { "Delay Control",              USB_MIXER_U16 }, /* FIXME: U32 in UAC2 */
      { "Bass Boost",                 USB_MIXER_BOOLEAN },
      { "Loudness",                   USB_MIXER_BOOLEAN },
      /* UAC2 specific */
-     { "Input Gain Control",         USB_MIXER_U16 },
-     { "Input Gain Pad Control",     USB_MIXER_BOOLEAN },
+     { "Input Gain Control",         USB_MIXER_S16 },
+     { "Input Gain Pad Control",     USB_MIXER_S16 },
      { "Phase Inverter Control",     USB_MIXER_BOOLEAN },
 };
 
Quoted 4 lines
Quoted 3 lines
Quoted 3 lines

--
2.1.4

_______________________________________________
Alsa-devel mailing list
[email protected]
http://mailman.alsa-project.org/mailman/listinfo/alsa-devel