From b9ffe4086206d1aedb3c7e62249e84beefdc2bca Mon Sep 17 00:00:00 2001 From: Andy Shevchenko Date: Wed, 27 Mar 2019 20:01:06 +0200 Subject: [PATCH] mmc: mmc_spi: Remove redundant dev_set_drvdata() Driver core sets it to NULL upon probe failure or release. Signed-off-by: Andy Shevchenko Signed-off-by: Ulf Hansson --- drivers/mmc/host/mmc_spi.c | 2 -- 1 file changed, 2 deletions(-) diff --git a/drivers/mmc/host/mmc_spi.c b/drivers/mmc/host/mmc_spi.c index a3533935e282..36baa9e88648 100644 --- a/drivers/mmc/host/mmc_spi.c +++ b/drivers/mmc/host/mmc_spi.c @@ -1489,7 +1489,6 @@ fail_ones_dma: fail_nobuf1: mmc_free_host(mmc); mmc_spi_put_pdata(spi); - dev_set_drvdata(&spi->dev, NULL); nomem: kfree(ones); @@ -1524,7 +1523,6 @@ static int mmc_spi_remove(struct spi_device *spi) spi->max_speed_hz = mmc->f_max; mmc_free_host(mmc); mmc_spi_put_pdata(spi); - dev_set_drvdata(&spi->dev, NULL); } return 0; } -- 2.30.2