[PATCH 09/11] Bluetooth: btintel: Simplify btintel_classify_pkt_type() by hci_acl_handle()

From: Zijun Hu

Date: Sat Jul 25 2026 - 04:58:45 EST


Simplify btintel_classify_pkt_type() by using hci_acl_handle() instead of:

__u16 handle = __le16_to_cpu(hci_acl_hdr(skb)->handle);
... hci_handle(handle) ...

Signed-off-by: Zijun Hu <zijun.hu@xxxxxxxxxxxxxxxx>
---
drivers/bluetooth/btintel.c | 4 +---
1 file changed, 1 insertion(+), 3 deletions(-)

diff --git a/drivers/bluetooth/btintel.c b/drivers/bluetooth/btintel.c
index dbcb3f138477..87a6a11e5b59 100644
--- a/drivers/bluetooth/btintel.c
+++ b/drivers/bluetooth/btintel.c
@@ -2740,19 +2740,17 @@ static void btintel_set_dsm_reset_method(struct hci_dev *hdev,

static u8 btintel_classify_pkt_type(struct hci_dev *hdev, struct sk_buff *skb)
{
/*
* Distinguish ISO data packets form ACL data packets
* based on their connection handle value range.
*/
if (iso_capable(hdev) && hci_skb_pkt_type(skb) == HCI_ACLDATA_PKT) {
- __u16 handle = __le16_to_cpu(hci_acl_hdr(skb)->handle);
-
- if (hci_handle(handle) >= BTINTEL_ISODATA_HANDLE_BASE)
+ if (hci_acl_handle(skb) >= BTINTEL_ISODATA_HANDLE_BASE)
return HCI_ISODATA_PKT;
}

return hci_skb_pkt_type(skb);
}

/*
* UefiCnvCommonDSBR UEFI variable provides information from the OEM platforms

--
2.34.1