[okl4-developer] Bugs: Device register files, 64bit IDL
Geoffrey Lee
glee at ok-labs.com
Wed May 21 22:57:27 EST 2008
On Wed, May 21, 2008 at 02:41:37PM +0200, Lukas HANEL wrote:
> Hi all,
>
> When I was testing the vtimer server with my iguana timer driver, I
> noted several problems, which I consider as bugs of the system not of my
> adaptions. Can you just confirm?
>
Hi Lukas
> *.dx files: When setting a register to read only: type="r", the
> generated header file will not have any functions for this register.
The type for read-only is "ro".
>
> * IDL compiler does not handle 64 bit (return) values:
> The vtimer client library has two interfaces that return uint64_t time
> values.
> However, the resulting header takes the return value only from one
> 32bit-register and casts it to 64bit. Hence, the clock, as perceived by
> the vtimer client is overflowing very often. Around every 4s, as the
> time is represented in nanoseconds (2^32/10^9).
>
> * drivers example, line 323: Do not display time in hex, and do not
> confuse the user neither!
> - printf("time is 0x%08lld\t", current);
> + printf("time is %08lld\t", current);
>
>
> ----
> * Source file : libs/vtimer/include/interfaces/vtimer.idl4
> * Output file :
> build/iguana/object/libs_vtimer/include/interfaces/vtimer_client.h
> ...
> /* Unmarshal */
> __return = (uint64_t)magpie_unmarshal_int32(&mr[4]);
Yes, we are aware this is an issue in the public release. It has since been
corrected.
-gl
> ...
> ---
> Output from drivers example:
> ...
> timer_get_ticks_impl: 9651300
> timer_get_ticks_impl: 9657452
> main: Got message from 0 (msg: 1)
> timer_get_ticks_impl: 9671208
> time is 0x4029670000 diff = 500001250
> rtc = 4029670000
> timer_get_ticks_impl: 10851299
> timer_get_ticks_impl: 10857659
> main: Got message from 0 (msg: 1)
> timer_get_ticks_impl: 10871628
> time is 0x234877704 diff = -3794792296
> rtc = 234877704
> timer_get_ticks_impl: 12051503
> timer_get_ticks_impl: 12057867
> main: Got message from 0 (msg: 1)
> timer_get_ticks_impl: 12071834
> time is 0x734963537 diff = 500085833
> rtc = 734963537
> ...
>
> thanks for your previous responses,
> Lukas
>
> _______________________________________________
> Developer mailing list
> Developer at okl4.org
> https://lists.okl4.org/mailman/listinfo/developer
>
--
More information about the Developer
mailing list