diff options
author | Jagan Teki <jteki@openedev.com> | 2015-12-03 22:19:05 +0530 |
---|---|---|
committer | Jagan Teki <jteki@openedev.com> | 2015-12-11 22:12:23 +0530 |
commit | 379b49d82ee3304b55ece1f32d95fbeef9e0176a (patch) | |
tree | 1a2bbc96caa12421947fb3e5b27639a1adab970a | |
parent | 789fa275b3750e60c60cb3d18eabc9467892c257 (diff) | |
download | u-boot-imx-379b49d82ee3304b55ece1f32d95fbeef9e0176a.zip u-boot-imx-379b49d82ee3304b55ece1f32d95fbeef9e0176a.tar.gz u-boot-imx-379b49d82ee3304b55ece1f32d95fbeef9e0176a.tar.bz2 |
spi: Get spi-3wire from dts
spi-3wire is used when SI/SO signals shared so get
the same from dts node and assign to mode on slave
plat->mode.
Acked-by: Simon Glass <sjg@chromium.org>
Signed-off-by: Jagan Teki <jteki@openedev.com>
-rw-r--r-- | drivers/spi/spi-uclass.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/drivers/spi/spi-uclass.c b/drivers/spi/spi-uclass.c index 3c7d64a..e0f6b25 100644 --- a/drivers/spi/spi-uclass.c +++ b/drivers/spi/spi-uclass.c @@ -378,6 +378,8 @@ int spi_slave_ofdata_to_platdata(const void *blob, int node, mode |= SPI_CPHA; if (fdtdec_get_bool(blob, node, "spi-cs-high")) mode |= SPI_CS_HIGH; + if (fdtdec_get_bool(blob, node, "spi-3wire")) + mode |= SPI_3WIRE; if (fdtdec_get_bool(blob, node, "spi-half-duplex")) mode |= SPI_PREAMBLE; plat->mode = mode; |