Lines Matching defs:diff
98 * "diff" is passed in to the macro as "delta - delta_l" and is expected to be
123 * We also have to be careful to constrain the value of diff such that it won't
124 * overflow whilst performing the calculation. The middle term i.e. (160 * diff)
125 * / hz is the limiting factor in the calculation. We must constrain diff to be
127 * i.e. diff < INT_MAX / 160
132 #define HTCP_CALC_ALPHA(diff) \
135 ((160 * (diff)) / hz) + \
136 (((diff) / hz) * (((diff) << HTCP_ALPHA_INC_SHIFT) / (4 * hz))) \
168 * The maximum number of ticks the value of diff can reach in
409 int alpha, diff, now;
428 diff = now - htcp_data->t_last_cong - HTCP_DELTA_L;
430 /* Cap alpha if the value of diff would overflow HTCP_CALC_ALPHA(). */
431 if (diff < htcp_max_diff) {
436 if (diff > 0) {
437 alpha = HTCP_CALC_ALPHA(diff);