aboutsummaryrefslogtreecommitdiff
path: root/drivers/pwm/pwm-spear.c
AgeCommit message (Collapse)AuthorFilesLines
2013-09-03pwm: simplify use of devm_ioremap_resourceJulia Lawall1-6/+1
Remove unneeded error handling on the result of a call to platform_get_resource when the value is passed to devm_ioremap_resource. Move the call to platform_get_resource adjacent to the call to devm_ioremap_resource to make the connection between them more clear. A simplified version of the semantic patch that makes this change is as follows: (http://coccinelle.lip6.fr/) // <smpl> @@ expression pdev,res,n,e,e1; expression ret != 0; identifier l; @@ - res = platform_get_resource(pdev, IORESOURCE_MEM, n); ... when != res - if (res == NULL) { ... \(goto l;\|return ret;\) } ... when != res + res = platform_get_resource(pdev, IORESOURCE_MEM, n); e = devm_ioremap_resource(e1, res); // </smpl> Signed-off-by: Julia Lawall <[email protected]> Acked-by: Viresh Kumar <[email protected]> Signed-off-by: Thierry Reding <[email protected]>
2013-06-12pwm: Fill in missing .owner fieldsThierry Reding1-0/+1
Some drivers don't set the .owner fields of the struct device_driver or struct pwm_ops, which causes the module usage count to become wrong. Signed-off-by: Thierry Reding <[email protected]>
2013-04-23pwm: Constify OF match tablesThierry Reding1-1/+1
A few drivers already annotate this properly. Make the same change for all other OF supporting drivers. Signed-off-by: Thierry Reding <[email protected]> Acked-by: Shawn Guo <[email protected]> Acked-by: Alexandre Pereira da Silva <[email protected]> Acked-by: Viresh Kumar <[email protected]>
2013-04-02pwm: spear: Remove unused *dev from struct spear_pwm_chipAxel Lin1-3/+0
Signed-off-by: Axel Lin <[email protected]> Acked-by: Shiraz Hashim <[email protected]> Acked-by: Viresh Kumar <[email protected]> Signed-off-by: Thierry Reding <[email protected]>
2013-04-02pwm: spear: Fix checking return value of clk_enable() and clk_prepare()Axel Lin1-3/+3
The logic to check return value of clk_enable() and clk_prepare() is reversed, fix it. Signed-off-by: Axel Lin <[email protected]> Cc: [email protected] Acked-by: Viresh Kumar <[email protected]> Signed-off-by: Thierry Reding <[email protected]>
2013-01-22pwm: Convert to devm_ioremap_resource()Thierry Reding1-3/+3
Convert all uses of devm_request_and_ioremap() to the newly introduced devm_ioremap_resource() which provides more consistent error handling. Signed-off-by: Thierry Reding <[email protected]> Acked-by: Viresh Kumar <[email protected]> Signed-off-by: Greg Kroah-Hartman <[email protected]>
2012-11-22pwm: spear: Staticize spear_pwm_config()Axel Lin1-2/+2
spear_pwm_config() is not referenced outside of this file, make it static. Signed-off-by: Axel Lin <[email protected]> Acked-by: Viresh Kumar <[email protected]> Signed-off-by: Thierry Reding <[email protected]>
2012-11-22pwm: Add SPEAr PWM chip driver supportShiraz Hashim1-0/+276
Add support for PWM chips present on SPEAr platforms. These PWM chips support 4 channel output with programmable duty cycle and frequency. More details on these PWM chips can be obtained from relevant chapter of reference manual, present at following[1] location. 1. http://www.st.com/internet/mcu/product/251211.jsp Cc: Thierry Reding <[email protected]> Signed-off-by: Shiraz Hashim <[email protected]> Signed-off-by: Viresh Kumar <[email protected]> Reviewed-by: Vipin Kumar <[email protected]> Acked-by: Viresh Kumar <[email protected]> Signed-off-by: Thierry Reding <[email protected]>