[U-Boot] [PATCH v2 2/3] avr32: Use uncached() macro to get an address for SDRAM init
Haavard Skinnemoen
haavard.skinnemoen at atmel.com
Fri Aug 13 14:12:41 CEST 2010
Detlev Zundel <dzu at denx.de> wrote:
> > 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?
I don't think so. How do you propose we do that?
> > 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.
The commit message already contains this:
The paging system which is required to set up caching properties has not
yet been initialized when the SDRAM is initialized. So when the
map_physmem() function is converted to return the physical address
unchanged, the SDRAM initialization will break on some boards.
which is essentially the same thing, isn't it?
Haavard
More information about the U-Boot
mailing list