diff -Nur iproute2.org/tc/q_esfq.c iproute2/tc/q_esfq.c --- iproute2.org/tc/q_esfq.c 2003-10-12 12:19:27.537543736 +0200 +++ iproute2/tc/q_esfq.c 2003-10-12 12:07:04.928437480 +0200 @@ -42,7 +42,7 @@ memset(&opt, 0, sizeof(opt)); - opt.hash_kind= TCA_SFQ_HASH_CLASSIC; +// opt.hash_kind= TCA_SFQ_HASH_CLASSIC; while (argc > 0) { if (strcmp(*argv, "quantum") == 0) { @@ -85,22 +85,22 @@ return -1; } ok++; - } else if (strcmp(*argv, "hash") == 0) { - NEXT_ARG(); - if(strcmp(*argv,"classic") == 0) { - opt.hash_kind= TCA_SFQ_HASH_CLASSIC; - } else - if(strcmp(*argv,"dst") == 0) { - opt.hash_kind= TCA_SFQ_HASH_DST; - } else - if(strcmp(*argv,"src") == 0) { - opt.hash_kind= TCA_SFQ_HASH_SRC; - } else { - fprintf(stderr, "Illegal \"hash\"\n"); - explain(); - return -1; - } - ok++; +// } else if (strcmp(*argv, "hash") == 0) { +// NEXT_ARG(); +// if(strcmp(*argv,"classic") == 0) { +// opt.hash_kind= TCA_SFQ_HASH_CLASSIC; +// } else +// if(strcmp(*argv,"dst") == 0) { +// opt.hash_kind= TCA_SFQ_HASH_DST; +// } else +// if(strcmp(*argv,"src") == 0) { +// opt.hash_kind= TCA_SFQ_HASH_SRC; +// } else { +// fprintf(stderr, "Illegal \"hash\"\n"); +// explain(); +// return -1; +// } +// ok++; } else if (strcmp(*argv, "help") == 0) { explain(); return -1; @@ -136,22 +136,22 @@ if (qopt->perturb_period) fprintf(f, "perturb %dsec ", qopt->perturb_period); - fprintf(f,"hash: "); - switch(qopt->hash_kind) - { - case TCA_SFQ_HASH_CLASSIC: - fprintf(f,"classic"); - break; - case TCA_SFQ_HASH_DST: - fprintf(f,"dst"); - break; - case TCA_SFQ_HASH_SRC: - fprintf(f,"src"); - break; - default: - fprintf(f,"Unknown"); - } - return 0; +// fprintf(f,"hash: "); +// switch(qopt->hash_kind) +// { +// case TCA_SFQ_HASH_CLASSIC: +// fprintf(f,"classic"); +// break; +// case TCA_SFQ_HASH_DST: +// fprintf(f,"dst"); +// break; +// case TCA_SFQ_HASH_SRC: +// fprintf(f,"src"); +// break; +// default: +// fprintf(f,"Unknown"); +// } +// return 0; } static int esfq_print_xstats(struct qdisc_util *qu, FILE *f, struct rtattr *xstats) diff -Nur iproute2.org/tc/q_htb.c iproute2/tc/q_htb.c --- iproute2.org/tc/q_htb.c 2003-10-12 12:19:27.462555136 +0200 +++ iproute2/tc/q_htb.c 2003-10-12 12:16:53.721927264 +0200 @@ -108,7 +108,8 @@ struct tc_htb_glob opt; struct rtattr *tail; unsigned i; char *p; - opt.rate2quantum = 10; opt.defcls = 1; opt.use_dcache = 0; + opt.rate2quantum = 10; opt.defcls = 1; +// opt.use_dcache = 0; opt.debug = 0; while (argc > 0) { @@ -128,8 +129,8 @@ if (*p<'0' || *p>'3') break; opt.debug |= (*p-'0')<<(2*i); } - } else if (matches(*argv, "dcache") == 0) { - opt.use_dcache = 1; +// } else if (matches(*argv, "dcache") == 0) { +// opt.use_dcache = 1; } else { fprintf(stderr, "What is \"%s\"?\n", *argv); explain(); @@ -154,7 +155,7 @@ struct rtattr *tail; memset(&opt, 0, sizeof(opt)); mtu = 1600; /* eth packet len */ - opt.injectd = 100; /* disable injecting */ +// opt.injectd = 100; /* disable injecting */ while (argc > 0) { if (matches(*argv, "prio") == 0) { @@ -168,11 +169,11 @@ if (get_u32(&mtu, *argv, 10)) { explain1("mtu"); return -1; } - } else if (matches(*argv, "inject") == 0) { - NEXT_ARG(); - if (get_u8(&opt.injectd, *argv, 10)) { - explain1("inject"); return -1; - } +// } else if (matches(*argv, "inject") == 0) { +// NEXT_ARG(); +// if (get_u8(&opt.injectd, *argv, 10)) { +// explain1("inject"); return -1; +// } } else if (matches(*argv, "burst") == 0 || strcmp(*argv, "buffer") == 0 || strcmp(*argv, "maxburst") == 0) { @@ -306,10 +307,10 @@ gopt = RTA_DATA(tb[TCA_HTB_INIT]); if (RTA_PAYLOAD(tb[TCA_HTB_INIT]) < sizeof(*gopt)) return -1; - fprintf(f, "r2q %d default %x dcache %d\n" - " deq_util 1/%d deq_rate %d trials_per_deq %d\n dcache_hits %u direct_packets %u", - gopt->rate2quantum,gopt->defcls,gopt->use_dcache,1000000/(1+gopt->utilz), - gopt->deq_rate, gopt->trials/(1+gopt->deq_rate),gopt->dcache_hits,gopt->direct_pkts); +// fprintf(f, "r2q %d default %x dcache %d\n" +// " deq_util 1/%d deq_rate %d trials_per_deq %d\n dcache_hits %u direct_packets %u", +// gopt->rate2quantum,gopt->defcls,gopt->use_dcache,1000000/(1+gopt->utilz), +// gopt->deq_rate, gopt->trials/(1+gopt->deq_rate),gopt->dcache_hits,gopt->direct_pkts); } return 0; } @@ -324,8 +325,8 @@ return -1; st = RTA_DATA(xstats); - fprintf(f, " lended: %u borrowed: %u giants: %u injects: %u\n", - st->lends,st->borrows,st->giants,st->injects); + fprintf(f, " lended: %u borrowed: %u giants: %u\n", + st->lends,st->borrows,st->giants); fprintf(f, " tokens: %d ctokens: %d\n", st->tokens,st->ctokens); return 0; }