diff options
author | Daniel Mack <daniel@zonque.org> | 2016-08-22 02:53:37 -0400 |
---|---|---|
committer | Takashi Iwai <tiwai@suse.de> | 2016-08-22 05:39:56 -0400 |
commit | ca0dd2736a05d1df94c8657b4865f9d6c6637085 (patch) | |
tree | 8692a34c087448112b450e241d1ccb41934b46a5 | |
parent | 9abc134167249ded16a8c776813121609610f119 (diff) |
ALSA: usb: use TEAC UD-H01 quirk for more devices
The quirk seems to be necessary not only for TEAC UD-H01 devices, but to
more that are based on the Tenor 8802TL chipset. Devices built by T+A
are affected too, and they apparently all use the same USB PID:PID.
Extend the quirky handling for that device as well, and rename the
quirks flag.
Reported-and-tested-by: Thomas Gresens <T.Gresens@intershop.de>
Signed-off-by: Daniel Mack <daniel@zonque.org>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
-rw-r--r-- | sound/usb/card.h | 2 | ||||
-rw-r--r-- | sound/usb/endpoint.c | 5 | ||||
-rw-r--r-- | sound/usb/quirks.c | 5 |
3 files changed, 7 insertions, 5 deletions
diff --git a/sound/usb/card.h b/sound/usb/card.h index 71778ca4b26a..111b0f009afa 100644 --- a/sound/usb/card.h +++ b/sound/usb/card.h | |||
@@ -92,7 +92,7 @@ struct snd_usb_endpoint { | |||
92 | unsigned int curframesize; /* current packet size in frames (for capture) */ | 92 | unsigned int curframesize; /* current packet size in frames (for capture) */ |
93 | unsigned int syncmaxsize; /* sync endpoint packet size */ | 93 | unsigned int syncmaxsize; /* sync endpoint packet size */ |
94 | unsigned int fill_max:1; /* fill max packet size always */ | 94 | unsigned int fill_max:1; /* fill max packet size always */ |
95 | unsigned int udh01_fb_quirk:1; /* corrupted feedback data */ | 95 | unsigned int tenor_fb_quirk:1; /* corrupted feedback data */ |
96 | unsigned int datainterval; /* log_2 of data packet interval */ | 96 | unsigned int datainterval; /* log_2 of data packet interval */ |
97 | unsigned int syncinterval; /* P for adaptive mode, 0 otherwise */ | 97 | unsigned int syncinterval; /* P for adaptive mode, 0 otherwise */ |
98 | unsigned char silence_value; | 98 | unsigned char silence_value; |
diff --git a/sound/usb/endpoint.c b/sound/usb/endpoint.c index 4b4ffa0adb88..c317a8d530cc 100644 --- a/sound/usb/endpoint.c +++ b/sound/usb/endpoint.c | |||
@@ -1167,9 +1167,10 @@ void snd_usb_handle_sync_urb(struct snd_usb_endpoint *ep, | |||
1167 | if (f == 0) | 1167 | if (f == 0) |
1168 | return; | 1168 | return; |
1169 | 1169 | ||
1170 | if (unlikely(sender->udh01_fb_quirk)) { | 1170 | if (unlikely(sender->tenor_fb_quirk)) { |
1171 | /* | 1171 | /* |
1172 | * The TEAC UD-H01 firmware sometimes changes the feedback value | 1172 | * Devices based on Tenor 8802 chipsets (TEAC UD-H01 |
1173 | * and others) sometimes change the feedback value | ||
1173 | * by +/- 0x1.0000. | 1174 | * by +/- 0x1.0000. |
1174 | */ | 1175 | */ |
1175 | if (f < ep->freqn - 0x8000) | 1176 | if (f < ep->freqn - 0x8000) |
diff --git a/sound/usb/quirks.c b/sound/usb/quirks.c index 299813f30630..d47d9275874c 100644 --- a/sound/usb/quirks.c +++ b/sound/usb/quirks.c | |||
@@ -1218,9 +1218,10 @@ void snd_usb_endpoint_start_quirk(struct snd_usb_endpoint *ep) | |||
1218 | ep->skip_packets = 16; | 1218 | ep->skip_packets = 16; |
1219 | 1219 | ||
1220 | /* Work around devices that report unreasonable feedback data */ | 1220 | /* Work around devices that report unreasonable feedback data */ |
1221 | if (ep->chip->usb_id == USB_ID(0x0644, 0x8038) /* TEAC UD-H01 */ && | 1221 | if ((ep->chip->usb_id == USB_ID(0x0644, 0x8038) || /* TEAC UD-H01 */ |
1222 | ep->chip->usb_id == USB_ID(0x1852, 0x5034)) && /* T+A Dac8 */ | ||
1222 | ep->syncmaxsize == 4) | 1223 | ep->syncmaxsize == 4) |
1223 | ep->udh01_fb_quirk = 1; | 1224 | ep->tenor_fb_quirk = 1; |
1224 | } | 1225 | } |
1225 | 1226 | ||
1226 | void snd_usb_set_interface_quirk(struct usb_device *dev) | 1227 | void snd_usb_set_interface_quirk(struct usb_device *dev) |