Lines Matching refs:srv
51 struct bt_mesh_rpr_node *srv, in link_report() argument
54 struct pb_remote_ctx ctx = { cli, srv }; in link_report()
96 struct bt_mesh_rpr_node srv = RPR_NODE(ctx); in handle_extended_scan_report() local
112 LOG_DBG("0x%04x: %s oob: 0x%04x adv data: %s", srv.addr, in handle_extended_scan_report()
116 LOG_DBG("0x%04x: %s not found.", srv.addr, bt_hex(dev.uuid, 16)); in handle_extended_scan_report()
120 cli->scan_report(cli, &srv, &dev, buf); in handle_extended_scan_report()
129 struct bt_mesh_rpr_node srv = RPR_NODE(ctx); in handle_link_report() local
143 if (cli->link.srv.addr != srv.addr) { in handle_link_report()
144 LOG_DBG("Link report from unknown server 0x%04x", srv.addr); in handle_link_report()
152 LOG_DBG("0x%04x: status: %u state: %u reason: %u", srv.addr, link.status, link.state, in handle_link_report()
159 link_report(cli, &cli->link.srv, &link); in handle_link_report()
168 struct bt_mesh_rpr_node srv = RPR_NODE(ctx); in handle_link_status() local
175 LOG_DBG("0x%04x: status: %u state: %u", srv.addr, link.status, in handle_link_status()
179 srv.addr, (void **)&rsp)) { in handle_link_status()
184 if (cli->link.srv.addr == srv.addr) { in handle_link_status()
189 cli->link.srv.addr = BT_MESH_ADDR_UNASSIGNED; in handle_link_status()
192 link_report(cli, &cli->link.srv, &link); in handle_link_status()
202 struct bt_mesh_rpr_node srv = RPR_NODE(ctx); in handle_pdu_outbound_report() local
206 if (srv.addr != cli->link.srv.addr) { in handle_pdu_outbound_report()
207 LOG_WRN("Outbound report from unknown server 0x%04x", srv.addr); in handle_pdu_outbound_report()
213 LOG_DBG("0x%04x: %u", srv.addr, num); in handle_pdu_outbound_report()
218 srv.addr, &cb_data) || in handle_pdu_outbound_report()
233 struct bt_mesh_rpr_node srv = RPR_NODE(ctx); in handle_pdu_report() local
236 &cli->link.srv, in handle_pdu_report()
240 if (cli->link.srv.addr != srv.addr) { in handle_pdu_report()
241 LOG_WRN("PDU report from unknown server 0x%04x", srv.addr); in handle_pdu_report()
253 LOG_DBG("0x%04x: %u (%u bytes)", srv.addr, pdu, buf->len); in handle_pdu_report()
264 struct bt_mesh_rpr_node srv = RPR_NODE(ctx); in handle_scan_caps_status() local
268 srv.addr, (void **)&caps)) { in handle_scan_caps_status()
269 LOG_WRN("Unexpected scan caps rsp from 0x%04x", srv.addr); in handle_scan_caps_status()
288 struct bt_mesh_rpr_node srv = RPR_NODE(ctx); in handle_scan_report() local
305 LOG_DBG("0x%04x: %s oob: 0x%04x %ddBm", srv.addr, in handle_scan_report()
310 cli->scan_report(cli, &srv, &dev, NULL); in handle_scan_report()
321 struct bt_mesh_rpr_node srv = RPR_NODE(ctx); in handle_scan_status() local
324 srv.addr, (void **)&status)) { in handle_scan_status()
325 LOG_WRN("Unexpected scan status from 0x%04x", srv.addr); in handle_scan_status()
423 struct bt_mesh_msg_ack_ctx *ack_ctx, const struct bt_mesh_rpr_node *srv, in tx_wait() argument
426 struct bt_mesh_msg_ctx ctx = LINK_CTX(srv, false); in tx_wait()
429 err = bt_mesh_msg_ack_ctx_prepare(ack_ctx, rsp, srv->addr, rsp_ctx); in tx_wait()
448 const struct bt_mesh_rpr_node *srv) in link_init() argument
450 cli->link.srv = *srv; in link_init()
460 cli->link.srv.addr = BT_MESH_ADDR_UNASSIGNED; in link_reset()
468 struct bt_mesh_rpr_node srv = cli->link.srv; in link_closed() local
474 LOG_DBG("0x%04x: status: %u state: %u rx: %u tx: %u", srv.addr, link.status, in link_closed()
479 link_report(cli, &srv, &link); in link_closed()
483 const struct bt_mesh_rpr_node *srv, in bt_mesh_rpr_scan_caps_get() argument
489 return tx_wait(cli, &cli->scan_ack_ctx, srv, &buf, RPR_OP_SCAN_CAPS_STATUS, caps); in bt_mesh_rpr_scan_caps_get()
493 const struct bt_mesh_rpr_node *srv, in bt_mesh_rpr_scan_get() argument
499 return tx_wait(cli, &cli->scan_ack_ctx, srv, &buf, RPR_OP_SCAN_STATUS, status); in bt_mesh_rpr_scan_get()
503 const struct bt_mesh_rpr_node *srv, in bt_mesh_rpr_scan_start() argument
522 return tx_wait(cli, &cli->scan_ack_ctx, srv, &buf, RPR_OP_SCAN_STATUS, status); in bt_mesh_rpr_scan_start()
526 const struct bt_mesh_rpr_node *srv, in bt_mesh_rpr_scan_start_ext() argument
530 struct bt_mesh_msg_ctx ctx = LINK_CTX(srv, false); in bt_mesh_rpr_scan_start_ext()
553 const struct bt_mesh_rpr_node *srv, in bt_mesh_rpr_scan_stop() argument
559 return tx_wait(cli, &cli->scan_ack_ctx, srv, &buf, RPR_OP_SCAN_STATUS, status); in bt_mesh_rpr_scan_stop()
563 const struct bt_mesh_rpr_node *srv, in bt_mesh_rpr_link_get() argument
569 return tx_wait(cli, &cli->prov_ack_ctx, srv, &buf, RPR_OP_LINK_STATUS, rsp); in bt_mesh_rpr_link_get()
573 const struct bt_mesh_rpr_node *srv, in bt_mesh_rpr_link_close() argument
580 return tx_wait(cli, &cli->prov_ack_ctx, srv, &buf, RPR_OP_LINK_STATUS, rsp); in bt_mesh_rpr_link_close()
584 const struct bt_mesh_rpr_node *srv, const uint8_t uuid[16], in link_open_prov() argument
587 struct bt_mesh_msg_ctx ctx = LINK_CTX(srv, false); in link_open_prov()
602 const struct bt_mesh_rpr_node *srv, in link_open_node() argument
605 struct bt_mesh_msg_ctx ctx = LINK_CTX(srv, false); in link_open_node()
618 struct bt_mesh_msg_ctx ctx = LINK_CTX(&cli->link.srv, false); in link_close()
621 if (cli->link.srv.addr == BT_MESH_ADDR_UNASSIGNED) { in link_close()
642 struct bt_mesh_msg_ctx ctx = LINK_CTX(&cli->link.srv, true); in send()
645 if (cli->link.srv.addr == BT_MESH_ADDR_UNASSIGNED) { in send()
657 cli->link.srv.addr, cb_data); in send()
710 const struct bt_mesh_rpr_node *srv = ctx->srv; in pb_link_open() local
713 if (cli->link.srv.addr != BT_MESH_ADDR_UNASSIGNED) { in pb_link_open()
724 link_init(cli, srv); in pb_link_open()
727 err = link_open_prov(cli, srv, uuid, timeout); in pb_link_open()
729 err = link_open_node(cli, srv, ctx->refresh); in pb_link_open()