Commit 7c5d8a24 authored by Geert Uytterhoeven's avatar Geert Uytterhoeven Committed by Mark Brown

spi: Do not print a message if spi_controller_{suspend,resume}() fails

spi_controller_{suspend,resume}() already prints an error message on
failure, so there is no need to repeat this in individual drivers.

Note: spi_master_{suspend,resume}() is an alias for
      spi_controller_{suspend,resume}().
Signed-off-by: default avatarGeert Uytterhoeven <geert+renesas@glider.be>
Reviewed-by: default avatarAlexandre Belloni <alexandre.belloni@bootlin.com>
Reviewed-by: default avatarDaniel Mack <daniel@zonque.org>
Acked-by: default avatarNicolas Ferre <nicolas.ferre@microchip.com>
Signed-off-by: default avatarMark Brown <broonie@kernel.org>
parent 35386dfd
...@@ -1767,10 +1767,8 @@ static int atmel_spi_suspend(struct device *dev) ...@@ -1767,10 +1767,8 @@ static int atmel_spi_suspend(struct device *dev)
/* Stop the queue running */ /* Stop the queue running */
ret = spi_master_suspend(master); ret = spi_master_suspend(master);
if (ret) { if (ret)
dev_warn(dev, "cannot suspend master\n");
return ret; return ret;
}
if (!pm_runtime_suspended(dev)) if (!pm_runtime_suspended(dev))
atmel_spi_runtime_suspend(dev); atmel_spi_runtime_suspend(dev);
...@@ -1799,11 +1797,7 @@ static int atmel_spi_resume(struct device *dev) ...@@ -1799,11 +1797,7 @@ static int atmel_spi_resume(struct device *dev)
} }
/* Start the queue running */ /* Start the queue running */
ret = spi_master_resume(master); return spi_master_resume(master);
if (ret)
dev_err(dev, "problem starting queue (%d)\n", ret);
return ret;
} }
#endif #endif
......
...@@ -572,13 +572,8 @@ EXPORT_SYMBOL_GPL(dw_spi_suspend_host); ...@@ -572,13 +572,8 @@ EXPORT_SYMBOL_GPL(dw_spi_suspend_host);
int dw_spi_resume_host(struct dw_spi *dws) int dw_spi_resume_host(struct dw_spi *dws)
{ {
int ret;
spi_hw_init(&dws->master->dev, dws); spi_hw_init(&dws->master->dev, dws);
ret = spi_controller_resume(dws->master); return spi_controller_resume(dws->master);
if (ret)
dev_err(&dws->master->dev, "fail to start queue (%d)\n", ret);
return ret;
} }
EXPORT_SYMBOL_GPL(dw_spi_resume_host); EXPORT_SYMBOL_GPL(dw_spi_resume_host);
......
...@@ -798,10 +798,8 @@ static int of_fsl_espi_suspend(struct device *dev) ...@@ -798,10 +798,8 @@ static int of_fsl_espi_suspend(struct device *dev)
int ret; int ret;
ret = spi_master_suspend(master); ret = spi_master_suspend(master);
if (ret) { if (ret)
dev_warn(dev, "cannot suspend master\n");
return ret; return ret;
}
return pm_runtime_force_suspend(dev); return pm_runtime_force_suspend(dev);
} }
......
...@@ -2325,10 +2325,8 @@ static int pl022_suspend(struct device *dev) ...@@ -2325,10 +2325,8 @@ static int pl022_suspend(struct device *dev)
int ret; int ret;
ret = spi_master_suspend(pl022->master); ret = spi_master_suspend(pl022->master);
if (ret) { if (ret)
dev_warn(dev, "cannot suspend master\n");
return ret; return ret;
}
ret = pm_runtime_force_suspend(dev); ret = pm_runtime_force_suspend(dev);
if (ret) { if (ret) {
...@@ -2353,9 +2351,7 @@ static int pl022_resume(struct device *dev) ...@@ -2353,9 +2351,7 @@ static int pl022_resume(struct device *dev)
/* Start the queue running */ /* Start the queue running */
ret = spi_master_resume(pl022->master); ret = spi_master_resume(pl022->master);
if (ret) if (!ret)
dev_err(dev, "problem starting queue (%d)\n", ret);
else
dev_dbg(dev, "resumed\n"); dev_dbg(dev, "resumed\n");
return ret; return ret;
......
...@@ -1808,13 +1808,7 @@ static int pxa2xx_spi_resume(struct device *dev) ...@@ -1808,13 +1808,7 @@ static int pxa2xx_spi_resume(struct device *dev)
lpss_ssp_setup(drv_data); lpss_ssp_setup(drv_data);
/* Start the queue running */ /* Start the queue running */
status = spi_controller_resume(drv_data->master); return spi_controller_resume(drv_data->master);
if (status != 0) {
dev_err(dev, "problem starting queue (%d)\n", status);
return status;
}
return 0;
} }
#endif #endif
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment