[Top] [All Lists]

Re: [PATCH 1/7] pwm: Add pwm core driver

To: Samuel Ortiz <>
Subject: Re: [PATCH 1/7] pwm: Add pwm core driver
From: Felipe Balbi <>
Date: Tue, 28 Sep 2010 16:35:01 +0300
Cc: "V, Hemanth" <>, Arun Murthy <>, "" <>, Andrew Morton <>, "" <>, "" <>, "" <>, "" <>, "" <>, "" <>, "" <>, "" <>, "" <>, "" <>, "" <>, "" <>
In-reply-to: <20100928130610.GB20749@sortiz-mobl>
References: <> <> <040c01cb5f0c$29bcb3b0$LocalHost@wipblrx0099946> <20100928130610.GB20749@sortiz-mobl>
User-agent: Mutt/1.5.20 (2009-06-14)
On Tue, Sep 28, 2010 at 08:06:11AM -0500, Samuel Ortiz wrote:
On Tue, Sep 28, 2010 at 06:23:24PM +0530, Hemanth V wrote:
----- Original Message ----- From: "Arun Murthy"

>The existing pwm based led and backlight driver makes use of the
>pwm(include/linux/pwm.h). So all the board specific pwm drivers will
>be exposing the same set of function name as in include/linux/pwm.h.
>As a result build fails in case of multi soc environments where each soc
>has a pwm device in it.

This seems very specific to ST environment,
No it's not. It's an issue Arun has hit while enabling one of the ST MFD chip,
but he's tackling a generic issue.

looking at the driver list from
( [PATCH 4/7] pwm: Align existing pwm drivers with pwm-core ) it seems
most multi SOC environments might support PWM in either one of the SOC.


Unless people have examples of other SOCs which might use this,
the better approach might be to go for a custom driver rather than changing
the framework.
I wouldn't call the current pwm code a framework. It's a bunch of header
definitions that happens to work in the specific case of 1 pwm per
sub architecture.
What Arun is proposing is an actual framework. And it seems to be clean and
simple enough.

FWIW, I agree with you Sam. Sooner or later, this will hit other SoCs.


<Prev in Thread] Current Thread [Next in Thread>