Lines Matching refs:p
57 typedef void (*tAVDT_MSG_BLD)(UINT8 **p, tAVDT_MSG *p_msg);
60 typedef UINT8 (*tAVDT_MSG_PRS)(tAVDT_MSG *p_msg, UINT8 *p, UINT16 len);
67 static void avdt_msg_bld_none(UINT8 **p, tAVDT_MSG *p_msg);
68 static void avdt_msg_bld_single(UINT8 **p, tAVDT_MSG *p_msg);
69 static void avdt_msg_bld_setconfig_cmd(UINT8 **p, tAVDT_MSG *p_msg);
70 static void avdt_msg_bld_reconfig_cmd(UINT8 **p, tAVDT_MSG *p_msg);
71 static void avdt_msg_bld_multi(UINT8 **p, tAVDT_MSG *p_msg);
72 static void avdt_msg_bld_security_cmd(UINT8 **p, tAVDT_MSG *p_msg);
73 static void avdt_msg_bld_discover_rsp(UINT8 **p, tAVDT_MSG *p_msg);
74 static void avdt_msg_bld_svccap(UINT8 **p, tAVDT_MSG *p_msg);
75 static void avdt_msg_bld_security_rsp(UINT8 **p, tAVDT_MSG *p_msg);
76 static void avdt_msg_bld_all_svccap(UINT8 **p, tAVDT_MSG *p_msg);
77 static void avdt_msg_bld_delay_rpt(UINT8 **p, tAVDT_MSG *p_msg);
79 static UINT8 avdt_msg_prs_none(tAVDT_MSG *p_msg, UINT8 *p, UINT16 len);
80 static UINT8 avdt_msg_prs_single(tAVDT_MSG *p_msg, UINT8 *p, UINT16 len);
81 static UINT8 avdt_msg_prs_setconfig_cmd(tAVDT_MSG *p_msg, UINT8 *p, UINT16 len);
82 static UINT8 avdt_msg_prs_reconfig_cmd(tAVDT_MSG *p_msg, UINT8 *p, UINT16 len);
83 static UINT8 avdt_msg_prs_multi(tAVDT_MSG *p_msg, UINT8 *p, UINT16 len);
84 static UINT8 avdt_msg_prs_security_cmd(tAVDT_MSG *p_msg, UINT8 *p, UINT16 len);
85 static UINT8 avdt_msg_prs_discover_rsp(tAVDT_MSG *p_msg, UINT8 *p, UINT16 len);
86 static UINT8 avdt_msg_prs_svccap(tAVDT_MSG *p_msg, UINT8 *p, UINT16 len);
87 static UINT8 avdt_msg_prs_all_svccap(tAVDT_MSG *p_msg, UINT8 *p, UINT16 len);
88 static UINT8 avdt_msg_prs_security_rsp(tAVDT_MSG *p_msg, UINT8 *p, UINT16 len);
89 static UINT8 avdt_msg_prs_delay_rpt (tAVDT_MSG *p_msg, UINT8 *p, UINT16 len);
272 static void avdt_msg_bld_cfg(UINT8 **p, tAVDT_CFG *p_cfg) in avdt_msg_bld_cfg() argument
281 *(*p)++ = AVDT_CAT_TRANS; in avdt_msg_bld_cfg()
282 *(*p)++ = 0; /* length */ in avdt_msg_bld_cfg()
289 *(*p)++ = AVDT_CAT_REPORT; in avdt_msg_bld_cfg()
290 *(*p)++ = 0; /* length */ in avdt_msg_bld_cfg()
297 *(*p)++ = AVDT_CAT_CODEC; in avdt_msg_bld_cfg()
302 memcpy(*p, p_cfg->codec_info, len); in avdt_msg_bld_cfg()
303 *p += len; in avdt_msg_bld_cfg()
309 *(*p)++ = AVDT_CAT_PROTECT; in avdt_msg_bld_cfg()
314 memcpy(*p, p_cfg->protect_info, len); in avdt_msg_bld_cfg()
315 *p += len; in avdt_msg_bld_cfg()
322 *(*p)++ = AVDT_CAT_MUX; in avdt_msg_bld_cfg()
325 *(*p)++ = 7; /* frag (1) + media + report + recovery */ in avdt_msg_bld_cfg()
327 *(*p)++ = 5; /* frag (1) + media + report */ in avdt_msg_bld_cfg()
329 *(*p)++ = 3; /* frag (1) + media */ in avdt_msg_bld_cfg()
333 *(*p)++ = 0x80; in avdt_msg_bld_cfg()
335 *(*p)++ = 0; in avdt_msg_bld_cfg()
338 *(*p)++ = p_cfg->mux_tsid_media<<3; /* TSID */ in avdt_msg_bld_cfg()
339 *(*p)++ = p_cfg->mux_tcid_media<<3; /* TCID */ in avdt_msg_bld_cfg()
344 *(*p)++ = p_cfg->mux_tsid_report<<3; /* TSID */ in avdt_msg_bld_cfg()
345 *(*p)++ = p_cfg->mux_tcid_report<<3; /* TCID */ in avdt_msg_bld_cfg()
347 *(*p)++ = p_cfg->mux_tsid_recov<<3; /* TSID */ in avdt_msg_bld_cfg()
348 *(*p)++ = p_cfg->mux_tcid_recov<<3; /* TCID */ in avdt_msg_bld_cfg()
353 *(*p)++ = p_cfg->mux_tsid_report<<3; /* TSID */ in avdt_msg_bld_cfg()
354 *(*p)++ = p_cfg->mux_tcid_report<<3; /* TCID */ in avdt_msg_bld_cfg()
362 *(*p)++ = AVDT_CAT_DELAY_RPT; in avdt_msg_bld_cfg()
363 *(*p)++ = 0; /* length */ in avdt_msg_bld_cfg()
377 static void avdt_msg_bld_none(UINT8 **p, tAVDT_MSG *p_msg) in avdt_msg_bld_none() argument
379 UNUSED(p); in avdt_msg_bld_none()
395 static void avdt_msg_bld_single(UINT8 **p, tAVDT_MSG *p_msg) in avdt_msg_bld_single() argument
397 AVDT_MSG_BLD_SEID(*p, p_msg->single.seid); in avdt_msg_bld_single()
411 static void avdt_msg_bld_setconfig_cmd(UINT8 **p, tAVDT_MSG *p_msg) in avdt_msg_bld_setconfig_cmd() argument
413 AVDT_MSG_BLD_SEID(*p, p_msg->config_cmd.hdr.seid); in avdt_msg_bld_setconfig_cmd()
414 AVDT_MSG_BLD_SEID(*p, p_msg->config_cmd.int_seid); in avdt_msg_bld_setconfig_cmd()
415 avdt_msg_bld_cfg(p, p_msg->config_cmd.p_cfg); in avdt_msg_bld_setconfig_cmd()
429 static void avdt_msg_bld_reconfig_cmd(UINT8 **p, tAVDT_MSG *p_msg) in avdt_msg_bld_reconfig_cmd() argument
431 AVDT_MSG_BLD_SEID(*p, p_msg->reconfig_cmd.hdr.seid); in avdt_msg_bld_reconfig_cmd()
435 avdt_msg_bld_cfg(p, p_msg->reconfig_cmd.p_cfg); in avdt_msg_bld_reconfig_cmd()
449 static void avdt_msg_bld_multi(UINT8 **p, tAVDT_MSG *p_msg) in avdt_msg_bld_multi() argument
455 AVDT_MSG_BLD_SEID(*p, p_msg->multi.seid_list[i]); in avdt_msg_bld_multi()
469 static void avdt_msg_bld_security_cmd(UINT8 **p, tAVDT_MSG *p_msg) in avdt_msg_bld_security_cmd() argument
471 AVDT_MSG_BLD_SEID(*p, p_msg->security_cmd.hdr.seid); in avdt_msg_bld_security_cmd()
472 memcpy(*p, p_msg->security_cmd.p_data, p_msg->security_cmd.len); in avdt_msg_bld_security_cmd()
473 *p += p_msg->security_cmd.len; in avdt_msg_bld_security_cmd()
486 static void avdt_msg_bld_delay_rpt(UINT8 **p, tAVDT_MSG *p_msg) in avdt_msg_bld_delay_rpt() argument
488 AVDT_MSG_BLD_SEID(*p, p_msg->delay_rpt_cmd.hdr.seid); in avdt_msg_bld_delay_rpt()
489 UINT16_TO_BE_STREAM(*p, p_msg->delay_rpt_cmd.delay); in avdt_msg_bld_delay_rpt()
503 static void avdt_msg_bld_discover_rsp(UINT8 **p, tAVDT_MSG *p_msg) in avdt_msg_bld_discover_rsp() argument
510 AVDT_MSG_BLD_DISC(*p, p_msg->discover_rsp.p_sep_info[i].seid, in avdt_msg_bld_discover_rsp()
528 static void avdt_msg_bld_svccap(UINT8 **p, tAVDT_MSG *p_msg) in avdt_msg_bld_svccap() argument
535 avdt_msg_bld_cfg(p, &cfg); in avdt_msg_bld_svccap()
549 static void avdt_msg_bld_all_svccap(UINT8 **p, tAVDT_MSG *p_msg) in avdt_msg_bld_all_svccap() argument
551 avdt_msg_bld_cfg(p, p_msg->svccap.p_cfg); in avdt_msg_bld_all_svccap()
565 static void avdt_msg_bld_security_rsp(UINT8 **p, tAVDT_MSG *p_msg) in avdt_msg_bld_security_rsp() argument
567 memcpy(*p, p_msg->security_rsp.p_data, p_msg->security_rsp.len); in avdt_msg_bld_security_rsp()
568 *p += p_msg->security_rsp.len; in avdt_msg_bld_security_rsp()
583 static UINT8 avdt_msg_prs_cfg(tAVDT_CFG *p_cfg, UINT8 *p, UINT16 len, UINT8* p_elem, UINT8 sig_id) in avdt_msg_prs_cfg() argument
606 p_end = p + len; in avdt_msg_prs_cfg()
607 while ((p < p_end) && (err == 0)) in avdt_msg_prs_cfg()
610 if ((p_end - p) < AVDT_LEN_CFG_MIN) in avdt_msg_prs_cfg()
617 elem = *p++; in avdt_msg_prs_cfg()
618 elem_len = *p++; in avdt_msg_prs_cfg()
637 p += elem_len; in avdt_msg_prs_cfg()
658 p_cfg->recov_type = *p++; in avdt_msg_prs_cfg()
659 p_cfg->recov_mrws = *p++; in avdt_msg_prs_cfg()
660 p_cfg->recov_mnmp = *p++; in avdt_msg_prs_cfg()
681 memcpy(&p_cfg->protect_info[protect_offset], p, elem_len); in avdt_msg_prs_cfg()
684 p += elem_len; in avdt_msg_prs_cfg()
688 p_cfg->hdrcmp_mask = *p++; in avdt_msg_prs_cfg()
708 p_cfg->mux_mask = *p++ & (UINT8)AVDT_MUX_FRAG; in avdt_msg_prs_cfg()
712 p_cfg->mux_tsid_media = (*p++)>>3; in avdt_msg_prs_cfg()
717 p_cfg->mux_tcid_media = (*p++)>>3; in avdt_msg_prs_cfg()
722 p_cfg->mux_tsid_report = (*p++)>>3; in avdt_msg_prs_cfg()
727 p_cfg->mux_tcid_report = (*p++)>>3; in avdt_msg_prs_cfg()
732 p_cfg->mux_tsid_recov = (*p++)>>3; in avdt_msg_prs_cfg()
737 p_cfg->mux_tcid_recov = (*p++)>>3; in avdt_msg_prs_cfg()
752 memcpy(&p_cfg->codec_info[1], p, tmp); in avdt_msg_prs_cfg()
753 p += elem_len; in avdt_msg_prs_cfg()
760 p += elem_len; in avdt_msg_prs_cfg()
781 static UINT8 avdt_msg_prs_none(tAVDT_MSG *p_msg, UINT8 *p, UINT16 len) in avdt_msg_prs_none() argument
784 UNUSED(p); in avdt_msg_prs_none()
800 static UINT8 avdt_msg_prs_single(tAVDT_MSG *p_msg, UINT8 *p, UINT16 len) in avdt_msg_prs_single() argument
811 AVDT_MSG_PRS_SEID(p, p_msg->single.seid); in avdt_msg_prs_single()
832 static UINT8 avdt_msg_prs_setconfig_cmd(tAVDT_MSG *p_msg, UINT8 *p, UINT16 len) in avdt_msg_prs_setconfig_cmd() argument
846 AVDT_MSG_PRS_SEID(p, p_msg->config_cmd.hdr.seid); in avdt_msg_prs_setconfig_cmd()
852 AVDT_MSG_PRS_SEID(p, p_msg->config_cmd.int_seid); in avdt_msg_prs_setconfig_cmd()
864 …err = avdt_msg_prs_cfg(p_msg->config_cmd.p_cfg, p, len, &p_msg->hdr.err_param, AVDT_SIG_SETCONFIG); in avdt_msg_prs_setconfig_cmd()
891 static UINT8 avdt_msg_prs_reconfig_cmd(tAVDT_MSG *p_msg, UINT8 *p, UINT16 len) in avdt_msg_prs_reconfig_cmd() argument
905 AVDT_MSG_PRS_SEID(p, p_msg->reconfig_cmd.hdr.seid); in avdt_msg_prs_reconfig_cmd()
914 … err = avdt_msg_prs_cfg(p_msg->config_cmd.p_cfg, p, len, &p_msg->hdr.err_param, AVDT_SIG_RECONFIG); in avdt_msg_prs_reconfig_cmd()
942 static UINT8 avdt_msg_prs_multi(tAVDT_MSG *p_msg, UINT8 *p, UINT16 len) in avdt_msg_prs_multi() argument
959 AVDT_MSG_PRS_SEID(p, p_msg->multi.seid_list[i]); in avdt_msg_prs_multi()
984 static UINT8 avdt_msg_prs_security_cmd(tAVDT_MSG *p_msg, UINT8 *p, UINT16 len) in avdt_msg_prs_security_cmd() argument
996 AVDT_MSG_PRS_SEID(p, p_msg->security_cmd.hdr.seid); in avdt_msg_prs_security_cmd()
1003 p_msg->security_cmd.p_data = p; in avdt_msg_prs_security_cmd()
1021 static UINT8 avdt_msg_prs_discover_rsp(tAVDT_MSG *p_msg, UINT8 *p, UINT16 len) in avdt_msg_prs_discover_rsp() argument
1038 AVDT_MSG_PRS_DISC(p, p_msg->discover_rsp.p_sep_info[i].seid, in avdt_msg_prs_discover_rsp()
1066 static UINT8 avdt_msg_prs_svccap(tAVDT_MSG *p_msg, UINT8 *p, UINT16 len) in avdt_msg_prs_svccap() argument
1069 …UINT8 err = avdt_msg_prs_cfg(p_msg->svccap.p_cfg, p, len, &p_msg->hdr.err_param, AVDT_SIG_GETCAP… in avdt_msg_prs_svccap()
1089 static UINT8 avdt_msg_prs_all_svccap(tAVDT_MSG *p_msg, UINT8 *p, UINT16 len) in avdt_msg_prs_all_svccap() argument
1091 …UINT8 err = avdt_msg_prs_cfg(p_msg->svccap.p_cfg, p, len, &p_msg->hdr.err_param, AVDT_SIG_GET_AL… in avdt_msg_prs_all_svccap()
1110 static UINT8 avdt_msg_prs_security_rsp(tAVDT_MSG *p_msg, UINT8 *p, UINT16 len) in avdt_msg_prs_security_rsp() argument
1112 p_msg->security_rsp.p_data = p; in avdt_msg_prs_security_rsp()
1128 static UINT8 avdt_msg_prs_rej(tAVDT_MSG *p_msg, UINT8 *p, UINT8 sig) in avdt_msg_prs_rej() argument
1132 p_msg->hdr.err_param = *p++; in avdt_msg_prs_rej()
1133 p_msg->hdr.err_code = *p; in avdt_msg_prs_rej()
1137 AVDT_MSG_PRS_SEID(p, p_msg->hdr.err_param); in avdt_msg_prs_rej()
1138 p_msg->hdr.err_code = *p; in avdt_msg_prs_rej()
1142 p_msg->hdr.err_code = *p; in avdt_msg_prs_rej()
1159 static UINT8 avdt_msg_prs_delay_rpt (tAVDT_MSG *p_msg, UINT8 *p, UINT16 len) in avdt_msg_prs_delay_rpt() argument
1172 AVDT_MSG_PRS_SEID (p, p_msg->delay_rpt_cmd.hdr.seid); in avdt_msg_prs_delay_rpt()
1180 BE_STREAM_TO_UINT16 (p_msg->delay_rpt_cmd.delay, p); in avdt_msg_prs_delay_rpt()
1205 UINT8 *p; in avdt_msg_send() local
1328 p = (UINT8 *)(p_buf + 1) + p_buf->offset; in avdt_msg_send()
1331 AVDT_MSG_BLD_HDR(p, label, pkt_type, msg); in avdt_msg_send()
1334 AVDT_MSG_BLD_NOSP(p, nosp); in avdt_msg_send()
1338 AVDT_MSG_BLD_SIG(p, sig); in avdt_msg_send()
1360 UINT8 *p; in avdt_msg_asmbl() local
1365 p = (UINT8 *)(p_buf + 1) + p_buf->offset; in avdt_msg_asmbl()
1366 AVDT_MSG_PRS_PKT_TYPE(p, pkt_type); in avdt_msg_asmbl()
1408 p = (UINT8 *)(p_ccb->p_rx_msg + 1) + p_ccb->p_rx_msg->offset; in avdt_msg_asmbl()
1411 *(p + 1) = *p; in avdt_msg_asmbl()
1493 UINT8 *p; in avdt_msg_send_cmd() local
1499 p_start = p = (UINT8 *)(p_buf + 1) + p_buf->offset; in avdt_msg_send_cmd()
1502 (*avdt_msg_bld_cmd[sig_id - 1])(&p, p_params); in avdt_msg_send_cmd()
1505 p_buf->len = (UINT16) (p - p_start); in avdt_msg_send_cmd()
1510 p = (UINT8 *)(p_buf + 1); in avdt_msg_send_cmd()
1515 memcpy(p, (UINT8 *) p_scb, p_buf->len); in avdt_msg_send_cmd()
1520 *p = avdt_scb_to_hdl((tAVDT_SCB *) p_scb); in avdt_msg_send_cmd()
1554 UINT8 *p; in avdt_msg_send_rsp() local
1560 p_start = p = (UINT8 *)(p_buf + 1) + p_buf->offset; in avdt_msg_send_rsp()
1563 (*avdt_msg_bld_rsp[sig_id - 1])(&p, p_params); in avdt_msg_send_rsp()
1566 p_buf->len = (UINT16) (p - p_start); in avdt_msg_send_rsp()
1595 UINT8 *p; in avdt_msg_send_rej() local
1601 p_start = p = (UINT8 *)(p_buf + 1) + p_buf->offset; in avdt_msg_send_rej()
1610 AVDT_MSG_BLD_PARAM(p, p_params->hdr.err_param); in avdt_msg_send_rej()
1615 AVDT_MSG_BLD_SEID(p, p_params->hdr.err_param); in avdt_msg_send_rej()
1619 AVDT_MSG_BLD_ERR(p, p_params->hdr.err_code); in avdt_msg_send_rej()
1624 p_buf->len = (UINT16) (p - p_start); in avdt_msg_send_rej()
1652 UINT8 *p; in avdt_msg_send_grej() local
1658 p_start = p = (UINT8 *)(p_buf + 1) + p_buf->offset; in avdt_msg_send_grej()
1661 p_buf->len = (UINT16) (p - p_start); in avdt_msg_send_grej()
1689 UINT8 *p; in avdt_msg_ind() local
1709 p = (UINT8 *)(p_buf + 1) + p_buf->offset; in avdt_msg_ind()
1712 AVDT_MSG_PRS_HDR(p, label, pkt_type, msg_type); in avdt_msg_ind()
1742 AVDT_MSG_PRS_SIG(p, sig); in avdt_msg_ind()
1794 msg.hdr.err_code = err = (*avdt_msg_prs_cmd[sig - 1])(&msg, p, p_buf->len); in avdt_msg_ind()
1799 msg.hdr.err_code = err = (*avdt_msg_prs_rsp[sig - 1])(&msg, p, p_buf->len); in avdt_msg_ind()
1804 err = avdt_msg_prs_rej(&msg, p, sig); in avdt_msg_ind()