Message ID | 1272012457-32140-1-git-send-email-w.wegner@astro-kom.de |
---|---|
State | Awaiting Upstream |
Delegated to: | Marek Vasut |
Headers | show |
diff --git a/drivers/spi/cf_spi.c b/drivers/spi/cf_spi.c index 722aafc..8cc1d03 100644 --- a/drivers/spi/cf_spi.c +++ b/drivers/spi/cf_spi.c @@ -256,6 +256,11 @@ struct spi_slave *cfspi_setup_slave(struct cf_spi_slave *cfslave, uint mode) } else bus_setup |= (dspi->ctar[cfslave->slave.bus] & 0x78FCFFF0); + if (mode & SPI_CS_HIGH) + dspi->mcr &= ~(1 << (16 + cfslave->slave.cs)); + else + dspi->mcr |= (1 << (16 + cfslave->slave.cs)); + cfslave->charbit = ((dspi->ctar[cfslave->slave.bus] & 0x78000000) == 0x78000000) ? 16 : 8;
Signed-off-by: Wolfgang Wegner <w.wegner@astro-kom.de> --- I tested this patch on a MCF54455. The basic intention was to make using DSPI for MMC/SD-Card possible. drivers/spi/cf_spi.c | 5 +++++ 1 files changed, 5 insertions(+), 0 deletions(-)