Re: [PATCH 1/7] DMAENGINE: add generic PrimeCell interface to COH 901 318 v6

From: Dan Williams
Date: Tue May 11 2010 - 12:53:33 EST


On Tue, May 11, 2010 at 9:37 AM, Dan Williams <dan.j.williams@xxxxxxxxx> wrote:
> On Sun, May 2, 2010 at 5:54 PM, Linus Walleij
> <linus.walleij@xxxxxxxxxxxxxx> wrote:
>> This extends the DMA engine driver for the COH 901 318 used in the
>> U300 platform with the generic PrimeCell interface.
>>
>> Signed-off-by: Linus Walleij <linus.walleij@xxxxxxxxxxxxxx>
>> ---
>>  drivers/dma/coh901318.c |  146 +++++++++++++++++++++++++++++++++++++++++++++++
>>  1 files changed, 146 insertions(+), 0 deletions(-)
>>
>> diff --git a/drivers/dma/coh901318.c b/drivers/dma/coh901318.c
>> index 4233440..1d5ed16 100644
>> --- a/drivers/dma/coh901318.c
>> +++ b/drivers/dma/coh901318.c
> [..]
>> +void dma_set_ambaconfig(struct dma_chan *chan,
>> +                       struct amba_dma_channel_config *config)
>
> What happens when two primecell dma devices are present on one soc?
> Can that happen?  In that case we'll have conflicting providers of
> dma_set_ambaconfig().
>

...the ->device_control() method is already approaching an ioctl()
let's just add the argument parameter to complete the capability,
i.e.:

int (*device_control)(struct dma_chan *chan, enum dma_ctrl_cmd cmd,
unsigned long arg);

This might also be useful be useful for the mux case to change that
configuration at runtime.

--
Dan
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/