Lines Matching refs:msg

9 int decode_rw_file_memory_req(const struct pldm_msg *msg, size_t payload_length,  in decode_rw_file_memory_req()  argument
13 if (msg == NULL || file_handle == NULL || offset == NULL || in decode_rw_file_memory_req()
23 (struct pldm_read_write_file_memory_req *)msg->payload; in decode_rw_file_memory_req()
36 struct pldm_msg *msg) in encode_rw_file_memory_resp() argument
38 if (msg == NULL) { in encode_rw_file_memory_resp()
47 uint8_t rc = pack_pldm_header(&header, &(msg->hdr)); in encode_rw_file_memory_resp()
53 (struct pldm_read_write_file_memory_resp *)msg->payload; in encode_rw_file_memory_resp()
66 struct pldm_msg *msg) in encode_rw_file_memory_req() argument
68 if (msg == NULL) { in encode_rw_file_memory_req()
77 uint8_t rc = pack_pldm_header(&header, &(msg->hdr)); in encode_rw_file_memory_req()
83 (struct pldm_read_write_file_memory_req *)msg->payload; in encode_rw_file_memory_req()
92 int decode_rw_file_memory_resp(const struct pldm_msg *msg, in decode_rw_file_memory_resp() argument
96 if (msg == NULL || length == NULL || completion_code == NULL) { in decode_rw_file_memory_resp()
105 (struct pldm_read_write_file_memory_resp *)msg->payload; in decode_rw_file_memory_resp()
115 int decode_get_file_table_req(const struct pldm_msg *msg, size_t payload_length, in decode_get_file_table_req() argument
119 if (msg == NULL || transfer_handle == NULL || transfer_opflag == NULL || in decode_get_file_table_req()
129 (struct pldm_get_file_table_req *)msg->payload; in decode_get_file_table_req()
142 size_t table_size, struct pldm_msg *msg) in encode_get_file_table_resp() argument
144 if (msg == NULL) { in encode_get_file_table_resp()
153 uint8_t rc = pack_pldm_header(&header, &(msg->hdr)); in encode_get_file_table_resp()
159 (struct pldm_get_file_table_resp *)msg->payload; in encode_get_file_table_resp()
174 struct pldm_msg *msg) in encode_get_file_table_req() argument
176 if (msg == NULL) { in encode_get_file_table_req()
185 uint8_t rc = pack_pldm_header(&header, &(msg->hdr)); in encode_get_file_table_req()
191 (struct pldm_get_file_table_req *)msg->payload; in encode_get_file_table_req()
200 int decode_get_file_table_resp(const struct pldm_msg *msg, in decode_get_file_table_resp() argument
207 if (msg == NULL || transfer_flag == NULL || in decode_get_file_table_resp()
217 *completion_code = msg->payload[0]; in decode_get_file_table_resp()
224 (struct pldm_get_file_table_resp *)msg->payload; in decode_get_file_table_resp()
238 int decode_read_file_req(const struct pldm_msg *msg, size_t payload_length, in decode_read_file_req() argument
242 if (msg == NULL || file_handle == NULL || offset == NULL || in decode_read_file_req()
252 (struct pldm_read_file_req *)msg->payload; in decode_read_file_req()
263 uint32_t offset, uint32_t length, struct pldm_msg *msg) in encode_read_file_req() argument
265 if (msg == NULL) { in encode_read_file_req()
278 uint8_t rc = pack_pldm_header(&header, &(msg->hdr)); in encode_read_file_req()
284 (struct pldm_read_file_req *)msg->payload; in encode_read_file_req()
294 int decode_read_file_resp(const struct pldm_msg *msg, size_t payload_length, in decode_read_file_resp() argument
298 if (msg == NULL || completion_code == NULL || length == NULL) { in decode_read_file_resp()
307 (struct pldm_read_file_resp *)msg->payload; in decode_read_file_resp()
323 uint32_t length, struct pldm_msg *msg) in encode_read_file_resp() argument
325 if (msg == NULL) { in encode_read_file_resp()
334 uint8_t rc = pack_pldm_header(&header, &(msg->hdr)); in encode_read_file_resp()
340 (struct pldm_read_file_resp *)msg->payload; in encode_read_file_resp()
351 int decode_write_file_req(const struct pldm_msg *msg, size_t payload_length, in decode_write_file_req() argument
355 if (msg == NULL || file_handle == NULL || length == NULL) { in decode_write_file_req()
364 (struct pldm_write_file_req *)msg->payload; in decode_write_file_req()
381 struct pldm_msg *msg) in encode_write_file_req() argument
383 if (msg == NULL) { in encode_write_file_req()
396 uint8_t rc = pack_pldm_header(&header, &(msg->hdr)); in encode_write_file_req()
402 (struct pldm_write_file_req *)msg->payload; in encode_write_file_req()
412 int decode_write_file_resp(const struct pldm_msg *msg, size_t payload_length, in decode_write_file_resp() argument
415 if (msg == NULL || completion_code == NULL || length == NULL) { in decode_write_file_resp()
424 (struct pldm_write_file_resp *)msg->payload; in decode_write_file_resp()
436 uint32_t length, struct pldm_msg *msg) in encode_write_file_resp() argument
438 if (msg == NULL) { in encode_write_file_resp()
447 uint8_t rc = pack_pldm_header(&header, &(msg->hdr)); in encode_write_file_resp()
453 (struct pldm_write_file_resp *)msg->payload; in encode_write_file_resp()
464 int decode_rw_file_by_type_memory_req(const struct pldm_msg *msg, in decode_rw_file_by_type_memory_req() argument
470 if (msg == NULL || file_type == NULL || file_handle == NULL || in decode_rw_file_by_type_memory_req()
480 (struct pldm_read_write_file_by_type_memory_req *)msg->payload; in decode_rw_file_by_type_memory_req()
493 struct pldm_msg *msg) in encode_rw_file_by_type_memory_resp() argument
495 if (msg == NULL) { in encode_rw_file_by_type_memory_resp()
504 uint8_t rc = pack_pldm_header(&header, &(msg->hdr)); in encode_rw_file_by_type_memory_resp()
510 (struct pldm_read_write_file_by_type_memory_resp *)msg->payload; in encode_rw_file_by_type_memory_resp()
523 uint64_t address, struct pldm_msg *msg) in encode_rw_file_by_type_memory_req() argument
525 if (msg == NULL) { in encode_rw_file_by_type_memory_req()
534 uint8_t rc = pack_pldm_header(&header, &(msg->hdr)); in encode_rw_file_by_type_memory_req()
540 (struct pldm_read_write_file_by_type_memory_req *)msg->payload; in encode_rw_file_by_type_memory_req()
551 int decode_rw_file_by_type_memory_resp(const struct pldm_msg *msg, in decode_rw_file_by_type_memory_resp() argument
556 if (msg == NULL || length == NULL || completion_code == NULL) { in decode_rw_file_by_type_memory_resp()
565 (struct pldm_read_write_file_by_type_memory_resp *)msg->payload; in decode_rw_file_by_type_memory_resp()
575 int decode_new_file_req(const struct pldm_msg *msg, size_t payload_length, in decode_new_file_req() argument
579 if (msg == NULL || file_type == NULL || file_handle == NULL || in decode_new_file_req()
589 (struct pldm_new_file_req *)msg->payload; in decode_new_file_req()
599 struct pldm_msg *msg) in encode_new_file_resp() argument
601 if (msg == NULL) { in encode_new_file_resp()
610 uint8_t rc = pack_pldm_header(&header, &(msg->hdr)); in encode_new_file_resp()
616 (struct pldm_new_file_resp *)msg->payload; in encode_new_file_resp()
625 struct pldm_msg *msg) in encode_new_file_req() argument
627 if (msg == NULL) { in encode_new_file_req()
636 uint8_t rc = pack_pldm_header(&header, &(msg->hdr)); in encode_new_file_req()
642 (struct pldm_new_file_req *)msg->payload; in encode_new_file_req()
651 int decode_new_file_resp(const struct pldm_msg *msg, size_t payload_length, in decode_new_file_resp() argument
654 if (msg == NULL || completion_code == NULL) { in decode_new_file_resp()
663 (struct pldm_new_file_resp *)msg->payload; in decode_new_file_resp()
670 int decode_rw_file_by_type_req(const struct pldm_msg *msg, in decode_rw_file_by_type_req() argument
675 if (msg == NULL || file_type == NULL || file_handle == NULL || in decode_rw_file_by_type_req()
685 (struct pldm_read_write_file_by_type_req *)msg->payload; in decode_rw_file_by_type_req()
697 struct pldm_msg *msg) in encode_rw_file_by_type_resp() argument
699 if (msg == NULL) { in encode_rw_file_by_type_resp()
712 uint8_t rc = pack_pldm_header(&header, &(msg->hdr)); in encode_rw_file_by_type_resp()
718 (struct pldm_read_write_file_by_type_resp *)msg->payload; in encode_rw_file_by_type_resp()
731 struct pldm_msg *msg) in encode_rw_file_by_type_req() argument
733 if (msg == NULL) { in encode_rw_file_by_type_req()
746 uint8_t rc = pack_pldm_header(&header, &(msg->hdr)); in encode_rw_file_by_type_req()
752 (struct pldm_read_write_file_by_type_req *)msg->payload; in encode_rw_file_by_type_req()
762 int decode_rw_file_by_type_resp(const struct pldm_msg *msg, in decode_rw_file_by_type_resp() argument
766 if (msg == NULL || length == NULL || completion_code == NULL) { in decode_rw_file_by_type_resp()
775 (struct pldm_read_write_file_by_type_resp *)msg->payload; in decode_rw_file_by_type_resp()
785 int decode_file_ack_req(const struct pldm_msg *msg, size_t payload_length, in decode_file_ack_req() argument
789 if (msg == NULL || file_type == NULL || file_handle == NULL) { in decode_file_ack_req()
798 (struct pldm_file_ack_req *)msg->payload; in decode_file_ack_req()
808 struct pldm_msg *msg) in encode_file_ack_resp() argument
810 if (msg == NULL) { in encode_file_ack_resp()
819 uint8_t rc = pack_pldm_header(&header, &(msg->hdr)); in encode_file_ack_resp()
825 (struct pldm_file_ack_resp *)msg->payload; in encode_file_ack_resp()
834 struct pldm_msg *msg) in encode_file_ack_req() argument
836 if (msg == NULL) { in encode_file_ack_req()
845 uint8_t rc = pack_pldm_header(&header, &(msg->hdr)); in encode_file_ack_req()
851 (struct pldm_file_ack_req *)msg->payload; in encode_file_ack_req()
860 int decode_file_ack_resp(const struct pldm_msg *msg, size_t payload_length, in decode_file_ack_resp() argument
863 if (msg == NULL || completion_code == NULL) { in decode_file_ack_resp()
872 (struct pldm_file_ack_resp *)msg->payload; in decode_file_ack_resp()
883 uint32_t file_meta_data_4, struct pldm_msg *msg) in encode_file_ack_with_meta_data_req() argument
885 if (msg == NULL) { in encode_file_ack_with_meta_data_req()
894 uint8_t rc = pack_pldm_header(&header, &(msg->hdr)); in encode_file_ack_with_meta_data_req()
900 (struct pldm_file_ack_with_meta_data_req *)msg->payload; in encode_file_ack_with_meta_data_req()
913 int decode_file_ack_with_meta_data_resp(const struct pldm_msg *msg, in decode_file_ack_with_meta_data_resp() argument
917 if (msg == NULL || completion_code == NULL) { in decode_file_ack_with_meta_data_resp()
926 (struct pldm_file_ack_with_meta_data_resp *)msg->payload; in decode_file_ack_with_meta_data_resp()
934 const struct pldm_msg *msg, size_t payload_length, uint16_t *file_type, in decode_file_ack_with_meta_data_req() argument
939 if (msg == NULL || file_type == NULL || file_handle == NULL) { in decode_file_ack_with_meta_data_req()
948 (struct pldm_file_ack_with_meta_data_req *)msg->payload; in decode_file_ack_with_meta_data_req()
963 struct pldm_msg *msg) in encode_file_ack_with_meta_data_resp() argument
965 if (msg == NULL) { in encode_file_ack_with_meta_data_resp()
974 uint8_t rc = pack_pldm_header(&header, &(msg->hdr)); in encode_file_ack_with_meta_data_resp()
980 (struct pldm_file_ack_with_meta_data_resp *)msg->payload; in encode_file_ack_with_meta_data_resp()
993 struct pldm_msg *msg) in encode_new_file_with_metadata_req() argument
995 if (msg == NULL) { in encode_new_file_with_metadata_req()
1004 uint8_t rc = pack_pldm_header(&header, &(msg->hdr)); in encode_new_file_with_metadata_req()
1010 (struct pldm_new_file_with_metadata_req *)msg->payload; in encode_new_file_with_metadata_req()
1023 int decode_new_file_with_metadata_resp(const struct pldm_msg *msg, in decode_new_file_with_metadata_resp() argument
1027 if (msg == NULL || completion_code == NULL) { in decode_new_file_with_metadata_resp()
1037 (struct pldm_new_file_with_metadata_resp *)msg->payload; in decode_new_file_with_metadata_resp()
1039 *completion_code = msg->payload[0]; in decode_new_file_with_metadata_resp()
1048 const struct pldm_msg *msg, size_t payload_length, uint16_t *file_type, in decode_new_file_with_metadata_req() argument
1053 if (msg == NULL || file_type == NULL || file_handle == NULL || in decode_new_file_with_metadata_req()
1064 (struct pldm_new_file_with_metadata_req *)msg->payload; in decode_new_file_with_metadata_req()
1079 struct pldm_msg *msg) in encode_new_file_with_metadata_resp() argument
1081 if (msg == NULL) { in encode_new_file_with_metadata_resp()
1090 uint8_t rc = pack_pldm_header(&header, &(msg->hdr)); in encode_new_file_with_metadata_resp()
1096 (struct pldm_new_file_with_metadata_resp *)msg->payload; in encode_new_file_with_metadata_resp()