spi/xilinx: Simplify spi_fill_tx_fifo
authorRicardo Ribalda Delgado <ricardo.ribalda@gmail.com>
Wed, 28 Jan 2015 12:23:40 +0000 (13:23 +0100)
committerMark Brown <broonie@kernel.org>
Wed, 28 Jan 2015 19:42:42 +0000 (19:42 +0000)
commit4c9a761402d780b86b9b068aba4ef8e29ed15e99
treee0270a671ce5f9e811fb72892ea4c05af24956b5
parentc5d348dffa7ca1f072ff5526171a2b88bbffc24b
spi/xilinx: Simplify spi_fill_tx_fifo

Instead of checking the TX_FULL flag for every transaction, find out the
size of the buffer at probe time and use it.

To avoid situations where the core had some data on the buffer before
initialization, the core is reseted before the buffer size is detected

Signed-off-by: Ricardo Ribalda Delgado <ricardo.ribalda@gmail.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
drivers/spi/spi-xilinx.c