Commit 30cd8248 authored by charles.park's avatar charles.park

ODROIDXU3 : SPI CS-GPIO(#190) request error bug fix.

Change-Id: I3729423e41e63ac2b8e6bf89c20b9c514a41260b
parent 68c55c48
...@@ -1826,7 +1826,7 @@ CONFIG_SPI_MASTER=y ...@@ -1826,7 +1826,7 @@ CONFIG_SPI_MASTER=y
# CONFIG_SPI_OC_TINY is not set # CONFIG_SPI_OC_TINY is not set
# CONFIG_SPI_PL022 is not set # CONFIG_SPI_PL022 is not set
# CONFIG_SPI_PXA2XX_PCI is not set # CONFIG_SPI_PXA2XX_PCI is not set
CONFIG_SPI_S3C64XX=y CONFIG_SPI_S3C64XX=m
# CONFIG_SPI_SC18IS602 is not set # CONFIG_SPI_SC18IS602 is not set
# CONFIG_SPI_XCOMM is not set # CONFIG_SPI_XCOMM is not set
# CONFIG_SPI_XILINX is not set # CONFIG_SPI_XILINX is not set
......
...@@ -1537,9 +1537,11 @@ static int s3c64xx_spi_remove(struct platform_device *pdev) ...@@ -1537,9 +1537,11 @@ static int s3c64xx_spi_remove(struct platform_device *pdev)
writel(0, sdd->regs + S3C64XX_SPI_INT_EN); writel(0, sdd->regs + S3C64XX_SPI_INT_EN);
#ifndef CONFIG_PM_RUNTIME
clk_disable_unprepare(sdd->src_clk); clk_disable_unprepare(sdd->src_clk);
clk_disable_unprepare(sdd->clk); clk_disable_unprepare(sdd->clk);
#endif
platform_set_drvdata(pdev, NULL); platform_set_drvdata(pdev, NULL);
spi_master_put(master); spi_master_put(master);
......
...@@ -631,6 +631,9 @@ static int spidev_remove(struct spi_device *spi) ...@@ -631,6 +631,9 @@ static int spidev_remove(struct spi_device *spi)
/* make sure ops on existing fds can abort cleanly */ /* make sure ops on existing fds can abort cleanly */
spin_lock_irq(&spidev->spi_lock); spin_lock_irq(&spidev->spi_lock);
spi->master->cleanup(spi);
spidev->spi = NULL; spidev->spi = NULL;
spi_set_drvdata(spi, NULL); spi_set_drvdata(spi, NULL);
spin_unlock_irq(&spidev->spi_lock); spin_unlock_irq(&spidev->spi_lock);
......
...@@ -1475,6 +1475,10 @@ static void __exit fbtft_device_exit(void) ...@@ -1475,6 +1475,10 @@ static void __exit fbtft_device_exit(void)
pr_debug(DRVNAME" - exit\n"); pr_debug(DRVNAME" - exit\n");
if (spi_device) { if (spi_device) {
if(spi_device->controller_data) {
struct s3c64xx_spi_csinfo *cs = spi_device->controller_data;
if(cs->line) gpio_free(cs->line);
}
device_del(&spi_device->dev); device_del(&spi_device->dev);
kfree(spi_device); kfree(spi_device);
} }
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment