Home
last modified time | relevance | path

Searched refs:weight (Results 1 – 25 of 276) sorted by relevance

12345678910>>...12

/linux/net/netfilter/ipvs/
H A Dip_vs_twos.c27 * decrement rweight1 and rweight2 by the destination weight
32 * by weight
49 int overhead2, total_weight = 0, weight; in ip_vs_twos_schedule()
53 /* Generate a random weight between [0,sum of all weights) */ in ip_vs_twos_schedule()
56 weight = atomic_read(&dest->weight); in ip_vs_twos_schedule()
57 if (weight > 0) { in ip_vs_twos_schedule()
58 total_weight += weight; in ip_vs_twos_schedule()
81 weight = atomic_read(&dest->weight); in ip_vs_twos_schedule()
50 int overhead2, total_weight = 0, weight; ip_vs_twos_schedule() local
[all...]
H A Dip_vs_wrr.c71 int weight; in ip_vs_wrr_gcd_weight() local
75 weight = atomic_read(&dest->weight); in ip_vs_wrr_gcd_weight()
76 if (weight > 0) { in ip_vs_wrr_gcd_weight()
78 g = gcd(weight, g); in ip_vs_wrr_gcd_weight()
80 g = weight; in ip_vs_wrr_gcd_weight()
93 int new_weight, weight = 0; in ip_vs_wrr_max_weight() local
96 new_weight = atomic_read(&dest->weight); in ip_vs_wrr_max_weight()
97 if (new_weight > weight) in ip_vs_wrr_max_weight()
98 weight = new_weight; in ip_vs_wrr_max_weight()
101 return weight; in ip_vs_wrr_max_weight()
[all …]
H A Dip_vs_lblcr.c172 if ((atomic_read(&least->weight) > 0) in ip_vs_dest_set_min()
188 if (((__s64)loh * atomic_read(&dest->weight) > in ip_vs_dest_set_min()
189 (__s64)doh * atomic_read(&least->weight)) in ip_vs_dest_set_min()
203 atomic_read(&least->weight), loh); in ip_vs_dest_set_min()
221 if (atomic_read(&most->weight) > 0) { in ip_vs_dest_set_max()
234 if (((__s64)moh * atomic_read(&dest->weight) < in ip_vs_dest_set_max()
235 (__s64)doh * atomic_read(&most->weight)) in ip_vs_dest_set_max()
236 && (atomic_read(&dest->weight) > 0)) { in ip_vs_dest_set_max()
248 atomic_read(&most->weight), moh); in ip_vs_dest_set_max()
583 if (atomic_read(&dest->weight) > 0) { in __ip_vs_lblcr_schedule()
[all …]
H A Dip_vs_nq.c62 * (server expected overhead) / dest->weight in ip_vs_nq_schedule()
67 * if every weight is larger than zero. in ip_vs_nq_schedule()
69 * The server with weight=0 is quiesced and will not receive any in ip_vs_nq_schedule()
76 !atomic_read(&dest->weight)) in ip_vs_nq_schedule()
89 ((__s64)loh * atomic_read(&dest->weight) > in ip_vs_nq_schedule()
90 (__s64)doh * atomic_read(&least->weight))) { in ip_vs_nq_schedule()
103 "activeconns %d refcnt %d weight %d overhead %d\n", in ip_vs_nq_schedule()
108 atomic_read(&least->weight), loh); in ip_vs_nq_schedule()
H A Dip_vs_wlc.c14 * Wensong Zhang : added any dest with weight=0 is quiesced
38 * (dest overhead) / dest->weight in ip_vs_wlc_schedule()
43 * if every weight is larger than zero. in ip_vs_wlc_schedule()
45 * The server with weight=0 is quiesced and will not receive any in ip_vs_wlc_schedule()
51 atomic_read(&dest->weight) > 0) { in ip_vs_wlc_schedule()
68 if ((__s64)loh * atomic_read(&dest->weight) > in ip_vs_wlc_schedule()
69 (__s64)doh * atomic_read(&least->weight)) { in ip_vs_wlc_schedule()
76 "activeconns %d refcnt %d weight %d overhead %d\n", in ip_vs_wlc_schedule()
81 atomic_read(&least->weight), loh); in ip_vs_wlc_schedule()
H A Dip_vs_sed.c14 * jobs on the ith server and Ui is the fixed service rate (weight) of
29 * (the server weight varies a lot).
66 * (server expected overhead) / dest->weight in ip_vs_sed_schedule()
71 * if every weight is larger than zero. in ip_vs_sed_schedule()
73 * The server with weight=0 is quiesced and will not receive any in ip_vs_sed_schedule()
79 atomic_read(&dest->weight) > 0) { in ip_vs_sed_schedule()
96 if ((__s64)loh * atomic_read(&dest->weight) > in ip_vs_sed_schedule()
97 (__s64)doh * atomic_read(&least->weight)) { in ip_vs_sed_schedule()
104 "activeconns %d refcnt %d weight %d overhead %d\n", in ip_vs_sed_schedule()
109 atomic_read(&least->weight), lo in ip_vs_sed_schedule()
[all...]
H A Dip_vs_mh.c82 return atomic_read(&dest->weight) <= 0 || in is_unavailable()
323 int weight; in ip_vs_mh_gcd_weight() local
327 weight = atomic_read(&dest->last_weight); in ip_vs_mh_gcd_weight()
328 if (weight > 0) { in ip_vs_mh_gcd_weight()
330 g = gcd(weight, g); in ip_vs_mh_gcd_weight()
332 g = weight; in ip_vs_mh_gcd_weight()
344 int new_weight, weight = 0; in ip_vs_mh_shift_weight() local
356 if (new_weight > weight) in ip_vs_mh_shift_weight()
357 weight = new_weight; in ip_vs_mh_shift_weight()
363 mw = weight / gcd; in ip_vs_mh_shift_weight()
H A Dip_vs_fo.c8 * Kenny Mathis : added initial functionality based on weight
24 int hw = 0; /* Track highest weight */ in ip_vs_fo_schedule()
29 * Find virtual server with highest weight and send it traffic in ip_vs_fo_schedule()
33 atomic_read(&dest->weight) > hw) { in ip_vs_fo_schedule()
35 hw = atomic_read(&dest->weight); in ip_vs_fo_schedule()
40 IP_VS_DBG_BUF(6, "FO: server %s:%u activeconns %d weight %d\n", in ip_vs_fo_schedule()
44 atomic_read(&hweight->weight)); in ip_vs_fo_schedule()
H A Dip_vs_lblc.c419 if (atomic_read(&dest->weight) > 0) { in __ip_vs_lblc_schedule()
436 if ((__s64)loh * atomic_read(&dest->weight) > in __ip_vs_lblc_schedule()
437 (__s64)doh * atomic_read(&least->weight)) { in __ip_vs_lblc_schedule()
449 atomic_read(&least->weight), loh); in __ip_vs_lblc_schedule()
462 if (atomic_read(&dest->activeconns) > atomic_read(&dest->weight)) { in is_overloaded()
467 < atomic_read(&d->weight)) { in is_overloaded()
506 atomic_read(&dest->weight) > 0 && !is_overloaded(dest, svc)) in ip_vs_lblc_schedule()
/linux/lib/
H A Dirq_poll.c88 int work, weight; in irq_poll_softirq() local
107 weight = iop->weight; in irq_poll_softirq()
110 work = iop->poll(iop, weight); in irq_poll_softirq()
124 if (work >= weight) { in irq_poll_softirq()
179 void irq_poll_init(struct irq_poll *iop, int weight, irq_poll_fn *poll_fn) in irq_poll_init() argument
183 iop->weight = weight; in irq_poll_init()
/linux/drivers/accel/ethosu/
H A Dethosu_gem.c143 struct buffer weight[4]; member
237 bool ifm, bool ifm2, bool weight, bool scale) in calc_sizes() argument
270 if (weight) { in calc_sizes()
272 op, st->weight[0].region, st->weight[0].base, in calc_sizes()
273 st->weight[0].base + st->weight[0].length - 1); in calc_sizes()
274 if (st->weight[0].region < 0 || st->weight[0].base == U64_MAX || in calc_sizes()
275 st->weight[0].length == U32_MAX) in calc_sizes()
277 info->region_size[st->weight[0].region] = in calc_sizes()
278 max(info->region_size[st->weight[0].region], in calc_sizes()
279 st->weight[0].base + st->weight[0].length); in calc_sizes()
[all …]
/linux/drivers/gpu/drm/ingenic/
H A Dingenic-ipu.c45 unsigned int weight, unsigned int offset);
157 unsigned int weight, unsigned int offset) in jz4760_set_coefs() argument
162 weight = clamp_val(weight, 0, 512); in jz4760_set_coefs()
171 weight = weight >= 256 ? 512 : 0; in jz4760_set_coefs()
173 w1 = weight; in jz4760_set_coefs()
174 w2 = 512 - weight; in jz4760_set_coefs()
186 weight = 512 - weight; in jz4760_set_coefs()
187 w0 = F2I(f_h + 512 * cubic_conv(f_a, I2F(512 + weight) / 512)); in jz4760_set_coefs()
188 w1 = F2I(f_h + 512 * cubic_conv(f_a, I2F(0 + weight) / 512)); in jz4760_set_coefs()
189 w2 = F2I(f_h + 512 * cubic_conv(f_a, I2F(512 - weight) / 512)); in jz4760_set_coefs()
[all …]
/linux/drivers/net/can/dev/
H A Drx-offload.c354 unsigned int weight) in can_rx_offload_init_queue() argument
359 offload->skb_queue_len_max = 2 << fls(weight); in can_rx_offload_init_queue()
365 weight); in can_rx_offload_init_queue()
376 unsigned int weight; in can_rx_offload_add_timestamp() local
384 weight = offload->mb_last - offload->mb_first; in can_rx_offload_add_timestamp()
387 weight = offload->mb_first - offload->mb_last; in can_rx_offload_add_timestamp()
390 return can_rx_offload_init_queue(dev, offload, weight); in can_rx_offload_add_timestamp()
395 struct can_rx_offload *offload, unsigned int weight) in can_rx_offload_add_fifo() argument
400 return can_rx_offload_init_queue(dev, offload, weight); in can_rx_offload_add_fifo()
406 unsigned int weight) in can_rx_offload_add_manual() argument
[all …]
/linux/kernel/events/
H A Dhw_breakpoint.c410 toggle_bp_slot(struct perf_event *bp, bool enable, enum bp_type_idx type, int weight) in toggle_bp_slot() argument
415 weight = -weight; in toggle_bp_slot()
425 bp_slots_histogram_add(&cpu_pinned[type], info->cpu_pinned, weight); in toggle_bp_slot()
426 info->cpu_pinned += weight; in toggle_bp_slot()
479 bp_slots_histogram_add(&tsk_pinned_all[type], next_tsk_pinned, weight); in toggle_bp_slot()
488 next_tsk_pinned, weight); in toggle_bp_slot()
495 next_tsk_pinned + hw_breakpoint_weight(bp), weight); in toggle_bp_slot()
512 next_tsk_pinned, weight); in toggle_bp_slot()
577 int weight; in __reserve_bp_slot() local
589 weight = hw_breakpoint_weight(bp); in __reserve_bp_slot()
[all …]
/linux/Documentation/ABI/testing/
H A Dsysfs-kernel-mm-mempolicy-weighted-interleave11 The interleave weight for a memory node (N). These weights are
18 The minimum weight for a node is always 1.
20 Minimum weight: 1
21 Maximum weight: 255
26 Changing the weight to a valid value will automatically
46 a default weight of 1.
53 Writing a new weight to a node directly via the nodeN interface
H A Dsysfs-class-firmware4 Contact: Russ Weight <russ.weight@linux.dev>
16 Contact: Russ Weight <russ.weight@linux.dev>
26 Contact: Russ Weight <russ.weight@linux.dev>
40 Contact: Russ Weight <russ.weight@linux.dev>
52 Contact: Russ Weight <russ.weight@linux.dev>
65 Contact: Russ Weight <russ.weight@linux.dev>
73 Contact: Russ Weight <russ.weight@linux.dev>
/linux/drivers/net/ethernet/marvell/octeontx2/nic/
H A Dcn10k.h15 u32 weight; in mtu_to_dwrr_weight() local
20 weight = mtu / pfvf->hw.dwrr_mtu; in mtu_to_dwrr_weight()
22 weight += 1; in mtu_to_dwrr_weight()
24 return weight; in mtu_to_dwrr_weight()
/linux/drivers/dma/qcom/
H A Dhidma_mgmt.c104 if (mgmtdev->weight[i] > HIDMA_MAX_CHANNEL_WEIGHT) { in hidma_mgmt_setup()
112 if (mgmtdev->weight[i] == 0) in hidma_mgmt_setup()
113 mgmtdev->weight[i] = 1; in hidma_mgmt_setup()
137 u32 weight = mgmtdev->weight[i]; in hidma_mgmt_setup() local
144 val |= (weight & HIDMA_WEIGHT_MASK) << HIDMA_WRR_BIT_POS; in hidma_mgmt_setup()
277 mgmtdev->weight = devm_kcalloc(&pdev->dev, in hidma_mgmt_probe()
279 sizeof(*mgmtdev->weight), GFP_KERNEL); in hidma_mgmt_probe()
280 if (!mgmtdev->weight) { in hidma_mgmt_probe()
/linux/tools/sched_ext/
H A Dscx_qmap.bpf.c6 * assigned to one depending on its compound weight. Each CPU round robins
181 static int weight_to_idx(u32 weight) in weight_to_idx() argument
183 /* Coarsely map the compound weight to a FIFO. */ in weight_to_idx()
184 if (weight <= 25) in weight_to_idx()
186 else if (weight <= 50) in weight_to_idx()
188 else if (weight < 200) in weight_to_idx()
190 else if (weight < 400) in weight_to_idx()
201 int idx = weight_to_idx(p->scx.weight); in BPF_STRUCT_OPS()
274 if (highpri_boosting && p->scx.weight >= HIGHPRI_WEIGHT) { in BPF_STRUCT_OPS()
294 int idx = weight_to_idx(p->scx.weight); in update_core_sched_head_seq()
658 BPF_STRUCT_OPS(qmap_cgroup_set_weight,struct cgroup * cgrp,u32 weight) BPF_STRUCT_OPS() argument
[all...]
H A Dscx_flatcg.bpf.c4 * hierarchical weight-based cgroup CPU control by flattening the cgroup
5 * hierarchy into a single layer by compounding the active weight share at each
32 * apache instances competing with 2:1 weight ratio nested four level deep.
132 /* gets inc'd on weight tree changes to expire the cached hweights */
237 div_round_up(pcgc->hweight * cgc->weight, in cgrp_refresh_hweight()
412 * Walk the cgroup tree to update the active weight sums as tasks wake up and
413 * sleep. The weight sums are used as the base when calculating the proportion a
445 * it's added to the weight tree so that enqueue has the up-to-date in update_active_weight_sums()
447 * refreshed before it's removed from the weight tree so that the usage in update_active_weight_sums()
470 * against weight change in update_active_weight_sums()
586 BPF_STRUCT_OPS(fcg_cgroup_set_weight,struct cgroup * cgrp,u32 weight) BPF_STRUCT_OPS() argument
[all...]
/linux/arch/powerpc/platforms/pseries/
H A Dlparcfg.c79 u8 weight; member
131 ppp_data->weight = (retbuf[3] >> 5 * 8) & 0xff; in h_get_ppp()
238 seq_printf(m, "capacity_weight=%d\n", ppp_data.weight); in parse_ppp_data()
601 static ssize_t update_ppp(u64 *entitlement, u8 *weight) in update_ppp() argument
614 new_weight = ppp_data.weight; in update_ppp()
616 } else if (weight) { in update_ppp()
617 new_weight = *weight; in update_ppp()
623 __func__, ppp_data.entitlement, ppp_data.weight); in update_ppp()
639 static ssize_t update_mpp(u64 *entitlement, u8 *weight) in update_mpp() argument
662 } else if (weight) { in update_mpp()
[all …]
/linux/drivers/net/wireless/rsi/
H A Drsi_91x_core.c38 common->min_weight = tx_qinfo[ii].weight; in rsi_determine_min_weight_queue()
64 tx_qinfo[ii].weight = in rsi_recalculate_weights()
65 ((tx_qinfo[ii].weight > common->min_weight) ? in rsi_recalculate_weights()
66 tx_qinfo[ii].weight - common->min_weight : 0); in rsi_recalculate_weights()
69 tx_qinfo[ii].weight = tx_qinfo[ii].wme_params; in rsi_recalculate_weights()
73 tx_qinfo[ii].weight = 0; in rsi_recalculate_weights()
174 (common->tx_qinfo[ii].weight < common->min_weight)) && in rsi_core_determine_hal_queue()
176 common->min_weight = common->tx_qinfo[ii].weight; in rsi_core_determine_hal_queue()
/linux/net/dccp/ccids/lib/
H A Dtfrc.h
/linux/net/ceph/crush/
H A Dmapper.c414 const __u32 *weight, int weight_max, in is_out() argument
419 if (weight[item] >= 0x10000) in is_out()
421 if (weight[item] == 0) in is_out()
424 < weight[item]) in is_out()
456 const __u32 *weight, int weight_max, in crush_choose_firstn() argument
569 weight, weight_max, in crush_choose_firstn()
592 reject = is_out(map, weight, in crush_choose_firstn()
649 const __u32 *weight, int weight_max, in crush_choose_indep() argument
782 weight, weight_max, in crush_choose_indep()
800 is_out(map, weight, weight_max, item, x)) in crush_choose_indep()
[all …]
/linux/block/
H A Dbfq-wf2q.c286 static u64 bfq_delta(unsigned long service, unsigned long weight) in bfq_delta() argument
288 return div64_ul((u64)service << WFQ_SERVICE_SHIFT, weight); in bfq_delta()
301 bfq_delta(service, entity->weight); in bfq_calc_finish()
306 service, entity->weight); in bfq_calc_finish()
310 bfq_delta(service, entity->weight)); in bfq_calc_finish()
518 static unsigned short bfq_weight_to_ioprio(int weight) in bfq_weight_to_ioprio() argument
521 IOPRIO_NR_LEVELS - weight / BFQ_WEIGHT_CONVERSION_COEFF); in bfq_weight_to_ioprio()
632 st->wsum -= entity->weight; in bfq_forget_entity()
713 old_st->wsum -= entity->weight; in __bfq_entity_update_weight_prio()
750 prev_weight = entity->weight; in __bfq_entity_update_weight_prio()
[all …]

12345678910>>...12