spi: spidev: remove unnecessary spi_set_drvdata()
authorJingoo Han <jg1.han@samsung.com>
Tue, 10 Sep 2013 09:55:20 +0000 (18:55 +0900)
committerMark Brown <broonie@linaro.org>
Mon, 16 Sep 2013 23:19:50 +0000 (00:19 +0100)
The driver core clears the driver data to NULL after device_release
or on probe failure. Thus, it is not needed to manually clear the
device driver data to NULL.

Signed-off-by: Jingoo Han <jg1.han@samsung.com>
Signed-off-by: Mark Brown <broonie@linaro.org>
drivers/spi/spidev.c

index ca5bcfe874d0afa3d01849c23b72a1c5d08846a2..c53556a1899a7558efb80d914e579792e1500f99 100644 (file)
@@ -629,7 +629,6 @@ static int spidev_remove(struct spi_device *spi)
        /* make sure ops on existing fds can abort cleanly */
        spin_lock_irq(&spidev->spi_lock);
        spidev->spi = NULL;
-       spi_set_drvdata(spi, NULL);
        spin_unlock_irq(&spidev->spi_lock);
 
        /* prevent new opens */