From 270200e972e6c2a5733a12ee70fcc3b7e2940c6c Mon Sep 17 00:00:00 2001 From: Sebastian Huber Date: Thu, 8 Sep 2022 09:41:12 +0200 Subject: score: Remove _CPU_Counter_difference() All CPU ports used the same _CPU_Counter_difference() implementation. Remove this CPU port interface and mandate a monotonically increasing CPU counter. Close #3456. --- cpukit/include/rtems/score/smplockstats.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'cpukit/include/rtems/score/smplockstats.h') diff --git a/cpukit/include/rtems/score/smplockstats.h b/cpukit/include/rtems/score/smplockstats.h index 102fb6eac5..cebfb80bd6 100644 --- a/cpukit/include/rtems/score/smplockstats.h +++ b/cpukit/include/rtems/score/smplockstats.h @@ -235,7 +235,7 @@ static inline void _SMP_lock_Stats_acquire_end( second = _CPU_Counter_read(); stats_context->acquire_instant = second; - delta = _CPU_Counter_difference( second, acquire_context->first ); + delta = second - acquire_context->first; ++stats->usage_count; @@ -270,7 +270,7 @@ static inline void _SMP_lock_Stats_release_update( stats = stats_context->stats; first = stats_context->acquire_instant; second = _CPU_Counter_read(); - delta = _CPU_Counter_difference( second, first ); + delta = second - first; stats->total_section_time += delta; -- cgit v1.2.3