[PATCH 1/3] Documentation:spi:fsl-dspi:add DSPI dma transfer support

Shawn Guo shawn.guo at linaro.org
Thu Feb 27 02:42:50 EST 2014


On Thu, Feb 27, 2014 at 12:38:22AM +0900, Mark Brown wrote:
> On Wed, Feb 26, 2014 at 10:19:49PM +0800, Shawn Guo wrote:
> > On Tue, Feb 25, 2014 at 09:08:30AM +0000, Mark Rutland wrote:
> 
> > > > +- use-dma: the bool decide if use dma method in DSPI transfering.
> 
> > > Why can the OS not decide this based on the presence of dmas which it
> > > can use?
> 
> > Yes, OS/driver should decide to use DMA or not, but it shouldn't be
> > based on the presence of 'dmas' property.  The DMA is a hardware
> > resource just like IRQ.  It should be just there in client device's node
> > as long as the SoC design assigns the channel to the device.  The device
> > driver should make the decision when DMA should be used, e.g. big amount
> > data transfer, and when PIO should be used, e.g. small data.
> 
> Right, that's very common - but that decision is usually taken on a per
> transfer basis so a DT property would seem odd, especially just a simple
> boolean.

Yea, I guess we're on the same page - the decision should be made by
the device driver on its own not the device tree.

Shawn




More information about the linux-arm-kernel mailing list