time_extras: prepare for adding cpu tstamp
time_extras: prepare for adding cpu tstamp

This commit refactors "tstamp_sysclock_diff_ns" to be able to reuse
it with other clocks.

RafaGago/base_library,RafaGago/base_library,RafaGago/base_library