[U-Boot] The forbidden value in omap3-common timer.c code

Hi there,
I just started to work with the u-boot sources for my bachelor thesis. There was a part in the source which irritated me a bit.
I talk about ./arch/arm/cpu/armv7/omap-common/timer.c
It's about that part of code: #define TIMER_LOAD_VAL 0xffffffff
int timer_init(void) { /* start the counter ticking up, reload value on overflow */ writel(TIMER_LOAD_VAL, &timer_base->tldr); /* enable timer */ writel((CONFIG_SYS_PTV << 2) | TCLR_PRE | TCLR_AR | TCLR_ST, &timer_base->tclr);
reset_timer_masked(); /* init the timestamp and lastinc value */
return 0; }
The tldr ist loaded with 0xFFFFFFFF.
The OMAP35x Technical Reference Manual (Rev. P) says on page 2583: Do not put the overflow value (0xFFFFFFFF) in the GPTi.TLDR register because it can lead to undesired results.
Is there a reason why the value is used nevertheless? At this time I don't know where the timer is used, maybe the "undesired results" haven't been noticed yet?
Thanks! Simon
participants (2)
-
Bedia, Vaibhav
-
Simon Schwarz