* [PATCH iproute2 0/2] skbedit cleanup
@ 2013-12-21 21:38 Jamal Hadi Salim
2013-12-21 21:38 ` [PATCH iproute2 1/2] skbedit to default to pipe Jamal Hadi Salim
2013-12-21 21:38 ` [PATCH iproute2 2/2] skbedit print missing metadata Jamal Hadi Salim
0 siblings, 2 replies; 3+ messages in thread
From: Jamal Hadi Salim @ 2013-12-21 21:38 UTC (permalink / raw)
To: stephen, alexander.h.duyck; +Cc: netdev, Jamal Hadi Salim
These changes make skbedit behave similar to other actions
when printing stats and participating in an action chain for
a single flow
Jamal Hadi Salim (2):
[Iproute2: actions] skbedit to default to pipe
[Iproute2: actions] skbedit print missing metadata
tc/m_skbedit.c | 7 +++++++
1 file changed, 7 insertions(+)
--
1.7.9.5
^ permalink raw reply [flat|nested] 3+ messages in thread
* [PATCH iproute2 1/2] skbedit to default to pipe
2013-12-21 21:38 [PATCH iproute2 0/2] skbedit cleanup Jamal Hadi Salim
@ 2013-12-21 21:38 ` Jamal Hadi Salim
2013-12-21 21:38 ` [PATCH iproute2 2/2] skbedit print missing metadata Jamal Hadi Salim
1 sibling, 0 replies; 3+ messages in thread
From: Jamal Hadi Salim @ 2013-12-21 21:38 UTC (permalink / raw)
To: stephen, alexander.h.duyck; +Cc: netdev, Jamal Hadi Salim
Allow skbedit to be used as is in an action chain by default
without need to specify pipe
Signed-off-by: Jamal Hadi Salim <jhs@mojatatu.com>
---
tc/m_skbedit.c | 1 +
1 file changed, 1 insertion(+)
diff --git a/tc/m_skbedit.c b/tc/m_skbedit.c
index cca05ed..6b582f3 100644
--- a/tc/m_skbedit.c
+++ b/tc/m_skbedit.c
@@ -99,6 +99,7 @@ parse_skbedit(struct action_util *a, int *argc_p, char ***argv_p, int tca_id,
argv++;
}
+ sel.action = TC_ACT_PIPE;
if (argc) {
if (matches(*argv, "reclassify") == 0) {
sel.action = TC_ACT_RECLASSIFY;
--
1.7.9.5
^ permalink raw reply related [flat|nested] 3+ messages in thread
* [PATCH iproute2 2/2] skbedit print missing metadata
2013-12-21 21:38 [PATCH iproute2 0/2] skbedit cleanup Jamal Hadi Salim
2013-12-21 21:38 ` [PATCH iproute2 1/2] skbedit to default to pipe Jamal Hadi Salim
@ 2013-12-21 21:38 ` Jamal Hadi Salim
1 sibling, 0 replies; 3+ messages in thread
From: Jamal Hadi Salim @ 2013-12-21 21:38 UTC (permalink / raw)
To: stephen, alexander.h.duyck; +Cc: netdev, Jamal Hadi Salim
skbedit should print the index and other generic metadata info
Signed-off-by: Jamal Hadi Salim <jhs@mojatatu.com>
---
tc/m_skbedit.c | 6 ++++++
1 file changed, 6 insertions(+)
diff --git a/tc/m_skbedit.c b/tc/m_skbedit.c
index 6b582f3..4b4ee06 100644
--- a/tc/m_skbedit.c
+++ b/tc/m_skbedit.c
@@ -165,6 +165,7 @@ static int print_skbedit(struct action_util *au, FILE *f, struct rtattr *arg)
__u32 *priority;
__u32 *mark;
__u16 *queue_mapping;
+ struct tc_skbedit *p = NULL;
if (arg == NULL)
return -1;
@@ -175,6 +176,7 @@ static int print_skbedit(struct action_util *au, FILE *f, struct rtattr *arg)
fprintf(f, "[NULL skbedit parameters]");
return -1;
}
+ p = RTA_DATA(tb[TCA_SKBEDIT_PARMS]);
fprintf(f, " skbedit");
@@ -191,6 +193,8 @@ static int print_skbedit(struct action_util *au, FILE *f, struct rtattr *arg)
fprintf(f, " mark %d", *mark);
}
+ fprintf(f, "\n\t index %d ref %d bind %d", p->index, p->refcnt, p->bindcnt);
+
if (show_stats) {
if (tb[TCA_SKBEDIT_TM]) {
struct tcf_t *tm = RTA_DATA(tb[TCA_SKBEDIT_TM]);
@@ -198,6 +202,8 @@ static int print_skbedit(struct action_util *au, FILE *f, struct rtattr *arg)
}
}
+ fprintf(f, "\n ");
+
return 0;
}
--
1.7.9.5
^ permalink raw reply related [flat|nested] 3+ messages in thread
end of thread, other threads:[~2013-12-21 21:39 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2013-12-21 21:38 [PATCH iproute2 0/2] skbedit cleanup Jamal Hadi Salim
2013-12-21 21:38 ` [PATCH iproute2 1/2] skbedit to default to pipe Jamal Hadi Salim
2013-12-21 21:38 ` [PATCH iproute2 2/2] skbedit print missing metadata Jamal Hadi Salim
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).