Message ID | af5b2e8ac6695383111328267a689bcf1c0ecdb1.1702369869.git.sean@mess.org |
---|---|
State | Accepted |
Commit | dc518b378dced419baa95d76a85f4c8c405722bc |
Headers | show |
Series | Improve pwm-ir-tx precision | expand |
On Tue, Dec 12, 2023 at 08:34:01AM +0000, Sean Young wrote:
> ENOTSUPP is not a standard error code and should be avoided.
I'd write:
According to Documentation/dev-tools/checkpatch.rst ENOTSUPP is
not recommended and EOPNOTSUPP should be used instead.
to give the sentence a bit of authority.
Other than that I'm fine with the change.
Best regards
Uwe
diff --git a/include/linux/pwm.h b/include/linux/pwm.h index b64b8a82415c4..c9cb87b59ac80 100644 --- a/include/linux/pwm.h +++ b/include/linux/pwm.h @@ -407,12 +407,12 @@ static inline int pwm_apply_might_sleep(struct pwm_device *pwm, const struct pwm_state *state) { might_sleep(); - return -ENOTSUPP; + return -EOPNOTSUPP; } static inline int pwm_adjust_config(struct pwm_device *pwm) { - return -ENOTSUPP; + return -EOPNOTSUPP; } static inline int pwm_config(struct pwm_device *pwm, int duty_ns,
ENOTSUPP is not a standard error code and should be avoided. Signed-off-by: Sean Young <sean@mess.org> --- include/linux/pwm.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-)