diff mbox series

[v2] ASoC: codecs: Fix error handling in aw_dev_get_dsp_status()

Message ID 20241009094313.8820-1-zhujun2@cmss.chinamobile.com (mailing list archive)
State Accepted
Commit 53189ae7aa1eeabd937c7a4d1f41e40513597d2c
Headers show
Series [v2] ASoC: codecs: Fix error handling in aw_dev_get_dsp_status() | expand

Commit Message

Zhu Jun Oct. 9, 2024, 9:43 a.m. UTC
Changed the error handling in aw_dev_get_dsp_status to return -EPERM directly
instead of setting it to a variable.

Signed-off-by: Zhu Jun <zhujun2@cmss.chinamobile.com>
---
V1 -> V2:
- add a dot after the commit
- modify commit info

 sound/soc/codecs/aw88399.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

Comments

Markus Elfring Oct. 9, 2024, 11:12 a.m. UTC | #1
> Changed the error handling in aw_dev_get_dsp_status to return -EPERM directly
> instead of setting it to a variable.

* How do you think about to choose an imperative wording for an improved change description?
  https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/tree/Documentation/process/submitting-patches.rst?h=v6.12-rc2#n94

* Would you like to add any tags (like “Fixes” and “Cc”) accordingly?
  https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/tree/Documentation/process/submitting-patches.rst?h=v6.12-rc2#n145

…
> ---
> V1 -> V2:
> - add a dot after the commit
> - modify commit info

Can it be that higher version numbers would be more appropriate according to
the evolving patch review?

Regards,
Markus
Mark Brown Oct. 9, 2024, 12:47 p.m. UTC | #2
On Wed, Oct 09, 2024 at 01:12:21PM +0200, Markus Elfring wrote:
> > Changed the error handling in aw_dev_get_dsp_status to return -EPERM directly
> > instead of setting it to a variable.
> 
> * How do you think about to choose an imperative wording for an improved change description?

Feel free to ignore Markus, he has a long history of sending
unhelpful review comments and continues to ignore repeated requests
to stop.
diff mbox series

Patch

diff --git a/sound/soc/codecs/aw88399.c b/sound/soc/codecs/aw88399.c
index 8dc2b8aa6832..bba59885242d 100644
--- a/sound/soc/codecs/aw88399.c
+++ b/sound/soc/codecs/aw88399.c
@@ -656,7 +656,7 @@  static int aw_dev_get_dsp_status(struct aw_device *aw_dev)
 	if (ret)
 		return ret;
 	if (!(reg_val & (~AW88399_WDT_CNT_MASK)))
-		ret = -EPERM;
+		return -EPERM;
 
 	return 0;
 }