lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite for Android: free password hash cracker in your pocket
[<prev] [next>] [day] [month] [year] [list]
Message-Id: <7687c4239424f2a49c6c596d19eea8dd7ebe8a30.1678226070.git.len.brown@intel.com>
Date:   Tue,  7 Mar 2023 15:56:06 -0600
From:   Len Brown <len.brown@...el.com>
To:     rafael@...nel.org
Cc:     linux-pm@...r.kernel.org, Len Brown <len.brown@...el.com>,
        Marcel Holtmann <marcel@...tmann.org>,
        Johan Hedberg <johan.hedberg@...il.com>,
        Luiz Augusto von Dentz <luiz.dentz@...il.com>,
        linux-bluetooth@...r.kernel.org, linux-kernel@...r.kernel.org
Subject: [PATCH 1/1] hci_qca: do not interfere with system suspend

When hci_qca returns an error to its pm_ops.suspend routine,
the PM subsystem will terminate the system wide suspend.

It is extremely unlikely that there will ever be a justification
for hci_qca, no matter what its internal malfunction, should
cause system-wide suspend to terminate.

Doing so, could result in the scenario where a laptop lid is closed,
suspend termnates, the user places the running laptop into a breifcase,
not expecting it to be overheating or draining its battery...

This is not a theoretical issue.
The 6.3-rc1 currently fails this way on the Dell XPS-13-9310:

Bluetooth: hci0: SSR or FW download time out
hci_uart_qca serial0-0: PM: dpm_run_callback(): acpi_subsys_suspend+0x0/0x70 returns -110
hci_uart_qca serial0-0: PM: failed to suspend: error -110
PM: suspend of devices aborted after 3218.724 msecs
PM: start suspend of devices aborted after 3246.859 msecs
PM: Some devices failed to suspend, or early wake event detected
PM: resume of devices complete after 84.988 msecs

Signed-off-by: Len Brown <len.brown@...el.com>
Cc: Marcel Holtmann <marcel@...tmann.org>
Cc: Johan Hedberg <johan.hedberg@...il.com>
Cc: Luiz Augusto von Dentz <luiz.dentz@...il.com>
Cc: linux-bluetooth@...r.kernel.org
Cc: linux-kernel@...r.kernel.org
---
 drivers/bluetooth/hci_qca.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/bluetooth/hci_qca.c b/drivers/bluetooth/hci_qca.c
index 3df8c3606e93..1795cc527b88 100644
--- a/drivers/bluetooth/hci_qca.c
+++ b/drivers/bluetooth/hci_qca.c
@@ -2309,7 +2309,7 @@ static int __maybe_unused qca_suspend(struct device *dev)
 error:
 	clear_bit(QCA_SUSPENDING, &qca->flags);
 
-	return ret;
+	return 0;
 }
 
 static int __maybe_unused qca_resume(struct device *dev)
-- 
2.37.2

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