diff options
author | Kiran K <kiran.k@intel.com> | 2024-05-11 11:10:59 +0530 |
---|---|---|
committer | Luiz Augusto von Dentz <luiz.von.dentz@intel.com> | 2024-05-14 10:58:30 -0400 |
commit | 6a486c1361ea588938898ae812b32dcfbd4022f2 (patch) | |
tree | ac466be74174512bc700c304d0cea4c599a65280 /drivers/bluetooth/btintel_pcie.c | |
parent | e5a43efba2560d617b06e59dc10d2f9de7d08e5f (diff) |
Bluetooth: btintel_pcie: Refactor and code cleanup
Minor refactor and s/TX_WAIT_TIMEOUT_MS/BTINTEL_PCIE_TX_WAIT_TIMEOUT_MS/g.
Fixes: 6e65a09f9275 ("Bluetooth: btintel_pcie: Add *setup* function to download firmware")
Signed-off-by: Kiran K <kiran.k@intel.com>
Signed-off-by: Luiz Augusto von Dentz <luiz.von.dentz@intel.com>
Diffstat (limited to 'drivers/bluetooth/btintel_pcie.c')
-rw-r--r-- | drivers/bluetooth/btintel_pcie.c | 7 |
1 files changed, 3 insertions, 4 deletions
diff --git a/drivers/bluetooth/btintel_pcie.c b/drivers/bluetooth/btintel_pcie.c index 030a75e5d2a3..5b6805d87fcf 100644 --- a/drivers/bluetooth/btintel_pcie.c +++ b/drivers/bluetooth/btintel_pcie.c @@ -151,7 +151,7 @@ static int btintel_pcie_send_sync(struct btintel_pcie_data *data, /* Wait for the complete interrupt - URBD0 */ ret = wait_event_timeout(data->tx_wait_q, data->tx_wait_done, - msecs_to_jiffies(TX_WAIT_TIMEOUT_MS)); + msecs_to_jiffies(BTINTEL_PCIE_TX_WAIT_TIMEOUT_MS)); if (!ret) return -ETIME; @@ -1096,10 +1096,9 @@ static int btintel_pcie_send_frame(struct hci_dev *hdev, hdev->stat.err_tx++; bt_dev_err(hdev, "Failed to send frame (%d)", ret); goto exit_error; - } else { - hdev->stat.byte_tx += skb->len; - kfree_skb(skb); } + hdev->stat.byte_tx += skb->len; + kfree_skb(skb); exit_error: return ret; |