aboutsummaryrefslogtreecommitdiffstats
path: root/include/linux/pwm.h
diff options
context:
space:
mode:
authorPhilip, Avinash <avinashphilip@ti.com>2012-11-21 02:40:44 -0500
committerThierry Reding <thierry.reding@avionic-design.de>2012-11-22 16:47:12 -0500
commit83af24027b3df1af5c5a9aa9adcdcfeb3429d3be (patch)
tree3e104ed41554bb7e97378cc7cc3866c842306dff /include/linux/pwm.h
parent422470a8265fbb1d182c00ab2421f4b416ab2dba (diff)
pwm: Device tree support for PWM polarity
Add support for encoding PWM properties in bit encoded form with of_pwm_xlate_with_flags() function support. Platforms require platform specific PWM properties has to populate in 3rd cell of the pwm-specifier and PWM driver should also set .of_xlate support with this function. Currently PWM property polarity encoded in bit position 0 of the third cell in pwm-specifier. Signed-off-by: Philip, Avinash <avinashphilip@ti.com> Acked-by: Grant Likely <grant.likely@secretlab.ca> Signed-off-by: Thierry Reding <thierry.reding@avionic-design.de>
Diffstat (limited to 'include/linux/pwm.h')
-rw-r--r--include/linux/pwm.h3
1 files changed, 3 insertions, 0 deletions
diff --git a/include/linux/pwm.h b/include/linux/pwm.h
index 112b31436848..6d661f32e0e4 100644
--- a/include/linux/pwm.h
+++ b/include/linux/pwm.h
@@ -171,6 +171,9 @@ struct pwm_device *pwm_request_from_chip(struct pwm_chip *chip,
171 unsigned int index, 171 unsigned int index,
172 const char *label); 172 const char *label);
173 173
174struct pwm_device *of_pwm_xlate_with_flags(struct pwm_chip *pc,
175 const struct of_phandle_args *args);
176
174struct pwm_device *pwm_get(struct device *dev, const char *consumer); 177struct pwm_device *pwm_get(struct device *dev, const char *consumer);
175void pwm_put(struct pwm_device *pwm); 178void pwm_put(struct pwm_device *pwm);
176 179