ALSA: usb: use TEAC UD-H01 quirk for more devices
authorDaniel Mack <daniel@zonque.org>
Mon, 22 Aug 2016 06:53:37 +0000 (08:53 +0200)
committerTakashi Iwai <tiwai@suse.de>
Mon, 22 Aug 2016 09:39:56 +0000 (11:39 +0200)
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>
sound/usb/card.h
sound/usb/endpoint.c
sound/usb/quirks.c

index 71778ca4b26aafcb3dacedcc660947a5df61f7e2..111b0f009afa493c1aab56ae7fd6c4b07b648996 100644 (file)
@@ -92,7 +92,7 @@ struct snd_usb_endpoint {
        unsigned int curframesize;      /* current packet size in frames (for capture) */
        unsigned int syncmaxsize;       /* sync endpoint packet size */
        unsigned int fill_max:1;        /* fill max packet size always */
-       unsigned int udh01_fb_quirk:1;  /* corrupted feedback data */
+       unsigned int tenor_fb_quirk:1;  /* corrupted feedback data */
        unsigned int datainterval;      /* log_2 of data packet interval */
        unsigned int syncinterval;      /* P for adaptive mode, 0 otherwise */
        unsigned char silence_value;
index 4b4ffa0adb88f22e7adbb42fcdc7dd761e4073b0..c317a8d530cc765371afa4bede91bdf3a6b8f254 100644 (file)
@@ -1167,9 +1167,10 @@ void snd_usb_handle_sync_urb(struct snd_usb_endpoint *ep,
        if (f == 0)
                return;
 
-       if (unlikely(sender->udh01_fb_quirk)) {
+       if (unlikely(sender->tenor_fb_quirk)) {
                /*
-                * The TEAC UD-H01 firmware sometimes changes the feedback value
+                * Devices based on Tenor 8802 chipsets (TEAC UD-H01
+                * and others) sometimes change the feedback value
                 * by +/- 0x1.0000.
                 */
                if (f < ep->freqn - 0x8000)
index 299813f30630f9a18e14208a08917e31a3006633..d47d9275874cdfbbe69b1d1817eb4b8e4756771d 100644 (file)
@@ -1218,9 +1218,10 @@ void snd_usb_endpoint_start_quirk(struct snd_usb_endpoint *ep)
                ep->skip_packets = 16;
 
        /* Work around devices that report unreasonable feedback data */
-       if (ep->chip->usb_id == USB_ID(0x0644, 0x8038) /* TEAC UD-H01 */ &&
+       if ((ep->chip->usb_id == USB_ID(0x0644, 0x8038) ||  /* TEAC UD-H01 */
+            ep->chip->usb_id == USB_ID(0x1852, 0x5034)) && /* T+A Dac8 */
            ep->syncmaxsize == 4)
-               ep->udh01_fb_quirk = 1;
+               ep->tenor_fb_quirk = 1;
 }
 
 void snd_usb_set_interface_quirk(struct usb_device *dev)