On Saturday 05 November 2011 15:17:37 Simon Glass wrote: > On Sat, Nov 5, 2011 at 10:13 AM, Mike Frysinger wrote: > > On Saturday 05 November 2011 10:36:30 Simon Glass wrote: > >> On Thu, Nov 3, 2011 at 6:36 PM, Mike Frysinger wrote: > >> > On Thursday 03 November 2011 18:41:34 Simon Glass wrote: > >> >> --- /dev/null > >> >> +++ b/drivers/spi/tegra2_spi.c > >> >> > >> >> +int spi_cs_is_valid(unsigned int bus, unsigned int cs) > >> >> +{ > >> >> + /* Tegra2 SPI-Flash - only 1 device ('bus/cs') */ > >> >> + if (bus > 0 && cs != 0) > >> >> + return 0; > >> >> + else > >> >> + return 1; > >> >> +} > >> > > >> > shouldn't that be "||" and not "&&" ? > >> > >> This function should be removed as it doesn't print enough errors. > > > > this func is part of the SPI API. you can't remove it ;). > > OK - it seems to only be used by the mmc_spi command which Tegra isn't > using. But I will add it back in. (Should it be called in > spi_flash_probe(), for example?)
the call in mmc_spi could conceivably be dropped since spi_setup_slave() verifies things itself. the point of having this func be split out is so boards could override it (as well as the cs activate/deactivate funcs). -mike
signature.asc
Description: This is a digitally signed message part.
_______________________________________________ U-Boot mailing list U-Boot@lists.denx.de http://lists.denx.de/mailman/listinfo/u-boot