spi: rspi: Remove useless memory allocation failure message
authorGeert Uytterhoeven <geert+renesas@glider.be>
Wed, 4 Jan 2017 10:15:07 +0000 (11:15 +0100)
committerMark Brown <broonie@kernel.org>
Wed, 4 Jan 2017 17:39:21 +0000 (17:39 +0000)
Printing an error on memory allocation failure is unnecessary.

Signed-off-by: Geert Uytterhoeven <geert+renesas@glider.be>
Signed-off-by: Mark Brown <broonie@kernel.org>
drivers/spi/spi-rspi.c

index 9daf500317376bd143cb56eb4b14738d11adbdca..58b7e68013f3bcdc39e669146b9bf017b80439ac 100644 (file)
@@ -1227,10 +1227,8 @@ static int rspi_probe(struct platform_device *pdev)
        const struct spi_ops *ops;
 
        master = spi_alloc_master(&pdev->dev, sizeof(struct rspi_data));
-       if (master == NULL) {
-               dev_err(&pdev->dev, "spi_alloc_master error.\n");
+       if (master == NULL)
                return -ENOMEM;
-       }
 
        of_id = of_match_device(rspi_of_match, &pdev->dev);
        if (of_id) {