diff mbox series

[v2] pwm: reword docs about pwm_apply_state()

Message ID 20210423163225.2438763-1-u.kleine-koenig@pengutronix.de
State Accepted
Headers show
Series [v2] pwm: reword docs about pwm_apply_state() | expand

Commit Message

Uwe Kleine-König April 23, 2021, 4:32 p.m. UTC
The main issue is that the current documentation talks about the
non-existent function pwm_get_last_applied_state. (This was right in the
context of
https://lore.kernel.org/linux-pwm/20210406073036.26857-1-u.kleine-koenig@pengutronix.de/
but was then missed to adapt when this patch was reduced to a
documentation update.)

While at is also clarify "last applied PWM state" to "PWM state that was
passed to the last invocation of pwm_apply_state()" to better
distinguish to the last actually implemented state and reword to drop a
word repetition.

Fixes: 539ed98e2bd3 ("pwm: Clarify documentation about pwm_get_state()")
Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
---
Hello,

the only change compared to v1 is that I didn't use --word-diff to
create the patch. I just found out that git am cannot apply patches
created with --word-diff.

Best regards
Uwe

 Documentation/driver-api/pwm.rst | 10 +++++-----
 1 file changed, 5 insertions(+), 5 deletions(-)


base-commit: 64d7d074acd52e1bdff621f2cb86c0aae9bcef80

Comments

Thierry Reding April 23, 2021, 5:06 p.m. UTC | #1
On Fri, Apr 23, 2021 at 06:32:26PM +0200, Uwe Kleine-König wrote:
> The main issue is that the current documentation talks about the
> non-existent function pwm_get_last_applied_state. (This was right in the
> context of
> https://lore.kernel.org/linux-pwm/20210406073036.26857-1-u.kleine-koenig@pengutronix.de/
> but was then missed to adapt when this patch was reduced to a
> documentation update.)
> 
> While at is also clarify "last applied PWM state" to "PWM state that was
> passed to the last invocation of pwm_apply_state()" to better
> distinguish to the last actually implemented state and reword to drop a
> word repetition.
> 
> Fixes: 539ed98e2bd3 ("pwm: Clarify documentation about pwm_get_state()")
> Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
> ---
> Hello,
> 
> the only change compared to v1 is that I didn't use --word-diff to
> create the patch. I just found out that git am cannot apply patches
> created with --word-diff.
> 
> Best regards
> Uwe
> 
>  Documentation/driver-api/pwm.rst | 10 +++++-----
>  1 file changed, 5 insertions(+), 5 deletions(-)

Applied, thanks.

Thierry
diff mbox series

Patch

diff --git a/Documentation/driver-api/pwm.rst b/Documentation/driver-api/pwm.rst
index 381f3c46cdac..a7ca4f58305a 100644
--- a/Documentation/driver-api/pwm.rst
+++ b/Documentation/driver-api/pwm.rst
@@ -55,11 +55,11 @@  several parameter at once. For example, if you see pwm_config() and
 pwm_{enable,disable}() calls in the same function, this probably means you
 should switch to pwm_apply_state().
 
-The PWM user API also allows one to query the last applied PWM state with
-pwm_get_last_applied_state(). Note this is different to what the driver has
-actually implemented if the request cannot be implemented exactly with the
-hardware in use. There is currently no way for consumers to get the actually
-implemented settings.
+The PWM user API also allows one to query the PWM state that was passed to the
+last invocation of pwm_apply_state() using pwm_get_state(). Note this is
+different to what the driver has actually implemented if the request cannot be
+satisfied exactly with the hardware in use. There is currently no way for
+consumers to get the actually implemented settings.
 
 In addition to the PWM state, the PWM API also exposes PWM arguments, which
 are the reference PWM config one should use on this PWM.