[U-Boot] [PATCH v2 2/3] avr32: Use uncached() macro to get an address for SDRAM init

Detlev Zundel dzu at denx.de
Fri Aug 13 13:01:25 CEST 2010


Hi Haavard,

> Detlev Zundel <dzu at denx.de> wrote:
>> So this patch replaces a construct which seems to be valid over all
>> architectures by a construct which is only used in avr32, right?  It
>> also deletes the explicit statement that such a mapping is not needed
>> any further.
>
> Problem is that in order to make the CFI driver work on avr32, we need
> to change the map_physmem() macro to return the physical address
> unchanged.

I see.  And I presume you cannot tell the situation apart inside
map_physmem?

>> Isn't this a step backward?  Can't you put the functionality inside the
>> map function and leave the unmap a noop?
>
> I agree it's a step backward, but since the previous flamewar didn't
> get us anywhere, I decided to go for a compromise this time. At least
> this small architecture-specific kludge is localized to
> architecture-specific code.
>
> The map_physmem() macro currently does exactly the same thing as the
> uncached() macro, and the unmap is a noop, but the next patch changes
> it in order to fix the CFI driver. If the next patch is applied without
> this patch being applied first, the SDRAM driver will do cached
> accesses during initialization, and that may cause the initialization
> to fail.

Why not include a note to this extent into the git commit message?  This
would be a great help for other people to later understand why this
change has been done the "backward way" that it was.

Cheers
  Detlev

-- 
vi vi vi - the roman numeral of the beast.
--
DENX Software Engineering GmbH,      MD: Wolfgang Denk & Detlev Zundel
HRB 165235 Munich,  Office: Kirchenstr.5, D-82194 Groebenzell, Germany
Phone: (+49)-8142-66989-40 Fax: (+49)-8142-66989-80 Email: dzu at denx.de


More information about the U-Boot mailing list