spi: pxa2xx: Move chip select control bits into lpss_config structure
authorMika Westerberg <mika.westerberg@linux.intel.com>
Mon, 8 Feb 2016 15:14:30 +0000 (17:14 +0200)
committerMark Brown <broonie@kernel.org>
Tue, 9 Feb 2016 19:01:07 +0000 (19:01 +0000)
commitc1e4a53c6b8161ded3a44e3352ef38206d0967ea
tree1f8debab51784cf7117842bd6574fdf2adf702ea
parent0c27d9cf7245d832d3d34f289c1bcd4f7f3fbd30
spi: pxa2xx: Move chip select control bits into lpss_config structure

Some Intel LPSS SPI controllers, like the one in Braswell has these bits in
a different location so move these bits to be part of the LPSS
configuration.

Since not all LPSS SPI controllers support multiple native chip selects we
refactor selecting chip select to its own function and check
control->cs_sel_mask before switching to another chip select.

Signed-off-by: Mika Westerberg <mika.westerberg@linux.intel.com>
Reviewed-by: Jarkko Nikula <jarkko.nikula@linux.intel.com>
Reviewed-by: Andy Shevchenko <andy.shevchenko@gmail.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
drivers/spi/spi-pxa2xx.c