[PATCH v2 0/1] pwm: tiehrpwm: ensures that state.enabled is
From: Rafael V. Volkmer
Date: Wed Feb 05 2025 - 22:14:27 EST
Hi Uwe.
Thanks for the feedback! It was very constructive for improving the code!
I fixed the points you mentioned and hope you can review v2 of my patch!
Changes in v2:
- Adjusted the indentation reported by checkpatch.pl;
- Added the bitfield header to replace the register bit defines with GEN_MASK
and FIELD_GET;
- Concentrated the use of clk_get_rate() only once, inside ehrpwm_get_state();
- Added the ehrpwm_get_state() function as part of the driver's fops, directly
linked to .get_state;
- Now, the activation of clk_prepare_enable() when the pwm is already running
is done before pwmchip_add(), and runtime_get_sync() after;
- Added comments for each new function;
- Added comments in specific areas of register manipulation, in order to make
understanding how they work more intuitive;
- Removed unnecessary null pointer checks in functions and also improper
returns;
- I improved the commit message, as suggested.
Rafael V. Volkmer (1):
pwm: tiehrpwm: ensures that state.enabled is synchronized in .probe()
drivers/pwm/pwm-tiehrpwm.c | 202 ++++++++++++++++++++++++++++++++++++-
1 file changed, 201 insertions(+), 1 deletion(-)
--
2.25.1