From: bui duc phuc <[email protected]> The errors are either reported directly by these functions or already reported deeper in the call chain, so additional dev_err() and dev_warn() calls are unnecessary.
Signed-off-by: bui duc phuc <[email protected]> --- sound/soc/fsl/fsl_sai.c | 12 +++--------- 1 file changed, 3 insertions(+), 9 deletions(-) diff --git a/sound/soc/fsl/fsl_sai.c b/sound/soc/fsl/fsl_sai.c index 44a34f48a0cf..5532fab80be0 100644 --- a/sound/soc/fsl/fsl_sai.c +++ b/sound/soc/fsl/fsl_sai.c @@ -1615,10 +1615,8 @@ static int fsl_sai_probe(struct platform_device *pdev) /* read dataline mask for rx and tx*/ ret = fsl_sai_read_dlcfg(sai); - if (ret < 0) { - dev_err(dev, "failed to read dlcfg %d\n", ret); + if (ret < 0) return ret; - } irq = platform_get_irq(pdev, 0); if (irq < 0) @@ -1698,9 +1696,7 @@ static int fsl_sai_probe(struct platform_device *pdev) if (ret < 0) dev_warn(dev, "Error reading SAI version: %d\n", ret); - ret = fsl_sai_reset_hw(dev); - if (ret < 0) - dev_warn(dev, "Failed to reset hardware: %d\n", ret); + fsl_sai_reset_hw(dev); /* Select MCLK direction */ if (sai->mclk_direction_output && @@ -1715,10 +1711,8 @@ static int fsl_sai_probe(struct platform_device *pdev) ret = devm_request_irq(dev, irq, fsl_sai_isr, IRQF_SHARED, np->name, sai); - if (ret) { - dev_err(dev, "failed to claim irq %u\n", irq); + if (ret) goto err_pm_get_sync; - } if (of_device_is_compatible(np, "fsl,imx952-sai") && !of_property_read_string(np, "fsl,sai-amix-mode", &str)) { -- 2.43.0
