diff options
Diffstat (limited to '')
-rw-r--r-- | cpukit/score/src/kern_tc.c | 15 |
1 files changed, 15 insertions, 0 deletions
diff --git a/cpukit/score/src/kern_tc.c b/cpukit/score/src/kern_tc.c index 39e67ede19..799d27c0ac 100644 --- a/cpukit/score/src/kern_tc.c +++ b/cpukit/score/src/kern_tc.c @@ -301,6 +301,7 @@ static void _Timecounter_Windup(struct bintime *new_boottimebin, #endif /* __rtems__ */ void dtrace_getnanotime(struct timespec *tsp); +void dtrace_getnanouptime(struct timespec *tsp); #ifndef __rtems__ static int @@ -1173,6 +1174,20 @@ dtrace_getnanotime(struct timespec *tsp) GETTHMEMBER(tsp, th_nanotime); } + +/* + * This is a clone of getnanouptime used for time since boot. + * The dtrace_ prefix prevents fbt from creating probes for + * it so an uptime that can be safely used in all fbt probes. + */ +void +dtrace_getnanouptime(struct timespec *tsp) +{ + struct bintime bt; + + GETTHMEMBER(&bt, th_offset); + bintime2timespec(&bt, tsp); +} #endif /* __rtems__ */ #ifdef FFCLOCK |