MCPcopy Create free account
hub / github.com/F-Stack/f-stack / ffclock_convert_diff

Function ffclock_convert_diff

freebsd/kern/kern_tc.c:856–868  ·  view source on GitHub ↗

* Difference clock conversion. * Low level function to Convert a time interval measured in RAW counter units * into bintime. The difference clock allows measuring small intervals much more * reliably than the absolute clock. */

Source from the content-addressed store, hash-verified

854 * reliably than the absolute clock.
855 */
856void
857ffclock_convert_diff(ffcounter ffdelta, struct bintime *bt)
858{
859 struct fftimehands *ffth;
860 uint8_t gen;
861
862 /* No locking but check generation has not changed. */
863 do {
864 ffth = fftimehands;
865 gen = ffth->gen;
866 ffclock_convert_delta(ffdelta, ffth->cest.period, bt);
867 } while (gen == 0 || gen != ffth->gen);
868}
869
870/*
871 * Access to current ffcounter value.

Callers 2

ffclock_abstimeFunction · 0.85
ffclock_difftimeFunction · 0.85

Calls 1

ffclock_convert_deltaFunction · 0.85

Tested by

no test coverage detected