Lines Matching refs:data_ptr

486 	res_inst->data_ptr = buffer_ptr;  in lwm2m_set_res_buf()
543 void *data_ptr = NULL; in lwm2m_engine_set() local
579 data_ptr = res_inst->data_ptr; in lwm2m_engine_set()
584 data_ptr = res->pre_write_cb(obj_inst->obj_inst_id, res->res_id, in lwm2m_engine_set()
588 if (!data_ptr) { in lwm2m_engine_set()
603 if (memcmp(data_ptr, value, len) != 0 || res_inst->data_len != len) { in lwm2m_engine_set()
622 memcpy((uint8_t *)data_ptr, value, len); in lwm2m_engine_set()
628 strncpy(data_ptr, value, len - 1); in lwm2m_engine_set()
629 ((char *)data_ptr)[len - 1] = '\0'; in lwm2m_engine_set()
631 ((char *)data_ptr)[0] = '\0'; in lwm2m_engine_set()
636 *((uint32_t *)data_ptr) = *(uint32_t *)value; in lwm2m_engine_set()
640 *((uint16_t *)data_ptr) = *(uint16_t *)value; in lwm2m_engine_set()
644 *((uint8_t *)data_ptr) = *(uint8_t *)value; in lwm2m_engine_set()
657 *((time_t *)data_ptr) = *(time_t *)value; in lwm2m_engine_set()
659 *((time_t *)data_ptr) = (time_t) *((uint32_t *)value); in lwm2m_engine_set()
666 *((uint32_t *)data_ptr) = *(uint32_t *)value; in lwm2m_engine_set()
668 *((uint32_t *)data_ptr) = (uint32_t) *((time_t *)value); in lwm2m_engine_set()
675 *((int64_t *)data_ptr) = *(int64_t *)value; in lwm2m_engine_set()
679 *((int32_t *)data_ptr) = *(int32_t *)value; in lwm2m_engine_set()
683 *((int16_t *)data_ptr) = *(int16_t *)value; in lwm2m_engine_set()
687 *((int8_t *)data_ptr) = *(int8_t *)value; in lwm2m_engine_set()
691 *((bool *)data_ptr) = *(bool *)value; in lwm2m_engine_set()
695 *(double *)data_ptr = *(double *)value; in lwm2m_engine_set()
699 *((struct lwm2m_objlnk *)data_ptr) = *(struct lwm2m_objlnk *)value; in lwm2m_engine_set()
717 data_ptr, len, false, 0, 0); in lwm2m_engine_set()
727 int lwm2m_set_opaque(const struct lwm2m_obj_path *path, const char *data_ptr, uint16_t data_len) in lwm2m_set_opaque() argument
729 return lwm2m_engine_set(path, data_ptr, data_len); in lwm2m_set_opaque()
732 int lwm2m_set_string(const struct lwm2m_obj_path *path, const char *data_ptr) in lwm2m_set_string() argument
734 uint16_t len = strlen(data_ptr); in lwm2m_set_string()
741 return lwm2m_engine_set(path, data_ptr, len); in lwm2m_set_string()
844 *buffer_ptr = res_inst->data_ptr; in lwm2m_get_res_buf()
867 void *data_ptr = NULL; in lwm2m_engine_get() local
892 data_ptr = res_inst->data_ptr; in lwm2m_engine_get()
897 data_ptr = res->read_cb(obj_inst->obj_inst_id, res->res_id, res_inst->res_inst_id, in lwm2m_engine_get()
901 if (data_ptr && data_len > 0) { in lwm2m_engine_get()
913 memcpy(buf, data_ptr, data_len); in lwm2m_engine_get()
917 strncpy(buf, data_ptr, data_len - 1); in lwm2m_engine_get()
922 *(uint32_t *)buf = *(uint32_t *)data_ptr; in lwm2m_engine_get()
934 *((time_t *)buf) = *(time_t *)data_ptr; in lwm2m_engine_get()
939 *((uint32_t *)buf) = (uint32_t) *((time_t *)data_ptr); in lwm2m_engine_get()
944 *((uint32_t *)buf) = *(uint32_t *)data_ptr; in lwm2m_engine_get()
946 *((time_t *)buf) = (time_t) *((uint32_t *)data_ptr); in lwm2m_engine_get()
952 *(uint16_t *)buf = *(uint16_t *)data_ptr; in lwm2m_engine_get()
956 *(uint8_t *)buf = *(uint8_t *)data_ptr; in lwm2m_engine_get()
960 *(int64_t *)buf = *(int64_t *)data_ptr; in lwm2m_engine_get()
964 *(int32_t *)buf = *(int32_t *)data_ptr; in lwm2m_engine_get()
968 *(int16_t *)buf = *(int16_t *)data_ptr; in lwm2m_engine_get()
972 *(int8_t *)buf = *(int8_t *)data_ptr; in lwm2m_engine_get()
976 *(bool *)buf = *(bool *)data_ptr; in lwm2m_engine_get()
980 *(double *)buf = *(double *)data_ptr; in lwm2m_engine_get()
984 *(struct lwm2m_objlnk *)buf = *(struct lwm2m_objlnk *)data_ptr; in lwm2m_engine_get()
1254 res_inst->data_ptr = NULL; in lwm2m_delete_res_inst()