* [PATCH v3 1/2] Bluetooth: hci_qca: Refactor HFP hardware offload capability handling
2026-01-27 2:54 [PATCH v3 0/2] Bluetooth: hci_qca: Refactor HFP hardware offload capability handling Mengshi Wu
@ 2026-01-27 2:54 ` Mengshi Wu
2026-01-27 10:15 ` Bartosz Golaszewski
2026-01-27 2:54 ` [PATCH v3 2/2] Bluetooth: hci_qca: Enable HFP hardware offload for WCN6855 and WCN7850 Mengshi Wu
2026-01-29 18:20 ` [PATCH v3 0/2] Bluetooth: hci_qca: Refactor HFP hardware offload capability handling patchwork-bot+bluetooth
2 siblings, 1 reply; 6+ messages in thread
From: Mengshi Wu @ 2026-01-27 2:54 UTC (permalink / raw)
To: Bartosz Golaszewski, Marcel Holtmann, Luiz Augusto von Dentz
Cc: linux-arm-msm, linux-bluetooth, linux-kernel, shuai.zhang,
cheng.jiang, chezhou, wei.deng, yiboz, Mengshi Wu,
Dmitry Baryshkov
Replace SoC-specific check with capability-based approach for HFP
hardware offload configuration. Add QCA_CAP_HFP_HW_OFFLOAD capability
flag and support_hfp_hw_offload field to qca_serdev structure. Add
QCA_CAP_HFP_HW_OFFLOAD capability flag to QCA2066 device data
structures.
Reviewed-by: Dmitry Baryshkov <dmitry.baryshkov@oss.qualcomm.com>
Signed-off-by: Mengshi Wu <mengshi.wu@oss.qualcomm.com>
---
drivers/bluetooth/hci_qca.c | 13 +++++++++----
1 file changed, 9 insertions(+), 4 deletions(-)
diff --git a/drivers/bluetooth/hci_qca.c b/drivers/bluetooth/hci_qca.c
index 888176b0f..b99fdda88 100644
--- a/drivers/bluetooth/hci_qca.c
+++ b/drivers/bluetooth/hci_qca.c
@@ -87,6 +87,7 @@ enum qca_flags {
enum qca_capabilities {
QCA_CAP_WIDEBAND_SPEECH = BIT(0),
QCA_CAP_VALID_LE_STATES = BIT(1),
+ QCA_CAP_HFP_HW_OFFLOAD = BIT(2),
};
/* HCI_IBS transmit side sleep protocol states */
@@ -229,6 +230,7 @@ struct qca_serdev {
u32 init_speed;
u32 oper_speed;
bool bdaddr_property_broken;
+ bool support_hfp_hw_offload;
const char *firmware_name[2];
};
@@ -1879,7 +1881,7 @@ static int qca_setup(struct hci_uart *hu)
const char *rampatch_name = qca_get_rampatch_name(hu);
int ret;
struct qca_btsoc_version ver;
- struct qca_serdev *qcadev;
+ struct qca_serdev *qcadev = serdev_device_get_drvdata(hu->serdev);
const char *soc_name;
ret = qca_check_speeds(hu);
@@ -1943,7 +1945,6 @@ static int qca_setup(struct hci_uart *hu)
case QCA_WCN6750:
case QCA_WCN6855:
case QCA_WCN7850:
- qcadev = serdev_device_get_drvdata(hu->serdev);
if (qcadev->bdaddr_property_broken)
hci_set_quirk(hdev, HCI_QUIRK_BDADDR_PROPERTY_BROKEN);
@@ -2033,7 +2034,7 @@ static int qca_setup(struct hci_uart *hu)
else
hu->hdev->set_bdaddr = qca_set_bdaddr;
- if (soc_type == QCA_QCA2066)
+ if (qcadev->support_hfp_hw_offload)
qca_configure_hfp_offload(hdev);
qca->fw_version = le16_to_cpu(ver.patch_ver);
@@ -2117,7 +2118,8 @@ static const struct qca_device_data qca_soc_data_wcn3998 __maybe_unused = {
static const struct qca_device_data qca_soc_data_qca2066 __maybe_unused = {
.soc_type = QCA_QCA2066,
.num_vregs = 0,
- .capabilities = QCA_CAP_WIDEBAND_SPEECH | QCA_CAP_VALID_LE_STATES,
+ .capabilities = QCA_CAP_WIDEBAND_SPEECH | QCA_CAP_VALID_LE_STATES |
+ QCA_CAP_HFP_HW_OFFLOAD,
};
static const struct qca_device_data qca_soc_data_qca6390 __maybe_unused = {
@@ -2502,6 +2504,9 @@ static int qca_serdev_probe(struct serdev_device *serdev)
if (!(data->capabilities & QCA_CAP_VALID_LE_STATES))
hci_set_quirk(hdev, HCI_QUIRK_BROKEN_LE_STATES);
+
+ if (data->capabilities & QCA_CAP_HFP_HW_OFFLOAD)
+ qcadev->support_hfp_hw_offload = true;
}
return 0;
--
2.34.1
^ permalink raw reply related [flat|nested] 6+ messages in thread* Re: [PATCH v3 1/2] Bluetooth: hci_qca: Refactor HFP hardware offload capability handling
2026-01-27 2:54 ` [PATCH v3 1/2] " Mengshi Wu
@ 2026-01-27 10:15 ` Bartosz Golaszewski
0 siblings, 0 replies; 6+ messages in thread
From: Bartosz Golaszewski @ 2026-01-27 10:15 UTC (permalink / raw)
To: Mengshi Wu
Cc: linux-arm-msm, linux-bluetooth, linux-kernel, shuai.zhang,
cheng.jiang, chezhou, wei.deng, yiboz, Dmitry Baryshkov,
Bartosz Golaszewski, Marcel Holtmann, Luiz Augusto von Dentz
On Tue, 27 Jan 2026 03:54:22 +0100, Mengshi Wu
<mengshi.wu@oss.qualcomm.com> said:
> Replace SoC-specific check with capability-based approach for HFP
> hardware offload configuration. Add QCA_CAP_HFP_HW_OFFLOAD capability
> flag and support_hfp_hw_offload field to qca_serdev structure. Add
> QCA_CAP_HFP_HW_OFFLOAD capability flag to QCA2066 device data
> structures.
>
> Reviewed-by: Dmitry Baryshkov <dmitry.baryshkov@oss.qualcomm.com>
> Signed-off-by: Mengshi Wu <mengshi.wu@oss.qualcomm.com>
> ---
Acked-by: Bartosz Golaszewski <bartosz.golaszewski@oss.qualcomm.com>
^ permalink raw reply [flat|nested] 6+ messages in thread
* [PATCH v3 2/2] Bluetooth: hci_qca: Enable HFP hardware offload for WCN6855 and WCN7850
2026-01-27 2:54 [PATCH v3 0/2] Bluetooth: hci_qca: Refactor HFP hardware offload capability handling Mengshi Wu
2026-01-27 2:54 ` [PATCH v3 1/2] " Mengshi Wu
@ 2026-01-27 2:54 ` Mengshi Wu
2026-01-27 10:15 ` Bartosz Golaszewski
2026-01-29 18:20 ` [PATCH v3 0/2] Bluetooth: hci_qca: Refactor HFP hardware offload capability handling patchwork-bot+bluetooth
2 siblings, 1 reply; 6+ messages in thread
From: Mengshi Wu @ 2026-01-27 2:54 UTC (permalink / raw)
To: Bartosz Golaszewski, Marcel Holtmann, Luiz Augusto von Dentz
Cc: linux-arm-msm, linux-bluetooth, linux-kernel, shuai.zhang,
cheng.jiang, chezhou, wei.deng, yiboz, Mengshi Wu
Add QCA_CAP_HFP_HW_OFFLOAD capability flag to WCN6855 and WCN7850
device data structures to enable Hands-Free Profile (HFP) hardware
offload support on these Qualcomm Bluetooth chipsets.
Signed-off-by: Mengshi Wu <mengshi.wu@oss.qualcomm.com>
---
drivers/bluetooth/hci_qca.c | 6 ++++--
1 file changed, 4 insertions(+), 2 deletions(-)
diff --git a/drivers/bluetooth/hci_qca.c b/drivers/bluetooth/hci_qca.c
index b99fdda88..6b4784dee 100644
--- a/drivers/bluetooth/hci_qca.c
+++ b/drivers/bluetooth/hci_qca.c
@@ -2155,7 +2155,8 @@ static const struct qca_device_data qca_soc_data_wcn6855 __maybe_unused = {
{ "vddrfa1p2", 257000 },
},
.num_vregs = 6,
- .capabilities = QCA_CAP_WIDEBAND_SPEECH | QCA_CAP_VALID_LE_STATES,
+ .capabilities = QCA_CAP_WIDEBAND_SPEECH | QCA_CAP_VALID_LE_STATES |
+ QCA_CAP_HFP_HW_OFFLOAD,
};
static const struct qca_device_data qca_soc_data_wcn7850 __maybe_unused = {
@@ -2169,7 +2170,8 @@ static const struct qca_device_data qca_soc_data_wcn7850 __maybe_unused = {
{ "vddrfa1p9", 302000 },
},
.num_vregs = 6,
- .capabilities = QCA_CAP_WIDEBAND_SPEECH | QCA_CAP_VALID_LE_STATES,
+ .capabilities = QCA_CAP_WIDEBAND_SPEECH | QCA_CAP_VALID_LE_STATES |
+ QCA_CAP_HFP_HW_OFFLOAD,
};
static void qca_power_shutdown(struct hci_uart *hu)
--
2.34.1
^ permalink raw reply related [flat|nested] 6+ messages in thread* Re: [PATCH v3 2/2] Bluetooth: hci_qca: Enable HFP hardware offload for WCN6855 and WCN7850
2026-01-27 2:54 ` [PATCH v3 2/2] Bluetooth: hci_qca: Enable HFP hardware offload for WCN6855 and WCN7850 Mengshi Wu
@ 2026-01-27 10:15 ` Bartosz Golaszewski
0 siblings, 0 replies; 6+ messages in thread
From: Bartosz Golaszewski @ 2026-01-27 10:15 UTC (permalink / raw)
To: Mengshi Wu
Cc: linux-arm-msm, linux-bluetooth, linux-kernel, shuai.zhang,
cheng.jiang, chezhou, wei.deng, yiboz, Bartosz Golaszewski,
Marcel Holtmann, Luiz Augusto von Dentz
On Tue, 27 Jan 2026 03:54:23 +0100, Mengshi Wu
<mengshi.wu@oss.qualcomm.com> said:
> Add QCA_CAP_HFP_HW_OFFLOAD capability flag to WCN6855 and WCN7850
> device data structures to enable Hands-Free Profile (HFP) hardware
> offload support on these Qualcomm Bluetooth chipsets.
>
> Signed-off-by: Mengshi Wu <mengshi.wu@oss.qualcomm.com>
> ---
> drivers/bluetooth/hci_qca.c | 6 ++++--
> 1 file changed, 4 insertions(+), 2 deletions(-)
>
> diff --git a/drivers/bluetooth/hci_qca.c b/drivers/bluetooth/hci_qca.c
> index b99fdda88..6b4784dee 100644
> --- a/drivers/bluetooth/hci_qca.c
> +++ b/drivers/bluetooth/hci_qca.c
> @@ -2155,7 +2155,8 @@ static const struct qca_device_data qca_soc_data_wcn6855 __maybe_unused = {
> { "vddrfa1p2", 257000 },
> },
> .num_vregs = 6,
> - .capabilities = QCA_CAP_WIDEBAND_SPEECH | QCA_CAP_VALID_LE_STATES,
> + .capabilities = QCA_CAP_WIDEBAND_SPEECH | QCA_CAP_VALID_LE_STATES |
> + QCA_CAP_HFP_HW_OFFLOAD,
> };
>
> static const struct qca_device_data qca_soc_data_wcn7850 __maybe_unused = {
> @@ -2169,7 +2170,8 @@ static const struct qca_device_data qca_soc_data_wcn7850 __maybe_unused = {
> { "vddrfa1p9", 302000 },
> },
> .num_vregs = 6,
> - .capabilities = QCA_CAP_WIDEBAND_SPEECH | QCA_CAP_VALID_LE_STATES,
> + .capabilities = QCA_CAP_WIDEBAND_SPEECH | QCA_CAP_VALID_LE_STATES |
> + QCA_CAP_HFP_HW_OFFLOAD,
> };
>
> static void qca_power_shutdown(struct hci_uart *hu)
> --
> 2.34.1
>
>
Acked-by: Bartosz Golaszewski <bartosz.golaszewski@oss.qualcomm.com>
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: [PATCH v3 0/2] Bluetooth: hci_qca: Refactor HFP hardware offload capability handling
2026-01-27 2:54 [PATCH v3 0/2] Bluetooth: hci_qca: Refactor HFP hardware offload capability handling Mengshi Wu
2026-01-27 2:54 ` [PATCH v3 1/2] " Mengshi Wu
2026-01-27 2:54 ` [PATCH v3 2/2] Bluetooth: hci_qca: Enable HFP hardware offload for WCN6855 and WCN7850 Mengshi Wu
@ 2026-01-29 18:20 ` patchwork-bot+bluetooth
2 siblings, 0 replies; 6+ messages in thread
From: patchwork-bot+bluetooth @ 2026-01-29 18:20 UTC (permalink / raw)
To: Mengshi Wu
Cc: brgl, marcel, luiz.dentz, linux-arm-msm, linux-bluetooth,
linux-kernel, shuai.zhang, cheng.jiang, chezhou, wei.deng, yiboz
Hello:
This series was applied to bluetooth/bluetooth-next.git (master)
by Luiz Augusto von Dentz <luiz.von.dentz@intel.com>:
On Tue, 27 Jan 2026 10:54:21 +0800 you wrote:
> Changes from v3:
> - Add QCA_CAP_HFP_HW_OFFLOAD capability flag to WCN7850
>
> Changes from v2:
> - Add QCA_CAP_HFP_HW_OFFLOAD capability flag at first commit to avoid
> breaking original logic.
> - Link to v2:
> https://lore.kernel.org/all/20260126162444.4194293-1-mengshi.wu@oss.qualcomm.com/
>
> [...]
Here is the summary with links:
- [v3,1/2] Bluetooth: hci_qca: Refactor HFP hardware offload capability handling
https://git.kernel.org/bluetooth/bluetooth-next/c/2241cc90a694
- [v3,2/2] Bluetooth: hci_qca: Enable HFP hardware offload for WCN6855 and WCN7850
https://git.kernel.org/bluetooth/bluetooth-next/c/0393a2959963
You are awesome, thank you!
--
Deet-doot-dot, I am a bot.
https://korg.docs.kernel.org/patchwork/pwbot.html
^ permalink raw reply [flat|nested] 6+ messages in thread