On Monday 18 April 2016 12:04:15 Mark Brown wrote: > On Mon, Apr 18, 2016 at 12:51:55PM +0200, Arnd Bergmann wrote: > > > This would be easier if have a conclusive proof that 1MB per CS always enough. > > Is this something that is guaranteed in the SPI spec or the documentation for > > this controller? > > There's no spec for SPI but if there were it'd be hard to see it > imposing a limit, one can transfer data as long as the bus is clocked > (which some things like ADCs and DACs make use of). > I just reread Stefan's patch and realized that I had fundamentally misunderstood how the transfer is done: I thought the offset inside of the window was used to address a NOR flash directly, but it seems it is just used to send arbitrarily long commands. This means that the 1MB window is probably a reasonable size (provided that the (most importantly) the SPI-NOR driver can guarantee that it never exceeds this). It also means that we are probably better off using the single-window mode of the SPI controller, where all CS lines share a single mbus window. The only real difference here is that we can map all endpoints using a single contiguous window into the CPU address space if we want, or we can still map them separately on a given board if that results in a nicer layout. Arnd -- To unsubscribe from this list: send the line "unsubscribe linux-spi" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html