spi: dw: use plain struct device * at earlier ->probe()
authorAndy Shevchenko <andriy.shevchenko@linux.intel.com>
Wed, 14 Oct 2015 20:12:17 +0000 (23:12 +0300)
committerMark Brown <broonie@kernel.org>
Mon, 19 Oct 2015 19:31:57 +0000 (20:31 +0100)
The name of the master device is set during registrationg which happens after
we issue the error message. Change it to plain struct device * to see which
device registration failed.

Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
drivers/spi/spi-dw.c

index 1153d36ec8a655d2e8b06c7243c082f3cf1f781b..749a831f26ce61796fe28bd31fafb26fc1e63557 100644 (file)
@@ -520,7 +520,7 @@ int dw_spi_add_host(struct device *dev, struct dw_spi *dws)
        ret = devm_request_irq(dev, dws->irq, dw_spi_irq, IRQF_SHARED,
                        dws->name, master);
        if (ret < 0) {
-               dev_err(&master->dev, "can not get IRQ\n");
+               dev_err(dev, "can not get IRQ\n");
                goto err_free_master;
        }