diff options
author | Sebastian Huber <sebastian.huber@embedded-brains.de> | 2019-10-01 13:04:29 +0200 |
---|---|---|
committer | Sebastian Huber <sebastian.huber@embedded-brains.de> | 2019-10-02 07:01:36 +0200 |
commit | 47e5c1d7cde10e0daa9c43fd183ed19b7140425d (patch) | |
tree | 87b1d87c9734f7598277e653a3547124efa98c0b /testsuites | |
parent | 2763f530d37ce6583dabac928c56172d931a8be0 (diff) |
score: Remove strange timecounter init step
The double call of the timecounter get method was added to FreeBSD in
2002 without a comment. It is not clear why this is needed.
Diffstat (limited to 'testsuites')
-rw-r--r-- | testsuites/sptests/sptimecounter01/init.c | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/testsuites/sptests/sptimecounter01/init.c b/testsuites/sptests/sptimecounter01/init.c index 9fc36583c4..8928c5e051 100644 --- a/testsuites/sptests/sptimecounter01/init.c +++ b/testsuites/sptests/sptimecounter01/init.c @@ -126,25 +126,25 @@ void boot_card(const char *cmdline) tc_soft->tc_frequency = soft_freq; tc_soft->tc_quality = 1234; _Timecounter_Install(tc_soft); - assert(ctx->tc_soft_counter == 3); + assert(ctx->tc_soft_counter == 1); rtems_bsd_binuptime(&bt); - assert(ctx->tc_soft_counter == 4); + assert(ctx->tc_soft_counter == 2); assert(bt.sec == 1); assert(bt.frac == 18446744073708); - ctx->tc_soft_counter = 0xf0000000 | 3; + ctx->tc_soft_counter = 0xf0000000 | 1; rtems_bsd_binuptime(&bt); - assert(ctx->tc_soft_counter == (0xf0000000 | 4)); + assert(ctx->tc_soft_counter == (0xf0000000 | 2)); assert(bt.sec == 1); assert(bt.frac == 18446744073708); /* Ensure that the fraction overflows and the second remains constant */ - ctx->tc_soft_counter = (0xf0000000 | 3) + soft_freq; + ctx->tc_soft_counter = (0xf0000000 | 1) + soft_freq; rtems_bsd_binuptime(&bt); - assert(ctx->tc_soft_counter == (0xf0000000 | 4) + soft_freq); + assert(ctx->tc_soft_counter == (0xf0000000 | 2) + soft_freq); assert(bt.sec == 1); assert(bt.frac == 18446742522092); |