From mboxrd@z Thu Jan 1 00:00:00 1970 From: Matthias Fuchs Date: Sat, 14 Jan 2012 21:09:12 +0100 Subject: [U-Boot] [PATCH] mx28: fix i.MX28 spi driver In-Reply-To: References: <4F117435.7080807@esd.eu> Message-ID: <4F11E0E8.8070801@esd.eu> List-Id: MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit To: u-boot@lists.denx.de This cannot work. I do not understand what you are trying to achieve with this. Matthias On 01/14/2012 07:54 PM, Fabio Estevam wrote: > On Sat, Jan 14, 2012 at 4:53 PM, Fabio Estevam wrote: > >> Actually I meant this: > > One more time ;-) > > --- a/drivers/spi/mxs_spi.c > +++ b/drivers/spi/mxs_spi.c > @@ -130,13 +130,10 @@ int spi_xfer(struct spi_slave *slave, unsigned int bitlen, > const char *tx = dout; > char *rx = din; > > - if (bitlen == 0) > - return 0; > - > if (!rx && !tx) > return 0; > > - if (flags & SPI_XFER_BEGIN) > + if ((flags & SPI_XFER_BEGIN) && len) > mxs_spi_start_xfer(ssp_regs); > > while (len--) { > _______________________________________________ > U-Boot mailing list > U-Boot at lists.denx.de > http://lists.denx.de/mailman/listinfo/u-boot