ramips: improve rt2880 spi wait ready function
authorJohn Crispin <john@openwrt.org>
Sun, 22 Nov 2015 11:48:34 +0000 (11:48 +0000)
committerJohn Crispin <john@openwrt.org>
Sun, 22 Nov 2015 11:48:34 +0000 (11:48 +0000)
commitbf89d139e1cf6029eeab39bd06f8ad2f5bc1c739
tree076a75fba9ab05b1830cb23765f6b3c2b6f36542
parent702c480dfe557087a1d4c534036fee4d59677f38
ramips: improve rt2880 spi wait ready function

use loops_per_jiffy, spi clock speed and write bytes to get the
spi loop count. if loop to 0 than spi operation timeout.
remove usleep. we only write 1 byte to spi device. use busy loop
would be better.

Signed-off-by: Michael Lee <igvtee@gmail.com>
SVN-Revision: 47575
target/linux/ramips/patches-3.18/0050-SPI-ralink-add-Ralink-SoC-spi-driver.patch