| From 6b47471bad4ae8c81b835c2f20158e306701e6b9 Mon Sep 17 00:00:00 2001 |
| From: Ying Hsu <yinghsu@chromium.org> |
| Date: Thu, 23 Jun 2022 15:32:34 +0800 |
| Subject: [PATCH] Revert "UPSTREAM: Bluetooth: hci_qca: Add device_may_wakeup |
| support" |
| |
| This reverts commit dc4ca4f431f8588cd7dcf1af9da4bc0dac42c7fd. |
| |
| Reason for revert: it breaks wake-on-bt on trogdor |
| |
| BUG=b:235991191 |
| TEST=Verified on trogdor |
| |
| Signed-off-by: Ying Hsu <yinghsu@chromium.org> |
| Signed-off-by: Zhengping Jiang <jiangzp@google.com> |
| --- |
| drivers/bluetooth/hci_qca.c | 16 +--------------- |
| 1 file changed, 1 insertion(+), 15 deletions(-) |
| |
| diff --git a/drivers/bluetooth/hci_qca.c b/drivers/bluetooth/hci_qca.c |
| index 6eddc23e49d9a7dc30eb24d6614e0402baa6bd91..b87151f9a60cc554b7cf8064ff77bcccddd6b3d4 100644 |
| --- a/drivers/bluetooth/hci_qca.c |
| +++ b/drivers/bluetooth/hci_qca.c |
| @@ -1583,20 +1583,6 @@ static void qca_cmd_timeout(struct hci_dev *hdev) |
| mutex_unlock(&qca->hci_memdump_lock); |
| } |
| |
| -static bool qca_wakeup(struct hci_dev *hdev) |
| -{ |
| - struct hci_uart *hu = hci_get_drvdata(hdev); |
| - bool wakeup; |
| - |
| - /* UART driver handles the interrupt from BT SoC.So we need to use |
| - * device handle of UART driver to get the status of device may wakeup. |
| - */ |
| - wakeup = device_may_wakeup(hu->serdev->ctrl->dev.parent); |
| - bt_dev_dbg(hu->hdev, "wakeup status : %d", wakeup); |
| - |
| - return wakeup; |
| -} |
| - |
| static int qca_regulator_init(struct hci_uart *hu) |
| { |
| enum qca_btsoc_type soc_type = qca_soc_type(hu); |
| @@ -1772,7 +1758,7 @@ static int qca_setup(struct hci_uart *hu) |
| hu->hdev->hw_error = qca_hw_error; |
| hu->hdev->cmd_timeout = qca_cmd_timeout; |
| if (device_can_wakeup(hu->serdev->ctrl->dev.parent)) |
| - hu->hdev->wakeup = qca_wakeup; |
| + |
| } else if (ret == -ENOENT) { |
| /* No patch/nvm-config found, run with original fw/config */ |
| set_bit(QCA_ROM_FW, &qca->flags); |
| -- |
| 2.39.0.314.g84b9a713c41-goog |
| |