diff options
author | Alexander Krutwig <alexander.krutwig@embedded-brains.de> | 2015-05-12 14:32:47 +0200 |
---|---|---|
committer | Sebastian Huber <sebastian.huber@embedded-brains.de> | 2015-05-20 08:40:33 +0200 |
commit | 7cd2484c4cf9fc759b7205ed6d8adcc6d2c28ff6 (patch) | |
tree | dd60b6032354124d97233e7070506f09d1566832 /cpukit/score/src/coretodadjust.c | |
parent | timecounter: Port to RTEMS (diff) | |
download | rtems-7cd2484c4cf9fc759b7205ed6d8adcc6d2c28ff6.tar.bz2 |
timecounter: Use in RTEMS
Replace timestamp implementation with FreeBSD bintime and timecounters.
New test sptests/sptimecounter02.
Update #2271.
Diffstat (limited to '')
-rw-r--r-- | cpukit/score/src/coretodadjust.c | 9 |
1 files changed, 4 insertions, 5 deletions
diff --git a/cpukit/score/src/coretodadjust.c b/cpukit/score/src/coretodadjust.c index 09cf01ad7c..6097e207dc 100644 --- a/cpukit/score/src/coretodadjust.c +++ b/cpukit/score/src/coretodadjust.c @@ -25,8 +25,7 @@ void _TOD_Adjust( const Timestamp_Control delta ) { - Timestamp_Control tod; - Timestamp_Control *tod_ptr; + Timestamp_Control tod; /* * Currently, RTEMS does the adjustment in one movement. @@ -41,11 +40,11 @@ void _TOD_Adjust( */ _Thread_Disable_dispatch(); - tod_ptr = _TOD_Get_with_nanoseconds( &tod, &_TOD.now ); + _TOD_Get( &tod ); - _Timestamp_Add_to( tod_ptr, &delta ); + _Timestamp_Add_to( &tod, &delta ); - _TOD_Set_with_timestamp( tod_ptr ); + _TOD_Set_with_timestamp( &tod ); _Thread_Enable_dispatch(); } |