Fix HFP mSBC support on Realtek Bluetooth USB controller

Bug #2007331 reported by Kai-Heng Feng
10
This bug affects 1 person
Affects Status Importance Assigned to Milestone
HWE Next
New
Undecided
Unassigned
linux-oem-6.0 (Ubuntu)
Invalid
Undecided
Unassigned
Jammy
Fix Released
Medium
Unassigned
Kinetic
Invalid
Undecided
Unassigned
Lunar
Invalid
Undecided
Unassigned
linux-oem-6.1 (Ubuntu)
Invalid
Undecided
Unassigned
Jammy
Fix Released
Medium
Unassigned
Kinetic
Invalid
Undecided
Unassigned
Lunar
Invalid
Undecided
Unassigned
pulseaudio (Ubuntu)
Fix Released
Medium
Unassigned
Jammy
Fix Released
Medium
Unassigned
Kinetic
Fix Released
Medium
Unassigned
Lunar
Fix Released
Medium
Unassigned

Bug Description

[Impact]
When a BT headset is connected Realtek BT USB controller, HFP profile can't play or record sound when mSBC codec is used.

[Fix]
At Linux kernel side, add a Realtek specific quirk to support mSBC.

At PulseAudio side, send more data frames until the connected device sends response.

[Test]
Connect different headsets to the said controller, HFP can play and record sounds now.
Also verified A2DP profile is unaffected.

[Where problems could occur]
The kernel part is Realtek specific, so the regression risk is very limited.

The pulseaudio side only affects HFP profile, since the codeflow only changes when a mic is present.

CVE References

affects: linux (Ubuntu) → linux-oem-6.1 (Ubuntu)
Changed in linux-oem-6.0 (Ubuntu):
status: New → Invalid
Changed in linux-oem-6.0 (Ubuntu Jammy):
status: New → Confirmed
importance: Undecided → Medium
Changed in linux-oem-6.1 (Ubuntu):
status: New → Invalid
Changed in linux-oem-6.1 (Ubuntu Jammy):
status: New → Confirmed
importance: Undecided → Low
importance: Low → Medium
Changed in linux-oem-6.0 (Ubuntu Kinetic):
status: New → Invalid
Changed in linux-oem-6.1 (Ubuntu Kinetic):
status: New → Invalid
Changed in pulseaudio (Ubuntu Jammy):
importance: Undecided → Medium
status: New → Confirmed
Changed in pulseaudio (Ubuntu Kinetic):
importance: Undecided → Medium
status: New → Confirmed
Changed in pulseaudio (Ubuntu Lunar):
importance: Undecided → Medium
status: New → Confirmed
tags: added: oem-priority originate-from-1998757 stella
Revision history for this message
Kai-Heng Feng (kaihengfeng) wrote :

debdiff for lunar

Revision history for this message
Kai-Heng Feng (kaihengfeng) wrote :

debdiff for kinetic

Revision history for this message
Kai-Heng Feng (kaihengfeng) wrote :

debdiff for jammy

Revision history for this message
Timo Aaltonen (tjaalton) wrote :

Is this actually expected to land in oem-6.0? My understanding is that it's basically done already.

Revision history for this message
Ubuntu Kernel Bot (ubuntu-kernel-bot) wrote :

This bug is awaiting verification that the linux-oem-6.1/6.1.0-1008.8 kernel in -proposed solves the problem. Please test the kernel and update this bug with the results. If the problem is solved, change the tag 'verification-needed-jammy' to 'verification-done-jammy'. If the problem still exists, change the tag 'verification-needed-jammy' to 'verification-failed-jammy'.

If verification is not done by 5 working days from today, this fix will be dropped from the source code, and this bug will be closed.

See https://wiki.ubuntu.com/Testing/EnableProposed for documentation how to enable and use -proposed. Thank you!

tags: added: kernel-spammed-jammy-linux-oem-6.1 verification-needed-jammy
Revision history for this message
Steve Langasek (vorlon) wrote : Please test proposed package

Hello Kai-Heng, or anyone else affected,

Accepted pulseaudio into kinetic-proposed. The package will build now and be available at https://launchpad.net/ubuntu/+source/pulseaudio/1:16.1+dfsg1-1ubuntu3.1 in a few hours, and then in the -proposed repository.

