[bug report] Bluetooth: btusb: Add support for Qualcomm multi-subsystem QCC2072
From: Dan Carpenter <hidden>
Date: 2026-09-17 19:15:28
Hello Zijun Hu,
Commit 2e63b55654e0 ("Bluetooth: btusb: Add support for Qualcomm
multi-subsystem QCC2072") from Sep 13, 2026 (linux-next), leads to
the following Smatch static checker warning:
drivers/bluetooth/btusb_qcom.c:2516 btqcom_set_bdaddr()
warn: passing positive error code '(-4095)-(-62),(-60)-(-1),1-255' to 'ERR_PTR'
drivers/bluetooth/btusb_qcom.c
2507 *
2508 * Return: 0 on success, or a negative errno on failure.
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
2509 */
2510 static int btqcom_set_bdaddr(struct hci_dev *hdev, const bdaddr_t *bdaddr)
2511 {
2512 int ret;
2513
2514 ret = __hci_reset_sync(hdev);
2515 if (ret) {
--> 2516 bt_dev_err(hdev, "HCI reset before setting BD_ADDR failed: %pe",
2517 ERR_PTR(ret));
2518 return ret;
ret comes from skb->data in __hci_cmd_sync_status_sk() so it's a u8 and
not necessarily a negative error code.
2519 }
2520
2521 ret = qbt_write_bda(hdev, bdaddr);
2522
2523 return ret;
2524 }
This email is a free service from the Smatch-CI project [smatch.sf.net].
regards,
dan carpenter