/linux-6.6.21/net/netfilter/ |
D | xt_limit.c | 112 || user2credits(r->avg * r->burst) < user2credits(r->avg)) { in limit_mt_check() 114 r->avg, r->burst); in limit_mt_check() 127 priv->credit = user2credits(r->avg * r->burst); /* Credits full. */ in limit_mt_check() 130 r->cost = user2credits(r->avg); in limit_mt_check() 145 u_int32_t avg; member 161 .avg = cm->avg, in limit_mt_compat_from_user() 175 .avg = m->avg, in limit_mt_compat_to_user()
|
/linux-6.6.21/net/bridge/netfilter/ |
D | ebt_limit.c | 75 user2credits(info->avg * info->burst) < user2credits(info->avg)) { in ebt_limit_mt_check() 77 info->avg, info->burst); in ebt_limit_mt_check() 83 info->credit = user2credits(info->avg * info->burst); in ebt_limit_mt_check() 84 info->credit_cap = user2credits(info->avg * info->burst); in ebt_limit_mt_check() 85 info->cost = user2credits(info->avg); in ebt_limit_mt_check() 96 compat_uint_t avg, burst; member
|
/linux-6.6.21/drivers/mfd/ |
D | pcf50633-adc.c | 27 int avg; member 54 static void adc_setup(struct pcf50633 *pcf, int channel, int avg) in adc_setup() argument 63 pcf50633_reg_write(pcf, PCF50633_REG_ADCC1, channel | avg | in adc_setup() 77 adc_setup(pcf, adc->queue[head]->mux, adc->queue[head]->avg); in trigger_next_adc_job_if_any() 116 int pcf50633_adc_sync_read(struct pcf50633 *pcf, int mux, int avg) in pcf50633_adc_sync_read() argument 123 ret = pcf50633_adc_async_read(pcf, mux, avg, in pcf50633_adc_sync_read() 134 int pcf50633_adc_async_read(struct pcf50633 *pcf, int mux, int avg, in pcf50633_adc_async_read() argument 147 req->avg = avg; in pcf50633_adc_async_read()
|
/linux-6.6.21/tools/perf/scripts/python/Perf-Trace-Util/lib/Perf/Trace/ |
D | Util.py | 20 def avg(total, n): function 40 min, max, avg, count = dict[key] 45 avg = (avg + value) / 2 46 dict[key] = (min, max, avg, count + 1)
|
/linux-6.6.21/tools/testing/selftests/kvm/ |
D | dirty_log_perf_test.c | 79 struct timespec avg; in vcpu_worker() local 122 avg = timespec_div(total, vcpu_last_completed_iteration[vcpu_idx]); in vcpu_worker() 125 total.tv_sec, total.tv_nsec, avg.tv_sec, avg.tv_nsec); in vcpu_worker() 151 struct timespec avg; in run_test() local 280 avg = timespec_div(get_dirty_log_total, p->iterations); in run_test() 283 get_dirty_log_total.tv_nsec, avg.tv_sec, avg.tv_nsec); in run_test() 286 avg = timespec_div(clear_dirty_log_total, p->iterations); in run_test() 289 clear_dirty_log_total.tv_nsec, avg.tv_sec, avg.tv_nsec); in run_test()
|
/linux-6.6.21/drivers/iio/humidity/ |
D | hts221_core.c | 174 const struct hts221_avg *avg = &hts221_avg_list[type]; in hts221_update_avg() local 178 if (avg->avg_avl[i] == val) in hts221_update_avg() 184 data = ((i << __ffs(avg->mask)) & avg->mask); in hts221_update_avg() 185 err = regmap_update_bits(hw->regmap, avg->addr, in hts221_update_avg() 186 avg->mask, data); in hts221_update_avg() 215 const struct hts221_avg *avg = &hts221_avg_list[HTS221_SENSOR_H]; in hts221_sysfs_rh_oversampling_avail() local 219 for (i = 0; i < ARRAY_SIZE(avg->avg_avl); i++) in hts221_sysfs_rh_oversampling_avail() 221 avg->avg_avl[i]); in hts221_sysfs_rh_oversampling_avail() 232 const struct hts221_avg *avg = &hts221_avg_list[HTS221_SENSOR_T]; in hts221_sysfs_temp_oversampling_avail() local 236 for (i = 0; i < ARRAY_SIZE(avg->avg_avl); i++) in hts221_sysfs_temp_oversampling_avail() [all …]
|
/linux-6.6.21/kernel/sched/ |
D | pelt.c | 297 if (___update_load_sum(now, &se->avg, 0, 0, 0)) { in __update_load_avg_blocked_se() 298 ___update_load_avg(&se->avg, se_weight(se)); in __update_load_avg_blocked_se() 308 if (___update_load_sum(now, &se->avg, !!se->on_rq, se_runnable(se), in __update_load_avg_se() 311 ___update_load_avg(&se->avg, se_weight(se)); in __update_load_avg_se() 312 cfs_se_util_change(&se->avg); in __update_load_avg_se() 322 if (___update_load_sum(now, &cfs_rq->avg, in __update_load_avg_cfs_rq() 327 ___update_load_avg(&cfs_rq->avg, 1); in __update_load_avg_cfs_rq()
|
D | pelt.h | 42 static inline u32 get_pelt_divider(struct sched_avg *avg) in get_pelt_divider() argument 44 return PELT_MIN_DIVIDER + avg->period_contrib; in get_pelt_divider() 47 static inline void cfs_se_util_change(struct sched_avg *avg) in cfs_se_util_change() argument 55 enqueued = avg->util_est.enqueued; in cfs_se_util_change() 61 WRITE_ONCE(avg->util_est.enqueued, enqueued); in cfs_se_util_change() 136 u32 util_sum = rq->cfs.avg.util_sum; in update_idle_rq_clock_pelt()
|
D | fair.c | 674 s64 avg = cfs_rq->avg_vruntime; in avg_vruntime() local 680 avg += entity_key(cfs_rq, curr) * weight; in avg_vruntime() 686 if (avg < 0) in avg_vruntime() 687 avg -= (load - 1); in avg_vruntime() 688 avg = div_s64(avg, load); in avg_vruntime() 691 return cfs_rq->min_vruntime + avg; in avg_vruntime() 741 s64 avg = cfs_rq->avg_vruntime; in entity_eligible() local 747 avg += entity_key(cfs_rq, curr) * weight; in entity_eligible() 751 return avg >= entity_key(cfs_rq, se) * load; in entity_eligible() 1055 struct sched_avg *sa = &se->avg; in init_entity_runnable_average() [all …]
|
D | psi.c | 316 static void calc_avgs(unsigned long avg[3], int missed_periods, in calc_avgs() 323 avg[0] = calc_load_n(avg[0], EXP_10s, 0, missed_periods); in calc_avgs() 324 avg[1] = calc_load_n(avg[1], EXP_60s, 0, missed_periods); in calc_avgs() 325 avg[2] = calc_load_n(avg[2], EXP_300s, 0, missed_periods); in calc_avgs() 331 avg[0] = calc_load(avg[0], EXP_10s, pct); in calc_avgs() 332 avg[1] = calc_load(avg[1], EXP_60s, pct); in calc_avgs() 333 avg[2] = calc_load(avg[2], EXP_300s, pct); in calc_avgs() 557 calc_avgs(group->avg[s], missed_periods, sample, period); in update_averages() 1255 unsigned long avg[3] = { 0, }; in psi_show() local 1262 avg[w] = group->avg[res * 2 + full][w]; in psi_show() [all …]
|
D | debug.c | 527 P(se->avg.load_avg); in print_cfs_group_stats() 528 P(se->avg.util_avg); in print_cfs_group_stats() 529 P(se->avg.runnable_avg); in print_cfs_group_stats() 677 cfs_rq->avg.load_avg); in print_cfs_rq() 679 cfs_rq->avg.runnable_avg); in print_cfs_rq() 681 cfs_rq->avg.util_avg); in print_cfs_rq() 683 cfs_rq->avg.util_est.enqueued); in print_cfs_rq() 1071 P(se.avg.load_sum); in proc_sched_show_task() 1072 P(se.avg.runnable_sum); in proc_sched_show_task() 1073 P(se.avg.util_sum); in proc_sched_show_task() [all …]
|
/linux-6.6.21/kernel/trace/ |
D | trace_benchmark.c | 45 unsigned int avg; in trace_do_benchmark() local 109 avg = delta; in trace_do_benchmark() 124 seed = avg; in trace_do_benchmark() 140 bm_last, bm_first, bm_max, bm_min, avg, std, stddev); in trace_do_benchmark() 143 bm_avg = avg; in trace_do_benchmark()
|
D | ring_buffer_benchmark.c | 238 unsigned long avg; in ring_buffer_producer() local 348 avg = NSEC_PER_MSEC / hit; in ring_buffer_producer() 349 trace_printk("%ld ns per entry\n", avg); in ring_buffer_producer() 366 avg = NSEC_PER_MSEC / (hit + missed); in ring_buffer_producer() 367 trace_printk("%ld ns per entry\n", avg); in ring_buffer_producer()
|
/linux-6.6.21/include/uapi/linux/netfilter/ |
D | xt_hashlimit.h | 34 __u32 avg; /* Average secs between packets * scale */ member 58 __u32 avg; /* Average secs between packets * scale */ member 71 __u64 avg; /* Average secs between packets * scale */ member 85 __u64 avg; /* Average secs between packets * scale */ member
|
/linux-6.6.21/net/dccp/ccids/lib/ |
D | tfrc.h | 49 static inline u32 tfrc_ewma(const u32 avg, const u32 newval, const u8 weight) in tfrc_ewma() argument 51 return avg ? (weight * avg + (10 - weight) * newval) / 10 : newval; in tfrc_ewma()
|
/linux-6.6.21/tools/perf/bench/ |
D | epoll-ctl.c | 294 unsigned long avg[EPOLL_NR_OPS]; in print_summary() local 298 avg[i] = avg_stats(&all_stats[i]); in print_summary() 303 avg[OP_EPOLL_ADD], rel_stddev_stats(stddev[OP_EPOLL_ADD], in print_summary() 304 avg[OP_EPOLL_ADD])); in print_summary() 306 avg[OP_EPOLL_MOD], rel_stddev_stats(stddev[OP_EPOLL_MOD], in print_summary() 307 avg[OP_EPOLL_MOD])); in print_summary() 309 avg[OP_EPOLL_DEL], rel_stddev_stats(stddev[OP_EPOLL_DEL], in print_summary() 310 avg[OP_EPOLL_DEL])); in print_summary()
|
/linux-6.6.21/drivers/cpuidle/governors/ |
D | menu.c | 174 unsigned int min, max, thresh, avg; in get_typical_interval() local 203 avg = sum >> INTERVAL_SHIFT; in get_typical_interval() 205 avg = div_u64(sum, divisor); in get_typical_interval() 212 int64_t diff = (int64_t)value - avg; in get_typical_interval() 234 if ((((u64)avg*avg > variance*36) && (divisor * 4 >= INTERVALS * 3)) in get_typical_interval() 236 return avg; in get_typical_interval()
|
/linux-6.6.21/drivers/hwmon/pmbus/ |
D | adm1275.c | 521 u32 avg; in adm1275_probe() local 786 "adi,power-sample-average", &avg) == 0) { in adm1275_probe() 787 if (!avg || avg > ADM1275_SAMPLES_AVG_MAX || in adm1275_probe() 788 BIT(__fls(avg)) != avg) { in adm1275_probe() 793 ret = adm1275_write_samples(data, client, true, ilog2(avg)); in adm1275_probe() 803 "adi,volt-curr-sample-average", &avg) == 0) { in adm1275_probe() 804 if (!avg || avg > ADM1275_SAMPLES_AVG_MAX || in adm1275_probe() 805 BIT(__fls(avg)) != avg) { in adm1275_probe() 810 ret = adm1275_write_samples(data, client, false, ilog2(avg)); in adm1275_probe()
|
/linux-6.6.21/kernel/time/ |
D | test_udelay.c | 31 uint64_t avg; in udelay_test_single() local 55 avg = sum; in udelay_test_single() 56 do_div(avg, iters); in udelay_test_single() 59 (usecs * 1000) - allowed_error_ns, min, avg, max); in udelay_test_single()
|
/linux-6.6.21/tools/perf/util/ |
D | stat-display.c | 132 double total, double avg, bool before_metric) in print_noise_pct() argument 134 double pct = rel_stddev_stats(total, avg); in print_noise_pct() 149 struct evsel *evsel, double avg, bool before_metric) in print_noise() argument 157 print_noise_pct(config, stddev_stats(&ps->res_stats), avg, before_metric); in print_noise() 648 struct evsel *evsel, double avg, bool ok) in print_counter_value_std() argument 661 fprintf(output, fmt, COUNTS_LEN, avg); in print_counter_value_std() 672 struct evsel *evsel, double avg, bool ok) in print_counter_value_csv() argument 681 fprintf(output, fmt, avg, sep); in print_counter_value_csv() 692 struct evsel *evsel, double avg, bool ok) in print_counter_value_json() argument 698 fprintf(output, "\"counter-value\" : \"%f\", ", avg); in print_counter_value_json() [all …]
|
/linux-6.6.21/drivers/power/supply/ |
D | ab8500_fg.c | 109 int avg; member 386 struct ab8500_fg_avg_cap *avg = &di->avg_cap; in ab8500_fg_add_cap_sample() local 389 avg->sum += sample - avg->samples[avg->pos]; in ab8500_fg_add_cap_sample() 390 avg->samples[avg->pos] = sample; in ab8500_fg_add_cap_sample() 391 avg->time_stamps[avg->pos] = now; in ab8500_fg_add_cap_sample() 392 avg->pos++; in ab8500_fg_add_cap_sample() 394 if (avg->pos == NBR_AVG_SAMPLES) in ab8500_fg_add_cap_sample() 395 avg->pos = 0; in ab8500_fg_add_cap_sample() 397 if (avg->nbr_samples < NBR_AVG_SAMPLES) in ab8500_fg_add_cap_sample() 398 avg->nbr_samples++; in ab8500_fg_add_cap_sample() [all …]
|
/linux-6.6.21/fs/ceph/ |
D | debugfs.c | 130 #define CEPH_LAT_METRIC_SHOW(name, total, avg, min, max, sq) { \ argument 132 _avg = ktime_to_us(avg); \ 143 #define CEPH_SZ_METRIC_SHOW(name, total, avg, min, max, sum) { \ argument 146 name, total, avg, _min, max, sum); \ 178 s64 total, avg, min, max, sq; in metrics_latency_show() local 188 avg = m->latency_avg; in metrics_latency_show() 193 CEPH_LAT_METRIC_SHOW(metric_str[i], total, avg, min, max, sq); in metrics_latency_show() 205 u64 sum, avg, min, max; in metrics_size_show() local 219 avg = total > 0 ? DIV64_U64_ROUND_CLOSEST(sum, total) : 0; in metrics_size_show() 223 CEPH_SZ_METRIC_SHOW(metric_str[i], total, avg, min, max, sum); in metrics_size_show()
|
D | metric.c | 80 ktime_to_ceph_timespec(&read->avg, m->metric[METRIC_READ].latency_avg); in ceph_mdsc_send_metrics() 93 ktime_to_ceph_timespec(&write->avg, m->metric[METRIC_WRITE].latency_avg); in ceph_mdsc_send_metrics() 106 ktime_to_ceph_timespec(&meta->avg, m->metric[METRIC_METADATA].latency_avg); in ceph_mdsc_send_metrics() 330 ktime_t avg; in __update_mean_and_stdev() local 336 avg = *lavg + div64_s64(lat - *lavg, total); in __update_mean_and_stdev() 337 *sq_sump += (lat - *lavg)*(lat - avg); in __update_mean_and_stdev() 338 *lavg = avg; in __update_mean_and_stdev()
|
/linux-6.6.21/drivers/clk/bcm/ |
D | clk-bcm53573-ilp.c | 50 int avg; in bcm53573_ilp_recalc_rate() local 87 avg = sum / num; in bcm53573_ilp_recalc_rate() 89 return parent_rate * 4 / avg; in bcm53573_ilp_recalc_rate()
|
/linux-6.6.21/include/linux/mfd/pcf50633/ |
D | adc.h | 63 pcf50633_adc_async_read(struct pcf50633 *pcf, int mux, int avg, 67 pcf50633_adc_sync_read(struct pcf50633 *pcf, int mux, int avg);
|