summaryrefslogtreecommitdiff
path: root/drivers/spi/spi-nuc900.c
diff options
context:
space:
mode:
authorAxel Lin <axel.lin@ingics.com>2013-08-15 10:11:21 +0400
committerMark Brown <broonie@linaro.org>2013-08-29 16:40:48 +0400
commit044d0bb620be2ecb02c7f8c2d4b547f7b7101811 (patch)
tree3d0d3bb36766323dc2be3ea01818480716c73e67 /drivers/spi/spi-nuc900.c
parentd8dfad3876e4386666b759da3c833d62fb8b2267 (diff)
downloadlinux-044d0bb620be2ecb02c7f8c2d4b547f7b7101811.tar.xz
spi: nuc900: Fix mode_bits setting
The code in nuc900_slave_select() supports handling SPI_CS_HIGH. Thus set SPI_CS_HIGH bit in master->mode_bits to make it work. Otherwise, spi_setup() will return unsupported mode bits error message if SPI_CS_HIGH is set in the mode field of struct spi_device. Signed-off-by: Axel Lin <axel.lin@ingics.com> Signed-off-by: Mark Brown <broonie@linaro.org>
Diffstat (limited to 'drivers/spi/spi-nuc900.c')
-rw-r--r--drivers/spi/spi-nuc900.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/spi/spi-nuc900.c b/drivers/spi/spi-nuc900.c
index 150d85453c27..ee0136631c00 100644
--- a/drivers/spi/spi-nuc900.c
+++ b/drivers/spi/spi-nuc900.c
@@ -373,7 +373,7 @@ static int nuc900_spi_probe(struct platform_device *pdev)
platform_set_drvdata(pdev, hw);
init_completion(&hw->done);
- master->mode_bits = SPI_MODE_0;
+ master->mode_bits = SPI_CPOL | SPI_CPHA | SPI_CS_HIGH;
master->num_chipselect = hw->pdata->num_cs;
master->bus_num = hw->pdata->bus_num;
hw->bitbang.master = hw->master;