This series of patches add drier support for hardware implemented modes:
spi_lsb_fist and spi_loop
Also fix an issue when multiple spi devices are defined on a device tree.
Ricardo Ribalda Delgado (3):
spi/xilinx: Use automatic bus number on device tree
spi/xilinx: Support for spi mode LSB_FIRST
spi/xilinx: Support for spi mode LOOP
drivers/spi/spi-xilinx.c | 12 ++++++++++--
1 file changed, 10 insertions(+), 2 deletions(-)
--
2.1.4
@@ -197,6 +197,8 @@ static void xilinx_spi_chipselect(struct spi_device *spi, int is_on)cr|=XSPI_CR_CPOL;if(spi->mode&SPI_LSB_FIRST)cr|=XSPI_CR_LSB_FIRST;+if(spi->mode&SPI_LOOP)+cr|=XSPI_CR_LOOP;xspi->write_fn(cr,xspi->regs+XSPI_CR_OFFSET);/* We do not check spi->max_speed_hz here as the SPI clock
@@ -194,6 +195,8 @@ static void xilinx_spi_chipselect(struct spi_device *spi, int is_on)cr|=XSPI_CR_CPHA;if(spi->mode&SPI_CPOL)cr|=XSPI_CR_CPOL;+if(spi->mode&SPI_LSB_FIRST)+cr|=XSPI_CR_LSB_FIRST;xspi->write_fn(cr,xspi->regs+XSPI_CR_OFFSET);/* We do not check spi->max_speed_hz here as the SPI clock
If there is more than one spi device on a device tree, the second one
will fail to probe due to a duplicated bus_num.
This patch uses automatic bus number if the device is deined on a device
tree.
Signed-off-by: Ricardo Ribalda Delgado <redacted>
---
drivers/spi/spi-xilinx.c | 5 ++++-
1 file changed, 4 insertions(+), 1 deletion(-)
Hi Lars
I think you are right. The other patches on the set are still valid though
Thanks!
On Wed, Jan 21, 2015 at 5:02 PM, Lars-Peter Clausen [off-list ref] wrote:
On 01/21/2015 04:53 PM, Ricardo Ribalda Delgado wrote:
quoted
If there is more than one spi device on a device tree, the second one
will fail to probe due to a duplicated bus_num.