Bug 206149 - Jabra Evolve 65 headset may need Alsa quirk
Summary: Jabra Evolve 65 headset may need Alsa quirk
Status: RESOLVED CODE_FIX
Alias: None
Product: Drivers
Classification: Unclassified
Component: Sound(ALSA) (show other bugs)
Hardware: All Linux
: P1 normal
Assignee: Jaroslav Kysela
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2020-01-09 21:31 UTC by Bill Nottingham
Modified: 2020-02-14 14:56 UTC (History)
1 user (show)

See Also:
Kernel Version: 5.4.7
Subsystem:
Regression: No
Bisected commit-id:


Attachments
lsusb -v -d 0b0e:030b output (9.37 KB, text/plain)
2020-01-10 19:54 UTC, Bill Nottingham
Details
Test fix patch (1.69 KB, patch)
2020-01-16 10:59 UTC, Takashi Iwai
Details | Diff
Test fix patch v2 (1.74 KB, patch)
2020-01-25 10:20 UTC, Takashi Iwai
Details | Diff
Fix patch (2.54 KB, patch)
2020-02-11 11:16 UTC, Takashi Iwai
Details | Diff

Description Bill Nottingham 2020-01-09 21:31:32 UTC
Jabra Evolve 65 headset plays all audio at 48kHz, regardless of what it is configured to do.

[notting@nostromo: ~]$ lsusb | grep Jabra
Bus 001 Device 019: ID 0b0e:030b GN Netcom Jabra EVOLVE 65

It claims it supports multiple sample rates:
    Interface Descriptor:
      bLength                 9
      bDescriptorType         4
      bInterfaceNumber        1
      bAlternateSetting       1
      bNumEndpoints           1
      bInterfaceClass         1 Audio
      bInterfaceSubClass      2 Streaming
      bInterfaceProtocol      0 
      iInterface              0 
      AudioStreaming Interface Descriptor:
        bLength                 7
        bDescriptorType        36
        bDescriptorSubtype      1 (AS_GENERAL)
        bTerminalLink           1
        bDelay                  0 frames
        wFormatTag         0x0001 PCM
      AudioStreaming Interface Descriptor:
        bLength                23
        bDescriptorType        36
        bDescriptorSubtype      2 (FORMAT_TYPE)
        bFormatType             1 (FORMAT_TYPE_I)
        bNrChannels             2
        bSubframeSize           2
        bBitResolution         16
        bSamFreqType            5 Discrete
        tSamFreq[ 0]         8000
        tSamFreq[ 1]        16000
        tSamFreq[ 2]        32000
        tSamFreq[ 3]        44100
        tSamFreq[ 4]        48000

However, all audio is played at 48kHz; if it is opened with a different sample rate, it will play at the wrong pitch/speed (all clips are resampled version of the same source, originally a 8.88-second 44.1kHz audio file): 

[notting@nostromo: ~]$ for foo in 8000 16000 32000 44100 48000 ; do time aplay -vvvv -D hw:1 oof-$foo.wav 2>&1 |head -10; done
Playing WAVE 'oof-8000.wav' : Signed 16 bit Little Endian, Rate 8000 Hz, Stereo
Hardware PCM card 1 'Jabra EVOLVE 65' device 0 subdevice 0
Its setup is:
  stream       : PLAYBACK
  access       : RW_INTERLEAVED
  format       : S16_LE
  subformat    : STD
  channels     : 2
  rate         : 8000
  exact rate   : 8000 (8000/1)

real	0m1.525s
user	0m0.007s
sys	0m0.010s
Playing WAVE 'oof-16000.wav' : Signed 16 bit Little Endian, Rate 16000 Hz, Stereo
Hardware PCM card 1 'Jabra EVOLVE 65' device 0 subdevice 0
Its setup is:
  stream       : PLAYBACK
  access       : RW_INTERLEAVED
  format       : S16_LE
  subformat    : STD
  channels     : 2
  rate         : 16000
  exact rate   : 16000 (16000/1)

