Bluetooth: btnxpuart: Simplify nxp_recv_acl_pkt() by hci_acl_handle()

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

__u16 handle = __le16_to_cpu(hci_acl_hdr(skb)->handle);
... (handle & 0x0FFF) ...

Reviewed-by: Neeraj Sanjay Kale <neeraj.sanjaykale@nxp.com>
Signed-off-by: Zijun Hu <zijun.hu@oss.qualcomm.com>
Signed-off-by: Luiz Augusto von Dentz <luiz.von.dentz@intel.com>
This commit is contained in:
Zijun Hu 2026-09-15 19:17:17 -07:00 committed by Luiz Augusto von Dentz
parent 10038da922
commit 589b80b654

View File

@ -1407,10 +1407,8 @@ static int nxp_process_fw_dump(struct hci_dev *hdev, struct sk_buff *skb)
static int nxp_recv_acl_pkt(struct hci_dev *hdev, struct sk_buff *skb)
{
__u16 handle = __le16_to_cpu(hci_acl_hdr(skb)->handle);
/* FW dump chunks are ACL packets with conn handle 0xfff */
if ((handle & 0x0FFF) == 0xFFF)
if (hci_acl_handle(skb) == 0xFFF)
return nxp_process_fw_dump(hdev, skb);
else
return hci_recv_frame(hdev, skb);