/Zephyr-Core-3.5.0/subsys/bluetooth/mesh/ |
D | blob_cli.c | 18 #define TARGETS_FOR_EACH(cli, target) \ argument 19 SYS_SLIST_FOR_EACH_CONTAINER((sys_slist_t *)&(cli)->inputs->targets, \ 27 #define CLIENT_TIMEOUT_MSEC(cli) (10 * MSEC_PER_SEC * (cli->inputs->timeout_base + 2) + \ argument 28 100 * cli->inputs->ttl) 32 #define SENDING_CHUNKS_IN_PULL_MODE(cli) ((cli)->state == BT_MESH_BLOB_CLI_STATE_BLOCK_SEND && \ argument 33 (cli)->xfer->mode == BT_MESH_BLOB_XFER_MODE_PULL) 34 #define UNICAST_MODE(cli) ((cli)->inputs->group == BT_MESH_ADDR_UNASSIGNED || \ argument 35 (cli)->tx.ctx.force_unicast) 58 static struct bt_mesh_blob_target *next_target(struct bt_mesh_blob_cli *cli, 60 static void transfer_cancel(struct bt_mesh_blob_cli *cli); [all …]
|
D | dfu_cli.c | 20 #define TARGETS_FOR_EACH(cli, target) \ argument 22 (sys_slist_t *)&((cli)->blob.inputs)->targets, target, blob.n) 24 #define MSG_CTX(cli, dst) \ argument 26 .app_idx = (cli)->blob.inputs->app_idx, .addr = dst, \ 27 .send_ttl = (cli)->blob.inputs->ttl, \ 71 static struct bt_mesh_dfu_target *target_get(struct bt_mesh_dfu_cli *cli, in target_get() argument 76 TARGETS_FOR_EACH(cli, target) { in target_get() 85 static void target_failed(struct bt_mesh_dfu_cli *cli, in target_failed() argument 100 if (cli->cb && cli->cb->lost_target) { in target_failed() 101 cli->cb->lost_target(cli, target); in target_failed() [all …]
|
D | rpr_cli.c | 38 struct bt_mesh_rpr_cli *cli; member 46 static void link_reset(struct bt_mesh_rpr_cli *cli); 47 static void link_closed(struct bt_mesh_rpr_cli *cli, 50 static void link_report(struct bt_mesh_rpr_cli *cli, in link_report() argument 54 struct pb_remote_ctx ctx = { cli, srv }; in link_report() 65 cli->link.time = PROTOCOL_TIMEOUT_SEC; in link_report() 81 static void tx_complete(struct bt_mesh_rpr_cli *cli, int err, void *cb_data) in tx_complete() argument 85 cli->link.tx_pdu++; in tx_complete() 86 bt_mesh_msg_ack_ctx_clear(&cli->prov_ack_ctx); in tx_complete() 97 struct bt_mesh_rpr_cli *cli = mod->user_data; in handle_extended_scan_report() local [all …]
|
D | health_cli.c | 43 struct bt_mesh_health_cli *cli = model->user_data; in health_fault_status() local 54 if (bt_mesh_msg_ack_ctx_match(&cli->ack_ctx, in health_fault_status() 80 bt_mesh_msg_ack_ctx_rx(&cli->ack_ctx); in health_fault_status() 84 if (cli->fault_status) { in health_fault_status() 85 cli->fault_status(cli, ctx->addr, test_id, cid, in health_fault_status() 96 struct bt_mesh_health_cli *cli = model->user_data; in health_current_status() local 108 if (cli->current_status) { in health_current_status() 109 cli->current_status(cli, ctx->addr, test_id, cid, in health_current_status() 124 struct bt_mesh_health_cli *cli = model->user_data; in health_period_status() local 133 if (bt_mesh_msg_ack_ctx_match(&cli->ack_ctx, in health_period_status() [all …]
|
D | sar_cfg_cli.c | 22 static struct bt_mesh_sar_cfg_cli *cli; variable 30 if (!bt_mesh_msg_ack_ctx_match(&cli->ack_ctx, OP_SAR_CFG_TX_STATUS, in transmitter_status() 43 bt_mesh_msg_ack_ctx_rx(&cli->ack_ctx); in transmitter_status() 58 if (!bt_mesh_msg_ack_ctx_match(&cli->ack_ctx, OP_SAR_CFG_RX_STATUS, in receiver_status() 69 bt_mesh_msg_ack_ctx_rx(&cli->ack_ctx); in receiver_status() 82 return cli->timeout; in bt_mesh_sar_cfg_cli_timeout_get() 87 cli->timeout = timeout; in bt_mesh_sar_cfg_cli_timeout_set() 102 cli = model->user_data; in bt_mesh_sar_cfg_cli_init() 103 cli->model = model; in bt_mesh_sar_cfg_cli_init() 104 cli->timeout = 2 * MSEC_PER_SEC; in bt_mesh_sar_cfg_cli_init() [all …]
|
D | priv_beacon_cli.c | 17 static struct bt_mesh_priv_beacon_cli *cli; variable 39 if (bt_mesh_msg_ack_ctx_match(&cli->ack_ctx, OP_PRIV_BEACON_STATUS, ctx->addr, in handle_beacon_status() 44 bt_mesh_msg_ack_ctx_rx(&cli->ack_ctx); in handle_beacon_status() 47 if (cli->cb && cli->cb->priv_beacon_status) { in handle_beacon_status() 53 cli->cb->priv_beacon_status(cli, ctx->addr, &state); in handle_beacon_status() 75 if (bt_mesh_msg_ack_ctx_match(&cli->ack_ctx, OP_PRIV_GATT_PROXY_STATUS, ctx->addr, in handle_gatt_proxy_status() 79 bt_mesh_msg_ack_ctx_rx(&cli->ack_ctx); in handle_gatt_proxy_status() 82 if (cli->cb && cli->cb->priv_gatt_proxy_status) { in handle_gatt_proxy_status() 83 cli->cb->priv_gatt_proxy_status(cli, ctx->addr, proxy); in handle_gatt_proxy_status() 108 if (bt_mesh_msg_ack_ctx_match(&cli->ack_ctx, OP_PRIV_NODE_ID_STATUS, ctx->addr, in handle_node_id_status() [all …]
|
D | od_priv_proxy_cli.c | 19 static struct bt_mesh_od_priv_proxy_cli *cli; variable 34 if (bt_mesh_msg_ack_ctx_match(&cli->ack_ctx, OP_OD_PRIV_PROXY_STATUS, in handle_proxy_status() 40 bt_mesh_msg_ack_ctx_rx(&cli->ack_ctx); in handle_proxy_status() 44 if (cli->od_status) { in handle_proxy_status() 45 cli->od_status(cli, ctx->addr, state_rsp); in handle_proxy_status() 61 .ack = &cli->ack_ctx, in bt_mesh_od_priv_proxy_cli_get() 70 return bt_mesh_msg_ackd_send(cli->model, &ctx, &msg, val_rsp ? &rsp : NULL); in bt_mesh_od_priv_proxy_cli_get() 77 .ack = &cli->ack_ctx, in bt_mesh_od_priv_proxy_cli_set() 88 return bt_mesh_msg_ackd_send(cli->model, &ctx, &msg, val_rsp ? &rsp : NULL); in bt_mesh_od_priv_proxy_cli_set() 103 cli = mod->user_data; in on_demand_proxy_cli_init() [all …]
|
D | large_comp_data_cli.c | 33 static struct bt_mesh_large_comp_data_cli *cli; variable 38 void (*cb)(struct bt_mesh_large_comp_data_cli *cli, uint16_t addr, in data_status() argument 54 if (bt_mesh_msg_ack_ctx_match(&cli->ack_ctx, op, ctx->addr, (void **)&rsp)) { in data_status() 64 bt_mesh_msg_ack_ctx_rx(&cli->ack_ctx); in data_status() 75 cb(cli, ctx->addr, &status_rsp); in data_status() 85 (cli->cb && cli->cb->large_comp_data_status ? in large_comp_data_status() 86 cli->cb->large_comp_data_status : NULL)); in large_comp_data_status() 93 (cli->cb && cli->cb->models_metadata_status ? in models_metadata_status() 94 cli->cb->models_metadata_status : NULL)); in models_metadata_status() 113 cli = model->user_data; in large_comp_data_cli_init() [all …]
|
D | sol_pdu_rpl_cli.c | 16 static struct bt_mesh_sol_pdu_rpl_cli *cli; variable 60 if (bt_mesh_msg_ack_ctx_match(&cli->ack_ctx, OP_SOL_PDU_RPL_ITEM_STATUS, in handle_status() 70 bt_mesh_msg_ack_ctx_rx(&cli->ack_ctx); in handle_status() 73 if (cli->srpl_status) { in handle_status() 74 cli->srpl_status(cli, ctx->addr, primary, len); in handle_status() 101 .ack = &cli->ack_ctx, in bt_mesh_sol_pdu_rpl_clear() 124 return bt_mesh_msg_ackd_send(cli->model, ctx, &msg, in bt_mesh_sol_pdu_rpl_clear() 148 return bt_mesh_msg_send(cli->model, ctx, &msg); in bt_mesh_sol_pdu_rpl_clear_unack() 172 cli = mod->user_data; in sol_pdu_rpl_cli_init() 173 cli->model = mod; in sol_pdu_rpl_cli_init() [all …]
|
D | cfg_cli.c | 49 static struct bt_mesh_cfg_cli *cli; variable 66 if (bt_mesh_msg_ack_ctx_match(&cli->ack_ctx, OP_DEV_COMP_DATA_STATUS, ctx->addr, in comp_data_status() 77 bt_mesh_msg_ack_ctx_rx(&cli->ack_ctx); in comp_data_status() 81 if (cli->cb && cli->cb->comp_data) { in comp_data_status() 82 cli->cb->comp_data(cli, ctx->addr, page, buf); in comp_data_status() 101 if (bt_mesh_msg_ack_ctx_match(&cli->ack_ctx, expect_status, ctx->addr, in state_status_u8() 108 bt_mesh_msg_ack_ctx_rx(&cli->ack_ctx); in state_status_u8() 122 if (cli->cb && cli->cb->beacon_status) { in beacon_status() 123 cli->cb->beacon_status(cli, ctx->addr, status); in beacon_status() 137 if (cli->cb && cli->cb->ttl_status) { in ttl_status() [all …]
|
D | op_agg_cli.c | 28 } cli; variable 46 if (!bt_mesh_msg_ack_ctx_match(&cli.ack_ctx, in handle_status() 86 bt_mesh_msg_ack_ctx_rx(&cli.ack_ctx); in handle_status() 109 cli.model = model; in op_agg_cli_init() 110 bt_mesh_msg_ack_ctx_init(&cli.ack_ctx); in op_agg_cli_init() 159 err = bt_mesh_msg_ack_ctx_prepare(&cli.ack_ctx, OP_OPCODES_AGGREGATOR_STATUS, agg->addr, in bt_mesh_op_agg_cli_seq_send() 167 err = bt_mesh_model_send(cli.model, &ctx, agg->sdu, NULL, NULL); in bt_mesh_op_agg_cli_seq_send() 170 bt_mesh_msg_ack_ctx_clear(&cli.ack_ctx); in bt_mesh_op_agg_cli_seq_send() 174 return bt_mesh_msg_ack_ctx_wait(&cli.ack_ctx, K_MSEC(msg_timeout)); in bt_mesh_op_agg_cli_seq_send()
|
D | pb_gatt_srv.c | 56 static struct bt_mesh_proxy_role *cli; variable 79 if (cli->conn != conn) { in gatt_recv() 103 bt_mesh_is_provisioned() || info.id != BT_ID_DEFAULT || cli) { in gatt_connected() 107 cli = bt_mesh_proxy_role_setup(conn, gatt_send, proxy_msg_recv); in gatt_connected() 118 info.id != BT_ID_DEFAULT || !cli || cli->conn != conn) { in gatt_disconnected() 122 bt_mesh_proxy_role_cleanup(cli); in gatt_disconnected() 123 cli = NULL; in gatt_disconnected() 140 if (cli->conn != conn) { in prov_ccc_write()
|
/Zephyr-Core-3.5.0/subsys/bluetooth/audio/ |
D | aics_client.c | 37 if (aics_insts[i].cli.conn == conn && in lookup_aics_by_handle() 38 aics_insts[i].cli.active && in lookup_aics_by_handle() 39 aics_insts[i].cli.start_handle <= handle && in lookup_aics_by_handle() 40 aics_insts[i].cli.end_handle >= handle) { in lookup_aics_by_handle() 73 if (handle == inst->cli.state_handle) { in aics_client_notify_handler() 79 inst->cli.change_counter = state->change_counter; in aics_client_notify_handler() 81 if (inst->cli.cb && inst->cli.cb->state) { in aics_client_notify_handler() 82 inst->cli.cb->state(inst, 0, state->gain, in aics_client_notify_handler() 87 } else if (handle == inst->cli.status_handle) { in aics_client_notify_handler() 91 if (inst->cli.cb && inst->cli.cb->status) { in aics_client_notify_handler() [all …]
|
/Zephyr-Core-3.5.0/tests/drivers/clock_control/onoff/src/ |
D | test_clock_control_onoff.c | 40 struct onoff_client cli; in ZTEST() local 46 sys_notify_init_spinwait(&cli.notify); in ZTEST() 47 err = onoff_request(mgr, &cli); in ZTEST() 50 while (sys_notify_fetch_result(&cli.notify, &err) < 0) { in ZTEST() 63 struct onoff_client cli; in ZTEST() local 70 sys_notify_init_spinwait(&cli.notify); in ZTEST() 71 err = onoff_request(mgr, &cli); in ZTEST() 75 err = onoff_cancel_or_release(mgr, &cli); in ZTEST() 83 static void request_cb(struct onoff_manager *mgr, struct onoff_client *cli, in request_cb() argument 88 err = onoff_cancel_or_release(mgr, cli); in request_cb() [all …]
|
/Zephyr-Core-3.5.0/include/zephyr/bluetooth/mesh/ |
D | dfu_cli.h | 126 struct bt_mesh_dfu_cli *cli, struct bt_mesh_msg_ctx *ctx, uint8_t idx, 137 void (*suspended)(struct bt_mesh_dfu_cli *cli); 147 void (*ended)(struct bt_mesh_dfu_cli *cli, 157 void (*applied)(struct bt_mesh_dfu_cli *cli); 166 void (*confirmed)(struct bt_mesh_dfu_cli *cli); 176 void (*lost_target)(struct bt_mesh_dfu_cli *cli, 252 int bt_mesh_dfu_cli_send(struct bt_mesh_dfu_cli *cli, 263 int bt_mesh_dfu_cli_suspend(struct bt_mesh_dfu_cli *cli); 271 int bt_mesh_dfu_cli_resume(struct bt_mesh_dfu_cli *cli); 283 int bt_mesh_dfu_cli_cancel(struct bt_mesh_dfu_cli *cli, [all …]
|
D | health_cli.h | 49 void (*period_status)(struct bt_mesh_health_cli *cli, uint16_t addr, 61 void (*attention_status)(struct bt_mesh_health_cli *cli, uint16_t addr, 79 void (*fault_status)(struct bt_mesh_health_cli *cli, uint16_t addr, 98 void (*current_status)(struct bt_mesh_health_cli *cli, uint16_t addr, 137 int bt_mesh_health_cli_fault_get(struct bt_mesh_health_cli *cli, struct bt_mesh_msg_ctx *ctx, 163 int bt_mesh_health_cli_fault_clear(struct bt_mesh_health_cli *cli, struct bt_mesh_msg_ctx *ctx, 178 int bt_mesh_health_cli_fault_clear_unack(struct bt_mesh_health_cli *cli, 200 int bt_mesh_health_cli_fault_test(struct bt_mesh_health_cli *cli, struct bt_mesh_msg_ctx *ctx, 214 int bt_mesh_health_cli_fault_test_unack(struct bt_mesh_health_cli *cli, struct bt_mesh_msg_ctx *ctx, 241 int bt_mesh_health_cli_period_get(struct bt_mesh_health_cli *cli, struct bt_mesh_msg_ctx *ctx, [all …]
|
D | blob_cli.h | 202 void (*caps)(struct bt_mesh_blob_cli *cli, 215 void (*lost_target)(struct bt_mesh_blob_cli *cli, 225 void (*suspended)(struct bt_mesh_blob_cli *cli); 237 void (*end)(struct bt_mesh_blob_cli *cli, 249 void (*xfer_progress)(struct bt_mesh_blob_cli *cli, 259 void (*xfer_progress_complete)(struct bt_mesh_blob_cli *cli); 265 void (*send)(struct bt_mesh_blob_cli *cli, uint16_t dst); 267 void (*send_complete)(struct bt_mesh_blob_cli *cli, uint16_t dst); 272 void (*next)(struct bt_mesh_blob_cli *cli); 339 int bt_mesh_blob_cli_caps_get(struct bt_mesh_blob_cli *cli, [all …]
|
D | rpr_cli.h | 75 void (*scan_report)(struct bt_mesh_rpr_cli *cli, 105 int bt_mesh_rpr_scan_caps_get(struct bt_mesh_rpr_cli *cli, 117 int bt_mesh_rpr_scan_get(struct bt_mesh_rpr_cli *cli, 144 int bt_mesh_rpr_scan_start(struct bt_mesh_rpr_cli *cli, 188 int bt_mesh_rpr_scan_start_ext(struct bt_mesh_rpr_cli *cli, 201 int bt_mesh_rpr_scan_stop(struct bt_mesh_rpr_cli *cli, 213 int bt_mesh_rpr_link_get(struct bt_mesh_rpr_cli *cli, 225 int bt_mesh_rpr_link_close(struct bt_mesh_rpr_cli *cli,
|
D | cfg_cli.h | 48 void (*comp_data)(struct bt_mesh_cfg_cli *cli, uint16_t addr, uint8_t page, 63 void (*mod_pub_status)(struct bt_mesh_cfg_cli *cli, uint16_t addr, uint8_t status, 78 void (*mod_sub_status)(struct bt_mesh_cfg_cli *cli, uint16_t addr, 98 void (*mod_sub_list)(struct bt_mesh_cfg_cli *cli, uint16_t addr, uint8_t status, 109 void (*node_reset_status)(struct bt_mesh_cfg_cli *cli, uint16_t addr); 119 void (*beacon_status)(struct bt_mesh_cfg_cli *cli, uint16_t addr, 130 void (*ttl_status)(struct bt_mesh_cfg_cli *cli, uint16_t addr, 141 void (*friend_status)(struct bt_mesh_cfg_cli *cli, uint16_t addr, 152 void (*gatt_proxy_status)(struct bt_mesh_cfg_cli *cli, uint16_t addr, 163 void (*network_transmit_status)(struct bt_mesh_cfg_cli *cli, uint16_t addr, [all …]
|
/Zephyr-Core-3.5.0/include/zephyr/sys/ |
D | onoff.h | 253 struct onoff_client *cli, 348 struct onoff_client *cli); 402 struct onoff_client *cli); 436 struct onoff_client *cli) in onoff_cancel_or_release() argument 438 int rv = onoff_cancel(mgr, cli); in onoff_cancel_or_release() 482 struct onoff_client *cli); 637 struct onoff_client *cli,
|
/Zephyr-Core-3.5.0/lib/os/ |
D | onoff.c | 123 struct onoff_client *cli) in validate_args() argument 125 if ((mgr == NULL) || (cli == NULL)) { in validate_args() 129 int rv = sys_notify_validate(&cli->notify); in validate_args() 132 && ((cli->notify.flags in validate_args() 169 struct onoff_client *cli, in notify_one() argument 174 (onoff_client_callback)sys_notify_finalize(&cli->notify, res); in notify_one() 177 cb(mgr, cli, state, res); in notify_one() 188 struct onoff_client *cli = in notify_all() local 193 notify_one(mgr, cli, state, res); in notify_all() 422 struct onoff_client *cli) in onoff_request() argument [all …]
|
/Zephyr-Core-3.5.0/subsys/bluetooth/controller/ll_sw/nordic/lll/ |
D | lll_clock.c | 22 struct onoff_client cli; member 29 static void clock_ready(struct onoff_manager *mgr, struct onoff_client *cli, in clock_ready() argument 33 CONTAINER_OF(cli, struct lll_clock_state, cli); in clock_ready() 45 sys_notify_init_callback(&state.cli.notify, clock_ready); in blocking_on() 46 err = onoff_request(mgr, &state.cli); in blocking_on()
|
/Zephyr-Core-3.5.0/subsys/bluetooth/mesh/shell/ |
D | health.c | 43 struct bt_mesh_health_cli *cli = mod->user_data; in cmd_fault_get() local 60 err = bt_mesh_health_cli_fault_get(cli, ctx.addr ? &ctx : NULL, cid, &test_id, faults, in cmd_fault_get() 77 struct bt_mesh_health_cli *cli = mod->user_data; in fault_clear() local 94 err = bt_mesh_health_cli_fault_clear(cli, ctx.addr ? &ctx : NULL, cid, &test_id, in fault_clear() 105 err = bt_mesh_health_cli_fault_clear_unack(cli, ctx.addr ? &ctx : NULL, cid); in fault_clear() 129 struct bt_mesh_health_cli *cli = mod->user_data; in fault_test() local 147 err = bt_mesh_health_cli_fault_test(cli, ctx.addr ? &ctx : NULL, cid, test_id, in fault_test() 158 err = bt_mesh_health_cli_fault_test_unack(cli, ctx.addr ? &ctx : NULL, cid, test_id); in fault_test() 182 struct bt_mesh_health_cli *cli = mod->user_data; in cmd_period_get() local 188 err = bt_mesh_health_cli_period_get(cli, ctx.addr ? &ctx : NULL, &divisor); in cmd_period_get() [all …]
|
/Zephyr-Core-3.5.0/drivers/clock_control/ |
D | nrf_clock_calibration.c | 41 struct onoff_client *cli, 44 struct onoff_client *cli, 70 static void clk_request(struct onoff_manager *mgr, struct onoff_client *cli, in clk_request() argument 75 sys_notify_init_callback(&cli->notify, callback); in clk_request() 76 err = onoff_request(mgr, cli); in clk_request() 109 struct onoff_client *cli, in cal_lf_callback() argument 165 struct onoff_client *cli, in cal_hf_callback() argument
|
/Zephyr-Core-3.5.0/tests/drivers/clock_control/nrf_onoff_and_bt/src/ |
D | main.c | 24 static struct onoff_client cli; variable 117 sys_notify_init_spinwait(&cli.notify); in ZTEST() 118 err = onoff_request(hf_mgr, &cli); in ZTEST() 127 err = onoff_cancel_or_release(hf_mgr, &cli); in ZTEST() 151 err = onoff_cancel_or_release(hf_mgr, &cli); in onoff_timeout_handler() 155 sys_notify_init_spinwait(&cli.notify); in onoff_timeout_handler() 156 err = onoff_request(hf_mgr, &cli); in onoff_timeout_handler()
|