From: Lukas Wunner Date: Mon, 4 May 2020 11:12:02 +0000 (+0200) Subject: spi: amd: Pass probe errors back to driver core X-Git-Tag: v5.10.7~2120^2~74^2~3 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=cc17fbec2e785926dafce65d014f8301847dff40;p=platform%2Fkernel%2Flinux-rpi.git spi: amd: Pass probe errors back to driver core If probing fails, the AMD SPI driver pretends success to the driver core by returning 0. Return the errno instead. Signed-off-by: Lukas Wunner Link: https://lore.kernel.org/r/689f29a359718dab4f5de9ee66c02ea97b3bd9e8.1588590210.git.lukas@wunner.de Signed-off-by: Mark Brown --- diff --git a/drivers/spi/spi-amd.c b/drivers/spi/spi-amd.c index 65b53ee..a4248b9 100644 --- a/drivers/spi/spi-amd.c +++ b/drivers/spi/spi-amd.c @@ -294,7 +294,7 @@ static int amd_spi_probe(struct platform_device *pdev) err_free_master: spi_master_put(master); - return 0; + return err; } static int amd_spi_remove(struct platform_device *pdev)