]> git.karo-electronics.de Git - karo-tx-linux.git/commit
pwm: sti: Maintain a bitmap of configured devices
authorAjit Pal Singh <ajitpal.singh@st.com>
Thu, 29 Jan 2015 09:04:43 +0000 (14:34 +0530)
committerThierry Reding <thierry.reding@gmail.com>
Fri, 30 Jan 2015 11:16:03 +0000 (12:16 +0100)
commitcd264b6a6559caa74579b5afca11379ddde92dca
tree6a21a884cd632b20c7e23e5c8035efa0a7b537b2
parented73598531337bce238915280396c8e0dcee93bc
pwm: sti: Maintain a bitmap of configured devices

This patch introduces a bitmap which is used to keep track of the
pwm channels which have been configured in a pwm chip.

The method used earlier to find the number of configured channels,
was to count the pwmdevices with PWMF_REQUESTED field set
and period value configured. This was not correct and failed
when of_pwm_get()/pwm_get() and then pwm_config() was used.

Signed-off-by: Ajit Pal Singh <ajitpal.singh@st.com>
Signed-off-by: Thierry Reding <thierry.reding@gmail.com>
drivers/pwm/pwm-sti.c