Home
last modified time | relevance | path

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

/external/u-boot/arch/arm/cpu/armv7/s5p-common/
Dpwm.c58 int pwm_config(int pwm_id, int duty_ns, int period_ns) in pwm_config() argument
75 if (period_ns > NS_IN_SEC || duty_ns > NS_IN_SEC || period_ns == 0) in pwm_config()
78 if (duty_ns > period_ns) in pwm_config()
81 frequency = NS_IN_SEC / period_ns; in pwm_config()
87 tcnt = period_ns / tin_ns; in pwm_config()
/external/u-boot/drivers/pwm/
Dsandbox_pwm.c18 uint period_ns; member
29 uint period_ns, uint duty_ns) in sandbox_pwm_set_config() argument
37 chan->period_ns = period_ns; in sandbox_pwm_set_config()
Dpwm-imx-util.c48 int pwm_imx_get_parms(int period_ns, int duty_ns, unsigned long *period_c, in pwm_imx_get_parms() argument
59 c = c * period_ns; in pwm_imx_get_parms()
67 do_div(c, period_ns); in pwm_imx_get_parms()
Drk_pwm.c38 static int rk_pwm_set_config(struct udevice *dev, uint channel, uint period_ns, in rk_pwm_set_config() argument
45 debug("%s: period_ns=%u, duty_ns=%u\n", __func__, period_ns, duty_ns); in rk_pwm_set_config()
51 period = lldiv((uint64_t)(priv->freq / 1000) * period_ns, 1000000); in rk_pwm_set_config()
Dexynos_pwm.c19 uint period_ns, uint duty_ns) in exynos_pwm_set_config() argument
31 __func__, dev->name, channel, period_ns, duty_ns); in exynos_pwm_set_config()
42 tcnt = period_ns / rate_ns; in exynos_pwm_set_config()
Dsunxi_pwm.c66 uint period_ns, uint duty_ns) in sunxi_pwm_set_config() argument
75 debug("%s: period_ns=%u, duty_ns=%u\n", __func__, period_ns, duty_ns); in sunxi_pwm_set_config()
82 period = lldiv(scaled_freq * period_ns, nsecs_per_sec); in sunxi_pwm_set_config()
Dpwm-uclass.c21 int pwm_set_config(struct udevice *dev, uint channel, uint period_ns, in pwm_set_config() argument
29 return ops->set_config(dev, channel, period_ns, duty_ns); in pwm_set_config()
Dpwm-imx.c27 int pwm_config(int pwm_id, int duty_ns, int period_ns) in pwm_config() argument
36 pwm_imx_get_parms(period_ns, duty_ns, &period_cycles, &duty_cycles, in pwm_config()
Dtegra_pwm.c18 uint period_ns, uint duty_ns) in tegra_pwm_set_config() argument
31 pulse_width = duty_ns * 255 / period_ns; in tegra_pwm_set_config()
Dpwm-imx-util.h13 int pwm_imx_get_parms(int period_ns, int duty_ns, unsigned long *period_c,
/external/u-boot/include/
Dpwm.h24 int (*set_config)(struct udevice *dev, uint channel, uint period_ns,
58 int pwm_set_config(struct udevice *dev, uint channel, uint period_ns,
84 int pwm_config (int pwm_id, int duty_ns, int period_ns);
/external/u-boot/drivers/power/regulator/
Dpwm_regulator.c22 int period_ns; member
79 priv->period_ns, (priv->period_ns / 100) * duty_cycle); in pwm_regulator_set_voltage()
102 priv->period_ns = args.args[1]; in pwm_regulator_ofdata_to_platdata()
/external/u-boot/drivers/video/
Dpwm_backlight.c19 uint period_ns; member
45 duty_cycle = priv->period_ns * (priv->default_level - priv->min_level) / in pwm_backlight_enable()
47 ret = pwm_set_config(priv->pwm, priv->channel, priv->period_ns, in pwm_backlight_enable()
93 priv->period_ns = args.args[1]; in pwm_backlight_ofdata_to_platdata()