Home | History | Annotate | Download | only in tc

Lines Matching refs:rate

35 		" r2q      DRR quantums are computed as rate in Bps/r2q {10}\n"
37 "... class add ... htb rate R1 [burst B1] [mpu B] [overhead O]\n"
40 " rate rate allocated to this class (class can still borrow)\n"
42 " mpu minimum packet size used in rate computations\n"
43 " overhead per-packet size overhead used in rate computations\n"
45 " ceil definite upper class rate (no borrows) {rate}\n"
47 " mtu max packet size we create rate map for {1600}\n"
170 if (opt.ceil.rate) {
174 if (get_rate(&opt.ceil.rate, *argv)) {
179 } else if (strcmp(*argv, "rate") == 0) {
181 if (opt.rate.rate) {
182 fprintf(stderr, "Double \"rate\" spec\n");
185 if (get_rate(&opt.rate.rate, *argv)) {
186 explain1("rate");
204 if (opt.rate.rate == 0) {
205 fprintf(stderr, "\"rate\" is required.\n");
208 /* if ceil params are missing, use the same as rate */
209 if (!opt.ceil.rate) opt.ceil = opt.rate;
211 /* compute minimal allowed burst from rate; mtu is added here to make
213 if (!buffer) buffer = opt.rate.rate / get_hz() + mtu;
214 if (!cbuffer) cbuffer = opt.ceil.rate / get_hz() + mtu;
217 opt.rate.overhead = overhead;
220 opt.rate.mpu = mpu;
222 if (tc_calc_rtable(&opt.rate, rtab, cell_log, mtu, linklayer) < 0) {
223 fprintf(stderr, "htb: failed to calculate rate table.\n");
226 opt.buffer = tc_calc_xmittime(opt.rate.rate, buffer);
229 fprintf(stderr, "htb: failed to calculate ceil rate table.\n");
232 opt.cbuffer = tc_calc_xmittime(opt.ceil.rate, cbuffer);
268 fprintf(f, "rate %s ", sprint_rate(hopt->rate.rate, b1));
269 buffer = tc_calc_xmitsize(hopt->rate.rate, hopt->buffer);
270 fprintf(f, "ceil %s ", sprint_rate(hopt->ceil.rate, b1));
271 cbuffer = tc_calc_xmitsize(hopt->ceil.rate, hopt->cbuffer);
275 1<<hopt->rate.cell_log,
276 sprint_size(hopt->rate.mpu&0xFF, b2),
277 sprint_size((hopt->rate.mpu>>8)&0xFF, b3));