[PATCH 03/12] PWM: core: remove ineffectual pwm_{set,get}_duty_cycle

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



From: Ahmad Fatoum <a.fatoum@xxxxxxxxxxxxxx>

The setter sets a value unused anywhere, but in the getter.
As the functions are unused, just drop them.
There's pwm_config that can be used for this instead.

Signed-off-by: Ahmad Fatoum <a.fatoum@xxxxxxxxxxxxxx>
---
 drivers/pwm/core.c | 10 ----------
 include/pwm.h      |  2 --
 2 files changed, 12 deletions(-)

diff --git a/drivers/pwm/core.c b/drivers/pwm/core.c
index cae23c98ee2d..eaf7de18295e 100644
--- a/drivers/pwm/core.c
+++ b/drivers/pwm/core.c
@@ -265,16 +265,6 @@ unsigned int pwm_get_period(struct pwm_device *pwm)
 	return pwm->period_ns;
 }
 
-void pwm_set_duty_cycle(struct pwm_device *pwm, unsigned int duty_ns)
-{
-	pwm->duty_ns = duty_ns;
-}
-
-unsigned int pwm_get_duty_cycle(struct pwm_device *pwm)
-{
-	return pwm->duty_ns;
-}
-
 /*
  * pwm_enable - start a PWM output toggling
  */
diff --git a/include/pwm.h b/include/pwm.h
index 98af1299748a..9897e86545c9 100644
--- a/include/pwm.h
+++ b/include/pwm.h
@@ -34,8 +34,6 @@ void pwm_disable(struct pwm_device *pwm);
 
 void pwm_set_period(struct pwm_device *pwm, unsigned int period);
 unsigned int pwm_get_period(struct pwm_device *pwm);
-void pwm_set_duty_cycle(struct pwm_device *pwm, unsigned int duty);
-unsigned int pwm_get_duty_cycle(struct pwm_device *pwm);
 
 struct pwm_chip;
 
-- 
2.20.1


_______________________________________________
barebox mailing list
barebox@xxxxxxxxxxxxxxxxxxx
http://lists.infradead.org/mailman/listinfo/barebox



[Index of Archives]     [Linux Embedded]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]     [XFree86]

  Powered by Linux