From mboxrd@z Thu Jan 1 00:00:00 1970 From: Mike Frysinger Date: Fri, 23 Apr 2010 11:34:53 -0400 Subject: [U-Boot] convention for SPI dummy data? In-Reply-To: <20100423151829.GO20047@leila.ping.de> References: <20100423084307.GN20047@leila.ping.de> <201004231108.11427.vapier@gentoo.org> <20100423151829.GO20047@leila.ping.de> Message-ID: <201004231134.54565.vapier@gentoo.org> List-Id: MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit To: u-boot@lists.denx.de On Friday 23 April 2010 11:18:29 Wolfgang Wegner wrote: > On Fri, Apr 23, 2010 at 11:08:10AM -0400, Mike Frysinger wrote: > > On Friday 23 April 2010 04:43:07 Wolfgang Wegner wrote: > > > However, one of the things I had to change was the dummy data sent > > > out by SPI for read-only transactions. The original driver had all > > > zeros, for SD/MMC all ones (0xFF) is needed. > > > > > > Is such a change acceptable, or is there any configuration option/flag > > > I could use? > > > > if it isnt part of the SPI/MMC spec, use a config option named like > > IDLE_VAL. > > the problem exists in the (coldfire) SPI driver, not in the MMC/SD code. sorry, i thought you were proposing to fix it in the SPI/MMC driver > (For SD, the spec IMHO clearly states 0xFF for all idle transfers.) thanks, wasnt aware > > changing the default to 0xff is OK i think. > > I could add CONFIG_SPI_IDLE_VAL and default it to 0x0 in the coldfire > SPI driver. In case one wants to use MMC/SD with this driver, one could > then add CONFIG_SPI_IDLE_VAL as 0xFF in the board to override it. > (Only pitfall is that the current 0x0 is used for 8- as well as 16-bit > transfers...) what i've seen so far is that the idle val doesnt matter to most spi devices. so on the Blackfin side, we've been defaulting to 0xff so that things do work "out of the box" for everyone (at least so far). -mike -------------- next part -------------- A non-text attachment was scrubbed... Name: not available Type: application/pgp-signature Size: 836 bytes Desc: This is a digitally signed message part. Url : http://lists.denx.de/pipermail/u-boot/attachments/20100423/4a83ff07/attachment.pgp