* [PATCH] Bluetooth: hci_ll: check clk_prepare_enable() return value
@ 2026-08-28 7:23 Li Youhong
2026-08-28 12:12 ` bluez.test.bot
0 siblings, 1 reply; 2+ messages in thread
From: Li Youhong @ 2026-08-28 7:23 UTC (permalink / raw)
To: marcel, luiz.dentz; +Cc: linux-bluetooth, Li Youhong
From: Li Youhong <liyouhong@kylinos.cn>
ll_open() ignored clk_prepare_enable() failures for the optional
external clock and still reported success. Propagate the error and
free the privately allocated protocol state on failure.
Signed-off-by: Li Youhong <liyouhong@kylinos.cn>
---
drivers/bluetooth/hci_ll.c | 11 +++++++++--
1 file changed, 9 insertions(+), 2 deletions(-)
diff --git a/drivers/bluetooth/hci_ll.c b/drivers/bluetooth/hci_ll.c
index ab744001dafc..c2dca22d1eee 100644
--- a/drivers/bluetooth/hci_ll.c
+++ b/drivers/bluetooth/hci_ll.c
@@ -112,6 +112,7 @@ static int send_hcill_cmd(u8 cmd, struct hci_uart *hu)
static int ll_open(struct hci_uart *hu)
{
struct ll_struct *ll;
+ int err;
BT_DBG("hu %p", hu);
@@ -130,8 +131,14 @@ static int ll_open(struct hci_uart *hu)
if (hu->serdev) {
struct ll_device *lldev = serdev_device_get_drvdata(hu->serdev);
- if (!IS_ERR(lldev->ext_clk))
- clk_prepare_enable(lldev->ext_clk);
+ if (!IS_ERR(lldev->ext_clk)) {
+ err = clk_prepare_enable(lldev->ext_clk);
+ if (err) {
+ hu->priv = NULL;
+ kfree(ll);
+ return err;
+ }
+ }
}
return 0;
--
2.25.1
^ permalink raw reply related [flat|nested] 2+ messages in thread
* RE: Bluetooth: hci_ll: check clk_prepare_enable() return value
2026-08-28 7:23 [PATCH] Bluetooth: hci_ll: check clk_prepare_enable() return value Li Youhong
@ 2026-08-28 12:12 ` bluez.test.bot
0 siblings, 0 replies; 2+ messages in thread
From: bluez.test.bot @ 2026-08-28 12:12 UTC (permalink / raw)
To: linux-bluetooth, dayou5941
[-- Attachment #1: Type: text/plain, Size: 1181 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=1153025
---Test result---
Test Summary:
CheckPatch PASS 0.57 seconds
VerifyFixes PASS 0.11 seconds
VerifySignedoff PASS 0.11 seconds
GitLint PASS 0.26 seconds
SubjectPrefix PASS 0.10 seconds
BuildKernel PASS 22.57 seconds
CheckAllWarning PASS 24.55 seconds
CheckSparse PASS 22.80 seconds
BuildKernel32 PASS 21.37 seconds
CheckKernelLLVM SKIP 0.00 seconds
TestRunnerSetup PASS 385.01 seconds
IncrementalBuild PASS 21.53 seconds
Details
##############################
Test: CheckKernelLLVM - SKIP
Desc: Build kernel with LLVM + context analysis
Output:
Clang not found
https://github.com/bluez/bluetooth-next/pull/659
---
Regards,
Linux Bluetooth
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2026-08-28 12:12 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2026-08-28 7:23 [PATCH] Bluetooth: hci_ll: check clk_prepare_enable() return value Li Youhong
2026-08-28 12:12 ` bluez.test.bot
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox