[U-Boot] [PATCH 4/4] arm920t/at91/timer: replace bss variables by gd

Andreas Bießmann andreas.devel at googlemail.com
Tue Nov 30 09:03:57 CET 2010


Dear Reinhard Meyer,

Am 30.11.2010 08:17, schrieb Reinhard Meyer:
> Dear Andreas Bießmann,
>> Reuse the gd->tbl/tbu values for timestamp/lastinc bss values in
>> arm920t/at91/timer driver.

> I see your dilemma here.
> 
> tbu/tbl were introduced by me to form a true 64 bit monotonous incrementing value
> (like on most powerPC).
> You use tbl as the last (16 bit) value of the 16 bit hardware timer and
> tbu as the actual, only 32 bits worth time value.
> If the rest of the timer functions handle this correctly (I doubt that, but I cannot look at
> that right now), that "abuse" might be OK.
> But I rather have a field, say "u32 last_hw_val" (or a better name) added to the GD inside the
> AT91FAMILY define and have tbu/tbl really be a functional 64 bit value.

[snip]

I think get your point.

To get this bss issue fixed for v2010.12 I'd like to add another value
to GD to hold the last hw timer value. My current usage of tbu should
therefore go to tbl, to have a virutal 64 bit value just counting 32
bit, is that right?

Later on I also see some work in that arm920t/at91 SoC 'driver' section.
E.g. we really do need something like arm926ejs/at91/clock to have the
usart driver merged. And I might have some other changes to the timer
part of arm920t/at91. I found out the at91rm9200 do also have a PIT ...
but that is for later discussion.

regards

Andreas Bießmann


More information about the U-Boot mailing list