Skip to contentSkip to conversation

Bluetooth: btintel: Don't log unsupported debug features as an error

PATCH In review Hex Lindqvist 2 participants 2 messages Nov 13 – Nov 14 Bluetooth drivers

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 Bluetooth: btintel: Don't log unsupported debug features as an error

Since commit af395330abed ("Bluetooth: btintel: Add Intel devcoredump support"), setup sends Read Supported Features (0xfca6) to decide whether to register devcoredump. Older controllers such as the 8260 and 8265 reject it with Command Disallowed, so every probe logs:

Bluetooth: hci0: Reading supported features failed (-16)
Bluetooth: hci0: Error reading debug features

This is harmless: it happens after the firmware is loaded and only means devcoredump is not registered.

Log the failure at debug level there, and keep the error in btintel_set_quality_report(), where the user asked for the feature.

Tested on an 8265 (8087:0a2b): the messages are gone and Bluetooth works as before.

AI was used to help write and test this patch.

Fixes af395330abed ("Bluetooth: btintel: Add Intel devcoredump support")
---
 drivers/bluetooth/btintel.c | 11 +++++------
 1 file changed, 5 insertions(+), 6 deletions(-)
drivers/bluetooth/btintel.c +5 -6
index a0aa110f4cdd..31dec65d3327 100644
@@ -1532,11 +1532,8 @@ static int btintel_read_debug_features(struct hci_dev *hdev,
 	 */
 	skb = __hci_cmd_sync(hdev, 0xfca6, sizeof(page_no), &page_no,
 			     HCI_INIT_TIMEOUT);
-	if (IS_ERR(skb)) {
-		bt_dev_err(hdev, "Reading supported features failed (%ld)",
-			   PTR_ERR(skb));
+	if (IS_ERR(skb))
 		return PTR_ERR(skb);
-	}
 
 	if (skb->len != (sizeof(features->page1) + 3)) {
 		bt_dev_err(hdev, "Supported features event size mismatch");
@@ -1653,8 +1650,10 @@ int btintel_set_quality_report(struct hci_dev *hdev, bool enable)
 	 * supported, need to load the additional DDC config to enable.
 	 */
 	err = btintel_read_debug_features(hdev, &features);
-	if (err)
+	if (err) {
+		bt_dev_err(hdev, "Reading supported features failed (%d)", err);
 		return err;
+	}
 
 	/* Set or reset the debug features. */
 	if (enable)
@@ -1705,7 +1704,7 @@ static int btintel_register_devcoredump_support(struct hci_dev *hdev)
 
 	err = btintel_read_debug_features(hdev, &features);
 	if (err) {
-		bt_dev_info(hdev, "Error reading debug features");
+		bt_dev_dbg(hdev, "Reading supported features failed (%d)", err);
 		return err;
 	}
 

base-commit: da3cc02587c629420603df4395179ec82955c941

Signature · 1 line
2.56.0
#1 lore raw

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/series/1211023/

---Test result---

Test Summary:

CheckPatch                    PASS      0.69 seconds
VerifyFixes                   PASS      0.12 seconds
VerifySignedoff               PASS      0.12 seconds
GitLint                       PASS      0.32 seconds
SubjectPrefix                 PASS      0.12 seconds
BuildKernel                   PASS      28.68 seconds
CheckAllWarning               PASS      31.77 seconds
CheckSparse                   PASS      34.01 seconds
BuildKernel32                 PASS      28.16 seconds
CheckKernelLLVM               PASS      28.60 seconds
TestRunnerSetup               PASS      672.61 seconds
IncrementalBuild              PASS      25.86 seconds

https://github.com/bluez/bluetooth-next/pull/1132

---
Regards,
Linux Bluetooth