]> Pileus Git - ~andy/linux/commitdiff
spi: efm32: add spi_bitbang_stop to device remove callback
authorUwe Kleine-König <u.kleine-koenig@pengutronix.de>
Tue, 10 Sep 2013 07:51:30 +0000 (09:51 +0200)
committerMark Brown <broonie@linaro.org>
Mon, 7 Oct 2013 13:51:24 +0000 (14:51 +0100)
This call is needed to cleanup the resources requested by
spi_bitbang_start in the probe callback.

Noticed-by: Axel Lin <axel.lin@ingics.com>
Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
Signed-off-by: Mark Brown <broonie@linaro.org>
drivers/spi/spi-efm32.c

index 34ef44c77e8e4862657263a04211b044f7e649db..5ce61e5f9770088ac6638875bbd7ce1085f16806 100644 (file)
@@ -477,6 +477,8 @@ static int efm32_spi_remove(struct platform_device *pdev)
        struct spi_master *master = platform_get_drvdata(pdev);
        struct efm32_spi_ddata *ddata = spi_master_get_devdata(master);
 
+       spi_bitbang_stop(&ddata->bitbang);
+
        efm32_spi_write32(ddata, 0, REG_IEN);
 
        free_irq(ddata->txirq, ddata);