Home | History | Annotate | Download | only in tc

Lines Matching refs:opt

41 	struct tc_sfq_qopt_v1 opt = {};
50 if (get_size(&opt.v0.quantum, *argv)) {
57 if (get_integer(&opt.v0.perturb_period, *argv, 0)) {
64 if (get_u32(&opt.v0.limit, *argv, 0)) {
68 if (opt.v0.limit < 2) {
75 if (get_u32(&opt.v0.divisor, *argv, 0)) {
82 if (get_u32(&opt.v0.flows, *argv, 0)) {
89 if (get_u32(&opt.depth, *argv, 0)) {
95 opt.headdrop = 1;
99 if (get_u32(&opt.limit, *argv, 0)) {
106 if (get_u32(&opt.qth_min, *argv, 0)) {
113 if (get_u32(&opt.qth_max, *argv, 0)) {
140 opt.flags |= TC_RED_ECN;
143 opt.flags |= TC_RED_HARDDROP;
156 if (!opt.limit) {
164 if (!opt.qth_max)
165 opt.qth_max = opt.limit / 4;
166 if (!opt.qth_min)
167 opt.qth_min = opt.qth_max / 3;
169 burst = (2 * opt.qth_min + opt.qth_max) / (3 * avpkt);
171 if (opt.qth_max > opt.limit) {
176 if (opt.qth_min >= opt.qth_max) {
181 wlog = tc_red_eval_ewma(opt.qth_min, burst, avpkt);
188 opt.Wlog = wlog;
190 wlog = tc_red_eval_P(opt.qth_min, opt.qth_max, probability);
195 opt.Plog = wlog;
196 opt.max_P = probability * pow(2, 32);
200 addattr_l(n, 1024, TCA_OPTIONS, &opt, sizeof(opt));
204 static int sfq_print_opt(struct qdisc_util *qu, FILE *f, struct rtattr *opt)
212 if (opt == NULL)
215 if (RTA_PAYLOAD(opt) < sizeof(*qopt))
217 if (RTA_PAYLOAD(opt) >= sizeof(*qopt_ext))
218 qopt_ext = RTA_DATA(opt);
219 qopt = RTA_DATA(opt);