Lines Matching refs:psc
172 unsigned int psc = 0, icpsc, scale; in stm32_pwm_capture() local
199 while ((div > priv->max_arr) && (psc < MAX_TIM_PSC)) { in stm32_pwm_capture()
200 psc++; in stm32_pwm_capture()
202 do_div(div, psc + 1); in stm32_pwm_capture()
205 regmap_write(priv->regmap, TIM_PSC, psc); in stm32_pwm_capture()
236 if (psc && scale > 1) { in stm32_pwm_capture()
238 psc /= scale; in stm32_pwm_capture()
239 regmap_write(priv->regmap, TIM_PSC, psc); in stm32_pwm_capture()
247 prd = (unsigned long long)raw_prd * (psc + 1) * NSEC_PER_SEC; in stm32_pwm_capture()
303 prd = (unsigned long long)raw_prd * (psc + 1) * NSEC_PER_SEC; in stm32_pwm_capture()
305 dty = (unsigned long long)raw_dty * (psc + 1) * NSEC_PER_SEC; in stm32_pwm_capture()
348 u32 psc, arr; in stm32_pwm_config() local
350 regmap_read(priv->regmap, TIM_PSC, &psc); in stm32_pwm_config()
353 if ((psc != prescaler) || (arr != prd - 1)) in stm32_pwm_config()