/Zephyr-latest/tests/lib/notify/src/ |
D | main.c | 33 struct sys_notify notify = { in ZTEST() local 39 zassert_equal(sys_notify_validate(¬ify), -EINVAL, in ZTEST() 50 struct sys_notify notify; in ZTEST() local 53 memset(¬ify, 0xac, sizeof(notify)); in ZTEST() 54 rc = sys_notify_validate(¬ify); in ZTEST() 58 sys_notify_init_spinwait(¬ify); in ZTEST() 59 rc = sys_notify_validate(¬ify); in ZTEST() 63 zassert_false(sys_notify_uses_callback(¬ify), in ZTEST() 66 zassert_equal(notify.flags, SYS_NOTIFY_METHOD_SPINWAIT, in ZTEST() 69 set_extflags(¬ify, xflags); in ZTEST() [all …]
|
/Zephyr-latest/include/zephyr/sys/ |
D | notify.h | 178 static inline uint32_t sys_notify_get_method(const struct sys_notify *notify) in sys_notify_get_method() argument 180 uint32_t method = notify->flags >> SYS_NOTIFY_METHOD_POS; in sys_notify_get_method() 204 int sys_notify_validate(struct sys_notify *notify); 222 sys_notify_generic_callback sys_notify_finalize(struct sys_notify *notify, 237 static inline int sys_notify_fetch_result(const struct sys_notify *notify, in sys_notify_fetch_result() argument 240 __ASSERT_NO_MSG(notify != NULL); in sys_notify_fetch_result() 244 if (sys_notify_get_method(notify) == SYS_NOTIFY_METHOD_COMPLETED) { in sys_notify_fetch_result() 246 *result = notify->result; in sys_notify_fetch_result() 264 static inline void sys_notify_init_spinwait(struct sys_notify *notify) in sys_notify_init_spinwait() argument 266 __ASSERT_NO_MSG(notify != NULL); in sys_notify_init_spinwait() [all …]
|
/Zephyr-latest/lib/utils/ |
D | notify.c | 11 int sys_notify_validate(struct sys_notify *notify) in sys_notify_validate() argument 15 if (notify == NULL) { in sys_notify_validate() 20 switch (sys_notify_get_method(notify)) { in sys_notify_validate() 24 if (notify->method.callback == NULL) { in sys_notify_validate() 30 if (notify->method.signal == NULL) { in sys_notify_validate() 42 notify->result = 0; in sys_notify_validate() 48 sys_notify_generic_callback sys_notify_finalize(struct sys_notify *notify, in sys_notify_finalize() argument 53 uint32_t method = sys_notify_get_method(notify); in sys_notify_finalize() 58 notify->result = res; in sys_notify_finalize() 63 rv = notify->method.callback; in sys_notify_finalize() [all …]
|
/Zephyr-latest/soc/nordic/nrf53/ |
D | nrf53_cpunet_mgmt.c | 24 static void onoff_start(struct onoff_manager *mgr, onoff_notify_fn notify) in onoff_start() argument 28 notify(mgr, 0); in onoff_start() 31 static void onoff_stop(struct onoff_manager *mgr, onoff_notify_fn notify) in onoff_stop() argument 35 notify(mgr, 0); in onoff_stop() 57 sys_notify_init_spinwait(&cli.notify); in nrf53_cpunet_enable() 63 ret = sys_notify_fetch_result(&cli.notify, &ignored); in nrf53_cpunet_enable()
|
/Zephyr-latest/soc/nordic/nrf54h/gpd/ |
D | gpd.c | 31 onoff_notify_fn notify; member 38 static void start(struct onoff_manager *mgr, onoff_notify_fn notify); 39 static void stop(struct onoff_manager *mgr, onoff_notify_fn notify); 156 gpd_mgr->notify(&gpd_mgr->mgr, 0); in evt_handler() 160 gpd_mgr->notify(&gpd_mgr->mgr, -EIO); in evt_handler() 176 static void start(struct onoff_manager *mgr, onoff_notify_fn notify) in start() argument 180 gpd_mgr->notify = notify; in start() 183 notify(mgr, 0); in start() 190 notify(mgr, -EIO); in start() 195 static void stop(struct onoff_manager *mgr, onoff_notify_fn notify) in stop() argument [all …]
|
/Zephyr-latest/subsys/bluetooth/audio/ |
D | vcp_vol_rend.c | 69 ATOMIC_DEFINE(notify, NOTIFY_NUM); 93 static const char *vol_rend_notify_str(enum vol_rend_notify notify) in vol_rend_notify_str() argument 95 switch (notify) { in vol_rend_notify_str() 105 static void notify_work_reschedule(struct bt_vcp_vol_rend *inst, enum vol_rend_notify notify, in notify_work_reschedule() argument 110 atomic_set_bit(inst->notify, notify); in notify_work_reschedule() 114 LOG_ERR("Failed to reschedule %s notification err %d", vol_rend_notify_str(notify), in notify_work_reschedule() 117 LOG_DBG("%s notification scheduled in %dms", vol_rend_notify_str(notify), in notify_work_reschedule() 122 static void notify(struct bt_vcp_vol_rend *inst, enum vol_rend_notify notify, in notify() argument 129 notify_work_reschedule(inst, notify, K_USEC(BT_AUDIO_NOTIFY_RETRY_DELAY_US)); in notify() 131 LOG_ERR("Notify %s err %d", vol_rend_notify_str(notify), err); in notify() [all …]
|
D | vocs.c | 65 static const char *vocs_notify_str(enum bt_vocs_notify notify) in vocs_notify_str() argument 67 switch (notify) { in vocs_notify_str() 79 static void notify_work_reschedule(struct bt_vocs_server *inst, enum bt_vocs_notify notify, in notify_work_reschedule() argument 84 atomic_set_bit(inst->notify, notify); in notify_work_reschedule() 89 vocs_notify_str(notify), err); in notify_work_reschedule() 93 static void notify(struct bt_vocs_server *inst, enum bt_vocs_notify notify, in notify() argument 100 notify_work_reschedule(inst, notify, K_USEC(BT_AUDIO_NOTIFY_RETRY_DELAY_US)); in notify() 102 LOG_ERR("Notify %s err %d", vocs_notify_str(notify), err); in notify() 111 if (atomic_test_and_clear_bit(inst->notify, NOTIFY_STATE)) { in notify_work_handler() 112 notify(inst, NOTIFY_STATE, BT_UUID_VOCS_STATE, &inst->state, sizeof(inst->state)); in notify_work_handler() [all …]
|
D | aics.c | 179 static const char *aics_notify_str(enum bt_aics_notify notify) in aics_notify_str() argument 181 switch (notify) { in aics_notify_str() 193 static void notify_work_reschedule(struct bt_aics *inst, enum bt_aics_notify notify, in notify_work_reschedule() argument 198 atomic_set_bit(inst->srv.notify, notify); in notify_work_reschedule() 203 aics_notify_str(notify), err); in notify_work_reschedule() 207 static void notify(struct bt_aics *inst, enum bt_aics_notify notify, const struct bt_uuid *uuid, in notify() function 214 notify_work_reschedule(inst, notify, K_USEC(BT_AUDIO_NOTIFY_RETRY_DELAY_US)); in notify() 216 LOG_ERR("Notify %s err %d", aics_notify_str(notify), err); in notify() 225 if (atomic_test_and_clear_bit(inst->srv.notify, AICS_NOTIFY_STATE)) { in notify_work_handler() 226 notify(inst, AICS_NOTIFY_STATE, BT_UUID_AICS_STATE, &inst->srv.state, in notify_work_handler() [all …]
|
D | mcs.c | 44 static void notify(const struct bt_uuid *uuid, const void *data, uint16_t len); 663 notify(BT_UUID_MCS_MEDIA_CONTROL_POINT, &cmd_ntf, sizeof(cmd_ntf)); in write_control_point() 679 notify(BT_UUID_MCS_MEDIA_CONTROL_POINT, &cmd_ntf, sizeof(cmd_ntf)); in write_control_point() 748 notify(BT_UUID_MCS_SEARCH_CONTROL_POINT, &result_code, sizeof(result_code)); in write_search_control_point() 973 static void notify(const struct bt_uuid *uuid, const void *data, uint16_t len) in notify() function 1061 notify(BT_UUID_MCS_TRACK_DURATION, &duration_le, sizeof(duration_le)); in notify_cb() 1069 notify(BT_UUID_MCS_TRACK_POSITION, &position_le, sizeof(position_le)); in notify_cb() 1076 notify(BT_UUID_MCS_PLAYBACK_SPEED, &speed, sizeof(speed)); in notify_cb() 1083 notify(BT_UUID_MCS_SEEKING_SPEED, &speed, sizeof(speed)); in notify_cb() 1094 notify(BT_UUID_MCS_CURRENT_TRACK_OBJ_ID, track_id_le, sizeof(track_id_le)); in notify_cb() [all …]
|
/Zephyr-latest/drivers/clock_control/ |
D | clock_control_nrf2_common.c | 55 onoff_notify_fn notify) in onoff_start_option() argument 63 onoff->notify = notify; in onoff_start_option() 70 onoff_notify_fn notify) in onoff_stop_option() argument 81 notify(mgr, 0); in onoff_stop_option() 176 onoff_notify_fn notify = cfg->onoff[i].notify; in clock_config_update_end() local 178 if (notify) { in clock_config_update_end() 189 cfg->onoff[i].notify = NULL; in clock_config_update_end() 190 notify(&cfg->onoff[i].mgr, status); in clock_config_update_end() 229 sys_notify_init_callback(&req.cli.notify, sync_cb); in nrf_clock_control_request_sync()
|
D | clock_control_nrf2_hfxo.c | 22 onoff_notify_fn notify; member 69 if (dev_data->notify) { in hfxo_start_up_timer_handler() 70 dev_data->notify(&dev_data->mgr, 0); in hfxo_start_up_timer_handler() 108 static void onoff_start_hfxo(struct onoff_manager *mgr, onoff_notify_fn notify) in onoff_start_hfxo() argument 113 dev_data->notify = notify; in onoff_start_hfxo() 164 static void onoff_stop_hfxo(struct onoff_manager *mgr, onoff_notify_fn notify) in onoff_stop_hfxo() argument 170 notify(mgr, 0); in onoff_stop_hfxo()
|
D | clock_control_nrf.c | 428 onoff_notify_fn notify) in onoff_stop() argument 433 notify(mgr, res); in onoff_stop() 442 onoff_notify_fn notify = user_data; in onoff_started_callback() local 444 notify(mgr, 0); in onoff_started_callback() 448 onoff_notify_fn notify) in onoff_start() argument 453 onoff_started_callback, notify, CTX_ONOFF); in onoff_start() 455 notify(mgr, err); in onoff_start() 558 sys_notify_init_spinwait(&cli.notify); in z_nrf_clock_control_lf_on()
|
/Zephyr-latest/tests/drivers/clock_control/onoff/src/ |
D | test_clock_control_onoff.c | 46 sys_notify_init_spinwait(&cli.notify); in ZTEST() 50 while (sys_notify_fetch_result(&cli.notify, &err) < 0) { in ZTEST() 70 sys_notify_init_spinwait(&cli.notify); in ZTEST() 105 sys_notify_init_callback(&cli.notify, request_cb); in ZTEST()
|
/Zephyr-latest/tests/lib/onoff/src/ |
D | main.c | 93 int rc = sys_notify_fetch_result(&cp->notify, &result); in cli_result() 113 onoff_notify_fn notify; member 121 tsp->notify = NULL; in reset_transit_state() 126 onoff_notify_fn notify, in run_transit() argument 131 tsp->notify = notify; in run_transit() 135 notify(srv, tsp->retval); in run_transit() 139 static void notify(struct transit_state *tsp) in notify() function 141 TC_PRINT("%s settle %d %p\n", tsp->tag, tsp->retval, tsp->notify); in notify() 142 tsp->notify(tsp->srv, tsp->retval); in notify() 143 tsp->notify = NULL; in notify() [all …]
|
/Zephyr-latest/tests/boards/nrf/mram_latency/src/ |
D | main.c | 56 sys_notify_init_callback(&req1.cli.notify, basic_cb); in ZTEST() 62 sys_notify_init_callback(&req2.cli.notify, basic_cb); in ZTEST() 87 sys_notify_init_callback(&req1.cli.notify, basic_cb); in ZTEST() 108 sys_notify_init_callback(&req->cli.notify, basic_cb); in timeout() 161 sys_notify_fetch_result(&early_client.notify, &early_result); in setup() 181 sys_notify_init_spinwait(&early_client.notify); in early_mram_client()
|
/Zephyr-latest/soc/nordic/common/ |
D | mram_latency.c | 66 static void no_latency_start(struct onoff_manager *mgr, onoff_notify_fn notify) in no_latency_start() argument 68 onoff_notify = notify; in no_latency_start() 72 static void no_latency_stop(struct onoff_manager *mgr, onoff_notify_fn notify) in no_latency_stop() argument 119 sys_notify_init_callback(&req.cli.notify, sync_req_cb); in mram_no_latency_sync_request()
|
/Zephyr-latest/include/zephyr/drivers/rtc/ |
D | maxim_ds3231.h | 248 struct sys_notify *notify, 505 struct sys_notify *notify); 569 struct sys_notify *notify);
|
/Zephyr-latest/drivers/usb/uvb/ |
D | uvb.h | 124 void (*notify)(const void *const priv, member 252 .notify = host_notify, \
|
/Zephyr-latest/samples/boards/nordic/clock_control/src/ |
D | main.c | 61 sys_notify_init_callback(&cli.notify, sample_notify_cb); in main() 82 ret = sys_notify_fetch_result(&cli.notify, &res); in main()
|
/Zephyr-latest/samples/drivers/counter/maxim_ds3231/src/ |
D | main.c | 200 struct sys_notify notify; in set_aligned_clock() local 206 sys_notify_init_signal(¬ify, &ss); in set_aligned_clock() 210 rc = maxim_ds3231_set(ds3231, &sp, ¬ify); in set_aligned_clock() 265 struct sys_notify notify; in main() local 272 sys_notify_init_signal(¬ify, &ss); in main() 276 rc = maxim_ds3231_synchronize(ds3231, ¬ify); in main()
|
/Zephyr-latest/subsys/bluetooth/controller/ll_sw/nordic/lll/ |
D | lll_clock.c | 45 sys_notify_init_callback(&state.cli.notify, clock_ready); in blocking_on() 59 sys_notify_init_spinwait(&lf_cli.notify); in lll_clock_init()
|
/Zephyr-latest/include/zephyr/logging/ |
D | log_backend.h | 74 void (*notify)(const struct log_backend *const backend, member 356 if (backend->api->notify) { in log_backend_notify() 357 backend->api->notify(backend, event, arg); in log_backend_notify()
|
/Zephyr-latest/tests/drivers/clock_control/nrf_clock_control/src/ |
D | main.c | 165 sys_notify_init_spinwait(&cli.notify); in test_request_release_clock_spec() 169 ret = sys_notify_fetch_result(&cli.notify, &res); in test_request_release_clock_spec() 253 sys_notify_init_spinwait(&cli.notify); in ZTEST() 295 sys_notify_init_spinwait(&cli.notify); in ZTEST()
|
/Zephyr-latest/drivers/counter/ |
D | maxim_ds3231.c | 112 struct sys_notify *notify; member 783 struct sys_notify *notify = NULL; in sync_finish() local 789 notify = data->sync.notify; in sync_finish() 796 LOG_DBG("sync complete, notify %d to %p or %p\n", rc, notify, signal); in sync_finish() 799 if (notify != NULL) { in sync_finish() 801 (maxim_ds3231_notify_callback)sys_notify_finalize(notify, rc); in sync_finish() 804 cb(dev, notify, rc); in sync_finish() 1000 struct sys_notify *notify) in maxim_ds3231_synchronize() argument 1006 if (notify == NULL) { in maxim_ds3231_synchronize() 1024 data->sync.notify = notify; in maxim_ds3231_synchronize() [all …]
|
/Zephyr-latest/doc/connectivity/bluetooth/shell/host/ |
D | gatt.rst | 21 The server can now notify the client with the command :code:`gatt notify`.
|