* [PATCH 01/10] ASoC: ti: ams-delta: Use dev_err_probe() for error handling
2026-07-14 12:00 [PATCH 00/10] ASoC: ti: Improve probe error handling phucduc.bui
@ 2026-07-14 12:00 ` phucduc.bui
2026-07-14 12:27 ` Christophe JAILLET
2026-07-14 12:00 ` [PATCH 02/10] ASoC: ti: davinci-evm: " phucduc.bui
` (8 subsequent siblings)
9 siblings, 1 reply; 16+ messages in thread
From: phucduc.bui @ 2026-07-14 12:00 UTC (permalink / raw)
To: Mark Brown, Sen Wang, Liam Girdwood, Jaroslav Kysela,
Takashi Iwai, Jarkko Nikula, linux-omap
Cc: linux-kernel, linux-sound, bui duc phuc
From: bui duc phuc <phucduc.bui@gmail.com>
Use dev_err_probe() to replace dev_err() followed by returning
the error code. This keeps the error handling concise and
suppresses log messages for deferred probe errors.
Signed-off-by: bui duc phuc <phucduc.bui@gmail.com>
---
sound/soc/ti/ams-delta.c | 3 +--
1 file changed, 1 insertion(+), 2 deletions(-)
diff --git a/sound/soc/ti/ams-delta.c b/sound/soc/ti/ams-delta.c
index 61252359d5cb..1c9342ceaf56 100644
--- a/sound/soc/ti/ams-delta.c
+++ b/sound/soc/ti/ams-delta.c
@@ -574,9 +574,8 @@ static int ams_delta_probe(struct platform_device *pdev)
ret = snd_soc_register_card(card);
if (ret) {
- dev_err(&pdev->dev, "snd_soc_register_card failed (%d)\n", ret);
card->dev = NULL;
- return ret;
+ return dev_err_probe(&pdev->dev, ret, "snd_soc_register_card failed\n");
}
return 0;
}
--
2.43.0
^ permalink raw reply related [flat|nested] 16+ messages in thread* Re: [PATCH 01/10] ASoC: ti: ams-delta: Use dev_err_probe() for error handling
2026-07-14 12:00 ` [PATCH 01/10] ASoC: ti: ams-delta: Use dev_err_probe() for " phucduc.bui
@ 2026-07-14 12:27 ` Christophe JAILLET
2026-07-14 23:06 ` Bui Duc Phuc
0 siblings, 1 reply; 16+ messages in thread
From: Christophe JAILLET @ 2026-07-14 12:27 UTC (permalink / raw)
To: phucduc.bui, Mark Brown, Sen Wang, Liam Girdwood, Jaroslav Kysela,
Takashi Iwai, Jarkko Nikula, linux-omap
Cc: linux-kernel, linux-sound
Le 14/07/2026 à 14:00, phucduc.bui@gmail.com a écrit :
> From: bui duc phuc <phucduc.bui@gmail.com>
>
> Use dev_err_probe() to replace dev_err() followed by returning
> the error code. This keeps the error handling concise and
> suppresses log messages for deferred probe errors.
>
> Signed-off-by: bui duc phuc <phucduc.bui@gmail.com>
> ---
> sound/soc/ti/ams-delta.c | 3 +--
> 1 file changed, 1 insertion(+), 2 deletions(-)
>
> diff --git a/sound/soc/ti/ams-delta.c b/sound/soc/ti/ams-delta.c
> index 61252359d5cb..1c9342ceaf56 100644
> --- a/sound/soc/ti/ams-delta.c
> +++ b/sound/soc/ti/ams-delta.c
> @@ -574,9 +574,8 @@ static int ams_delta_probe(struct platform_device *pdev)
>
> ret = snd_soc_register_card(card);
> if (ret) {
> - dev_err(&pdev->dev, "snd_soc_register_card failed (%d)\n", ret);
> card->dev = NULL;
> - return ret;
> + return dev_err_probe(&pdev->dev, ret, "snd_soc_register_card failed\n");
Nitpick: could add some () (i.e. snd_soc_register_card()) to match patch
9/10.
CJ
> }
> return 0;
> }
^ permalink raw reply [flat|nested] 16+ messages in thread* Re: [PATCH 01/10] ASoC: ti: ams-delta: Use dev_err_probe() for error handling
2026-07-14 12:27 ` Christophe JAILLET
@ 2026-07-14 23:06 ` Bui Duc Phuc
0 siblings, 0 replies; 16+ messages in thread
From: Bui Duc Phuc @ 2026-07-14 23:06 UTC (permalink / raw)
To: Christophe JAILLET
Cc: Mark Brown, Sen Wang, Liam Girdwood, Jaroslav Kysela,
Takashi Iwai, Jarkko Nikula, linux-omap, linux-kernel,
linux-sound
Hi Christophe,
Thank you for your review.
>
> Nitpick: could add some () (i.e. snd_soc_register_card()) to match patch
> 9/10.
>
> CJ
>
I'll fix this in the next version.
Best regards,
Phuc
^ permalink raw reply [flat|nested] 16+ messages in thread
* [PATCH 02/10] ASoC: ti: davinci-evm: Use dev_err_probe() for error handling
2026-07-14 12:00 [PATCH 00/10] ASoC: ti: Improve probe error handling phucduc.bui
2026-07-14 12:00 ` [PATCH 01/10] ASoC: ti: ams-delta: Use dev_err_probe() for " phucduc.bui
@ 2026-07-14 12:00 ` phucduc.bui
2026-07-14 12:27 ` Christophe JAILLET
2026-07-14 12:29 ` Christophe JAILLET
2026-07-14 12:00 ` [PATCH 03/10] ASoC: ti: j721e-evm: Return the original error from card name parsing phucduc.bui
` (7 subsequent siblings)
9 siblings, 2 replies; 16+ messages in thread
From: phucduc.bui @ 2026-07-14 12:00 UTC (permalink / raw)
To: Mark Brown, Sen Wang, Liam Girdwood, Jaroslav Kysela,
Takashi Iwai, Jarkko Nikula, linux-omap
Cc: linux-kernel, linux-sound, bui duc phuc
From: bui duc phuc <phucduc.bui@gmail.com>
Replace dev_err() with dev_err_probe() when reporting
devm_snd_soc_register_card() failures. This suppresses
unnecessary log messages for deferred probe errors.
Signed-off-by: bui duc phuc <phucduc.bui@gmail.com>
---
sound/soc/ti/davinci-evm.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/sound/soc/ti/davinci-evm.c b/sound/soc/ti/davinci-evm.c
index ad514c2e5a25..7bcbb0067e25 100644
--- a/sound/soc/ti/davinci-evm.c
+++ b/sound/soc/ti/davinci-evm.c
@@ -247,7 +247,7 @@ static int davinci_evm_probe(struct platform_device *pdev)
ret = devm_snd_soc_register_card(&pdev->dev, &evm_soc_card);
if (ret) {
- dev_err(&pdev->dev, "snd_soc_register_card failed (%d)\n", ret);
+ dev_err_probe(&pdev->dev, ret, "snd_soc_register_card failed\n");
goto err_put;
}
--
2.43.0
^ permalink raw reply related [flat|nested] 16+ messages in thread* Re: [PATCH 02/10] ASoC: ti: davinci-evm: Use dev_err_probe() for error handling
2026-07-14 12:00 ` [PATCH 02/10] ASoC: ti: davinci-evm: " phucduc.bui
@ 2026-07-14 12:27 ` Christophe JAILLET
2026-07-14 12:29 ` Christophe JAILLET
1 sibling, 0 replies; 16+ messages in thread
From: Christophe JAILLET @ 2026-07-14 12:27 UTC (permalink / raw)
To: phucduc.bui, Mark Brown, Sen Wang, Liam Girdwood, Jaroslav Kysela,
Takashi Iwai, Jarkko Nikula, linux-omap
Cc: linux-kernel, linux-sound
Le 14/07/2026 à 14:00, phucduc.bui@gmail.com a écrit :
> From: bui duc phuc <phucduc.bui@gmail.com>
>
> Replace dev_err() with dev_err_probe() when reporting
> devm_snd_soc_register_card() failures. This suppresses
> unnecessary log messages for deferred probe errors.
>
> Signed-off-by: bui duc phuc <phucduc.bui@gmail.com>
> ---
> sound/soc/ti/davinci-evm.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/sound/soc/ti/davinci-evm.c b/sound/soc/ti/davinci-evm.c
> index ad514c2e5a25..7bcbb0067e25 100644
> --- a/sound/soc/ti/davinci-evm.c
> +++ b/sound/soc/ti/davinci-evm.c
> @@ -247,7 +247,7 @@ static int davinci_evm_probe(struct platform_device *pdev)
> ret = devm_snd_soc_register_card(&pdev->dev, &evm_soc_card);
>
Nitpick: this blank new line could be removed.
CJ
> if (ret) {
> - dev_err(&pdev->dev, "snd_soc_register_card failed (%d)\n", ret);
> + dev_err_probe(&pdev->dev, ret, "snd_soc_register_card failed\n");
> goto err_put;
> }
>
^ permalink raw reply [flat|nested] 16+ messages in thread* Re: [PATCH 02/10] ASoC: ti: davinci-evm: Use dev_err_probe() for error handling
2026-07-14 12:00 ` [PATCH 02/10] ASoC: ti: davinci-evm: " phucduc.bui
2026-07-14 12:27 ` Christophe JAILLET
@ 2026-07-14 12:29 ` Christophe JAILLET
2026-07-14 23:09 ` Bui Duc Phuc
1 sibling, 1 reply; 16+ messages in thread
From: Christophe JAILLET @ 2026-07-14 12:29 UTC (permalink / raw)
To: phucduc.bui, Mark Brown, Sen Wang, Liam Girdwood, Jaroslav Kysela,
Takashi Iwai, Jarkko Nikula, linux-omap
Cc: linux-kernel, linux-sound
Le 14/07/2026 à 14:00, phucduc.bui@gmail.com a écrit :
> From: bui duc phuc <phucduc.bui@gmail.com>
>
> Replace dev_err() with dev_err_probe() when reporting
> devm_snd_soc_register_card() failures. This suppresses
> unnecessary log messages for deferred probe errors.
>
> Signed-off-by: bui duc phuc <phucduc.bui@gmail.com>
> ---
> sound/soc/ti/davinci-evm.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/sound/soc/ti/davinci-evm.c b/sound/soc/ti/davinci-evm.c
> index ad514c2e5a25..7bcbb0067e25 100644
> --- a/sound/soc/ti/davinci-evm.c
> +++ b/sound/soc/ti/davinci-evm.c
> @@ -247,7 +247,7 @@ static int davinci_evm_probe(struct platform_device *pdev)
> ret = devm_snd_soc_register_card(&pdev->dev, &evm_soc_card);
>
Nitpick: this blank new line could be removed.
> if (ret) {
> - dev_err(&pdev->dev, "snd_soc_register_card failed (%d)\n", ret);
> + dev_err_probe(&pdev->dev, ret, "snd_soc_register_card failed\n");
Nitpick: Could be snd_soc_register_card()
> goto err_put;
> }
>
CJ
^ permalink raw reply [flat|nested] 16+ messages in thread* Re: [PATCH 02/10] ASoC: ti: davinci-evm: Use dev_err_probe() for error handling
2026-07-14 12:29 ` Christophe JAILLET
@ 2026-07-14 23:09 ` Bui Duc Phuc
0 siblings, 0 replies; 16+ messages in thread
From: Bui Duc Phuc @ 2026-07-14 23:09 UTC (permalink / raw)
To: Christophe JAILLET
Cc: Mark Brown, Sen Wang, Liam Girdwood, Jaroslav Kysela,
Takashi Iwai, Jarkko Nikula, linux-omap, linux-kernel,
linux-sound
Hi Christophe,
Thank you for your review.
> Nitpick: this blank new line could be removed.
>
> > if (ret) {
> > - dev_err(&pdev->dev, "snd_soc_register_card failed (%d)\n", ret);
> > + dev_err_probe(&pdev->dev, ret, "snd_soc_register_card failed\n");
>
> Nitpick: Could be snd_soc_register_card()
>
> > goto err_put;
> > }
> >
I'll fix this in the next version.
Best regards,
Phuc
^ permalink raw reply [flat|nested] 16+ messages in thread
* [PATCH 03/10] ASoC: ti: j721e-evm: Return the original error from card name parsing
2026-07-14 12:00 [PATCH 00/10] ASoC: ti: Improve probe error handling phucduc.bui
2026-07-14 12:00 ` [PATCH 01/10] ASoC: ti: ams-delta: Use dev_err_probe() for " phucduc.bui
2026-07-14 12:00 ` [PATCH 02/10] ASoC: ti: davinci-evm: " phucduc.bui
@ 2026-07-14 12:00 ` phucduc.bui
2026-07-14 12:00 ` [PATCH 04/10] ASoC: ti: omap-abe-twl6040: Preserve error code and drop redundant log phucduc.bui
` (6 subsequent siblings)
9 siblings, 0 replies; 16+ messages in thread
From: phucduc.bui @ 2026-07-14 12:00 UTC (permalink / raw)
To: Mark Brown, Sen Wang, Liam Girdwood, Jaroslav Kysela,
Takashi Iwai, Jarkko Nikula, linux-omap
Cc: linux-kernel, linux-sound, bui duc phuc
From: bui duc phuc <phucduc.bui@gmail.com>
Return the error from snd_soc_of_parse_card_name() directly instead of
converting it to -ENODEV. The helper already logs the error, so drop the
redundant dev_err().
Signed-off-by: bui duc phuc <phucduc.bui@gmail.com>
---
sound/soc/ti/j721e-evm.c | 7 +++----
1 file changed, 3 insertions(+), 4 deletions(-)
diff --git a/sound/soc/ti/j721e-evm.c b/sound/soc/ti/j721e-evm.c
index 312298e0b004..600897a3e1c5 100644
--- a/sound/soc/ti/j721e-evm.c
+++ b/sound/soc/ti/j721e-evm.c
@@ -870,10 +870,9 @@ static int j721e_soc_probe(struct platform_device *pdev)
card->num_dapm_routes = ARRAY_SIZE(j721e_cpb_dapm_routes);
card->fully_routed = 1;
- if (snd_soc_of_parse_card_name(card, "model")) {
- dev_err(&pdev->dev, "Card name is not provided\n");
- return -ENODEV;
- }
+ ret = snd_soc_of_parse_card_name(card, "model");
+ if (ret)
+ return ret;
link_cnt = 0;
conf_cnt = 0;
--
2.43.0
^ permalink raw reply related [flat|nested] 16+ messages in thread* [PATCH 04/10] ASoC: ti: omap-abe-twl6040: Preserve error code and drop redundant log
2026-07-14 12:00 [PATCH 00/10] ASoC: ti: Improve probe error handling phucduc.bui
` (2 preceding siblings ...)
2026-07-14 12:00 ` [PATCH 03/10] ASoC: ti: j721e-evm: Return the original error from card name parsing phucduc.bui
@ 2026-07-14 12:00 ` phucduc.bui
2026-07-14 12:00 ` [PATCH 05/10] ASoC: ti: omap-abe-twl6040: Use dev_err_probe() for error handling phucduc.bui
` (5 subsequent siblings)
9 siblings, 0 replies; 16+ messages in thread
From: phucduc.bui @ 2026-07-14 12:00 UTC (permalink / raw)
To: Mark Brown, Sen Wang, Liam Girdwood, Jaroslav Kysela,
Takashi Iwai, Jarkko Nikula, linux-omap
Cc: linux-kernel, linux-sound, bui duc phuc
From: bui duc phuc <phucduc.bui@gmail.com>
Return the original errors from the OF parsing helpers and remove the
redundant error messages, as the helpers already report failures.
Signed-off-by: bui duc phuc <phucduc.bui@gmail.com>
---
sound/soc/ti/omap-abe-twl6040.c | 11 ++++-------
1 file changed, 4 insertions(+), 7 deletions(-)
diff --git a/sound/soc/ti/omap-abe-twl6040.c b/sound/soc/ti/omap-abe-twl6040.c
index 56aa4b22083b..dfa931071d81 100644
--- a/sound/soc/ti/omap-abe-twl6040.c
+++ b/sound/soc/ti/omap-abe-twl6040.c
@@ -234,16 +234,13 @@ static int omap_abe_probe(struct platform_device *pdev)
card->dapm_routes = audio_map;
card->num_dapm_routes = ARRAY_SIZE(audio_map);
- if (snd_soc_of_parse_card_name(card, "ti,model")) {
- dev_err(&pdev->dev, "Card name is not provided\n");
- return -ENODEV;
- }
+ ret = snd_soc_of_parse_card_name(card, "ti,model");
+ if (ret)
+ return ret;
ret = snd_soc_of_parse_audio_routing(card, "ti,audio-routing");
- if (ret) {
- dev_err(&pdev->dev, "Error while parsing DAPM routing\n");
+ if (ret)
return ret;
- }
dai_node = of_parse_phandle(node, "ti,mcpdm", 0);
if (!dai_node) {
--
2.43.0
^ permalink raw reply related [flat|nested] 16+ messages in thread* [PATCH 05/10] ASoC: ti: omap-abe-twl6040: Use dev_err_probe() for error handling
2026-07-14 12:00 [PATCH 00/10] ASoC: ti: Improve probe error handling phucduc.bui
` (3 preceding siblings ...)
2026-07-14 12:00 ` [PATCH 04/10] ASoC: ti: omap-abe-twl6040: Preserve error code and drop redundant log phucduc.bui
@ 2026-07-14 12:00 ` phucduc.bui
2026-07-14 12:00 ` [PATCH 06/10] ASoC: ti: omap-dmic: " phucduc.bui
` (4 subsequent siblings)
9 siblings, 0 replies; 16+ messages in thread
From: phucduc.bui @ 2026-07-14 12:00 UTC (permalink / raw)
To: Mark Brown, Sen Wang, Liam Girdwood, Jaroslav Kysela,
Takashi Iwai, Jarkko Nikula, linux-omap
Cc: linux-kernel, linux-sound, bui duc phuc
From: bui duc phuc <phucduc.bui@gmail.com>
Replace dev_err() with dev_err_probe() when reporting
devm_snd_soc_register_card() failures. This suppresses
unnecessary log messages for deferred probe errors.
Signed-off-by: bui duc phuc <phucduc.bui@gmail.com>
---
sound/soc/ti/omap-abe-twl6040.c | 3 +--
1 file changed, 1 insertion(+), 2 deletions(-)
diff --git a/sound/soc/ti/omap-abe-twl6040.c b/sound/soc/ti/omap-abe-twl6040.c
index dfa931071d81..d86cdd312efe 100644
--- a/sound/soc/ti/omap-abe-twl6040.c
+++ b/sound/soc/ti/omap-abe-twl6040.c
@@ -296,8 +296,7 @@ static int omap_abe_probe(struct platform_device *pdev)
ret = devm_snd_soc_register_card(&pdev->dev, card);
if (ret)
- dev_err(&pdev->dev, "devm_snd_soc_register_card() failed: %d\n",
- ret);
+ dev_err_probe(&pdev->dev, ret, "devm_snd_soc_register_card() failed\n");
return ret;
}
--
2.43.0
^ permalink raw reply related [flat|nested] 16+ messages in thread* [PATCH 06/10] ASoC: ti: omap-dmic: Use dev_err_probe() for error handling
2026-07-14 12:00 [PATCH 00/10] ASoC: ti: Improve probe error handling phucduc.bui
` (4 preceding siblings ...)
2026-07-14 12:00 ` [PATCH 05/10] ASoC: ti: omap-abe-twl6040: Use dev_err_probe() for error handling phucduc.bui
@ 2026-07-14 12:00 ` phucduc.bui
2026-07-14 12:00 ` [PATCH 07/10] ASoC: ti: omap-hdmi: " phucduc.bui
` (3 subsequent siblings)
9 siblings, 0 replies; 16+ messages in thread
From: phucduc.bui @ 2026-07-14 12:00 UTC (permalink / raw)
To: Mark Brown, Sen Wang, Liam Girdwood, Jaroslav Kysela,
Takashi Iwai, Jarkko Nikula, linux-omap
Cc: linux-kernel, linux-sound, bui duc phuc
From: bui duc phuc <phucduc.bui@gmail.com>
Replace dev_err() with dev_err_probe() when handling clock lookup
failures. This preserves the original error code and suppresses
unnecessary deferred probe error messages.
Signed-off-by: bui duc phuc <phucduc.bui@gmail.com>
---
sound/soc/ti/omap-dmic.c | 7 +++----
1 file changed, 3 insertions(+), 4 deletions(-)
diff --git a/sound/soc/ti/omap-dmic.c b/sound/soc/ti/omap-dmic.c
index b795b9f66b0e..c8d791f05ae4 100644
--- a/sound/soc/ti/omap-dmic.c
+++ b/sound/soc/ti/omap-dmic.c
@@ -465,10 +465,9 @@ static int asoc_dmic_probe(struct platform_device *pdev)
mutex_init(&dmic->mutex);
dmic->fclk = devm_clk_get(dmic->dev, "fck");
- if (IS_ERR(dmic->fclk)) {
- dev_err(dmic->dev, "can't get fck\n");
- return -ENODEV;
- }
+ if (IS_ERR(dmic->fclk))
+ return dev_err_probe(dmic->dev, PTR_ERR(dmic->fclk),
+ "can't get fck\n");
res = platform_get_resource_byname(pdev, IORESOURCE_MEM, "dma");
if (!res) {
--
2.43.0
^ permalink raw reply related [flat|nested] 16+ messages in thread* [PATCH 07/10] ASoC: ti: omap-hdmi: Use dev_err_probe() for error handling
2026-07-14 12:00 [PATCH 00/10] ASoC: ti: Improve probe error handling phucduc.bui
` (5 preceding siblings ...)
2026-07-14 12:00 ` [PATCH 06/10] ASoC: ti: omap-dmic: " phucduc.bui
@ 2026-07-14 12:00 ` phucduc.bui
2026-07-14 12:00 ` [PATCH 08/10] ASoC: ti: omap-twl4030: Return the original error code phucduc.bui
` (2 subsequent siblings)
9 siblings, 0 replies; 16+ messages in thread
From: phucduc.bui @ 2026-07-14 12:00 UTC (permalink / raw)
To: Mark Brown, Sen Wang, Liam Girdwood, Jaroslav Kysela,
Takashi Iwai, Jarkko Nikula, linux-omap
Cc: linux-kernel, linux-sound, bui duc phuc
From: bui duc phuc <phucduc.bui@gmail.com>
Replace dev_err() with dev_err_probe() when reporting
devm_snd_soc_register_card() failures. This suppresses
unnecessary log messages for deferred probe errors.
Signed-off-by: bui duc phuc <phucduc.bui@gmail.com>
---
sound/soc/ti/omap-hdmi.c | 6 ++----
1 file changed, 2 insertions(+), 4 deletions(-)
diff --git a/sound/soc/ti/omap-hdmi.c b/sound/soc/ti/omap-hdmi.c
index e60f5b483fc5..72114965c37d 100644
--- a/sound/soc/ti/omap-hdmi.c
+++ b/sound/soc/ti/omap-hdmi.c
@@ -375,10 +375,8 @@ static int omap_hdmi_audio_probe(struct platform_device *pdev)
card->dev = dev;
ret = devm_snd_soc_register_card(dev, card);
- if (ret) {
- dev_err(dev, "snd_soc_register_card failed (%d)\n", ret);
- return ret;
- }
+ if (ret)
+ return dev_err_probe(dev, ret, "snd_soc_register_card failed\n");
ad->card = card;
snd_soc_card_set_drvdata(card, ad);
--
2.43.0
^ permalink raw reply related [flat|nested] 16+ messages in thread* [PATCH 08/10] ASoC: ti: omap-twl4030: Return the original error code
2026-07-14 12:00 [PATCH 00/10] ASoC: ti: Improve probe error handling phucduc.bui
` (6 preceding siblings ...)
2026-07-14 12:00 ` [PATCH 07/10] ASoC: ti: omap-hdmi: " phucduc.bui
@ 2026-07-14 12:00 ` phucduc.bui
2026-07-14 12:00 ` [PATCH 09/10] ASoC: ti: omap-twl4030: Use dev_err_probe() for error handling phucduc.bui
2026-07-14 12:00 ` [PATCH 10/10] ASoC: ti: rx51: " phucduc.bui
9 siblings, 0 replies; 16+ messages in thread
From: phucduc.bui @ 2026-07-14 12:00 UTC (permalink / raw)
To: Mark Brown, Sen Wang, Liam Girdwood, Jaroslav Kysela,
Takashi Iwai, Jarkko Nikula, linux-omap
Cc: linux-kernel, linux-sound, bui duc phuc
From: bui duc phuc <phucduc.bui@gmail.com>
Return the error from snd_soc_of_parse_card_name() directly and drop
the redundant error message since the helper already logs the failure.
Signed-off-by: bui duc phuc <phucduc.bui@gmail.com>
---
sound/soc/ti/omap-twl4030.c | 7 +++----
1 file changed, 3 insertions(+), 4 deletions(-)
diff --git a/sound/soc/ti/omap-twl4030.c b/sound/soc/ti/omap-twl4030.c
index 4d80f8a7a947..2a80e44035d7 100644
--- a/sound/soc/ti/omap-twl4030.c
+++ b/sound/soc/ti/omap-twl4030.c
@@ -253,10 +253,9 @@ static int omap_twl4030_probe(struct platform_device *pdev)
struct device_node *dai_node;
struct property *prop;
- if (snd_soc_of_parse_card_name(card, "ti,model")) {
- dev_err(&pdev->dev, "Card name is not provided\n");
- return -ENODEV;
- }
+ ret = snd_soc_of_parse_card_name(card, "ti,model");
+ if (ret)
+ return ret;
dai_node = of_parse_phandle(node, "ti,mcbsp", 0);
if (!dai_node) {
--
2.43.0
^ permalink raw reply related [flat|nested] 16+ messages in thread* [PATCH 09/10] ASoC: ti: omap-twl4030: Use dev_err_probe() for error handling
2026-07-14 12:00 [PATCH 00/10] ASoC: ti: Improve probe error handling phucduc.bui
` (7 preceding siblings ...)
2026-07-14 12:00 ` [PATCH 08/10] ASoC: ti: omap-twl4030: Return the original error code phucduc.bui
@ 2026-07-14 12:00 ` phucduc.bui
2026-07-14 12:00 ` [PATCH 10/10] ASoC: ti: rx51: " phucduc.bui
9 siblings, 0 replies; 16+ messages in thread
From: phucduc.bui @ 2026-07-14 12:00 UTC (permalink / raw)
To: Mark Brown, Sen Wang, Liam Girdwood, Jaroslav Kysela,
Takashi Iwai, Jarkko Nikula, linux-omap
Cc: linux-kernel, linux-sound, bui duc phuc
From: bui duc phuc <phucduc.bui@gmail.com>
Replace dev_err() with dev_err_probe() when reporting
devm_snd_soc_register_card() failures. This suppresses
unnecessary log messages for deferred probe errors.
Signed-off-by: bui duc phuc <phucduc.bui@gmail.com>
---
sound/soc/ti/omap-twl4030.c | 8 +++-----
1 file changed, 3 insertions(+), 5 deletions(-)
diff --git a/sound/soc/ti/omap-twl4030.c b/sound/soc/ti/omap-twl4030.c
index 2a80e44035d7..576f4d3615e8 100644
--- a/sound/soc/ti/omap-twl4030.c
+++ b/sound/soc/ti/omap-twl4030.c
@@ -306,11 +306,9 @@ static int omap_twl4030_probe(struct platform_device *pdev)
snd_soc_card_set_drvdata(card, priv);
ret = devm_snd_soc_register_card(&pdev->dev, card);
- if (ret) {
- dev_err(&pdev->dev, "devm_snd_soc_register_card() failed: %d\n",
- ret);
- return ret;
- }
+ if (ret)
+ return dev_err_probe(&pdev->dev, ret,
+ "devm_snd_soc_register_card() failed\n");
return 0;
}
--
2.43.0
^ permalink raw reply related [flat|nested] 16+ messages in thread* [PATCH 10/10] ASoC: ti: rx51: Use dev_err_probe() for error handling
2026-07-14 12:00 [PATCH 00/10] ASoC: ti: Improve probe error handling phucduc.bui
` (8 preceding siblings ...)
2026-07-14 12:00 ` [PATCH 09/10] ASoC: ti: omap-twl4030: Use dev_err_probe() for error handling phucduc.bui
@ 2026-07-14 12:00 ` phucduc.bui
9 siblings, 0 replies; 16+ messages in thread
From: phucduc.bui @ 2026-07-14 12:00 UTC (permalink / raw)
To: Mark Brown, Sen Wang, Liam Girdwood, Jaroslav Kysela,
Takashi Iwai, Jarkko Nikula, linux-omap
Cc: linux-kernel, linux-sound, bui duc phuc
From: bui duc phuc <phucduc.bui@gmail.com>
Replace dev_err() with dev_err_probe() when reporting probe
failures. This preserves the original error code and suppresses
unnecessary log messages for deferred probe errors.
Signed-off-by: bui duc phuc <phucduc.bui@gmail.com>
---
sound/soc/ti/rx51.c | 28 ++++++++++++----------------
1 file changed, 12 insertions(+), 16 deletions(-)
diff --git a/sound/soc/ti/rx51.c b/sound/soc/ti/rx51.c
index cfc23e0838c2..46053b8f3202 100644
--- a/sound/soc/ti/rx51.c
+++ b/sound/soc/ti/rx51.c
@@ -418,31 +418,27 @@ static int rx51_soc_probe(struct platform_device *pdev)
pdata->tvout_selection_gpio = devm_gpiod_get(card->dev,
"tvout-selection",
GPIOD_OUT_LOW);
- if (IS_ERR(pdata->tvout_selection_gpio)) {
- dev_err(card->dev, "could not get tvout selection gpio\n");
- return PTR_ERR(pdata->tvout_selection_gpio);
- }
+ if (IS_ERR(pdata->tvout_selection_gpio))
+ return dev_err_probe(card->dev, PTR_ERR(pdata->tvout_selection_gpio),
+ "could not get tvout selection gpio\n");
pdata->eci_sw_gpio = devm_gpiod_get(card->dev, "eci-switch",
GPIOD_OUT_HIGH);
- if (IS_ERR(pdata->eci_sw_gpio)) {
- dev_err(card->dev, "could not get eci switch gpio\n");
- return PTR_ERR(pdata->eci_sw_gpio);
- }
+ if (IS_ERR(pdata->eci_sw_gpio))
+ return dev_err_probe(card->dev, PTR_ERR(pdata->eci_sw_gpio),
+ "could not get eci switch gpio\n");
pdata->speaker_amp_gpio = devm_gpiod_get(card->dev,
"speaker-amplifier",
GPIOD_OUT_LOW);
- if (IS_ERR(pdata->speaker_amp_gpio)) {
- dev_err(card->dev, "could not get speaker enable gpio\n");
- return PTR_ERR(pdata->speaker_amp_gpio);
- }
+ if (IS_ERR(pdata->speaker_amp_gpio))
+ return dev_err_probe(card->dev, PTR_ERR(pdata->speaker_amp_gpio),
+ "could not get speaker enable gpio\n");
err = devm_snd_soc_register_card(card->dev, card);
- if (err) {
- dev_err(card->dev, "snd_soc_register_card failed (%d)\n", err);
- return err;
- }
+ if (err)
+ return dev_err_probe(card->dev, err,
+ "snd_soc_register_card failed\n");
return 0;
}
--
2.43.0
^ permalink raw reply related [flat|nested] 16+ messages in thread