SPI_3WIRE is spi mode not spi flags, so this patch fixed
the spi-3wire checking throgh mode instead of flags.

Cc: Mugunthan V N <mugunthan...@ti.com>
Cc: Simon Glass <s...@chromium.org>
Signed-off-by: Jagan Teki <jt...@openedev.com>
---
 drivers/spi/ti_qspi.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/spi/ti_qspi.c b/drivers/spi/ti_qspi.c
index 646dd89..5747ed1 100644
--- a/drivers/spi/ti_qspi.c
+++ b/drivers/spi/ti_qspi.c
@@ -293,7 +293,7 @@ int spi_xfer(struct spi_slave *slave, unsigned int bitlen, 
const void *dout,
        qslave->cmd = 0;
        qslave->cmd |= QSPI_WLEN(8);
        qslave->cmd |= QSPI_EN_CS(slave->cs);
-       if (flags & SPI_3WIRE)
+       if (qslave->mode & SPI_3WIRE)
                qslave->cmd |= QSPI_3_PIN;
        qslave->cmd |= 0xfff;
 
-- 
1.9.1

_______________________________________________
U-Boot mailing list
U-Boot@lists.denx.de
http://lists.denx.de/mailman/listinfo/u-boot

Reply via email to