Lines Matching defs:lss
53 struct tc_cbq_lssopt lss;
62 memset(&lss, 0, sizeof(lss));
161 lss.ewma_log = ewma_log;
162 lss.maxidle = tc_calc_xmittime(r.rate, avpkt);
163 lss.change = TCF_CBQ_LSS_MAXIDLE|TCF_CBQ_LSS_EWMA|TCF_CBQ_LSS_AVPKT;
164 lss.avpkt = avpkt;
169 addattr_l(n, 1024, TCA_CBQ_LSSOPT, &lss, sizeof(lss));
185 struct tc_cbq_lssopt lss;
200 memset(&lss, 0, sizeof(lss));
220 if (get_u32(&lss.minidle, *argv, 0)) {
224 lss.change |= TCF_CBQ_LSS_MINIDLE;
231 lss.change |= TCF_CBQ_LSS_OFFTIME;
238 lss.change |= TCF_CBQ_LSS_MAXIDLE;
240 lss.flags |= TCF_CBQ_LSS_BOUNDED;
241 lss.change |= TCF_CBQ_LSS_FLAGS;
243 lss.flags &= ~TCF_CBQ_LSS_BOUNDED;
244 lss.change |= TCF_CBQ_LSS_FLAGS;
246 lss.flags |= TCF_CBQ_LSS_ISOLATED;
247 lss.change |= TCF_CBQ_LSS_FLAGS;
249 lss.flags &= ~TCF_CBQ_LSS_ISOLATED;
250 lss.change |= TCF_CBQ_LSS_FLAGS;
261 lss.change |= TCF_CBQ_LSS_EWMA;
299 if (get_size(&lss.avpkt, *argv)) {
303 lss.change |= TCF_CBQ_LSS_AVPKT;
361 if (wrr.allot < (lss.avpkt*3)/2)
362 wrr.allot = (lss.avpkt*3)/2;
372 lss.ewma_log = ewma_log;
373 if (lss.change&(TCF_CBQ_LSS_OFFTIME|TCF_CBQ_LSS_MAXIDLE)) {
374 if (lss.avpkt == 0) {
387 wrr.allot = (lss.avpkt*3)/2;
397 if (lss.change&TCF_CBQ_LSS_MAXIDLE) {
398 lss.maxidle = tc_cbq_calc_maxidle(bndw, r.rate, lss.avpkt, ewma_log, maxburst);
399 lss.change |= TCF_CBQ_LSS_MAXIDLE;
400 lss.change |= TCF_CBQ_LSS_EWMA|TCF_CBQ_LSS_AVPKT;
402 if (lss.change&TCF_CBQ_LSS_OFFTIME) {
403 lss.offtime = tc_cbq_calc_offtime(bndw, r.rate, lss.avpkt, ewma_log, minburst);
404 lss.change |= TCF_CBQ_LSS_OFFTIME;
405 lss.change |= TCF_CBQ_LSS_EWMA|TCF_CBQ_LSS_AVPKT;
407 if (lss.change&TCF_CBQ_LSS_MINIDLE) {
408 lss.minidle <<= lss.ewma_log;
409 lss.change |= TCF_CBQ_LSS_EWMA;
414 if (lss.change) {
415 lss.change |= TCF_CBQ_LSS_FLAGS;
416 addattr_l(n, 1024, TCA_CBQ_LSSOPT, &lss, sizeof(lss));
441 struct tc_cbq_lssopt *lss = NULL;
461 if (RTA_PAYLOAD(tb[TCA_CBQ_LSSOPT]) < sizeof(*lss))
462 fprintf(stderr, "CBQ: too short lss opt\n");
464 lss = RTA_DATA(tb[TCA_CBQ_LSSOPT]);
502 if (lss && lss->flags) {
505 if (lss->flags&TCF_CBQ_LSS_BOUNDED) {
509 if (lss->flags&TCF_CBQ_LSS_ISOLATED) {
532 if (lss && show_details) {
533 fprintf(f, "\nlevel %u ewma %u avpkt %ub ", lss->level, lss->ewma_log, lss->avpkt);
534 if (lss->maxidle) {
535 fprintf(f, "maxidle %s ", sprint_ticks(lss->maxidle>>lss->ewma_log, b1));
537 fprintf(f, "[%08x] ", lss->maxidle);
539 if (lss->minidle!=0x7fffffff) {
540 fprintf(f, "minidle %s ", sprint_ticks(lss->minidle>>lss->ewma_log, b1));
542 fprintf(f, "[%08x] ", lss->minidle);
544 if (lss->offtime) {
545 fprintf(f, "offtime %s ", sprint_ticks(lss->offtime, b1));
547 fprintf(f, "[%08x] ", lss->offtime);