linux-bluetooth.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH v1 0/1] Bluetooth: hci_qca: only assign wakeup with serial port support
@ 2022-10-13 21:45 Zhengping Jiang
  2022-10-13 21:45 ` [PATCH v1 1/1] " Zhengping Jiang
  2022-10-13 22:30 ` [PATCH v1 0/1] " patchwork-bot+bluetooth
  0 siblings, 2 replies; 4+ messages in thread
From: Zhengping Jiang @ 2022-10-13 21:45 UTC (permalink / raw)
  To: linux-bluetooth, marcel, luiz.dentz
  Cc: Zhengping Jiang, Johan Hedberg, linux-kernel


This patch will check if the serial port supports wakeup before assigning
the hdev->wakeup callback. After landing the 'commit c1a74160eaf1a
("Bluetooth: hci_qca: Add device_may_wakeup support")', the wake-on-bt
was broken in Jacuzzi because the qca_wakeup returns false. In this case
it will fall back to the default hci_uart_wakeup.

Changes in v1:
- Check serial port support before assigning wakeup callback

Zhengping Jiang (1):
  Bluetooth: hci_qca: only assign wakeup with serial port support

 drivers/bluetooth/hci_qca.c | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

-- 
2.38.0.413.g74048e4d9e-goog


^ permalink raw reply	[flat|nested] 4+ messages in thread

* [PATCH v1 1/1] Bluetooth: hci_qca: only assign wakeup with serial port support
  2022-10-13 21:45 [PATCH v1 0/1] Bluetooth: hci_qca: only assign wakeup with serial port support Zhengping Jiang
@ 2022-10-13 21:45 ` Zhengping Jiang
  2022-10-13 22:10   ` bluez.test.bot
  2022-10-13 22:30 ` [PATCH v1 0/1] " patchwork-bot+bluetooth
  1 sibling, 1 reply; 4+ messages in thread
From: Zhengping Jiang @ 2022-10-13 21:45 UTC (permalink / raw)
  To: linux-bluetooth, marcel, luiz.dentz
  Cc: Zhengping Jiang, Johan Hedberg, linux-kernel

Only assign hdev->wakeup if the serial port supports wakeup. Otherwise
it will fall back to the hci_uart_wakeup or the behavior that can be
overridden before calling the hci_uart_register_device().

Signed-off-by: Zhengping Jiang <jiangzp@google.com>
---

Changes in v1:
- Check serial port support before assigning wakeup callback

 drivers/bluetooth/hci_qca.c | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/drivers/bluetooth/hci_qca.c b/drivers/bluetooth/hci_qca.c
index 8df11016fd51..dacb6f5efd29 100644
--- a/drivers/bluetooth/hci_qca.c
+++ b/drivers/bluetooth/hci_qca.c
@@ -1765,7 +1765,8 @@ static int qca_setup(struct hci_uart *hu)
 		qca_debugfs_init(hdev);
 		hu->hdev->hw_error = qca_hw_error;
 		hu->hdev->cmd_timeout = qca_cmd_timeout;
-		hu->hdev->wakeup = qca_wakeup;
+		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.38.0.413.g74048e4d9e-goog


^ permalink raw reply related	[flat|nested] 4+ messages in thread

* RE: Bluetooth: hci_qca: only assign wakeup with serial port support
  2022-10-13 21:45 ` [PATCH v1 1/1] " Zhengping Jiang
@ 2022-10-13 22:10   ` bluez.test.bot
  0 siblings, 0 replies; 4+ messages in thread
From: bluez.test.bot @ 2022-10-13 22:10 UTC (permalink / raw)
  To: linux-bluetooth, jiangzp

[-- Attachment #1: Type: text/plain, Size: 1259 bytes --]

This is automated email and please do not reply to this email!

Dear submitter,

Thank you for submitting the patches to the linux bluetooth mailing list.
This is a CI test results with your patch series:
PW Link:https://patchwork.kernel.org/project/bluetooth/list/?series=685198

---Test result---

Test Summary:
CheckPatch                    PASS      1.25 seconds
GitLint                       PASS      0.74 seconds
SubjectPrefix                 PASS      0.62 seconds
BuildKernel                   PASS      34.78 seconds
BuildKernel32                 PASS      30.82 seconds
Incremental Build with patchesPASS      43.19 seconds
TestRunner: Setup             PASS      516.57 seconds
TestRunner: l2cap-tester      PASS      17.46 seconds
TestRunner: iso-tester        PASS      16.66 seconds
TestRunner: bnep-tester       PASS      6.55 seconds
TestRunner: mgmt-tester       PASS      107.54 seconds
TestRunner: rfcomm-tester     PASS      10.42 seconds
TestRunner: sco-tester        PASS      9.87 seconds
TestRunner: ioctl-tester      PASS      11.18 seconds
TestRunner: mesh-tester       PASS      8.18 seconds
TestRunner: smp-tester        PASS      9.89 seconds
TestRunner: userchan-tester   PASS      6.85 seconds



---
Regards,
Linux Bluetooth


^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [PATCH v1 0/1] Bluetooth: hci_qca: only assign wakeup with serial port support
  2022-10-13 21:45 [PATCH v1 0/1] Bluetooth: hci_qca: only assign wakeup with serial port support Zhengping Jiang
  2022-10-13 21:45 ` [PATCH v1 1/1] " Zhengping Jiang
@ 2022-10-13 22:30 ` patchwork-bot+bluetooth
  1 sibling, 0 replies; 4+ messages in thread
From: patchwork-bot+bluetooth @ 2022-10-13 22:30 UTC (permalink / raw)
  To: Zhengping Jiang
  Cc: linux-bluetooth, marcel, luiz.dentz, johan.hedberg, linux-kernel

Hello:

This patch was applied to bluetooth/bluetooth-next.git (master)
by Luiz Augusto von Dentz <luiz.von.dentz@intel.com>:

On Thu, 13 Oct 2022 14:45:07 -0700 you wrote:
> This patch will check if the serial port supports wakeup before assigning
> the hdev->wakeup callback. After landing the 'commit c1a74160eaf1a
> ("Bluetooth: hci_qca: Add device_may_wakeup support")', the wake-on-bt
> was broken in Jacuzzi because the qca_wakeup returns false. In this case
> it will fall back to the default hci_uart_wakeup.
> 
> Changes in v1:
> - Check serial port support before assigning wakeup callback
> 
> [...]

Here is the summary with links:
  - [v1,1/1] Bluetooth: hci_qca: only assign wakeup with serial port support
    https://git.kernel.org/bluetooth/bluetooth-next/c/9fe208c7117d

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] 4+ messages in thread

end of thread, other threads:[~2022-10-13 22:30 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2022-10-13 21:45 [PATCH v1 0/1] Bluetooth: hci_qca: only assign wakeup with serial port support Zhengping Jiang
2022-10-13 21:45 ` [PATCH v1 1/1] " Zhengping Jiang
2022-10-13 22:10   ` bluez.test.bot
2022-10-13 22:30 ` [PATCH v1 0/1] " patchwork-bot+bluetooth

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).