[U-Boot-Users] get_timer on ppc and bugs related to calling it (fsl_i2c)
Kumar Gala
galak at kernel.crashing.org
Tue Jul 29 16:48:32 CEST 2008
In debugging moving the bss outside of the image on 85xx I run into in
issue with the SPD code using fsl_i2c before we are running in ram and
setup the BSS.
It looks like i2c_wait4bus() [in fsl_i2c.c] calls get_timer().
get_timer implemented in lib_ppc/interrupts.c and uses a global
timestamp that exists in the BSS. This seems pretty bad in that we
have been just getting a bogus value for timestamp out of flash.
Luckily we don't write timestamp until interrupts are enabled and at
that point we've relocated to memory.
However it seems like fsl_i2c.c should NOT be using get_timer(). Is
there another global interface to get relative time that we can just
use time base for?
- k
More information about the U-Boot
mailing list