diff mbox

[1/2] mtd: sst25l: Remove redundant spi_set_drvdata

Message ID 1381224094-14098-1-git-send-email-sachin.kamat@linaro.org
State Accepted
Commit fcfd9f2dd786a79400e1e799713ff71e939b40b5
Headers show

Commit Message

Sachin Kamat Oct. 8, 2013, 9:21 a.m. UTC
Driver core will set the driver data to NULL upon detach
or probe failure.

Signed-off-by: Sachin Kamat <sachin.kamat@linaro.org>
---
 drivers/mtd/devices/sst25l.c |    1 -
 1 file changed, 1 deletion(-)

Comments

Brian Norris Oct. 10, 2013, 12:49 a.m. UTC | #1
On Tue, Oct 08, 2013 at 02:51:33PM +0530, Sachin Kamat wrote:
> Driver core will set the driver data to NULL upon detach
> or probe failure.
> 
> Signed-off-by: Sachin Kamat <sachin.kamat@linaro.org>

Pushed the pair to l2-mtd.git. Thanks!

Brian
diff mbox

Patch

diff --git a/drivers/mtd/devices/sst25l.c b/drivers/mtd/devices/sst25l.c
index a42f1f0..7cc70db 100644
--- a/drivers/mtd/devices/sst25l.c
+++ b/drivers/mtd/devices/sst25l.c
@@ -404,7 +404,6 @@  static int sst25l_probe(struct spi_device *spi)
 					data ? data->nr_parts : 0);
 	if (ret) {
 		kfree(flash);
-		spi_set_drvdata(spi, NULL);
 		return -ENODEV;
 	}