Lines Matching refs:sample
67 struct sample { struct
115 struct sample sample; member
866 struct sample *sample = &cpu->sample; in intel_pstate_calc_busy() local
869 core_pct = int_tofp(sample->aperf) * int_tofp(100); in intel_pstate_calc_busy()
870 core_pct = div64_u64(core_pct, int_tofp(sample->mperf)); in intel_pstate_calc_busy()
872 sample->freq = fp_toint( in intel_pstate_calc_busy()
878 sample->core_pct_busy = (int32_t)core_pct; in intel_pstate_calc_busy()
898 cpu->last_sample_time = cpu->sample.time; in intel_pstate_sample()
899 cpu->sample.time = ktime_get(); in intel_pstate_sample()
900 cpu->sample.aperf = aperf; in intel_pstate_sample()
901 cpu->sample.mperf = mperf; in intel_pstate_sample()
902 cpu->sample.tsc = tsc; in intel_pstate_sample()
903 cpu->sample.aperf -= cpu->prev_aperf; in intel_pstate_sample()
904 cpu->sample.mperf -= cpu->prev_mperf; in intel_pstate_sample()
905 cpu->sample.tsc -= cpu->prev_tsc; in intel_pstate_sample()
947 core_busy = cpu->sample.core_pct_busy; in intel_pstate_get_scaled_busy()
960 duration_us = ktime_us_delta(cpu->sample.time, in intel_pstate_get_scaled_busy()
977 struct sample *sample; in intel_pstate_adjust_busy_pstate() local
989 sample = &cpu->sample; in intel_pstate_adjust_busy_pstate()
990 trace_pstate_sample(fp_toint(sample->core_pct_busy), in intel_pstate_adjust_busy_pstate()
994 sample->mperf, in intel_pstate_adjust_busy_pstate()
995 sample->aperf, in intel_pstate_adjust_busy_pstate()
996 sample->tsc, in intel_pstate_adjust_busy_pstate()
997 sample->freq); in intel_pstate_adjust_busy_pstate()
1090 struct sample *sample; in intel_pstate_get() local
1096 sample = &cpu->sample; in intel_pstate_get()
1097 return sample->freq; in intel_pstate_get()