From: Rini van Zetten Date: Mon, 10 Dec 2007 23:49:34 +0000 (-0800) Subject: atmel_spi: reload RCR before TCR X-Git-Tag: v2.6.24-rc5~4 X-Git-Url: http://git.openpandora.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=d84248bf46582a406116c55b94405c05193773b1;p=pandora-kernel.git atmel_spi: reload RCR before TCR We have a wifi module connected to the spi bus and got sometimes FIFO overrun errors on the spi bus. After some investigation i found that the driver loads the TCR (transmit count) register before the RCR (receive count). When the transfer list is not empty the atmel_spi_next_message is called while tx and rx are enabled. As soon as the TCR is loaded, hardware starts transfer and causes a rx fifo overrun because the RCR is not loaded yet. Load the RCR before the TCR. After this patch the fifo overrun disapears at out setup. Signed-off-by: Haavard Skinnemoen Signed-off-by: Rini van Zetten Signed-off-by: David Brownell Signed-off-by: Andrew Morton Signed-off-by: Linus Torvalds --- Reading git-diff-tree failed