Please help us by testing this new package. See https://wiki.ubuntu.com/Testing/EnableProposed for documentation on how to enable and use -proposed. Your feedback will aid us getting this update out to other Ubuntu users.

If this package fixes the bug for you, please add a comment to this bug, mentioning the version of the package you tested, what testing has been performed on the package and change the tag from verification-needed-kinetic to verification-done-kinetic. If it does not fix the bug for you, please add a comment stating that, and change the tag to verification-failed-kinetic. In either case, without details of your testing we will not be able to proceed.

Further information regarding the verification process can be found at https://wiki.ubuntu.com/QATeam/PerformingSRUVerification . Thank you in advance for helping!

N.B. The updated package will be released to -updates after the bug(s) fixed by this package have been verified and the package has been in -proposed for a minimum of 7 days.

Changed in pulseaudio (Ubuntu Kinetic):
status: Confirmed → Fix Committed
tags: added: verification-needed verification-needed-kinetic
Changed in pulseaudio (Ubuntu Lunar):
status: Confirmed → Fix Committed
Changed in pulseaudio (Ubuntu Jammy):
status: Confirmed → Fix Committed
Revision history for this message
Steve Langasek (vorlon) wrote :

Hello Kai-Heng, or anyone else affected,

Accepted pulseaudio into jammy-proposed. The package will build now and be available at https://launchpad.net/ubuntu/+source/pulseaudio/1:15.99.1+dfsg1-1ubuntu2.1 in a few hours, and then in the -proposed repository.

Please help us by testing this new package. See https://wiki.ubuntu.com/Testing/EnableProposed for documentation on how to enable and use -proposed. Your feedback will aid us getting this update out to other Ubuntu users.

If this package fixes the bug for you, please add a comment to this bug, mentioning the version of the package you tested, what testing has been performed on the package and change the tag from verification-needed-jammy to verification-done-jammy. If it does not fix the bug for you, please add a comment stating that, and change the tag to verification-failed-jammy. In either case, without details of your testing we will not be able to proceed.

Further information regarding the verification process can be found at https://wiki.ubuntu.com/QATeam/PerformingSRUVerification . Thank you in advance for helping!

N.B. The updated package will be released to -updates after the bug(s) fixed by this package have been verified and the package has been in -proposed for a minimum of 7 days.

Revision history for this message
Launchpad Janitor (janitor) wrote :

This bug was fixed in the package pulseaudio - 1:16.1+dfsg1-2ubuntu3

---------------
pulseaudio (1:16.1+dfsg1-2ubuntu3) lunar; urgency=medium

  [ Kai-Heng Feng ]
  * d/p/0015-bluetooth-Amend-writeout-to-send-more-initial-frames.patch
    (LP: #2007331)

 -- Kai-Heng Feng <email address hidden> Wed, 15 Feb 2023 09:44:55 +0800

Changed in pulseaudio (Ubuntu Lunar):
status: Fix Committed → Fix Released
Revision history for this message
Ubuntu SRU Bot (ubuntu-sru-bot) wrote : Autopkgtest regression report (pulseaudio/1:16.1+dfsg1-1ubuntu3.1)

All autopkgtests for the newly accepted pulseaudio (1:16.1+dfsg1-1ubuntu3.1) for kinetic have finished running.
The following regressions have been reported in tests triggered by the package:

openjdk-8/8u362-ga-0ubuntu1~22.10 (amd64)

Please visit the excuses page listed below and investigate the failures, proceeding afterwards as per the StableReleaseUpdates policy regarding autopkgtest regressions [1].

https://people.canonical.com/~ubuntu-archive/proposed-migration/kinetic/update_excuses.html#pulseaudio

[1] https://wiki.ubuntu.com/StableReleaseUpdates#Autopkgtest_Regressions

Thank you!

Timo Aaltonen (tjaalton)
Changed in linux-oem-6.0 (Ubuntu Jammy):
status: Confirmed → Won't Fix
Revision history for this message
Kai-Heng Feng (kaihengfeng) wrote :

Verified on the following steps:
1) Enabled proposed pocket, upgrade pulseaudio and install oem kernel 6.1.0-1008.8.
2) Reboot.
3) Pair and connect AirPods, play some audio to ensure that A2DP still works.
4) Switch to HFP and I can hear sound. Microphone also works too.
5) Keep switching between A2DP and HFP profile, both of them work all the time.

