Home
last modified time | relevance | path

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

/openbmc/linux/drivers/pwm/
H A Dpwm-sifive.c40 #define PWM_SIFIVE_CMPWIDTH 16 macro
96 scale = clamp(ilog2(scale_pow) - PWM_SIFIVE_CMPWIDTH, 0, 0xf); in pwm_sifive_update_clock()
103 num = (unsigned long long)NSEC_PER_SEC << (PWM_SIFIVE_CMPWIDTH + scale); in pwm_sifive_update_clock()
125 (u64)duty * ddata->real_period >> PWM_SIFIVE_CMPWIDTH; in pwm_sifive_get_state()
158 num = (u64)duty_cycle * (1U << PWM_SIFIVE_CMPWIDTH); in pwm_sifive_apply()
161 frac = min(frac, (1U << PWM_SIFIVE_CMPWIDTH) - 1); in pwm_sifive_apply()