Home
last modified time | relevance | path

Searched refs:result (Results 1 – 25 of 596) sorted by relevance

12345678910>>...24

/Zephyr-latest/tests/crypto/tinycrypt_hmac_prng/src/
Dhmac_prng.c73 unsigned int result = TC_PASS; in do_hmac_prng_pr_false_test() local
101 result = check_result(testnum, vec->returnedbits, vec->returnedbitslen, in do_hmac_prng_pr_false_test()
103 return result; in do_hmac_prng_pr_false_test()
108 unsigned int result = TC_PASS; in test_1() local
163 result = do_hmac_prng_pr_false_test(1, &vec); in test_1()
165 return result; in test_1()
170 unsigned int result = TC_PASS; in test_2() local
225 result = do_hmac_prng_pr_false_test(2, &vec); in test_2()
227 return result; in test_2()
232 unsigned int result = TC_PASS; in test_3() local
[all …]
/Zephyr-latest/drivers/sensor/tdk/icm42605/
Dicm42605_setup.c21 int result; in icm42605_set_fs() local
23 result = inv_spi_read(&cfg->spi, REG_ACCEL_CONFIG0, &databuf, 1); in icm42605_set_fs()
24 if (result) { in icm42605_set_fs()
25 return result; in icm42605_set_fs()
31 result = inv_spi_single_write(&cfg->spi, REG_ACCEL_CONFIG0, &databuf); in icm42605_set_fs()
33 result = inv_spi_read(&cfg->spi, REG_GYRO_CONFIG0, &databuf, 1); in icm42605_set_fs()
35 if (result) { in icm42605_set_fs()
36 return result; in icm42605_set_fs()
42 result = inv_spi_single_write(&cfg->spi, REG_GYRO_CONFIG0, &databuf); in icm42605_set_fs()
44 if (result) { in icm42605_set_fs()
[all …]
/Zephyr-latest/tests/unit/math_extras/
Dtests.inc13 uint32_t result = 42;
15 zassert_false(u32_add_overflow(2, 3, &result));
16 zassert_equal(result, 5);
18 zassert_false(u32_add_overflow(2, 0, &result));
19 zassert_equal(result, 2);
21 zassert_false(u32_add_overflow(0, 3, &result));
22 zassert_equal(result, 3);
24 zassert_false(u32_add_overflow(0, UINT32_MAX, &result));
25 zassert_equal(result, UINT32_MAX);
26 zassert_true(u32_add_overflow(1, UINT32_MAX, &result));
[all …]
/Zephyr-latest/subsys/bluetooth/audio/shell/
Dtbs_client.c34 int result = 0; in cmd_tbs_client_discover() local
36 result = bt_tbs_client_discover(default_conn); in cmd_tbs_client_discover()
37 if (result != 0) { in cmd_tbs_client_discover()
38 shell_print(sh, "Fail: %d", result); in cmd_tbs_client_discover()
41 return result; in cmd_tbs_client_discover()
51 int result = 0; in cmd_tbs_client_set_signal_strength_interval() local
60 inst_index = shell_strtoul(argv[1], 0, &result); in cmd_tbs_client_set_signal_strength_interval()
61 if (result != 0) { in cmd_tbs_client_set_signal_strength_interval()
64 result); in cmd_tbs_client_set_signal_strength_interval()
80 interval = shell_strtoul(argv[argc - 1], 0, &result); in cmd_tbs_client_set_signal_strength_interval()
[all …]
Dmicp_mic_dev.c114 int result; in cmd_micp_mic_dev_param() local
143 result = bt_micp_mic_dev_register(&micp_param); in cmd_micp_mic_dev_param()
144 if (result != 0) { in cmd_micp_mic_dev_param()
145 shell_error(sh, "MICP register failed: %d", result); in cmd_micp_mic_dev_param()
146 return result; in cmd_micp_mic_dev_param()
149 shell_print(sh, "MICP initialized: %d", result); in cmd_micp_mic_dev_param()
152 result = bt_micp_mic_dev_included_get(&micp_included); in cmd_micp_mic_dev_param()
153 if (result != 0) { in cmd_micp_mic_dev_param()
154 shell_error(sh, "MICP get failed: %d", result); in cmd_micp_mic_dev_param()
158 return result; in cmd_micp_mic_dev_param()
[all …]
Dvcp_vol_rend.c173 int result = 0; in cmd_vcp_vol_rend_init() local
223 vcp_register_param.step = shell_strtoul(kwarg, 10, &result); in cmd_vcp_vol_rend_init()
225 vcp_register_param.mute = shell_strtobool(kwarg, 10, &result); in cmd_vcp_vol_rend_init()
227 vcp_register_param.volume = shell_strtoul(kwarg, 10, &result); in cmd_vcp_vol_rend_init()
237 if (result != 0) { in cmd_vcp_vol_rend_init()
245 result = bt_vcp_vol_rend_register(&vcp_register_param); in cmd_vcp_vol_rend_init()
246 if (result) { in cmd_vcp_vol_rend_init()
247 shell_print(sh, "Fail: %d", result); in cmd_vcp_vol_rend_init()
248 return result; in cmd_vcp_vol_rend_init()
251 result = bt_vcp_vol_rend_included_get(&vcp_included); in cmd_vcp_vol_rend_init()
[all …]
Dtbs.c126 int result = 0; in cmd_tbs_accept() local
128 call_index = shell_strtoul(argv[1], 0, &result); in cmd_tbs_accept()
129 if (result != 0) { in cmd_tbs_accept()
130 shell_error(sh, "Could not parse call_index: %d", result); in cmd_tbs_accept()
141 result = bt_tbs_accept((uint8_t)call_index); in cmd_tbs_accept()
142 if (result != BT_TBS_RESULT_CODE_SUCCESS) { in cmd_tbs_accept()
143 shell_print(sh, "TBS failed: %d", result); in cmd_tbs_accept()
149 return result; in cmd_tbs_accept()
156 int result = 0; in cmd_tbs_terminate() local
158 call_index = shell_strtoul(argv[1], 0, &result); in cmd_tbs_terminate()
[all …]
Dvcp_vol_ctlr.c339 int result; in cmd_vcp_vol_ctlr_discover() local
346 result = bt_vcp_vol_ctlr_cb_register(&vcp_cbs); in cmd_vcp_vol_ctlr_discover()
347 if (result != 0) { in cmd_vcp_vol_ctlr_discover()
348 shell_print(sh, "CB register failed: %d", result); in cmd_vcp_vol_ctlr_discover()
349 return result; in cmd_vcp_vol_ctlr_discover()
360 result = bt_vcp_vol_ctlr_discover(default_conn, &vcp_vol_ctlr); in cmd_vcp_vol_ctlr_discover()
361 if (result != 0) { in cmd_vcp_vol_ctlr_discover()
362 shell_print(sh, "Fail: %d", result); in cmd_vcp_vol_ctlr_discover()
365 return result; in cmd_vcp_vol_ctlr_discover()
371 int result; in cmd_vcp_vol_ctlr_state_get() local
[all …]
Dmicp_mic_ctlr.c228 int result; in cmd_micp_mic_ctlr_discover() local
234 result = bt_micp_mic_ctlr_cb_register(&micp_cbs); in cmd_micp_mic_ctlr_discover()
235 if (result != 0) { in cmd_micp_mic_ctlr_discover()
236 shell_print(sh, "Failed to register callbacks: %d", result); in cmd_micp_mic_ctlr_discover()
243 result = bt_micp_mic_ctlr_discover(default_conn, &micp_mic_ctlr); in cmd_micp_mic_ctlr_discover()
244 if (result != 0) { in cmd_micp_mic_ctlr_discover()
245 shell_print(sh, "Fail: %d", result); in cmd_micp_mic_ctlr_discover()
248 return result; in cmd_micp_mic_ctlr_discover()
254 int result; in cmd_micp_mic_ctlr_mute_get() local
260 result = bt_micp_mic_ctlr_mute_get(micp_mic_ctlr); in cmd_micp_mic_ctlr_mute_get()
[all …]
Dmcc.c599 int result; in cmd_mcc_init() local
685 result = bt_mcc_init(&cb); in cmd_mcc_init()
687 if (result) { in cmd_mcc_init()
688 shell_error(sh, "Fail: %d", result); in cmd_mcc_init()
690 return result; in cmd_mcc_init()
697 int result = 0; in cmd_mcc_discover_mcs() local
700 subscribe = shell_strtobool(argv[1], 0, &result); in cmd_mcc_discover_mcs()
701 if (result != 0) { in cmd_mcc_discover_mcs()
703 result); in cmd_mcc_discover_mcs()
709 result = bt_mcc_discover_mcs(default_conn, (bool)subscribe); in cmd_mcc_discover_mcs()
[all …]
/Zephyr-latest/subsys/net/lib/lwm2m/
Dlwm2m_senml_cbor_decode.c19 #define log_result(state, result, func) \ argument
21 if (!result) { \
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);
38 struct record_key_value_pair_m *result);
[all …]
/Zephyr-latest/drivers/sensor/ti/tmp108/
Dtmp108.c25 int result; in tmp108_reg_read() local
27 result = i2c_burst_read_dt(&cfg->i2c_spec, reg, (uint8_t *) val, 2); in tmp108_reg_read()
29 if (result < 0) { in tmp108_reg_read()
30 return result; in tmp108_reg_read()
42 int result; in tmp108_reg_write() local
47 result = i2c_write_dt(&cfg->i2c_spec, tx_buf, sizeof(tx_buf)); in tmp108_reg_write()
49 if (result < 0) { in tmp108_reg_write()
50 return result; in tmp108_reg_write()
59 int result; in tmp108_write_config() local
61 result = tmp108_reg_read(dev, TI_TMP108_REG_CONF, &config); in tmp108_write_config()
[all …]
/Zephyr-latest/drivers/pwm/
Dpwm_max31790.c73 static bool max31790_convert_pwm_frequency_into_hz(uint16_t *result, uint8_t pwm_frequency) in max31790_convert_pwm_frequency_into_hz() argument
77 *result = 25; in max31790_convert_pwm_frequency_into_hz()
80 *result = 30; in max31790_convert_pwm_frequency_into_hz()
83 *result = 35; in max31790_convert_pwm_frequency_into_hz()
86 *result = 100; in max31790_convert_pwm_frequency_into_hz()
89 *result = 125; in max31790_convert_pwm_frequency_into_hz()
92 *result = 150; /* actually 149.7, according to the datasheet */ in max31790_convert_pwm_frequency_into_hz()
95 *result = 1250; in max31790_convert_pwm_frequency_into_hz()
98 *result = 1470; in max31790_convert_pwm_frequency_into_hz()
101 *result = 3570; in max31790_convert_pwm_frequency_into_hz()
[all …]
/Zephyr-latest/include/zephyr/sys/
Dmath_extras_impl.h32 static inline bool u16_add_overflow(uint16_t a, uint16_t b, uint16_t *result) in u16_add_overflow() argument
34 return __builtin_add_overflow(a, b, result); in u16_add_overflow()
37 static inline bool u32_add_overflow(uint32_t a, uint32_t b, uint32_t *result) in u32_add_overflow() argument
39 return __builtin_add_overflow(a, b, result); in u32_add_overflow()
42 static inline bool u64_add_overflow(uint64_t a, uint64_t b, uint64_t *result) in u64_add_overflow() argument
44 return __builtin_add_overflow(a, b, result); in u64_add_overflow()
47 static inline bool size_add_overflow(size_t a, size_t b, size_t *result) in size_add_overflow() argument
49 return __builtin_add_overflow(a, b, result); in size_add_overflow()
52 static inline bool u16_add_overflow(uint16_t a, uint16_t b, uint16_t *result) in u16_add_overflow() argument
56 *result = c; in u16_add_overflow()
[all …]
/Zephyr-latest/tests/bluetooth/host/id/bt_id_scan_random_addr_check/src/
Dmain.c41 bool result; in ZTEST() local
45 result = bt_id_scan_random_addr_check(); in ZTEST()
47 zassert_true(result, "Incorrect result was returned"); in ZTEST()
62 bool result; in ZTEST() local
66 result = bt_id_scan_random_addr_check(); in ZTEST()
68 zassert_true(result, "Incorrect result was returned"); in ZTEST()
86 bool result; in ZTEST() local
93 result = bt_id_scan_random_addr_check(); in ZTEST()
95 zassert_true(result, "Incorrect result was returned"); in ZTEST()
113 bool result; in ZTEST() local
[all …]
/Zephyr-latest/drivers/mfd/
Dmfd_tle9104.c163 int result; in tle9104_transceive_frame() local
191 result = spi_transceive_dt(&config->bus, &tx, &rx); in tle9104_transceive_frame()
192 if (result != 0) { in tle9104_transceive_frame()
193 LOG_ERR("spi_write failed with error %i", result); in tle9104_transceive_frame()
194 return result; in tle9104_transceive_frame()
234 int result; in tle9104_write_state_internal() local
265 result = gpio_pin_set_dt(&config->gpio_control[i], current_value); in tle9104_write_state_internal()
266 if (result != 0) { in tle9104_write_state_internal()
268 return result; in tle9104_write_state_internal()
273 result = tle9104_write_register(dev, TLE9104REGISTER_CTRL, register_ctrl); in tle9104_write_state_internal()
[all …]
/Zephyr-latest/tests/bluetooth/host/id/bt_id_adv_random_addr_check/src/
Dmain.c41 bool result; in ZTEST() local
46 result = bt_id_adv_random_addr_check(&adv_param); in ZTEST()
48 zassert_true(result, "Incorrect result was returned"); in ZTEST()
62 bool result; in ZTEST() local
67 result = bt_id_adv_random_addr_check(&adv_param); in ZTEST()
69 zassert_true(result, "Incorrect result was returned"); in ZTEST()
86 bool result; in ZTEST() local
95 result = bt_id_adv_random_addr_check(&adv_param); in ZTEST()
97 zassert_true(result, "Incorrect result was returned"); in ZTEST()
114 bool result; in ZTEST() local
[all …]
/Zephyr-latest/tests/crypto/tinycrypt/src/
Daes.c73 uint32_t result = TC_PASS; in test_aes_key_chain() local
99 result = check_result(1, expected.words, in test_aes_key_chain()
104 zassert_false(result, in test_aes_key_chain()
113 int result = TC_PASS; in test_aes_vectors() local
137 result = check_result(2, expected, sizeof(expected), in test_aes_vectors()
141 zassert_false(result, in test_aes_vectors()
150 uint32_t result = TC_PASS; in var_text_test() local
153 result = check_result(r, out, NUM_OF_NIST_KEYS, in var_text_test()
155 if (result != TC_FAIL) { in var_text_test()
158 result = TC_FAIL; in var_text_test()
[all …]
Dccm_mode.c78 uint32_t result = TC_PASS; in do_test() local
86 result = tc_ccm_config(&c, &sched, nonce, nlen, mlen); in do_test()
89 zassert_true(result, "CCM config failed"); in do_test()
91 result = tc_ccm_generation_encryption(ciphertext, sizeof(ciphertext), in do_test()
95 zassert_true(result, "ccm_encrypt failed"); in do_test()
106 result = tc_ccm_decryption_verification(decrypted, sizeof(decrypted), in do_test()
111 if (result == 0U) { in do_test()
119 result = TC_PASS; in do_test()
120 return result; in do_test()
125 uint32_t result = TC_PASS; in ZTEST() local
[all …]
Dsha256.c56 uint32_t result = TC_PASS; in ZTEST() local
73 result = check_result(1, expected, sizeof(expected), in ZTEST()
77 zassert_false(result, "SHA256 test #1 failed."); in ZTEST()
85 uint32_t result = TC_PASS; in ZTEST() local
104 result = check_result(2, expected, sizeof(expected), in ZTEST()
108 zassert_false(result, "SHA256 test #2 failed."); in ZTEST()
113 uint32_t result = TC_PASS; in ZTEST() local
131 result = check_result(3, expected, sizeof(expected), in ZTEST()
135 zassert_false(result, "SHA256 test #3 failed."); in ZTEST()
141 uint32_t result = TC_PASS; in ZTEST() local
[all …]
Dhmac.c50 uint32_t result = TC_PASS; in do_hmac_test() local
55 result = check_result(testnum, expected, expectedlen, in do_hmac_test()
57 return result; in do_hmac_test()
65 uint32_t result = TC_PASS; in ZTEST() local
89 result = do_hmac_test(&h, 1, data, sizeof(data), in ZTEST()
93 zassert_false(result, "HMAC test #7 failed"); in ZTEST()
98 uint32_t result = TC_PASS; in ZTEST() local
123 result = do_hmac_test(&h, 2, data, sizeof(data), in ZTEST()
127 zassert_false(result, "HMAC test #7 failed"); in ZTEST()
132 uint32_t result = TC_PASS; in ZTEST() local
[all …]
/Zephyr-latest/samples/net/mqtt_publisher/
Ddocker-test.sh19 result=$?
21 if [ $result -ne 0 ]; then
22 return $result
36 result=$?
38 if [ $result -ne 0 ]; then
39 return $result
43 return $result
55 result=$?
/Zephyr-latest/subsys/testsuite/include/zephyr/
Dtc_util.h85 static inline const char *TC_RESULT_TO_STR(int result) in TC_RESULT_TO_STR() argument
87 switch (result) { in TC_RESULT_TO_STR()
157 #define TC_END(result, fmt, ...) PRINT_DATA(fmt, ##__VA_ARGS__) argument
162 #define TC_END_PRINT(result, fmt, ...) PRINT_DATA(fmt, ##__VA_ARGS__); PRINT_LINE argument
164 #define TC_END_PRINT(result, fmt, ...) print_nothing(fmt) argument
170 #define Z_TC_END_RESULT(result, func) \ argument
172 TC_END_PRINT(result, " %s - %s in %u.%03u seconds\n", \
173 TC_RESULT_TO_STR(result), func, tc_spend_time/1000, \
179 #define TC_END_RESULT(result) \ argument
180 Z_TC_END_RESULT((result), __func__)
[all …]
/Zephyr-latest/drivers/flash/
Dflash_shell.c90 int result = -ENOTSUP; in cmd_erase() local
97 result = parse_helper(sh, &argc, &argv, &flash_dev, &page_addr); in cmd_erase()
98 if (result) { in cmd_erase()
99 return result; in cmd_erase()
106 result = flash_get_page_info_by_offs(flash_dev, page_addr, in cmd_erase()
109 if (result != 0) { in cmd_erase()
111 "code %d.", result); in cmd_erase()
118 result = flash_erase(flash_dev, page_addr, size); in cmd_erase()
120 if (result) { in cmd_erase()
121 shell_error(sh, "Erase Failed, code %d.", result); in cmd_erase()
[all …]
/Zephyr-latest/modules/cmsis/
Dcmsis_core_a_r_ext.h58 uint32_t result; in __get_DFAR() local
59 __get_CP(15, 0, result, 6, 0, 0); in __get_DFAR()
60 return result; in __get_DFAR()
65 uint32_t result; in __get_IFAR() local
66 __get_CP(15, 0, result, 6, 0, 2); in __get_IFAR()
67 return result; in __get_IFAR()
72 uint32_t result; in __get_DBGDSCR() local
73 __get_CP(14, 0, result, 0, 1, 0); in __get_DBGDSCR()
74 return result; in __get_DBGDSCR()

12345678910>>...24