spi/sirf: fix the misunderstanding about len of spi_transfer
authorQipan Li <Qipan.Li@csr.com>
Sun, 25 Aug 2013 13:42:50 +0000 (21:42 +0800)
committerMark Brown <broonie@linaro.org>
Mon, 26 Aug 2013 12:00:14 +0000 (13:00 +0100)
commit692fb0fe5aacea861e4006342029cf505a7dbe18
tree34e0abbfe07112687885f2097fa893fc7f3b7b12
parent6cca9e2dd01adfa46a3b81f54f80d318714da418
spi/sirf: fix the misunderstanding about len of spi_transfer

the unit of len of spi_transfer is in bytes, not in spi words. the
old codes misunderstood that and thought the len is the amount of
spi words. but it is actually how many bytes existing in the spi
buffer.

this patch fixes that and also rename left_tx_cnt and left_rx_cnt
to left_tx_word and left_rx_word to highlight they are in words.

Signed-off-by: Qipan Li <Qipan.Li@csr.com>
Signed-off-by: Barry Song <Baohua.Song@csr.com>
Signed-off-by: Mark Brown <broonie@linaro.org>
drivers/spi/spi-sirf.c