From: Illia Smyrnov Date: Fri, 14 Jun 2013 16:12:07 +0000 (+0300) Subject: spi: omap2-mcspi: Move bytes per word calculation to the function X-Git-Tag: omap-for-v3.11/fixes-for-merge-window~28^2~9^2~3 X-Git-Url: http://git.openpandora.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=56cd5c1578135120d73a7054140855728f8cca36;p=pandora-kernel.git spi: omap2-mcspi: Move bytes per word calculation to the function Introduce mcspi_bytes_per_word function as replacement for the next code fragment: int c = (word_len <= 8) ? 1 : (word_len <= 16) ? 2 : /* word_len <= 32 */ 4; This code used 2 times in current driver code and will be used 2 times in the next FIFO buffer support patch. Replace it with inline function with clear name to improve code legibility. Signed-off-by: Illia Smyrnov Signed-off-by: Mark Brown --- Reading git-diff-tree failed