On Wed, Nov 11, 2015 at 02:24:01PM +0100, Marc Kleine-Budde wrote:
> The DT probe uses a dynamically allocated base by pwm core. The actual pwm
> device number depends on the probe order of the devices in the DT. This not
> intuitive and sometimes hard for users to map the Linux pwm number to the
> actual hardware pin. (Especially on the mx25, where pwm4 is probed first.)
> 
> Use alias to identify the id of pwm port and pass it as base to the pwm core.
> If an alias is not defined in device tree, a base number dynamically allocated
> by pwm core will be used.
> 
> Signed-off-by: Marc Kleine-Budde <[email protected]>
> ---
>  drivers/pwm/pwm-imx.c | 8 ++++++--
>  1 file changed, 6 insertions(+), 2 deletions(-)

What is your use-case? The base is merely used as a way to set a fixed
global base number for the PWM chip. However that global namespace is a
relic from old times and no drivers (except for the very oldest) should
be using this. OF-enabled drivers certainly don't fall into that
category since there is no need to refer to the PWM devices by their
global number.

Also note that most users of the legacy API are now gone, so the global
namespace will be removed eventually, so you should not rely on it.

Thierry

Attachment: signature.asc
Description: PGP signature

Reply via email to