pwm: atmel: Fix duty cycle calculation in .get_state()
stable inclusion from stable-5.10.38 commit b22e8f427c3de299c47350caae2a4f80f6d7eb61 bugzilla: 51875 CVE: NA -------------------------------- [ Upstream commit 453e8b3d ] The CDTY register contains the number of inactive cycles. .apply() does this correctly, however .get_state() got this wrong. Fixes: 651b510a ("pwm: atmel: Implement .get_state()") Signed-off-by: NUwe Kleine-König <u.kleine-koenig@pengutronix.de> Signed-off-by: NThierry Reding <thierry.reding@gmail.com> Signed-off-by: NSasha Levin <sashal@kernel.org> Signed-off-by: NChen Jun <chenjun102@huawei.com> Acked-by: NWeilong Chen <chenweilong@huawei.com> Signed-off-by: NZheng Zengkai <zhengzengkai@huawei.com>
Showing
想要评论请 注册 或 登录