Lines Matching refs:opt
63 struct tc_htb_glob opt; in htb_parse_opt() local
66 memset(&opt,0,sizeof(opt)); in htb_parse_opt()
67 opt.rate2quantum = 10; in htb_parse_opt()
68 opt.version = 3; in htb_parse_opt()
73 if (get_u32(&opt.rate2quantum, *argv, 10)) { in htb_parse_opt()
78 if (get_u32(&opt.defcls, *argv, 16)) { in htb_parse_opt()
85 opt.debug |= (*p-'0')<<(2*i); in htb_parse_opt()
96 addattr_l(n, 2024, TCA_HTB_INIT, &opt, NLMSG_ALIGN(sizeof(opt))); in htb_parse_opt()
104 struct tc_htb_opt opt; in htb_parse_class_opt() local
114 memset(&opt, 0, sizeof(opt)); mtu = 1600; /* eth packet len */ in htb_parse_class_opt()
119 if (get_u32(&opt.prio, *argv, 10)) { in htb_parse_class_opt()
145 if (get_u32(&opt.quantum, *argv, 10)) { in htb_parse_class_opt()
168 if (opt.ceil.rate) { in htb_parse_class_opt()
172 if (get_rate(&opt.ceil.rate, *argv)) { in htb_parse_class_opt()
179 if (opt.rate.rate) { in htb_parse_class_opt()
183 if (get_rate(&opt.rate.rate, *argv)) { in htb_parse_class_opt()
202 if (opt.rate.rate == 0) { in htb_parse_class_opt()
207 if (!opt.ceil.rate) opt.ceil = opt.rate; in htb_parse_class_opt()
211 if (!buffer) buffer = opt.rate.rate / get_hz() + mtu; in htb_parse_class_opt()
212 if (!cbuffer) cbuffer = opt.ceil.rate / get_hz() + mtu; in htb_parse_class_opt()
214 opt.ceil.overhead = overhead; in htb_parse_class_opt()
215 opt.rate.overhead = overhead; in htb_parse_class_opt()
217 opt.ceil.mpu = mpu; in htb_parse_class_opt()
218 opt.rate.mpu = mpu; in htb_parse_class_opt()
220 if (tc_calc_rtable(&opt.rate, rtab, cell_log, mtu, linklayer) < 0) { in htb_parse_class_opt()
224 opt.buffer = tc_calc_xmittime(opt.rate.rate, buffer); in htb_parse_class_opt()
226 if (tc_calc_rtable(&opt.ceil, ctab, ccell_log, mtu, linklayer) < 0) { in htb_parse_class_opt()
230 opt.cbuffer = tc_calc_xmittime(opt.ceil.rate, cbuffer); in htb_parse_class_opt()
234 addattr_l(n, 2024, TCA_HTB_PARMS, &opt, sizeof(opt)); in htb_parse_class_opt()
241 static int htb_print_opt(struct qdisc_util *qu, FILE *f, struct rtattr *opt) in htb_print_opt() argument
251 if (opt == NULL) in htb_print_opt()
254 parse_rtattr_nested(tb, TCA_HTB_RTAB, opt); in htb_print_opt()