From: Waqar Hameed Date: Tue, 5 Aug 2025 09:33:32 +0000 (+0200) Subject: ASoC: SOF: imx: Remove error print for devm_add_action_or_reset() X-Git-Tag: v6.18-rc1~135^2~13^2~70 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=9d6a51651faa577e5d2be9d67915b7621c5c589a;p=thirdparty%2Fkernel%2Flinux.git ASoC: SOF: imx: Remove error print for devm_add_action_or_reset() When `devm_add_action_or_reset()` fails, it is due to a failed memory allocation and will thus return `-ENOMEM`. `dev_err_probe()` doesn't do anything when error is `-ENOMEM`. Therefore, remove the useless call to `dev_err_probe()` when `devm_add_action_or_reset()` fails, and just return the value instead. Signed-off-by: Waqar Hameed Reviewed-by: Daniel Baluta Link: https://patch.msgid.link/pndpldam7tf.a.out@axis.com Signed-off-by: Mark Brown --- diff --git a/sound/soc/sof/imx/imx-common.c b/sound/soc/sof/imx/imx-common.c index f00b381cec3b4..1757539a6a283 100644 --- a/sound/soc/sof/imx/imx-common.c +++ b/sound/soc/sof/imx/imx-common.c @@ -382,7 +382,7 @@ static int imx_probe(struct snd_sof_dev *sdev) imx_unregister_action, sdev); if (ret) - return dev_err_probe(sdev->dev, ret, "failed to add devm action\n"); + return ret; common->ipc_handle = dev_get_drvdata(&common->ipc_dev->dev); if (!common->ipc_handle)