* [PATCH v1] Bluetooth: hci_qca: Not send vendor pre-shutdown command for QCA Rome
@ 2020-02-29 12:21 Rocky Liao
2020-03-01 2:32 ` Marcel Holtmann
0 siblings, 1 reply; 2+ messages in thread
From: Rocky Liao @ 2020-02-29 12:21 UTC (permalink / raw)
To: marcel, johan.hedberg
Cc: mka, linux-kernel, linux-bluetooth, linux-arm-msm, bgodavar, Rocky Liao
QCA Rome doesn't support the pre-shutdown vendor hci command, this patch
will check the soc type in qca_power_off() and only send this command
for wcn399x.
Fixes: ae563183b647 ("Bluetooth: hci_qca: Enable power off/on support during hci down/up for QCA Rome")
Signed-off-by: Rocky Liao <rjliao@codeaurora.org>
---
drivers/bluetooth/hci_qca.c | 4 +++-
1 file changed, 3 insertions(+), 1 deletion(-)
diff --git a/drivers/bluetooth/hci_qca.c b/drivers/bluetooth/hci_qca.c
index 1e4d6118d9bf..bf436d6e638e 100644
--- a/drivers/bluetooth/hci_qca.c
+++ b/drivers/bluetooth/hci_qca.c
@@ -1759,9 +1759,11 @@ static int qca_power_off(struct hci_dev *hdev)
{
struct hci_uart *hu = hci_get_drvdata(hdev);
struct qca_data *qca = hu->priv;
+ enum qca_btsoc_type soc_type = qca_soc_type(hu);
/* Stop sending shutdown command if soc crashes. */
- if (qca->memdump_state == QCA_MEMDUMP_IDLE) {
+ if (qca_is_wcn399x(soc_type)
+ && qca->memdump_state == QCA_MEMDUMP_IDLE) {
qca_send_pre_shutdown_cmd(hdev);
usleep_range(8000, 10000);
}
--
The Qualcomm Innovation Center, Inc. is a member of the Code Aurora Forum, a Linux Foundation Collaborative Project
^ permalink raw reply related [flat|nested] 2+ messages in thread
* Re: [PATCH v1] Bluetooth: hci_qca: Not send vendor pre-shutdown command for QCA Rome
2020-02-29 12:21 [PATCH v1] Bluetooth: hci_qca: Not send vendor pre-shutdown command for QCA Rome Rocky Liao
@ 2020-03-01 2:32 ` Marcel Holtmann
0 siblings, 0 replies; 2+ messages in thread
From: Marcel Holtmann @ 2020-03-01 2:32 UTC (permalink / raw)
To: Rocky Liao
Cc: Johan Hedberg, Matthias Kaehlcke, LKML, Bluez mailing list, MSM,
bgodavar
Hi Rocky,
> QCA Rome doesn't support the pre-shutdown vendor hci command, this patch
> will check the soc type in qca_power_off() and only send this command
> for wcn399x.
>
> Fixes: ae563183b647 ("Bluetooth: hci_qca: Enable power off/on support during hci down/up for QCA Rome")
> Signed-off-by: Rocky Liao <rjliao@codeaurora.org>
> ---
> drivers/bluetooth/hci_qca.c | 4 +++-
> 1 file changed, 3 insertions(+), 1 deletion(-)
patch has been applied to bluetooth-next tree.
Regards
Marcel
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2020-03-01 2:32 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-02-29 12:21 [PATCH v1] Bluetooth: hci_qca: Not send vendor pre-shutdown command for QCA Rome Rocky Liao
2020-03-01 2:32 ` Marcel Holtmann
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).