Re: [PATCH 1/3] ata: sata_dwc_460ex: use "dmas" DT property to find dma channel

From: Måns Rullgård
Date: Fri Jan 08 2016 - 05:57:58 EST

Andy Shevchenko <andriy.shevchenko@xxxxxxxxxxxxxxx> writes:

> On Thu, 2016-01-07 at 18:32 +0000, MÃns RullgÃrd wrote:
>> Andy Shevchenko <andriy.shevchenko@xxxxxxxxxxxxxxx> writes:
>> > On Wed, 2016-01-06 at 19:36 +0200, Andy Shevchenko wrote:
>> > >Â
>> > So, MÃns, Julian, I just have published my repository containing
>> > MÃns' and my patches regarding dw_dmac and sata_dwc_460ex drivers
>> > here
>> >
>> >
>> I've picked out the relevant changes from your branch and made some
>> additional improvements.ÂÂA few notes:
>> - The __be32/__le32 typedefs for the DMA descriptor fields are necessary
>> Â to avoid a million sparse warnings (and sparse is correct to warn).
> Hmmâ Which version of sparse are you using? I always run builds with
> sparse enabled and didn't see anything.

You need to enable endian checking with CF=-D__CHECK_ENDIAN__

>> - Using #ifdef CONFIG_AVR32 is a step back, IMO, since this driver may
>> Â well be used on another big endian system some day.ÂÂThe Kconfig logic
>> Â for selecting this option could perhaps be improved though.
> Maybe runtime chosen accessors will be better than ifdefs?

Are there any systems that could otherwise run the same kernel that use
this hardware with different byte order? I doubt it.

> I don't like the Kconfig option which limits application of the
> (compiled) driver.

It's no more limited than a hard #ifdef AVR32 in the driver code.

MÃns RullgÃrd