[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <CADg1FFfBNSZSAV6Ygudmr959X2VsfThZaTMAj_OZ24B0TisDog@mail.gmail.com>
Date: Mon, 24 Feb 2025 21:06:58 +0800
From: Hsin-chen Chuang <chharry@...gle.com>
To: Paul Menzel <pmenzel@...gen.mpg.de>
Cc: linux-bluetooth@...r.kernel.org, luiz.dentz@...il.com,
gregkh@...uxfoundation.org, chromeos-bluetooth-upstreaming@...omium.org,
Hsin-chen Chuang <chharry@...omium.org>, Marcel Holtmann <marcel@...tmann.org>,
Ying Hsu <yinghsu@...omium.org>, linux-kernel@...r.kernel.org
Subject: Re: [PATCH] Bluetooth: btusb: Configure altsetting for USER_CHANNEL
Hi Paul,
On Mon, Feb 24, 2025 at 4:42 PM Paul Menzel <pmenzel@...gen.mpg.de> wrote:
>
> Dear Hsin-chen,
>
>
> Thank you for your patch.
>
> Am 24.02.25 um 03:24 schrieb Hsin-chen Chuang:
> > From: Hsin-chen Chuang <chharry@...omium.org>
> >
> > Automatically configure the altsetting for USER_CHANNEL when a SCO is
> > connected or disconnected. This adds support for the USER_CHANNEL to
> > transfer SCO data over USB transport.
>
> Should you re-spin, it’d be great if you elaborated a little more.
> Especially for the motivation. It’d be also great, if you added how to
> test this.
Sure and I'll update this to the commit message in the next patch version.
The motivation is to enable the HCI_USER_CHANNEL user to send out SCO
data through USB Bluetooth chips, which is mainly used for
bidirectional audio transfer (voice call).
This was not capable because
- Per Bluetooth Core Spec v5, Vol 4, Part B, 2.1, the corresponding
alternate setting should be set based on the air mode in order to
transfer SCO data.
- The Linux Bluetooth HCI_USER_CHANNEL exposes the Bluetooth Host
Controller Interface to the user space, which is something above the
USB layer. The user space is not able to configure the USB alt while
keeping the channel open.
This patch intercepts the specific packets that indicate the air mode
change, and configure the alt setting transparently in btusb.
I tested this patch on ChromeOS devices which are now using the
Android Bluetooth stack built on top of the HCI_USER_CHANNEL. The USB
Bluetooth models could work without a customized kernel.
>
> > Fixes: b16b327edb4d ("Bluetooth: btusb: add sysfs attribute to control USB alt setting")
> > Signed-off-by: Hsin-chen Chuang <chharry@...omium.org>
> > ---
> >
> > drivers/bluetooth/btusb.c | 224 +++++++++++++++++++++++++++++++-------
> > 1 file changed, 186 insertions(+), 38 deletions(-)
>
> […]
>
>
> Kind regards,
>
> Paul
--
Best Regards,
Hsin-chen
Powered by blists - more mailing lists