Home
last modified time | relevance | path

Searched full:state (Results 1 – 25 of 2382) sorted by relevance

12345678910>>...96

/Zephyr-latest/subsys/net/l2/ethernet/gptp/
Dgptp_md.c120 struct gptp_sync_rcv_state *state; in gptp_set_md_sync_receive() local
128 state = &GPTP_PORT_STATE(port)->sync_rcv; in gptp_set_md_sync_receive()
129 if (!state->rcvd_sync_ptr || !state->rcvd_follow_up_ptr) { in gptp_set_md_sync_receive()
135 sync_hdr = GPTP_HDR(state->rcvd_sync_ptr); in gptp_set_md_sync_receive()
136 fup_hdr = GPTP_HDR(state->rcvd_follow_up_ptr); in gptp_set_md_sync_receive()
137 fup = GPTP_FOLLOW_UP(state->rcvd_follow_up_ptr); in gptp_set_md_sync_receive()
138 sync_ts = &state->rcvd_sync_ptr->timestamp; in gptp_set_md_sync_receive()
183 struct gptp_pdelay_req_state *state; in gptp_md_pdelay_reset() local
188 state = &GPTP_PORT_STATE(port)->pdelay_req; in gptp_md_pdelay_reset()
191 if (state->lost_responses < port_ds->allowed_lost_responses) { in gptp_md_pdelay_reset()
[all …]
Dgptp_state.h8 * @brief PTP state machines
90 /* State to handle the transition after DISABLED state. */
176 /* Pdelay Request state machine variables. */
205 /** Current state of the state machine. */
206 enum gptp_pdelay_req_states state; member
222 * @brief Pdelay Response state machine variables.
225 /** Current state of the state machine. */
226 enum gptp_pdelay_resp_states state; member
229 /* SyncReceive state machine variables. */
243 /** Current state of the state machine. */
[all …]
Dgptp_mi.c18 static const char * const state2str(enum gptp_port_state state) in state2str() argument
20 switch (state) { in state2str()
44 static const char * const pa_info_state2str(enum gptp_pa_info_states state) in pa_info_state2str() argument
46 switch (state) { in pa_info_state2str()
72 void gptp_change_port_state_debug(int port, enum gptp_port_state state, in gptp_change_port_state_debug() argument
76 void gptp_change_port_state(int port, enum gptp_port_state state) in gptp_change_port_state_debug()
81 if (global_ds->selected_role[port] == state) { in gptp_change_port_state_debug()
86 NET_DBG("[%d] state %s -> %s (%s():%d)", port, in gptp_change_port_state_debug()
88 state2str(state), caller, line); in gptp_change_port_state_debug()
91 global_ds->selected_role[port] = state; in gptp_change_port_state_debug()
[all …]
/Zephyr-latest/lib/posix/options/getopt/
Dgetopt.c50 struct getopt_state *state; in getopt_init() local
52 state = getopt_state_get(); in getopt_init()
54 state->opterr = 1; in getopt_init()
55 state->optind = 1; in getopt_init()
56 state->optopt = 0; in getopt_init()
57 state->optreset = 0; in getopt_init()
58 state->optarg = NULL; in getopt_init()
60 state->place = ""; /* EMSG */ in getopt_init()
63 state->nonopt_start = -1; /* first non option argument (for permute) */ in getopt_init()
64 state->nonopt_end = -1; /* first option after non options (for permute) */ in getopt_init()
[all …]
Dgetopt_long.c61 #define PRINT_ERROR ((state->opterr) && (*options != ':'))
169 parse_long_options(struct getopt_state *state, char * const *nargv, in parse_long_options() argument
180 current_argv = state->place; in parse_long_options()
202 state->optind++; in parse_long_options()
252 state->optopt = 0; in parse_long_options()
270 state->optopt = long_options[match].val; in parse_long_options()
272 state->optopt = 0; in parse_long_options()
283 state->optarg = has_equal; in parse_long_options()
288 state->optarg = nargv[state->optind++]; in parse_long_options()
292 && (state->optarg == NULL)) { in parse_long_options()
[all …]
/Zephyr-latest/subsys/net/lib/lwm2m/
Dlwm2m_senml_cbor_decode.c19 #define log_result(state, result, func) \ argument
22 zcbor_trace_file(state); \
24 zcbor_error_str(zcbor_peek_error(state))); \
30 static bool decode_repeated_record_bn(zcbor_state_t *state, struct record_bn *result);
31 static bool decode_repeated_record_bt(zcbor_state_t *state, struct record_bt *result);
32 static bool decode_repeated_record_n(zcbor_state_t *state, struct record_n *result);
33 static bool decode_repeated_record_t(zcbor_state_t *state, struct record_t *result);
34 static bool decode_repeated_record_union(zcbor_state_t *state, struct record_union_r *result);
35 static bool decode_value(zcbor_state_t *state, struct value_r *result);
36 static bool decode_key_value_pair(zcbor_state_t *state, struct key_value_pair *result);
[all …]
Dlwm2m_senml_cbor_encode.c19 #define log_result(state, result, func) \ argument
22 zcbor_trace_file(state); \
24 zcbor_error_str(zcbor_peek_error(state))); \
30 static bool encode_repeated_record_bn(zcbor_state_t *state, const struct record_bn *input);
31 static bool encode_repeated_record_bt(zcbor_state_t *state, const struct record_bt *input);
32 static bool encode_repeated_record_n(zcbor_state_t *state, const struct record_n *input);
33 static bool encode_repeated_record_t(zcbor_state_t *state, const struct record_t *input);
34 static bool encode_repeated_record_union(zcbor_state_t *state, const struct record_union_r *input);
35 static bool encode_value(zcbor_state_t *state, const struct value_r *input);
36 static bool encode_key_value_pair(zcbor_state_t *state, const struct key_value_pair *input);
[all …]
Dlwm2m_senml_cbor.patch22 #define log_result(state, result, func) do { \
24 zcbor_trace_file(state); \
26 …(*result).record_n_present), (zcbor_decoder_t *)decode_repeated_record_n, state, (&(*result).recor…
27 …(*result).record_t_present), (zcbor_decoder_t *)decode_repeated_record_t, state, (&(*result).recor…
28 …).record_union_present), (zcbor_decoder_t *)decode_repeated_record_union, state, (&(*result).recor…
29state, (*&(*result).record_key_value_pair_m), sizeof(struct record_key_value_pair_m))) || (zcbor_l…
30state, (*&(*result).record_key_value_pair_m), sizeof(struct record_key_value_pair_m))) || (zcbor_l…
38state) && ((zcbor_multi_decode(1, 99, &(*result).lwm2m_senml_record_m_count, (zcbor_decoder_t *)de…
39state) && ((zcbor_multi_decode(1, ZCBOR_ARRAY_SIZE(result->lwm2m_senml_record_m), &(*result).lwm2m…
89 #define log_result(state, result, func) do { \
[all …]
/Zephyr-latest/include/zephyr/
Dsmf.h10 * @brief State Machine Framework header file
19 * @brief State Machine Framework API
20 * @defgroup smf State Machine Framework API
27 * @brief Macro to create a hierarchical state with initial transitions.
29 * @param _entry State entry function or NULL
30 * @param _run State run function or NULL
31 * @param _exit State exit function or NULL
32 * @param _parent State parent object or NULL
33 * @param _initial State initial transition object or NULL
45 * @brief Macro to cast user defined object to state machine
[all …]
/Zephyr-latest/include/zephyr/pm/
Dstate.h25 * @enum pm_state Power management state
29 * @brief Runtime active state
33 * @note This state is correlated with ACPI G0/S0 state
37 * @brief Runtime idle state
39 * Runtime idle is a system sleep state in which all of the cores
40 * enter deepest possible idle state and wait for interrupts, no
44 * @note This state is correlated with ACPI S0ix state
48 * @brief Suspend to idle state
51 * all of the cores in deepest possible idle state and *may* puts
52 * peripherals into low-power states. No operating state is lost (ie.
[all …]
/Zephyr-latest/tests/subsys/input/kbd_matrix_state_dump/
Dtestcase.yaml16 - "I: kbd-matrix state \\[01 -- -- --\\] \\(1\\)"
17 - "I: kbd-matrix state \\[11 -- -- --\\] \\(2\\)"
18 - "I: kbd-matrix state \\[11 02 -- --\\] \\(3\\)"
19 - "I: kbd-matrix state \\[11 02 04 --\\] \\(4\\)"
20 - "I: kbd-matrix state \\[10 02 04 --\\] \\(3\\)"
21 - "I: kbd-matrix state \\[-- 02 04 --\\] \\(2\\)"
22 - "I: kbd-matrix state \\[-- -- 04 --\\] \\(1\\)"
23 - "I: kbd-matrix state \\[-- -- -- --\\] \\(0\\)"
24 - "I: kbd-matrix state \\[-- -- -- 08\\] \\(1\\)"
25 - "I: kbd-matrix state \\[-- -- -- --\\] \\(0\\)"
[all …]
/Zephyr-latest/tests/subsys/pm/device_power_domains/src/
Dmain.c38 enum pm_device_state state; in ZTEST() local
40 /* Initial power state */ in ZTEST()
58 pm_device_state_get(dev, &state); in ZTEST()
59 zassert_equal(PM_DEVICE_STATE_OFF, state, ""); in ZTEST()
63 /* reg_chained is powered off reg_0, so it's power state should change */ in ZTEST()
76 pm_device_state_get(dev, &state); in ZTEST()
77 zassert_equal(PM_DEVICE_STATE_SUSPENDED, state, ""); in ZTEST()
79 pm_device_state_get(dev, &state); in ZTEST()
80 zassert_equal(PM_DEVICE_STATE_OFF, state, ""); in ZTEST()
89 pm_device_state_get(dev, &state); in ZTEST()
[all …]
/Zephyr-latest/include/zephyr/bluetooth/mesh/
Dsar_cfg.h22 /** SAR Transmitter Configuration state structure */
24 /** SAR Segment Interval Step state */
27 /** SAR Unicast Retransmissions Count state */
30 /** SAR Unicast Retransmissions Without Progress Count state */
33 /* SAR Unicast Retransmissions Interval Step state */
36 /** SAR Unicast Retransmissions Interval Increment state */
39 /** SAR Multicast Retransmissions Count state */
42 /** SAR Multicast Retransmissions Interval state */
46 /** SAR Receiver Configuration state structure */
48 /** SAR Segments Threshold state */
[all …]
/Zephyr-latest/tests/bsim/bluetooth/audio/src/
Dbap_scan_delegator_test.c114 struct sync_state *state = CONTAINER_OF(dwork, struct sync_state, pa_timer); in pa_timer_handler() local
116 state->pa_syncing = false; in pa_timer_handler()
118 if (state->recv_state != NULL) { in pa_timer_handler()
121 if (state->recv_state->pa_sync_state == BT_BAP_PA_STATE_INFO_REQ) { in pa_timer_handler()
127 bt_bap_scan_delegator_set_pa_state(state->recv_state->src_id, in pa_timer_handler()
135 struct sync_state *state, in pa_sync_past() argument
150 state->pa_syncing = true; in pa_sync_past()
151 k_work_init_delayable(&state->pa_timer, pa_timer_handler); in pa_sync_past()
152 (void)k_work_reschedule(&state->pa_timer, in pa_sync_past()
159 static int pa_sync_no_past(struct sync_state *state, in pa_sync_no_past() argument
[all …]
/Zephyr-latest/doc/services/smf/
Dindex.rst3 State Machine Framework
11 The State Machine Framework (SMF) is an application agnostic framework that
12 provides an easy way for developers to integrate state machines into their
16 State Creation
19 A state is represented by three functions, where one function implements the
23 defined structure that has the state machine context, :c:struct:`smf_ctx`, as
31 The :c:struct:`smf_ctx` member must be first because the state machine
38 By default, a state can have no ancestor states, resulting in a flat state
39 machine. But to enable the creation of a hierarchical state machine, the
42 By default, the hierarchical state machines do not support initial transitions
[all …]
/Zephyr-latest/drivers/counter/
Dcounter_cmos.c10 * the RTC state. Plus we have to read the state multiple times because we're
26 * A snapshot of the RTC state, or at least the state we're
36 struct state { struct
49 * values in 'struct state' are BCD-encoded. argument
56 * the members of 'struct state'.
62 * Interesting bits in 'struct state'.
88 /* Populate 'state' with current RTC state. */
90 void read_state(struct state *state) in read_state() argument
95 p = (uint8_t *) state; in read_state()
96 for (i = 0; i < sizeof(*state); ++i) { in read_state()
[all …]
/Zephyr-latest/subsys/random/
Drandom_xoshiro128.c19 * generators. It has excellent speed, a state size (128 bits) that is
26 * The state must be seeded so that it is not everywhere zero.
37 static uint32_t state[4]; variable
60 rc = entropy_get_entropy(entropy_driver, (uint8_t *)&state, sizeof(state)); in xoshiro128_init_state()
65 * Reseed the PRNG state with pseudo-random data until it can in xoshiro128_init_state()
69 state[0] = k_cycle_get_32(); in xoshiro128_init_state()
70 state[1] = k_cycle_get_32() ^ 0x9b64c2b0; in xoshiro128_init_state()
71 state[2] = k_cycle_get_32() ^ 0x86d3d2d4; in xoshiro128_init_state()
72 state[3] = k_cycle_get_32() ^ 0xa00ae278; in xoshiro128_init_state()
78 const uint32_t result = rotl(state[0] + state[3], 7) + state[0]; in xoshiro128_next()
[all …]
/Zephyr-latest/subsys/usb/usb_c/
Dusbc_tc_common_internal.h20 * sub-state runs
31 /** Super state that opens the CC lines */
34 /** Super state that applies Rd to the CC lines */
36 /** Unattached Sink State */
38 /** Attach Wait Sink State */
40 /** Attached Sink State */
43 /** Super state that applies Rp to the CC lines */
45 /** Unattached Source State */
47 /** Unattached Wait Source State */
49 /** Attach Wait Source State */
[all …]
/Zephyr-latest/subsys/mgmt/ec_host_cmd/backends/
Dec_host_cmd_backend_uart.c29 * This state represents UART layer is initialized and ready to
30 * receive host request. Once the response is sent, the current state is
31 * reset to this state to accept next packet.
36 * After first byte is received the current state is moved to receiving
37 * state until all the header bytes + datalen bytes are received.
38 * If host_request_timeout was called in this state, it would be
45 * the current state is moved to processing state. Host should not send
46 * any bytes in this state as it would be considered contiguous
52 * Once host task is ready with the response bytes, the current state is
53 * moved to sending state.
[all …]
/Zephyr-latest/modules/hal_nordic/nrf_802154/radio/platform/
Dnrf_802154_random_zephyr.c11 static uint32_t state; variable
15 state ^= (state<<13); in next()
16 state ^= (state>>17); in next()
17 return state ^= (state<<5); in next()
28 err = entropy_get_entropy(dev, (uint8_t *)&state, sizeof(state)); in nrf_802154_random_init()
30 } while (state == 0); in nrf_802154_random_init()
/Zephyr-latest/tests/subsys/pm/device_driver_init/src/
Dmain.c7 * State checking in this test is done via the GPIO state instead of
26 rc = pm_device_state_get(DEVICE_DT_GET(node_id), &state); \
27 zassert_equal(rc, 0, "Device state retrieval failed"); \
28 zassert_equal(state, value, "Unexpected device state");
33 enum pm_device_state state; in ZTEST() local
35 state = -1; in ZTEST()
36 zassert_str_equal("", pm_device_state_str(state), in ZTEST()
37 "Invalid device state"); in ZTEST()
43 zassert_str_equal("active", pm_device_state_str(state), in ZTEST()
44 "Invalid device state"); in ZTEST()
[all …]
/Zephyr-latest/lib/utils/
Donoff.c23 * onoff_manager::flags that indicate the state of the machine. The
28 * * ERROR indicates that the machine is in an error state. When
30 * * ONOFF indicates whether the target/current state is off (clear)
37 * state changes while invoking notifications associated with a
38 * state transition. This bounds the depth by limiting
39 * active process_event() call stacks to two instances. State changes
47 * * RECHECK indicates that a state transition has completed but
48 * process_events() must re-check the overall state to confirm no
57 /* Identify the events that can trigger state changes, as well as an
58 * internal state used when processing deferred actions.
[all …]
/Zephyr-latest/include/zephyr/drivers/
Dpinctrl.h41 /** Default state (state used when the device is in operational state). */
43 /** Sleep state (state used when the device is in low power mode). */
51 /** Pin control state configuration. */
57 /** State identifier (see @ref PINCTRL_STATES). */
70 /** List of state configurations. */
72 /** Number of state configurations. */
82 /** Out of power management configurations, ignore "sleep" state. */
87 * @brief Obtain the state identifier for the given node and state index.
89 * @param state_idx State index.
116 * identifier and state index.
[all …]
/Zephyr-latest/subsys/bluetooth/audio/
Dbap_scan_delegator.c70 struct bt_bap_scan_delegator_recv_state state; member
129 const struct bt_bap_scan_delegator_recv_state *state = &recv_state->state; in bt_debug_dump_recv_state() local
130 const bool is_bad_code = state->encrypt_state == BT_BAP_BIG_ENC_STATE_BAD_CODE; in bt_debug_dump_recv_state()
132 LOG_DBG("Receive State[%d]: src ID %u, addr %s, adv_sid %u, broadcast_id 0x%06X, " in bt_debug_dump_recv_state()
133 "pa_sync_state %u, encrypt state %u%s%s, num_subgroups %u", in bt_debug_dump_recv_state()
134 recv_state->index, state->src_id, bt_addr_le_str(&state->addr), in bt_debug_dump_recv_state()
135 state->adv_sid, state->broadcast_id, state->pa_sync_state, in bt_debug_dump_recv_state()
136 state->encrypt_state, is_bad_code ? ", bad code" : "", in bt_debug_dump_recv_state()
137 is_bad_code ? bt_hex(state->bad_code, sizeof(state->bad_code)) : "", in bt_debug_dump_recv_state()
138 state->num_subgroups); in bt_debug_dump_recv_state()
[all …]
/Zephyr-latest/tests/subsys/pm/power_domain/src/
Dmain.c69 * This way we can check if the subsystem properly handled its state.
116 * - notification when domain state changes
121 enum pm_device_state state; in ZTEST() local
142 pm_device_state_get(domain, &state); in ZTEST()
143 zassert_equal(state, PM_DEVICE_STATE_SUSPENDED); in ZTEST()
145 pm_device_state_get(deva, &state); in ZTEST()
146 zassert_equal(state, PM_DEVICE_STATE_SUSPENDED); in ZTEST()
148 pm_device_state_get(devb, &state); in ZTEST()
149 zassert_equal(state, PM_DEVICE_STATE_SUSPENDED); in ZTEST()
151 pm_device_state_get(devc, &state); in ZTEST()
[all …]

12345678910>>...96