tags: added: verification-done verification-done-jammy verification-done-kinetic
removed: verification-needed verification-needed-jammy verification-needed-kinetic
Revision history for this message
Kai-Heng Feng (kaihengfeng) wrote :

#9 doesn't seem to be a regression caused by pulseaudio.

Revision history for this message
Łukasz Zemczak (sil2100) wrote : Update Released

The verification of the Stable Release Update for pulseaudio has completed successfully and the package is now being released to -updates. Subsequently, the Ubuntu Stable Release Updates Team is being unsubscribed and will not receive messages about this bug report. In the event that you encounter a regression using the package from -updates please report a new bug using ubuntu-bug and tag the bug report regression-update so we can easily find any regressions.

Revision history for this message
Launchpad Janitor (janitor) wrote :

This bug was fixed in the package pulseaudio - 1:16.1+dfsg1-1ubuntu3.1

---------------
pulseaudio (1:16.1+dfsg1-1ubuntu3.1) kinetic; urgency=medium

  [ Kai-Heng Feng ]
  * d/p/0015-bluetooth-Amend-writeout-to-send-more-initial-frames.patch
    (LP: #2007331)

 -- Kai-Heng Feng <email address hidden> Wed, 15 Feb 2023 20:20:36 +0800

Changed in pulseaudio (Ubuntu Kinetic):
status: Fix Committed → Fix Released
Revision history for this message
Ubuntu Kernel Bot (ubuntu-kernel-bot) wrote :

This bug is awaiting verification that the linux-oem-6.0/6.0.0-1013.13 kernel in -proposed solves the problem. Please test the kernel and update this bug with the results. If the problem is solved, change the tag 'verification-needed-jammy' to 'verification-done-jammy'. If the problem still exists, change the tag 'verification-needed-jammy' to 'verification-failed-jammy'.

If verification is not done by 5 working days from today, this fix will be dropped from the source code, and this bug will be closed.

See https://wiki.ubuntu.com/Testing/EnableProposed for documentation how to enable and use -proposed. Thank you!

tags: added: kernel-spammed-jammy-linux-oem-6.0 verification-needed-jammy
removed: verification-done verification-done-jammy
Revision history for this message
Timo Aaltonen (tjaalton) wrote :

this is missing verification of oem-6.1 kernel

Changed in linux-oem-6.1 (Ubuntu Jammy):
status: Confirmed → Fix Committed
tags: added: verification-done-jammy
removed: verification-needed-jammy
Revision history for this message
Launchpad Janitor (janitor) wrote :

This bug was fixed in the package linux-oem-6.0 - 6.0.0-1013.13

---------------
linux-oem-6.0 (6.0.0-1013.13) jammy; urgency=medium

  * jammy/linux-oem-6.0: 6.0.0-1013.13 -proposed tracker (LP: #2008351)

  * CVE-2023-1281
    - net/sched: tcindex: update imperfect hash filters respecting rcu

  * CVE-2023-1032
    - net: avoid double iput when sock_alloc_file fails

  * rtcpie in timers from ubuntu_kernel_selftests randomly failing
    (LP: #1814234)
    - SAUCE: selftest: rtcpie: Force passing unreliable subtest

  * CVE-2022-2196
    - KVM: VMX: Execute IBPB on emulated VM-exit when guest has IBRS

  * Fix HFP mSBC support on Realtek Bluetooth USB controller (LP: #2007331)
    - Bluetooth: btrtl: Add btrealtek data struct
    - Bluetooth: btusb: Ignore zero length of USB packets on ALT 6 for specific
      chip

 -- Timo Aaltonen <email address hidden> Thu, 16 Mar 2023 17:59:47 +0200

Changed in linux-oem-6.0 (Ubuntu Jammy):
status: Won't Fix → Fix Released
Revision history for this message
Launchpad Janitor (janitor) wrote :
Download full text (77.0 KiB)

This bug was fixed in the package linux-oem-6.1 - 6.1.0-1008.8

---------------
linux-oem-6.1 (6.1.0-1008.8) jammy; urgency=medium

  * jammy/linux-oem-6.1: 6.1.0-1008.8 -proposed tracker (LP: #2008352)

  * overlayfs mounts as R/O over idmapped mount (LP: #2009065)
    - SAUCE: overlayfs: handle idmapped mounts in ovl_do_(set|remove)xattr

  * Some QHD panels fail to refresh when PSR2 enabled (LP: #2009014)
    - SAUCE: drm/i915/psr: Use calculated io and fast wake lines

  * Fix mediatek wifi driver crash when loading wrong SAR table (LP: #2009118)
    - wifi: mt76: mt7921: fix error code of return in mt7921_acpi_read

  * Packaging resync (LP: #1786013)
    - [Packaging] update update.conf

  * Update dg2_dmc to 2.08 (LP: #1999375)
    - drm/i915/dmc: Update DG2 DMC version to v2.08

  * New DG2 workarounds (LP: #2006945)
    - drm/i915/dg2: Introduce Wa_18017747507
    - drm/i915/dg2: Introduce Wa_18018764978
    - drm/i915/dg2: Introduce Wa_18019271663

  * Screen backlight keeps in minimized and can't change it with amdgpu
    (LP: #2008871)
    - SAUCE: ACPI: video: Add backlight=native DMI quirk for Dell Vostro 15 3535

  * Remove all other acpi_video backlight interface on Dell AIO platforms
    (LP: #2008882)
    - SAUCE: ACPI: video: Dell AIO UART backlight detection

  * screen flicker after PSR2 enabled (LP: #2007516)
    - SAUCE: drm/i915/display/psr: Disable PSR2 sel fetch on panel SHP 5457

  * rtcpie in timers from ubuntu_kernel_selftests randomly failing
    (LP: #1814234)
    - SAUCE: selftest: rtcpie: Force passing unreliable subtest

  * Fix HFP mSBC support on Realtek Bluetooth USB controller (LP: #2007331)
    - Bluetooth: btrtl: Add btrealtek data struct
    - Bluetooth: btusb: Ignore zero length of USB packets on ALT 6 for specific
      chip

  * Jammy update: v6.1.14 upstream stable release (LP: #2008708)
    - drm/etnaviv: don't truncate physical page address
    - wifi: ath11k: fix warning in dma_free_coherent() of memory chunks while
      recovery
    - wifi: rtl8xxxu: gen2: Turn on the rate control
    - drm/edid: Fix minimum bpc supported with DSC1.2 for HDMI sink
    - clk: mxl: Switch from direct readl/writel based IO to regmap based IO
    - clk: mxl: Remove redundant spinlocks
    - clk: mxl: Add option to override gate clks
    - clk: mxl: Fix a clk entry by adding relevant flags
    - powerpc: dts: t208x: Mark MAC1 and MAC2 as 10G
    - clk: mxl: syscon_node_to_regmap() returns error pointers
    - sched/psi: Stop relying on timer_pending() for poll_work rescheduling
    - random: always mix cycle counter in add_latent_entropy()
    - scsi: libsas: Add smp_ata_check_ready_type()
    - scsi: hisi_sas: Fix SATA devices missing issue during I_T nexus reset
    - spi: mediatek: Enable irq when pdata is ready
    - docs: perf: Fix PMU instance name of hisi-pcie-pmu
    - KVM: x86: Fail emulation during EMULTYPE_SKIP on any exception
    - KVM: SVM: Skip WRMSR fastpath on VM-Exit if next RIP isn't valid
    - KVM: VMX: Execute IBPB on emulated VM-exit when guest has IBRS
    - can: kvaser_usb: hydra: help gcc-13 to figure out cmd_len
    - powerpc: dts: t208x: Disable 10G on MAC1 and MAC2
    - spi: mediatek: ...

Changed in linux-oem-6.1 (Ubuntu Jammy):
status: Fix Committed → Fix Released
Revision history for this message
Launchpad Janitor (janitor) wrote :

This bug was fixed in the package pulseaudio - 1:15.99.1+dfsg1-1ubuntu2.1

---------------
pulseaudio (1:15.99.1+dfsg1-1ubuntu2.1) jammy; urgency=medium

  [ Kai-Heng Feng ]
  * d/p/0018-bluetooth-Amend-writeout-to-send-more-initial-frames.patch
    (LP: #2007331)

 -- Kai-Heng Feng <email address hidden> Thu, 16 Feb 2023 10:19:55 +0800

Changed in pulseaudio (Ubuntu Jammy):
status: Fix Committed → Fix Released
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.