Lines Matching refs:sr_cmd
51 tGATT_SR_CMD* p_cmd = &tcb.sr_cmd; in gatt_sr_enqueue_cmd()
82 bool gatt_sr_cmd_empty(tGATT_TCB& tcb) { return (tcb.sr_cmd.op_code == 0); } in gatt_sr_cmd_empty()
96 if (tcb.sr_cmd.p_rsp_msg) in gatt_dequeue_sr_cmd()
97 LOG(ERROR) << "free tcb.sr_cmd.p_rsp_msg = " << tcb.sr_cmd.p_rsp_msg; in gatt_dequeue_sr_cmd()
98 osi_free_and_reset((void**)&tcb.sr_cmd.p_rsp_msg); in gatt_dequeue_sr_cmd()
100 while (!fixed_queue_is_empty(tcb.sr_cmd.multi_rsp_q)) in gatt_dequeue_sr_cmd()
101 osi_free(fixed_queue_try_dequeue(tcb.sr_cmd.multi_rsp_q)); in gatt_dequeue_sr_cmd()
102 fixed_queue_free(tcb.sr_cmd.multi_rsp_q, NULL); in gatt_dequeue_sr_cmd()
103 memset(&tcb.sr_cmd, 0, sizeof(tGATT_SR_CMD)); in gatt_dequeue_sr_cmd()
241 if (!process_read_multi_rsp(&tcb.sr_cmd, status, p_msg, tcb.payload_size)) in gatt_sr_process_app_rsp()
250 tcb.sr_cmd.status = status; in gatt_sr_process_app_rsp()
253 if (tcb.sr_cmd.p_rsp_msg == NULL) { in gatt_sr_process_app_rsp()
254 tcb.sr_cmd.p_rsp_msg = attp_build_sr_msg(tcb, (uint8_t)(op_code + 1), in gatt_sr_process_app_rsp()
262 if ((tcb.sr_cmd.status == GATT_SUCCESS) && (tcb.sr_cmd.p_rsp_msg)) { in gatt_sr_process_app_rsp()
263 ret_code = attp_send_sr_msg(tcb, tcb.sr_cmd.p_rsp_msg); in gatt_sr_process_app_rsp()
264 tcb.sr_cmd.p_rsp_msg = NULL; in gatt_sr_process_app_rsp()
267 gatt_send_error_rsp(tcb, status, op_code, tcb.sr_cmd.handle, false); in gatt_sr_process_app_rsp()
362 tcb.sr_cmd.multi_req.num_handles = 0; in gatt_process_read_multi_req()
381 tcb.sr_cmd.multi_req.num_handles < GATT_MAX_READ_MULTI_HANDLES) { in gatt_process_read_multi_req()
386 tcb.sr_cmd.multi_req.handles[tcb.sr_cmd.multi_req.num_handles++] = handle; in gatt_process_read_multi_req()
407 if (tcb.sr_cmd.multi_req.num_handles == 0) err = GATT_INVALID_HANDLE; in gatt_process_read_multi_req()
411 gatt_sr_enqueue_cmd(tcb, op_code, tcb.sr_cmd.multi_req.handles[0]); in gatt_process_read_multi_req()
415 for (ll = 0; ll < tcb.sr_cmd.multi_req.num_handles; ll++) { in gatt_process_read_multi_req()
417 handle = tcb.sr_cmd.multi_req.handles[ll]; in gatt_process_read_multi_req()