aboutsummaryrefslogtreecommitdiffstats
path: root/drivers
diff options
context:
space:
mode:
authorBrian Niebuhr <bniebuhr@efjohnson.com>2010-09-24 09:23:32 -0400
committerSekhar Nori <nsekhar@ti.com>2010-11-18 08:08:33 -0500
commitb23a5d4691043e97bbfde8c2fb5b8fecdc400308 (patch)
tree8b6f66d23306761140b9501357fe9948ce5001c9 /drivers
parentbe88471b96cf3a0d7aea72d5ca9c6a95fb54bade (diff)
spi: davinci: remove unnecessary call to davinci_spi_setup_transfer()
Remove unnecessary call to davinci_spi_setup_transfer() at the end of davinci_spi_setup(). davinci_spi_setup_transfer() is registered as the setup_transfer callback for the bitbang layer and is called independently by the bitbang layer to setup the transfer before it begins. Signed-off-by: Brian Niebuhr <bniebuhr@efjohnson.com> Tested-By: Michael Williamson <michael.williamson@criticallink.com> Signed-off-by: Sekhar Nori <nsekhar@ti.com>
Diffstat (limited to 'drivers')
-rw-r--r--drivers/spi/davinci_spi.c11
1 files changed, 3 insertions, 8 deletions
diff --git a/drivers/spi/davinci_spi.c b/drivers/spi/davinci_spi.c
index 05b6145da3ef..77109dc11b09 100644
--- a/drivers/spi/davinci_spi.c
+++ b/drivers/spi/davinci_spi.c
@@ -479,7 +479,7 @@ static int davinci_spi_request_dma(struct spi_device *spi)
479 */ 479 */
480static int davinci_spi_setup(struct spi_device *spi) 480static int davinci_spi_setup(struct spi_device *spi)
481{ 481{
482 int retval; 482 int retval = 0;
483 struct davinci_spi *davinci_spi; 483 struct davinci_spi *davinci_spi;
484 struct davinci_spi_dma *davinci_spi_dma; 484 struct davinci_spi_dma *davinci_spi_dma;
485 struct davinci_spi_platform_data *pdata; 485 struct davinci_spi_platform_data *pdata;
@@ -512,16 +512,11 @@ static int davinci_spi_setup(struct spi_device *spi)
512 if (use_dma && davinci_spi->dma_channels) { 512 if (use_dma && davinci_spi->dma_channels) {
513 davinci_spi_dma = &davinci_spi->dma_channels[spi->chip_select]; 513 davinci_spi_dma = &davinci_spi->dma_channels[spi->chip_select];
514 514
515 if ((davinci_spi_dma->dma_rx_channel == -1) 515 if ((davinci_spi_dma->dma_rx_channel == -1) ||
516 || (davinci_spi_dma->dma_tx_channel == -1)) { 516 (davinci_spi_dma->dma_tx_channel == -1))
517 retval = davinci_spi_request_dma(spi); 517 retval = davinci_spi_request_dma(spi);
518 if (retval < 0)
519 return retval;
520 }
521 } 518 }
522 519
523 retval = davinci_spi_setup_transfer(spi, NULL);
524
525 return retval; 520 return retval;
526} 521}
527 522