real	0m3.024s
user	0m0.013s
sys	0m0.007s
Playing WAVE 'oof-32000.wav' : Signed 16 bit Little Endian, Rate 32000 Hz, Stereo
Hardware PCM card 1 'Jabra EVOLVE 65' device 0 subdevice 0
Its setup is:
  stream       : PLAYBACK
  access       : RW_INTERLEAVED
  format       : S16_LE
  subformat    : STD
  channels     : 2
  rate         : 32000
  exact rate   : 32000 (32000/1)

real	0m6.019s
user	0m0.012s
sys	0m0.010s
Playing WAVE 'oof-44100.wav' : Signed 16 bit Little Endian, Rate 44100 Hz, Stereo
Hardware PCM card 1 'Jabra EVOLVE 65' device 0 subdevice 0
Its setup is:
  stream       : PLAYBACK
  access       : RW_INTERLEAVED
  format       : S16_LE
  subformat    : STD
  channels     : 2
  rate         : 44100
  exact rate   : 44100 (44100/1)

real	0m8.284s
user	0m0.012s
sys	0m0.011s
Playing WAVE 'oof-48000.wav' : Signed 16 bit Little Endian, Rate 48000 Hz, Stereo
Hardware PCM card 1 'Jabra EVOLVE 65' device 0 subdevice 0
Its setup is:
  stream       : PLAYBACK
  access       : RW_INTERLEAVED
  format       : S16_LE
  subformat    : STD
  channels     : 2
  rate         : 48000
  exact rate   : 48000 (48000/1)

real	0m9.014s
user	0m0.012s
sys	0m0.010s


Originally filed as a pulseaudio bug here (https://gitlab.freedesktop.org/pulseaudio/pulseaudio/issues/788)
Comment 1 Takashi Iwai 2020-01-10 10:04:24 UTC
So basically it's a firmware bug.  We may need a quirk override for that.

Could you give the whole lsusb -v output for the device?
Comment 2 Bill Nottingham 2020-01-10 19:54:45 UTC
Created attachment 286743 [details]
lsusb -v -d 0b0e:030b output
Comment 3 Takashi Iwai 2020-01-16 10:58:31 UTC
Thanks.  Could you try the patch below?
Comment 4 Takashi Iwai 2020-01-16 10:59:00 UTC
Created attachment 286837 [details]
Test fix patch
Comment 5 Bill Nottingham 2020-01-23 16:02:07 UTC
Yes, that does the trick.
Comment 6 Bill Nottingham 2020-01-23 16:22:12 UTC
Actually, I may need to do more testing - this may have interfered with the microphone.
Comment 7 Bill Nottingham 2020-01-23 20:48:16 UTC
Yes, the above patch sets a fixed 48kHz rate for both playback and capture; however, the device only does 16kHz for capture (see the lsusb output).
Comment 8 Takashi Iwai 2020-01-25 10:19:54 UTC
OK, how about the patch below instead of the previous one?
Comment 9 Takashi Iwai 2020-01-25 10:20:21 UTC
Created attachment 286969 [details]
Test fix patch v2
Comment 10 Bill Nottingham 2020-02-07 16:20:01 UTC
"	if (chip->usb_id == case USB_ID(0x0b0e, 0x030b)) {"

extra 'case ' here, but with that fixed, it works. Thanks!
Comment 11 Takashi Iwai 2020-02-11 11:15:55 UTC
Thanks for confirmation.  I submitted the patch and will merge it later.  It'll be included in 5.6-rc, but I didn't put Cc to stable because it's not cleanly applicable to 5.5.y as is (although adaption would be trivial).
Comment 12 Takashi Iwai 2020-02-11 11:16:28 UTC
Created attachment 287305 [details]
Fix patch

Note You need to log in before you can comment on or make changes to this bug.