[U-Boot-Users] cfi_flash.c and lost volatile qualifier

Jerry Van Baren gerald.vanbaren at ge.com
Wed Apr 30 17:51:48 CEST 2008


Wolfgang Denk wrote:
> In message <48188584.3060109 at ge.com> you wrote:
>> The solution in the PowerPC world is to add a "eieio" or "sync" 
>> instruction[1] appropriately[2], which prevents the bus interface unit 
>> from reordering the memory operations.
> 
> No, the solution for ALL architectures  is  to  use  the  appropriate
> accessor  macros which take care of such things (and probably contain
> calls like sync or similar).
> 
> Best regards,
> 
> Wolfgang Denk

Agreed.

If my theory is correct, Adrian has turned up a problem with the ARM 
configuration that apparently only shows up for the PXA250.  Or I'm 
blowing smoke - nothing to see, move along.

The hairs on the back of my neck say it is a sync/bus interface unit 
problem.

I don't know if it is significant, not being very intimately familiar 
with ARM (and, in particular, the PXA250), but my quick grep turns up 
./include/asm-arm/io.h and a quick browsing shows no syncs.  The hairs 
on the back of my neck are starting to ache.  ;-)

static inline void sync(void)
{
}

#define __arch_getb(a)                  (*(volatile unsigned char *)(a))

gvb





More information about the U-Boot mailing list