summaryrefslogtreecommitdiffstats
path: root/drivers/pwm/pwm-crc.c
diff options
context:
space:
mode:
authorBoris Brezillon <boris.brezillon@free-electrons.com>2016-04-14 21:17:22 +0200
committerThierry Reding <thierry.reding@gmail.com>2016-05-17 14:44:59 +0200
commit4b58896f72176b781816a9e14dcea5f755b19b5c (patch)
treea66f0e8680513767108c2905e7ff46f7e8562fb0 /drivers/pwm/pwm-crc.c
parent459a25afe97cb3d7f978b90c881f4d7aac8fb755 (diff)
downloadlinux-4b58896f72176b781816a9e14dcea5f755b19b5c.tar.bz2
pwm: Use pwm_get/set_xxx() helpers where appropriate
Use pwm_get/set_xxx() helpers instead of directly accessing the pwm->xxx field. Doing that will ease adaptation of the PWM framework to support atomic update. Signed-off-by: Boris Brezillon <boris.brezillon@free-electrons.com> Signed-off-by: Thierry Reding <thierry.reding@gmail.com>
Diffstat (limited to 'drivers/pwm/pwm-crc.c')
-rw-r--r--drivers/pwm/pwm-crc.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/pwm/pwm-crc.c b/drivers/pwm/pwm-crc.c
index 7101c7020bf4..bd0ebd04856a 100644
--- a/drivers/pwm/pwm-crc.c
+++ b/drivers/pwm/pwm-crc.c
@@ -75,7 +75,7 @@ static int crc_pwm_config(struct pwm_chip *c, struct pwm_device *pwm,
return -EINVAL;
}
- if (pwm->period != period_ns) {
+ if (pwm_get_period(pwm) != period_ns) {
int clk_div;
/* changing the clk divisor, need to disable fisrt */