Home
last modified time | relevance | path

Searched refs:LOG2 (Results 1 – 17 of 17) sorted by relevance

/Zephyr-latest/tests/unit/pot/
Dlog2.c10 static const uint8_t val = LOG2(42);
11 static const uint8_t val64 = LOG2(42 + BIT64(32));
15 zassert_equal(-1, LOG2(LLONG_MIN)); in ZTEST()
16 zassert_equal(-1, LOG2(LONG_MIN)); in ZTEST()
17 zassert_equal(-1, LOG2(INT_MIN)); in ZTEST()
18 zassert_equal(-1, LOG2(-1)); in ZTEST()
19 zassert_equal(-1, LOG2(0)); in ZTEST()
20 zassert_equal(0, LOG2(1)); in ZTEST()
21 zassert_equal(1, LOG2(2)); in ZTEST()
22 zassert_equal(1, LOG2(3)); in ZTEST()
[all …]
Dlog2.cpp10 static constexpr uint8_t val = LOG2(42);
11 static constexpr uint8_t val64 = LOG2(42 + BIT64(32));
15 return LOG2(x); in log2()
20 zassert_equal(-1, LOG2(0)); in ZTEST()
21 zassert_equal(0, LOG2(1)); in ZTEST()
22 zassert_equal(1, LOG2(2)); in ZTEST()
23 zassert_equal(1, LOG2(3)); in ZTEST()
24 zassert_equal(2, LOG2(4)); in ZTEST()
25 zassert_equal(2, LOG2(5)); in ZTEST()
26 zassert_equal(31, LOG2(BIT(31))); in ZTEST()
[all …]
/Zephyr-latest/subsys/ipc/ipc_service/backends/
Dipc_rpmsg_static_vrings.h167 return (--num_desc == 0) ? 0 : (1 << LOG2(num_desc)); in optimal_num_desc()
/Zephyr-latest/lib/posix/options/
Dsignal.c15 #define SIGNO_WORD_BIT(_signo) (_signo & BIT_MASK(LOG2(BITS_PER_LONG)))
/Zephyr-latest/drivers/pwm/
Dpwm_max32.c44 prescaler_index = LOG2(cfg->prescaler); in api_set_cycles()
/Zephyr-latest/drivers/interrupt_controller/
Dintc_gpio_stm32wb0.c97 return LOG2(line); in ll_exti_line_to_portpin()
Dintc_exti_stm32.c120 return LOG2(line); in ll_exti_line_to_linenum()
Dintc_plic.c56 #define PLIC_REG_MASK BIT_MASK(LOG2(PLIC_REG_SIZE))
123 return local_irq >> LOG2(PLIC_REG_SIZE); in local_irq_to_reg_index()
/Zephyr-latest/include/zephyr/drivers/
Dstepper.h32 #define MICRO_STEP_RES_INDEX(res) LOG2(res)
/Zephyr-latest/drivers/watchdog/
Dwdt_npcx.c264 wdcp = LOG2(pre_scal - 1) + 1; in wdt_npcx_setup()
/Zephyr-latest/drivers/counter/
Dcounter_max32_timer.c248 prescaler_index = LOG2(cfg->prescaler); in max32_counter_init()
/Zephyr-latest/include/zephyr/sys/
Dutil.h703 #define LOG2(x) ((x) < 1 ? -1 : __z_log2(x)) macro
/Zephyr-latest/drivers/dma/
Ddma_silabs_ldma.c120 desc->xfer.size = LOG2(src_size); in dma_silabs_block_to_descriptor()
/Zephyr-latest/drivers/can/
Dcan_mcp251xfd.h18 ((flag_u32) >> ROUND_DOWN(LOG2((flag_u32)), 8))
/Zephyr-latest/drivers/stepper/adi_tmc/
Dadi_tmc5041_stepper_controller.c382 reg_value |= ((MICRO_STEP_RES_INDEX(STEPPER_MICRO_STEP_256) - LOG2(res)) in tmc5041_stepper_set_micro_step_res()
/Zephyr-latest/drivers/sensor/grow_r502a/
Dgrow_r502a.c986 val.val2 = LOG2(CONFIG_R502A_DATA_PKT_SIZE >> 5); in fps_init()
/Zephyr-latest/doc/releases/
Drelease-notes-2.7.rst1612 * :github:`36486` - LOG2 - self referential macro