Commit 2376a989 authored by Axel Lin's avatar Axel Lin Committed by Greg Kroah-Hartman

spi: nuc900: Set SPI_LSB_FIRST for master->mode_bits if hw->pdata->lsb is true

commit f7db1588 upstream.

Otherwise, spi_setup() fails with unsupported mode bits message.
Signed-off-by: default avatarAxel Lin <axel.lin@ingics.com>
Signed-off-by: default avatarMark Brown <broonie@linaro.org>
Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
parent 639558a4
......@@ -363,6 +363,8 @@ static int nuc900_spi_probe(struct platform_device *pdev)
init_completion(&hw->done);
master->mode_bits = SPI_CPOL | SPI_CPHA | SPI_CS_HIGH;
if (hw->pdata->lsb)
master->mode_bits |= SPI_LSB_FIRST;
master->num_chipselect = hw->pdata->num_cs;
master->bus_num = hw->pdata->bus_num;
hw->bitbang.master = hw->master;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment