tc: pass correct conversion specifier to print 'unsigned int' action index.
Signed-off-by: Roman Mashak <mrv@mojatatu.com> Signed-off-by: Jamal Hadi Salim <jhs@mojatatu.com>
This commit is contained in:
parent
ab91aee4b0
commit
530753184a
|
|
@ -178,7 +178,7 @@ static int bpf_print_opt(struct action_util *au, FILE *f, struct rtattr *arg)
|
||||||
}
|
}
|
||||||
|
|
||||||
fprintf(f, "default-action %s\n", action_n2a(parm->action));
|
fprintf(f, "default-action %s\n", action_n2a(parm->action));
|
||||||
fprintf(f, "\tindex %d ref %d bind %d", parm->index, parm->refcnt,
|
fprintf(f, "\tindex %u ref %d bind %d", parm->index, parm->refcnt,
|
||||||
parm->bindcnt);
|
parm->bindcnt);
|
||||||
|
|
||||||
if (show_stats) {
|
if (show_stats) {
|
||||||
|
|
|
||||||
|
|
@ -123,7 +123,7 @@ static int print_connmark(struct action_util *au, FILE *f, struct rtattr *arg)
|
||||||
ci = RTA_DATA(tb[TCA_CONNMARK_PARMS]);
|
ci = RTA_DATA(tb[TCA_CONNMARK_PARMS]);
|
||||||
|
|
||||||
fprintf(f, " connmark zone %d\n", ci->zone);
|
fprintf(f, " connmark zone %d\n", ci->zone);
|
||||||
fprintf(f, "\t index %d ref %d bind %d", ci->index,
|
fprintf(f, "\t index %u ref %d bind %d", ci->index,
|
||||||
ci->refcnt, ci->bindcnt);
|
ci->refcnt, ci->bindcnt);
|
||||||
|
|
||||||
if (show_stats) {
|
if (show_stats) {
|
||||||
|
|
|
||||||
|
|
@ -199,7 +199,8 @@ print_csum(struct action_util *au, FILE *f, struct rtattr *arg)
|
||||||
uflag_1, uflag_2, uflag_3,
|
uflag_1, uflag_2, uflag_3,
|
||||||
uflag_4, uflag_5, uflag_6,
|
uflag_4, uflag_5, uflag_6,
|
||||||
action_n2a(sel->action));
|
action_n2a(sel->action));
|
||||||
fprintf(f, "\tindex %d ref %d bind %d", sel->index, sel->refcnt, sel->bindcnt);
|
fprintf(f, "\tindex %u ref %d bind %d", sel->index, sel->refcnt,
|
||||||
|
sel->bindcnt);
|
||||||
|
|
||||||
if (show_stats) {
|
if (show_stats) {
|
||||||
if (tb[TCA_CSUM_TM]) {
|
if (tb[TCA_CSUM_TM]) {
|
||||||
|
|
|
||||||
|
|
@ -224,7 +224,8 @@ print_gact(struct action_util *au, FILE * f, struct rtattr *arg)
|
||||||
fprintf(f, "\n\t random type %s %s val %d",
|
fprintf(f, "\n\t random type %s %s val %d",
|
||||||
prob_n2a(pp->ptype), action_n2a(pp->paction), pp->pval);
|
prob_n2a(pp->ptype), action_n2a(pp->paction), pp->pval);
|
||||||
#endif
|
#endif
|
||||||
fprintf(f, "\n\t index %d ref %d bind %d", p->index, p->refcnt, p->bindcnt);
|
fprintf(f, "\n\t index %u ref %d bind %d", p->index, p->refcnt,
|
||||||
|
p->bindcnt);
|
||||||
if (show_stats) {
|
if (show_stats) {
|
||||||
if (tb[TCA_GACT_TM]) {
|
if (tb[TCA_GACT_TM]) {
|
||||||
struct tcf_t *tm = RTA_DATA(tb[TCA_GACT_TM]);
|
struct tcf_t *tm = RTA_DATA(tb[TCA_GACT_TM]);
|
||||||
|
|
|
||||||
|
|
@ -312,7 +312,7 @@ static int print_ife(struct action_util *au, FILE *f, struct rtattr *arg)
|
||||||
sizeof(b2)));
|
sizeof(b2)));
|
||||||
}
|
}
|
||||||
|
|
||||||
fprintf(f, "\n\t index %d ref %d bind %d", p->index, p->refcnt,
|
fprintf(f, "\n\t index %u ref %d bind %d", p->index, p->refcnt,
|
||||||
p->bindcnt);
|
p->bindcnt);
|
||||||
if (show_stats) {
|
if (show_stats) {
|
||||||
if (tb[TCA_IFE_TM]) {
|
if (tb[TCA_IFE_TM]) {
|
||||||
|
|
|
||||||
|
|
@ -489,7 +489,7 @@ print_ipt(struct action_util *au, FILE * f, struct rtattr *arg)
|
||||||
__u32 index;
|
__u32 index;
|
||||||
|
|
||||||
index = rta_getattr_u32(tb[TCA_IPT_INDEX]);
|
index = rta_getattr_u32(tb[TCA_IPT_INDEX]);
|
||||||
fprintf(f, "\n\tindex %d", index);
|
fprintf(f, "\n\tindex %u", index);
|
||||||
}
|
}
|
||||||
|
|
||||||
if (tb[TCA_IPT_CNT]) {
|
if (tb[TCA_IPT_CNT]) {
|
||||||
|
|
|
||||||
|
|
@ -276,7 +276,8 @@ print_mirred(struct action_util *au, FILE * f, struct rtattr *arg)
|
||||||
mirred_n2a(p->eaction), dev, action_n2a(p->action));
|
mirred_n2a(p->eaction), dev, action_n2a(p->action));
|
||||||
|
|
||||||
fprintf(f, "\n ");
|
fprintf(f, "\n ");
|
||||||
fprintf(f, "\tindex %d ref %d bind %d", p->index, p->refcnt, p->bindcnt);
|
fprintf(f, "\tindex %u ref %d bind %d", p->index, p->refcnt,
|
||||||
|
p->bindcnt);
|
||||||
|
|
||||||
if (show_stats) {
|
if (show_stats) {
|
||||||
if (tb[TCA_MIRRED_TM]) {
|
if (tb[TCA_MIRRED_TM]) {
|
||||||
|
|
|
||||||
|
|
@ -527,7 +527,7 @@ int print_pedit(struct action_util *au, FILE *f, struct rtattr *arg)
|
||||||
|
|
||||||
fprintf(f, " pedit action %s keys %d\n ",
|
fprintf(f, " pedit action %s keys %d\n ",
|
||||||
action_n2a(sel->action), sel->nkeys);
|
action_n2a(sel->action), sel->nkeys);
|
||||||
fprintf(f, "\t index %d ref %d bind %d", sel->index, sel->refcnt,
|
fprintf(f, "\t index %u ref %d bind %d", sel->index, sel->refcnt,
|
||||||
sel->bindcnt);
|
sel->bindcnt);
|
||||||
|
|
||||||
if (show_stats) {
|
if (show_stats) {
|
||||||
|
|
|
||||||
|
|
@ -187,7 +187,7 @@ static int print_simple(struct action_util *au, FILE *f, struct rtattr *arg)
|
||||||
simpdata = RTA_DATA(tb[TCA_DEF_DATA]);
|
simpdata = RTA_DATA(tb[TCA_DEF_DATA]);
|
||||||
|
|
||||||
fprintf(f, "Simple <%s>\n", simpdata);
|
fprintf(f, "Simple <%s>\n", simpdata);
|
||||||
fprintf(f, "\t index %d ref %d bind %d", sel->index,
|
fprintf(f, "\t index %u ref %d bind %d", sel->index,
|
||||||
sel->refcnt, sel->bindcnt);
|
sel->refcnt, sel->bindcnt);
|
||||||
|
|
||||||
if (show_stats) {
|
if (show_stats) {
|
||||||
|
|
|
||||||
|
|
@ -214,7 +214,7 @@ static int print_skbedit(struct action_util *au, FILE *f, struct rtattr *arg)
|
||||||
fprintf(f, " ptype %d", *ptype);
|
fprintf(f, " ptype %d", *ptype);
|
||||||
}
|
}
|
||||||
|
|
||||||
fprintf(f, "\n\t index %d ref %d bind %d",
|
fprintf(f, "\n\t index %u ref %d bind %d",
|
||||||
p->index, p->refcnt, p->bindcnt);
|
p->index, p->refcnt, p->bindcnt);
|
||||||
|
|
||||||
if (show_stats) {
|
if (show_stats) {
|
||||||
|
|
|
||||||
|
|
@ -237,7 +237,7 @@ static int print_skbmod(struct action_util *au, FILE *f, struct rtattr *arg)
|
||||||
if (p->flags & SKBMOD_F_SWAPMAC)
|
if (p->flags & SKBMOD_F_SWAPMAC)
|
||||||
fprintf(f, "swap mac ");
|
fprintf(f, "swap mac ");
|
||||||
|
|
||||||
fprintf(f, "\n\t index %d ref %d bind %d", p->index, p->refcnt,
|
fprintf(f, "\n\t index %u ref %d bind %d", p->index, p->refcnt,
|
||||||
p->bindcnt);
|
p->bindcnt);
|
||||||
if (show_stats) {
|
if (show_stats) {
|
||||||
if (tb[TCA_SKBMOD_TM]) {
|
if (tb[TCA_SKBMOD_TM]) {
|
||||||
|
|
|
||||||
|
|
@ -226,7 +226,7 @@ static int print_vlan(struct action_util *au, FILE *f, struct rtattr *arg)
|
||||||
}
|
}
|
||||||
fprintf(f, " %s", action_n2a(parm->action));
|
fprintf(f, " %s", action_n2a(parm->action));
|
||||||
|
|
||||||
fprintf(f, "\n\t index %d ref %d bind %d", parm->index, parm->refcnt,
|
fprintf(f, "\n\t index %u ref %d bind %d", parm->index, parm->refcnt,
|
||||||
parm->bindcnt);
|
parm->bindcnt);
|
||||||
|
|
||||||
if (show_stats) {
|
if (show_stats) {
|
||||||
|
|
|
||||||
|
|
@ -372,7 +372,7 @@ print_ipt(struct action_util *au, FILE *f, struct rtattr *arg)
|
||||||
__u32 index;
|
__u32 index;
|
||||||
|
|
||||||
index = rta_getattr_u32(tb[TCA_IPT_INDEX]);
|
index = rta_getattr_u32(tb[TCA_IPT_INDEX]);
|
||||||
fprintf(f, "\n\tindex %d", index);
|
fprintf(f, "\n\tindex %u", index);
|
||||||
}
|
}
|
||||||
|
|
||||||
if (tb[TCA_IPT_CNT]) {
|
if (tb[TCA_IPT_CNT]) {
|
||||||
|
|
|
||||||
|
|
@ -412,7 +412,7 @@ print_ipt(struct action_util *au, FILE * f, struct rtattr *arg)
|
||||||
__u32 index;
|
__u32 index;
|
||||||
|
|
||||||
index = rta_getattr_u32(tb[TCA_IPT_INDEX]);
|
index = rta_getattr_u32(tb[TCA_IPT_INDEX]);
|
||||||
fprintf(f, "\n\tindex %d", index);
|
fprintf(f, "\n\tindex %u", index);
|
||||||
}
|
}
|
||||||
|
|
||||||
if (tb[TCA_IPT_CNT]) {
|
if (tb[TCA_IPT_CNT]) {
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue