diff options
Diffstat (limited to 'drivers/spi/spi-xilinx.c')
-rw-r--r-- | drivers/spi/spi-xilinx.c | 16 |
1 files changed, 0 insertions, 16 deletions
diff --git a/drivers/spi/spi-xilinx.c b/drivers/spi/spi-xilinx.c index 109a535b639c..96b392843814 100644 --- a/drivers/spi/spi-xilinx.c +++ b/drivers/spi/spi-xilinx.c | |||
@@ -232,21 +232,6 @@ static int xilinx_spi_setup_transfer(struct spi_device *spi, | |||
232 | return 0; | 232 | return 0; |
233 | } | 233 | } |
234 | 234 | ||
235 | static int xilinx_spi_setup(struct spi_device *spi) | ||
236 | { | ||
237 | /* always return 0, we can not check the number of bits. | ||
238 | * There are cases when SPI setup is called before any driver is | ||
239 | * there, in that case the SPI core defaults to 8 bits, which we | ||
240 | * do not support in some cases. But if we return an error, the | ||
241 | * SPI device would not be registered and no driver can get hold of it | ||
242 | * When the driver is there, it will call SPI setup again with the | ||
243 | * correct number of bits per transfer. | ||
244 | * If a driver setups with the wrong bit number, it will fail when | ||
245 | * it tries to do a transfer | ||
246 | */ | ||
247 | return 0; | ||
248 | } | ||
249 | |||
250 | static void xilinx_spi_fill_tx_fifo(struct xilinx_spi *xspi) | 235 | static void xilinx_spi_fill_tx_fifo(struct xilinx_spi *xspi) |
251 | { | 236 | { |
252 | u8 sr; | 237 | u8 sr; |
@@ -373,7 +358,6 @@ struct spi_master *xilinx_spi_init(struct device *dev, struct resource *mem, | |||
373 | xspi->bitbang.chipselect = xilinx_spi_chipselect; | 358 | xspi->bitbang.chipselect = xilinx_spi_chipselect; |
374 | xspi->bitbang.setup_transfer = xilinx_spi_setup_transfer; | 359 | xspi->bitbang.setup_transfer = xilinx_spi_setup_transfer; |
375 | xspi->bitbang.txrx_bufs = xilinx_spi_txrx_bufs; | 360 | xspi->bitbang.txrx_bufs = xilinx_spi_txrx_bufs; |
376 | xspi->bitbang.master->setup = xilinx_spi_setup; | ||
377 | init_completion(&xspi->done); | 361 | init_completion(&xspi->done); |
378 | 362 | ||
379 | if (!request_mem_region(mem->start, resource_size(mem), | 363 | if (!request_mem_region(mem->start, resource_size(mem), |