diff options
author | Kiran <[email protected]> | 2024-07-26 16:13:26 +0530 |
---|---|---|
committer | Luiz Augusto von Dentz <[email protected]> | 2024-09-10 12:43:28 -0400 |
commit | 861da2c11c64abe706a8d39645bbcd3141c2efb5 (patch) | |
tree | bac142c30ffef8f9edaa93d711482b94a0203ea6 | |
parent | 29aeb4e8918e6aeeaf0bb7a03b000a73596d54a3 (diff) |
Bluetooth: btintel_pcie: Add support for ISO data
Add support for handling ISO RX and TX packets.
Signed-off-by: Kiran <[email protected]>
Signed-off-by: Luiz Augusto von Dentz <[email protected]>
-rw-r--r-- | drivers/bluetooth/btintel_pcie.c | 16 |
1 files changed, 16 insertions, 0 deletions
diff --git a/drivers/bluetooth/btintel_pcie.c b/drivers/bluetooth/btintel_pcie.c index 1c7631f22c52..d255bdf777b4 100644 --- a/drivers/bluetooth/btintel_pcie.c +++ b/drivers/bluetooth/btintel_pcie.c @@ -46,6 +46,7 @@ MODULE_DEVICE_TABLE(pci, btintel_pcie_table); #define BTINTEL_PCIE_HCI_ACL_PKT 0x00000002 #define BTINTEL_PCIE_HCI_SCO_PKT 0x00000003 #define BTINTEL_PCIE_HCI_EVT_PKT 0x00000004 +#define BTINTEL_PCIE_HCI_ISO_PKT 0x00000005 static inline void ipc_print_ia_ring(struct hci_dev *hdev, struct ia *ia, u16 queue_num) @@ -423,6 +424,18 @@ static int btintel_pcie_recv_frame(struct btintel_pcie_data *data, goto exit_error; } break; + + case BTINTEL_PCIE_HCI_ISO_PKT: + if (skb->len >= HCI_ISO_HDR_SIZE) { + plen = HCI_ISO_HDR_SIZE + __le16_to_cpu(hci_iso_hdr(skb)->dlen); + pkt_type = HCI_ISODATA_PKT; + } else { + bt_dev_err(hdev, "ISO packet is too short"); + ret = -EILSEQ; + goto exit_error; + } + break; + default: bt_dev_err(hdev, "Invalid packet type received: 0x%4.4x", pcie_pkt_type); @@ -1082,6 +1095,9 @@ static int btintel_pcie_send_frame(struct hci_dev *hdev, type = BTINTEL_PCIE_HCI_SCO_PKT; hdev->stat.sco_tx++; break; + case HCI_ISODATA_PKT: + type = BTINTEL_PCIE_HCI_ISO_PKT; + break; default: bt_dev_err(hdev, "Unknown HCI packet type"); return -EILSEQ; |