Home
last modified time | relevance | path

Searched refs:payload_len (Results 1 – 25 of 56) sorted by relevance

123

/Zephyr-Core-3.7.0/subsys/net/lib/lwm2m/
Dlwm2m_rw_cbor.c99 int payload_len; in put_s64() local
107 payload_len = CPKT_CBOR_W_SZ(states[0].payload, out->out_cpkt); in put_s64()
108 out->out_cpkt->offset += payload_len; in put_s64()
111 payload_len = -ENOMEM; in put_s64()
114 return payload_len; in put_s64()
119 int payload_len; in put_s32() local
127 payload_len = CPKT_CBOR_W_SZ(states[0].payload, out->out_cpkt); in put_s32()
128 out->out_cpkt->offset += payload_len; in put_s32()
131 payload_len = -ENOMEM; in put_s32()
134 return payload_len; in put_s32()
[all …]
Dlwm2m_pull_context.c226 uint16_t payload_len, payload_offset, len; in do_firmware_transfer_reply_cb() local
285 payload_start = coap_packet_get_payload(response, &payload_len); in do_firmware_transfer_reply_cb()
286 if (payload_len > 0) { in do_firmware_transfer_reply_cb()
317 while (payload_len > 0) { in do_firmware_transfer_reply_cb()
318 len = (payload_len > write_buflen) ? write_buflen : payload_len; in do_firmware_transfer_reply_cb()
319 payload_len -= len; in do_firmware_transfer_reply_cb()
329 last_block && (payload_len == 0U), in do_firmware_transfer_reply_cb()
Dlwm2m_senml_cbor_decode.h24 int cbor_decode_lwm2m_senml(const uint8_t *payload, size_t payload_len, struct lwm2m_senml *result,
Dlwm2m_senml_cbor_encode.h24 int cbor_encode_lwm2m_senml(uint8_t *payload, size_t payload_len, const struct lwm2m_senml *input,
/Zephyr-Core-3.7.0/drivers/i3c/
Di3c_ibi_workq.c57 uint8_t *payload, size_t payload_len) in i3c_ibi_work_enqueue_target_irq() argument
73 ibi_node->payload.payload_len = payload_len; in i3c_ibi_work_enqueue_target_irq()
75 if ((payload != NULL) && (payload_len > 0U)) { in i3c_ibi_work_enqueue_target_irq()
77 payload, payload_len); in i3c_ibi_work_enqueue_target_irq()
105 ibi_node->payload.payload_len = 0; in i3c_ibi_work_enqueue_hotjoin()
154 ibi_node->payload.payload_len); in i3c_ibi_work_handler()
156 if (ibi_node->payload.payload_len > 0U) { in i3c_ibi_work_handler()
158 ibi_node->payload.payload_len, "IBI Payload"); in i3c_ibi_work_handler()
164 if (ibi_node->payload.payload_len != 0U) { in i3c_ibi_work_handler()
/Zephyr-Core-3.7.0/tests/net/lib/lwm2m/block_transfer/src/
Dmain.c123 uint16_t payload_len; in ZTEST_F() local
125 coap_packet_get_payload(&msg->cpkt, &payload_len); in ZTEST_F()
126 zassert_equal(payload_len, CONFIG_LWM2M_COAP_BLOCK_SIZE, in ZTEST_F()
138 const uint8_t *payload = coap_packet_get_payload(&msg->cpkt, &payload_len); in ZTEST_F()
141 zassert_equal(payload_len, CONFIG_LWM2M_COAP_BLOCK_SIZE, in ZTEST_F()
156 for (uint_fast8_t i = 0; i < payload_len; ++i) { in ZTEST_F()
161 zassert_equal(payload[payload_len], 0x00, "Byte after payload is wrong"); in ZTEST_F()
168 uint16_t payload_len; in ZTEST_F() local
209 const uint8_t *payload = coap_packet_get_payload(&msg->cpkt, &payload_len); in ZTEST_F()
212 zassert_equal(payload_len, CONFIG_LWM2M_COAP_BLOCK_SIZE, "Wrong payload size"); in ZTEST_F()
[all …]
/Zephyr-Core-3.7.0/subsys/net/l2/ieee802154/
Dieee802154_security.c103 uint8_t payload_len, uint8_t authtag_len, in prepare_cipher_aead_pkt() argument
115 pkt->in_buf = is_encrypted && payload_len ? frame + ll_hdr_len : NULL; in prepare_cipher_aead_pkt()
116 pkt->in_len = is_encrypted ? payload_len : 0; in prepare_cipher_aead_pkt()
119 uint8_t out_buf_offset = is_encrypted ? ll_hdr_len : ll_hdr_len + payload_len; in prepare_cipher_aead_pkt()
123 pkt->out_buf_max = (is_encrypted ? payload_len : 0) + authtag_len; in prepare_cipher_aead_pkt()
127 apkt->tag = is_authenticated ? frame + ll_hdr_len + payload_len : NULL; in prepare_cipher_aead_pkt()
132 uint8_t ll_hdr_len, uint8_t payload_len, uint8_t authtag_len, in ieee802154_decrypt_auth() argument
152 prepare_cipher_aead_pkt(frame, level, ll_hdr_len, payload_len, authtag_len, &apkt, &pkt); in ieee802154_decrypt_auth()
157 payload_len, frame_counter); in ieee802154_decrypt_auth()
165 uint8_t ll_hdr_len, uint8_t payload_len, uint8_t authtag_len, in ieee802154_encrypt_auth() argument
[all …]
Dieee802154_security.h36 uint8_t ll_hdr_len, uint8_t payload_len, uint8_t authtag_len,
51 uint8_t ll_hdr_len, uint8_t payload_len,
/Zephyr-Core-3.7.0/include/zephyr/drivers/i3c/
Dibi.h66 uint8_t payload_len; member
78 uint8_t payload_len; member
185 uint8_t *payload, size_t payload_len);
/Zephyr-Core-3.7.0/tests/net/icmpv4/src/
Dmain.c180 uint8_t payload_len; in verify_echo_reply() local
201 payload_len = sizeof(icmpv4_echo_req) - in verify_echo_reply()
203 if (payload_len != net_pkt_remaining_data(pkt)) { in verify_echo_reply()
207 ret = net_pkt_read(pkt, buf, payload_len); in verify_echo_reply()
214 payload_len)) { in verify_echo_reply()
233 uint8_t payload_len; in verify_echo_reply_with_opts() local
265 payload_len = sizeof(icmpv4_echo_req_opt) - in verify_echo_reply_with_opts()
267 if (payload_len != net_pkt_remaining_data(pkt)) { in verify_echo_reply_with_opts()
271 ret = net_pkt_read(pkt, buf, payload_len); in verify_echo_reply_with_opts()
279 payload_len)) { in verify_echo_reply_with_opts()
/Zephyr-Core-3.7.0/subsys/bluetooth/host/
Dtesting.c41 const void *payload, size_t payload_len) in bt_test_mesh_net_recv() argument
48 payload_len); in bt_test_mesh_net_recv()
54 size_t payload_len) in bt_test_mesh_model_recv() argument
60 cb->mesh_model_recv(src, dst, payload, payload_len); in bt_test_mesh_model_recv()
Dtesting.h14 const void *payload, size_t payload_len);
16 size_t payload_len);
/Zephyr-Core-3.7.0/drivers/bluetooth/hci/
Duserchan.c107 uint16_t payload_len = 0; in hci_packet_complete() local
117 payload_len = cmd->param_len; in hci_packet_complete()
125 payload_len = sys_le16_to_cpu(acl->len); in hci_packet_complete()
133 payload_len = sco->len; in hci_packet_complete()
141 payload_len = evt->len; in hci_packet_complete()
149 payload_len = bt_iso_hdr_len(sys_le16_to_cpu(iso->len)); in hci_packet_complete()
160 if (buf_len < header_len || buf_len - header_len < payload_len) { in hci_packet_complete()
164 return (int32_t)header_len + payload_len; in hci_packet_complete()
Dhci_nxp.c169 uint8_t payload_len; in bt_evt_recv() local
174 payload_len = data[1]; in bt_evt_recv()
183 if ((len - BT_HCI_EVT_HDR_SIZE) != payload_len) { in bt_evt_recv()
218 uint16_t payload_len; in bt_acl_recv() local
225 memcpy((void *)&payload_len, (void *)&data[2], 2); in bt_acl_recv()
226 if ((len - BT_HCI_ACL_HDR_SIZE) != payload_len) { in bt_acl_recv()
Dhci_nxp_setup.c562 uint32_t payload_len; in fw_upload_get_last_5bytes() local
576 payload_len = fw_upload_get_payload_length(buffer); in fw_upload_get_last_5bytes()
578 if ((len == CMD_HDR_LEN) || ((uint32_t)len == payload_len)) { in fw_upload_get_last_5bytes()
590 static void fw_upload_update_result(uint32_t payload_len, uint16_t *sending_len, in fw_upload_update_result() argument
597 *sending_len = payload_len; in fw_upload_update_result()
608 uint32_t payload_len; in fw_upload_write_hdr_and_payload() local
615 payload_len = fw_upload_get_payload_length(buffer); in fw_upload_write_hdr_and_payload()
624 fw_upload_update_result(payload_len, &sending_len, in fw_upload_write_hdr_and_payload()
650 sending_len = payload_len; in fw_upload_write_hdr_and_payload()
652 } else if (len_to_send == (payload_len + 1)) { in fw_upload_write_hdr_and_payload()
[all …]
/Zephyr-Core-3.7.0/include/zephyr/bluetooth/
Dtesting.h39 const void *payload, size_t payload_len);
41 size_t payload_len);
/Zephyr-Core-3.7.0/samples/net/sockets/coap_server/src/
Dtest.c129 uint16_t payload_len; in test_put() local
145 payload = coap_packet_get_payload(request, &payload_len); in test_put()
147 net_hexdump("PUT Payload", payload, payload_len); in test_put()
181 uint16_t payload_len; in test_post() local
197 payload = coap_packet_get_payload(request, &payload_len); in test_post()
199 net_hexdump("POST Payload", payload, payload_len); in test_post()
/Zephyr-Core-3.7.0/subsys/net/lib/websocket/
Dwebsocket.c607 uint8_t *payload, size_t payload_len, in websocket_prepare_and_send() argument
616 io_vector[1].iov_len = payload_len; in websocket_prepare_and_send()
625 if ((payload != NULL) && (payload_len > 0)) { in websocket_prepare_and_send()
626 LOG_HEXDUMP_DBG(payload, payload_len, "Payload"); in websocket_prepare_and_send()
652 int websocket_send_msg(int ws_sock, const uint8_t *payload, size_t payload_len, in websocket_send_msg() argument
685 NET_DBG("[%p] Len %zd %s/%d/%s", ctx, payload_len, opcode2str(opcode), in websocket_send_msg()
699 if (payload_len < 126) { in websocket_send_msg()
700 header[1] |= payload_len; in websocket_send_msg()
701 } else if (payload_len < 65536) { in websocket_send_msg()
703 header[2] = payload_len >> 8; in websocket_send_msg()
[all …]
/Zephyr-Core-3.7.0/drivers/lora/
Drylrxxx.c38 #define RYLR_PAYLOAD_LENGTH_FIELD_CHARS(payload_len) \ argument
39 (payload_len >= 100 ? 3 : (payload_len >= 10 ? 2 : 1))
40 #define RYLR_CMD_SEND_LENGTH(payload_len) \ argument
42 RYLR_PAYLOAD_LENGTH_FIELD_CHARS(payload_len) + payload_len)
366 int rylr_send(const struct device *dev, uint8_t *payload, uint32_t payload_len) in rylr_send() argument
370 int cmd_len = RYLR_CMD_SEND_LENGTH(payload_len); in rylr_send()
396 snprintf(data->cmd_buffer, cmd_len + 1, RYLR_CMD_SEND_FORMAT, payload_len, payload); in rylr_send()
409 int rylr_send_async(const struct device *dev, uint8_t *payload, uint32_t payload_len, in rylr_send_async() argument
436 cmd_len = RYLR_CMD_SEND_LENGTH(payload_len); in rylr_send_async()
451 snprintf(data->cmd_buffer, cmd_len + 1, RYLR_CMD_SEND_FORMAT, payload_len, payload); in rylr_send_async()
/Zephyr-Core-3.7.0/subsys/net/lib/coap/
Dcoap_client.c223 uint16_t payload_len; in coap_client_init_request() local
268 payload_len = internal_req->send_blk_ctx.total_size - in coap_client_init_request()
270 if (payload_len > block_in_bytes) { in coap_client_init_request()
271 payload_len = block_in_bytes; in coap_client_init_request()
275 payload_len = req->len; in coap_client_init_request()
280 payload_len); in coap_client_init_request()
663 uint16_t payload_len; in handle_response() local
666 const uint8_t *payload = coap_packet_get_payload(response, &payload_len); in handle_response()
669 if (payload_len == 0 && response_type == COAP_TYPE_ACK && in handle_response()
791 payload_len = MIN(payload_len, CONFIG_COAP_CLIENT_BLOCK_SIZE); in handle_response()
[all …]
/Zephyr-Core-3.7.0/subsys/mgmt/updatehub/
Dupdatehub.c391 uint16_t payload_len; in install_update_cb_check_blk_num() local
394 (void)coap_packet_get_payload(resp, &payload_len); in install_update_cb_check_blk_num()
396 if ((payload_len == 0) || (blk2_opt < 0)) { in install_update_cb_check_blk_num()
417 uint16_t payload_len; in install_update_cb() local
447 payload_start = coap_packet_get_payload(&response_packet, &payload_len); in install_update_cb()
453 ctx.downloaded_size = ctx.downloaded_size + payload_len; in install_update_cb()
458 payload_len)) { in install_update_cb()
465 if (updatehub_storage_write(&ctx.storage_ctx, payload_start, payload_len, in install_update_cb()
690 uint16_t payload_len; in probe_cb() local
715 payload_start = coap_packet_get_payload(&reply, &payload_len); in probe_cb()
[all …]
/Zephyr-Core-3.7.0/subsys/net/ip/
Dicmpv6.c108 int16_t payload_len; in icmpv6_handle_echo_request() local
117 payload_len = ntohs(ip_hdr->len) - in icmpv6_handle_echo_request()
119 if (payload_len < NET_ICMPV6_UNUSED_LEN) { in icmpv6_handle_echo_request()
124 reply = net_pkt_alloc_with_buffer(net_pkt_iface(pkt), payload_len, in icmpv6_handle_echo_request()
160 net_pkt_copy(reply, pkt, payload_len)) { in icmpv6_handle_echo_request()
/Zephyr-Core-3.7.0/drivers/ieee802154/
Dieee802154_kw41z.c619 uint8_t payload_len = frag->len; in kw41z_tx() local
639 if (payload_len > KW41Z_PSDU_LENGTH) { in kw41z_tx()
651 ((uint8_t *)ZLL->PKT_BUFFER_TX)[0] = payload_len + KW41Z_FCS_LENGTH; in kw41z_tx()
653 (void *)frag->data, payload_len); in kw41z_tx()
655 ((uint8_t *)ZLL->PKT_BUFFER)[0] = payload_len + KW41Z_FCS_LENGTH; in kw41z_tx()
657 (void *)frag->data, payload_len); in kw41z_tx()
670 payload_len * KW41Z_PER_BYTE_TIME + 10 + in kw41z_tx()
674 payload_len, tx_timeout, frag->data[2]); in kw41z_tx()
681 payload_len, frag->data[2]); in kw41z_tx()
/Zephyr-Core-3.7.0/subsys/modem/
Dmodem_ubx.c73 uint16_t payload_len = frame->payload_size_high; in modem_ubx_get_payload_length() local
75 payload_len = payload_len << 8; in modem_ubx_get_payload_length()
77 return payload_len | frame->payload_size_low; in modem_ubx_get_payload_length()
/Zephyr-Core-3.7.0/tests/net/lib/coap/src/
Dmain.c110 uint16_t payload_len; in ZTEST() local
138 payload_start = coap_packet_get_payload(&cpkt, &payload_len); in ZTEST()
140 zassert_equal(payload_len, sizeof(payload), "Invalid payload length"); in ZTEST()
141 zassert_equal_ptr(payload_start, cpkt.data + cpkt.offset - payload_len, in ZTEST()
233 uint16_t payload_len; in ZTEST() local
247 payload_start = coap_packet_get_payload(&cpkt, &payload_len); in ZTEST()
249 zassert_equal(payload_len, sizeof(payload), "Invalid payload length"); in ZTEST()
250 zassert_equal_ptr(payload_start, cpkt.data + cpkt.offset - payload_len, in ZTEST()
499 int payload_len; in prepare_block1_request() local
527 payload_len = req_ctx->total_size - req_ctx->current; in prepare_block1_request()
[all …]

123