summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJohan Hovold <johan@kernel.org>2026-04-21 16:39:25 +0200
committerMark Brown <broonie@kernel.org>2026-04-22 15:05:53 +0100
commit2b20e674244248cdd3e33eee34eebd7408ff134f (patch)
treee0af21ce87e4d61511496da040b77182bb3492b9
parent821f0951b20880bd5976f73e202c2fa637c812f6 (diff)
spi: axiado: clean up probe return value
Drop the redundant initialisation and return explicit zero on successful probe to make the code more readable. Signed-off-by: Johan Hovold <johan@kernel.org> Link: https://patch.msgid.link/20260421143925.1551781-4-johan@kernel.org Signed-off-by: Mark Brown <broonie@kernel.org>
-rw-r--r--drivers/spi/spi-axiado.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/spi/spi-axiado.c b/drivers/spi/spi-axiado.c
index a347774ae824..9057a0a8df4a 100644
--- a/drivers/spi/spi-axiado.c
+++ b/drivers/spi/spi-axiado.c
@@ -751,9 +751,9 @@ static const struct spi_controller_mem_ops ax_spi_mem_ops = {
*/
static int ax_spi_probe(struct platform_device *pdev)
{
- int ret = 0, irq;
struct spi_controller *ctlr;
struct ax_spi *xspi;
+ int ret, irq;
u32 num_cs;
ctlr = devm_spi_alloc_host(&pdev->dev, sizeof(*xspi));
@@ -852,7 +852,7 @@ static int ax_spi_probe(struct platform_device *pdev)
pm_runtime_put_autosuspend(&pdev->dev);
- return ret;
+ return 0;
err_disable_rpm:
pm_runtime_disable(&pdev->dev);