From: Sjoerd Simons Date: Thu, 22 Mar 2018 21:55:02 +0000 (+0100) Subject: omap3: spi: Correct ti, pindir-d0-out-d1-in parsing X-Git-Tag: v2018.05-rc1~7^2 X-Git-Url: https://git.sur5r.net/?a=commitdiff_plain;h=63018a3eddd5d9c64f7ee42615a63c6a67ab484d;p=u-boot omap3: spi: Correct ti, pindir-d0-out-d1-in parsing The ti,pindir-d0-out-d1-in property is not expected to have a value according to the device-tree binding, so treat it as a boolean not a uint property. Signed-off-by: Sjoerd Simons Reviewed-by: Jagan Teki --- diff --git a/drivers/spi/omap3_spi.c b/drivers/spi/omap3_spi.c index 053a67bbe0..1ac691a68e 100644 --- a/drivers/spi/omap3_spi.c +++ b/drivers/spi/omap3_spi.c @@ -630,8 +630,10 @@ static int omap3_spi_probe(struct udevice *dev) (struct omap2_mcspi_platform_config*)dev_get_driver_data(dev); priv->regs = (struct mcspi *)(devfdt_get_addr(dev) + data->regs_offset); - priv->pin_dir = fdtdec_get_uint(blob, node, "ti,pindir-d0-out-d1-in", - MCSPI_PINDIR_D0_IN_D1_OUT); + if (fdtdec_get_bool(blob, node, "ti,pindir-d0-out-d1-in")) + priv->pin_dir = MCSPI_PINDIR_D0_OUT_D1_IN; + else + priv->pin_dir = MCSPI_PINDIR_D0_IN_D1_OUT; priv->wordlen = SPI_DEFAULT_WORDLEN; return 0; }