Lines Matching refs:tc
7 u64 perf_time_to_tsc(u64 ns, struct perf_tsc_conversion *tc) in perf_time_to_tsc() argument
11 t = ns - tc->time_zero; in perf_time_to_tsc()
12 quot = t / tc->time_mult; in perf_time_to_tsc()
13 rem = t % tc->time_mult; in perf_time_to_tsc()
14 return (quot << tc->time_shift) + in perf_time_to_tsc()
15 (rem << tc->time_shift) / tc->time_mult; in perf_time_to_tsc()
18 u64 tsc_to_perf_time(u64 cyc, struct perf_tsc_conversion *tc) in tsc_to_perf_time() argument
22 quot = cyc >> tc->time_shift; in tsc_to_perf_time()
23 rem = cyc & (((u64)1 << tc->time_shift) - 1); in tsc_to_perf_time()
24 return tc->time_zero + quot * tc->time_mult + in tsc_to_perf_time()
25 ((rem * tc->time_mult) >> tc->time_shift); in tsc_to_perf_time()