Lines Matching refs:rp
223 struct btp_gatt_read_supported_commands_rp *rp = rsp; in supported_commands() local
226 tester_set_bit(rp->data, BTP_GATT_READ_SUPPORTED_COMMANDS); in supported_commands()
227 tester_set_bit(rp->data, BTP_GATT_ADD_SERVICE); in supported_commands()
228 tester_set_bit(rp->data, BTP_GATT_ADD_CHARACTERISTIC); in supported_commands()
229 tester_set_bit(rp->data, BTP_GATT_ADD_DESCRIPTOR); in supported_commands()
230 tester_set_bit(rp->data, BTP_GATT_ADD_INCLUDED_SERVICE); in supported_commands()
231 tester_set_bit(rp->data, BTP_GATT_SET_VALUE); in supported_commands()
232 tester_set_bit(rp->data, BTP_GATT_START_SERVER); in supported_commands()
235 tester_set_bit(rp->data, BTP_GATT_SET_ENC_KEY_SIZE); in supported_commands()
236 tester_set_bit(rp->data, BTP_GATT_EXCHANGE_MTU); in supported_commands()
237 tester_set_bit(rp->data, BTP_GATT_DISC_ALL_PRIM); in supported_commands()
238 tester_set_bit(rp->data, BTP_GATT_DISC_PRIM_UUID); in supported_commands()
239 tester_set_bit(rp->data, BTP_GATT_FIND_INCLUDED); in supported_commands()
240 tester_set_bit(rp->data, BTP_GATT_DISC_ALL_CHRC); in supported_commands()
241 tester_set_bit(rp->data, BTP_GATT_DISC_CHRC_UUID); in supported_commands()
244 tester_set_bit(rp->data, BTP_GATT_DISC_ALL_DESC); in supported_commands()
245 tester_set_bit(rp->data, BTP_GATT_READ); in supported_commands()
246 tester_set_bit(rp->data, BTP_GATT_READ_LONG); in supported_commands()
247 tester_set_bit(rp->data, BTP_GATT_READ_MULTIPLE); in supported_commands()
248 tester_set_bit(rp->data, BTP_GATT_WRITE_WITHOUT_RSP); in supported_commands()
249 tester_set_bit(rp->data, BTP_GATT_SIGNED_WRITE_WITHOUT_RSP); in supported_commands()
250 tester_set_bit(rp->data, BTP_GATT_WRITE); in supported_commands()
253 tester_set_bit(rp->data, BTP_GATT_WRITE_LONG); in supported_commands()
254 tester_set_bit(rp->data, BTP_GATT_CFG_NOTIFY); in supported_commands()
255 tester_set_bit(rp->data, BTP_GATT_CFG_INDICATE); in supported_commands()
256 tester_set_bit(rp->data, BTP_GATT_GET_ATTRIBUTES); in supported_commands()
257 tester_set_bit(rp->data, BTP_GATT_GET_ATTRIBUTE_VALUE); in supported_commands()
258 tester_set_bit(rp->data, BTP_GATT_CHANGE_DB); in supported_commands()
259 tester_set_bit(rp->data, BTP_GATT_EATT_CONNECT); in supported_commands()
262 tester_set_bit(rp->data, BTP_GATT_READ_MULTIPLE_VAR); in supported_commands()
263 tester_set_bit(rp->data, BTP_GATT_NOTIFY_MULTIPLE); in supported_commands()
266 *rsp_len = sizeof(*rp) + 5; in supported_commands()
292 struct btp_gatt_add_service_rp *rp = rsp; in add_service() local
336 rp->svc_id = sys_cpu_to_le16(attr_svc->handle); in add_service()
337 *rsp_len = sizeof(*rp); in add_service()
497 struct btp_gatt_add_characteristic_rp *rp = rsp; in add_characteristic() local
527 rp->char_id = sys_cpu_to_le16(cmd_data.char_id); in add_characteristic()
528 *rsp_len = sizeof(*rp); in add_characteristic()
686 struct btp_gatt_add_descriptor_rp *rp = rsp; in add_descriptor() local
725 rp->desc_id = sys_cpu_to_le16(cmd_data.desc_id); in add_descriptor()
726 *rsp_len = sizeof(*rp); in add_descriptor()
757 struct btp_gatt_add_included_service_rp *rp = rsp; in add_included() local
784 rp->included_service_id = sys_cpu_to_le16(included_service_id); in add_included()
785 *rsp_len = sizeof(*rp); in add_included()
917 struct btp_gatt_start_server_rp *rp = rsp; in start_server() local
926 rp->db_attr_off = sys_cpu_to_le16(0); /* TODO*/ in start_server()
927 rp->db_attr_cnt = svc_attr_count; in start_server()
928 *rsp_len = sizeof(*rp); in start_server()
1039 struct btp_gatt_disc_prim_rp *rp = (void *) gatt_buf.buf; in disc_prim_cb() local
1074 rp->services_count++; in disc_prim_cb()
1166 struct btp_gatt_find_included_rp *rp = (void *) gatt_buf.buf; in find_included_cb() local
1202 rp->services_count++; in find_included_cb()
1245 struct btp_gatt_disc_chrc_rp *rp = (void *) gatt_buf.buf; in disc_chrc_cb() local
1280 rp->characteristics_count++; in disc_chrc_cb()
1372 struct btp_gatt_disc_all_desc_rp *rp = (void *) gatt_buf.buf; in disc_all_desc_cb() local
1404 rp->descriptors_count++; in disc_all_desc_cb()
1454 struct btp_gatt_read_rp *rp = (void *) gatt_buf.buf; in read_cb() local
1458 rp->att_response = err; in read_cb()
1475 rp->data_length += length; in read_cb()
1484 struct btp_gatt_read_uuid_rp *rp = (void *)gatt_buf.buf; in read_uuid_cb() local
1489 rp->att_response = err; in read_uuid_cb()
1518 rp->values_count++; in read_uuid_cb()
2206 struct btp_gatt_get_attributes_rp *rp = rsp; in get_attrs() local
2207 struct net_buf_simple *buf = NET_BUF_SIMPLE(BTP_DATA_MAX_SIZE - sizeof(*rp)); in get_attrs()
2245 (void)memcpy(rp->attrs, buf->data, buf->len); in get_attrs()
2246 rp->attrs_count = foreach.count; in get_attrs()
2248 *rsp_len = sizeof(*rp) + buf->len; in get_attrs()
2268 struct btp_gatt_get_attribute_value_rp *rp; in get_attr_val_rp() local
2271 rp = net_buf_simple_add(buf, sizeof(*rp)); in get_attr_val_rp()
2272 rp->value_length = 0x0000; in get_attr_val_rp()
2273 rp->att_response = BT_ATT_ERR_SUCCESS; in get_attr_val_rp()
2279 rp->att_response = BT_ATT_ERR_READ_NOT_PERMITTED; in get_attr_val_rp()
2284 rp->value_length); in get_attr_val_rp()
2286 rp->att_response = err_to_att(read); in get_attr_val_rp()
2290 rp->value_length += read; in get_attr_val_rp()
2299 if ((rp->att_response == BT_ATT_ERR_SUCCESS) && (value->enc_key_size > 0)) { in get_attr_val_rp()
2320 rp->att_response = BT_ATT_ERR_ENCRYPTION_KEY_SIZE; in get_attr_val_rp()
2323 rp->att_response = BT_ATT_ERR_ENCRYPTION_KEY_SIZE; in get_attr_val_rp()