Lines Matching refs:remaining

54 static struct net_buf *hci_ipc_cmd_recv(uint8_t *data, size_t remaining)  in hci_ipc_cmd_recv()  argument
59 if (remaining < sizeof(*hdr)) { in hci_ipc_cmd_recv()
67 remaining -= sizeof(*hdr); in hci_ipc_cmd_recv()
73 if (remaining != hdr->param_len) { in hci_ipc_cmd_recv()
79 if (remaining > net_buf_tailroom(buf)) { in hci_ipc_cmd_recv()
86 net_buf_add_mem(buf, data, remaining); in hci_ipc_cmd_recv()
91 static struct net_buf *hci_ipc_acl_recv(uint8_t *data, size_t remaining) in hci_ipc_acl_recv() argument
96 if (remaining < sizeof(*hdr)) { in hci_ipc_acl_recv()
104 remaining -= sizeof(*hdr); in hci_ipc_acl_recv()
110 if (remaining != sys_le16_to_cpu(hdr->len)) { in hci_ipc_acl_recv()
116 if (remaining > net_buf_tailroom(buf)) { in hci_ipc_acl_recv()
122 LOG_DBG("len %u", remaining); in hci_ipc_acl_recv()
123 net_buf_add_mem(buf, data, remaining); in hci_ipc_acl_recv()
128 static struct net_buf *hci_ipc_iso_recv(uint8_t *data, size_t remaining) in hci_ipc_iso_recv() argument
133 if (remaining < sizeof(*hdr)) { in hci_ipc_iso_recv()
141 remaining -= sizeof(*hdr); in hci_ipc_iso_recv()
147 if (remaining != bt_iso_hdr_len(sys_le16_to_cpu(hdr->len))) { in hci_ipc_iso_recv()
153 if (remaining > net_buf_tailroom(buf)) { in hci_ipc_iso_recv()
159 LOG_DBG("len %zu", remaining); in hci_ipc_iso_recv()
160 net_buf_add_mem(buf, data, remaining); in hci_ipc_iso_recv()
169 size_t remaining = len; in hci_ipc_rx() local
174 remaining -= sizeof(pkt_indicator); in hci_ipc_rx()
178 buf = hci_ipc_cmd_recv(data, remaining); in hci_ipc_rx()
182 buf = hci_ipc_acl_recv(data, remaining); in hci_ipc_rx()
186 buf = hci_ipc_iso_recv(data, remaining); in hci_ipc_rx()