Re: [RFC PATCH 0/3] spi/xilinx: Merge OF and non-OF drivers

Previous message: [thread] [date] [author]
Next message: [thread] [date] [author]
From: Grant Likely
Date: Monday, November 8, 2010 - 11:01 am

On Mon, Nov 8, 2010 at 9:34 AM, John Linn <John.Linn@xilinx.com> wrote:

Hmmm, that actually is not sane.  Ideally, drivers should never be
mucking with the dma mask.  It is supposed to only be set by the code
actually registering the device.  The mmc code should not be looking
at the parent's dma mask to determine if DMA is available; the spi bus
drivers should be explicitly stating whether or not it supports DMA.
The mmc_spi code is doing the wrong thing here.

That being said, until the mmc_spi code is fixed (and all the users
are fixed up so DMA still works) then this patch is probably the best
solution.  However, please note that dev->dma_mask is a pointer, so
you should actually be setting it to NULL.

g.




-- 
Grant Likely, B.Sc., P.Eng.
Secret Lab Technologies Ltd.
--
Previous message: [thread] [date] [author]
Next message: [thread] [date] [author]

Messages in current thread:
[RFC PATCH 0/3] spi/xilinx: Merge OF and non-OF drivers, Grant Likely, (Thu Oct 14, 9:19 am)
Re: [RFC PATCH 0/3] spi/xilinx: Merge OF and non-OF drivers, Grant Likely, (Mon Nov 8, 11:01 am)