DPDK patches and discussions
 help / color / mirror / Atom feed
* [dpdk-dev] RTE_PIPELINE_ACTION_PORT_META doesn't work properly
@ 2015-02-20 16:25 Ильдар Мустафин
  2015-02-20 19:26 ` Dumitrescu, Cristian
  0 siblings, 1 reply; 4+ messages in thread
From: Ильдар Мустафин @ 2015-02-20 16:25 UTC (permalink / raw)
  To: dev

 Hi, list!

RTE_PIPELINE_ACTION_PORT_META option in rte_pipeline library doesn't work for non-default table entries. Is this bug or correct behaviour?

This is my patch, that changes this behaviour:

--- a/lib/librte_pipeline/rte_pipeline.c
+++ b/lib/librte_pipeline/rte_pipeline.c
@@ -999,8 +999,10 @@ rte_pipeline_compute_masks(struct rte_pipeline *p, uint64_t pkts_mask)
 {
        p->action_mask1[RTE_PIPELINE_ACTION_DROP] = 0;
        p->action_mask1[RTE_PIPELINE_ACTION_PORT] = 0;
+    p->action_mask1[RTE_PIPELINE_ACTION_PORT_META] = 0;
        p->action_mask1[RTE_PIPELINE_ACTION_TABLE] = 0;
 
+
        if ((pkts_mask & (pkts_mask + 1)) == 0) {
                uint64_t n_pkts = __builtin_popcountll(pkts_mask);
                uint32_t i;
@@ -1224,6 +1226,7 @@ rte_pipeline_run(struct rte_pipeline *p)
                pkts_mask = RTE_LEN2MASK(n_pkts, uint64_t);
                p->action_mask0[RTE_PIPELINE_ACTION_DROP] = 0;
                p->action_mask0[RTE_PIPELINE_ACTION_PORT] = 0;
+        p->action_mask0[RTE_PIPELINE_ACTION_PORT_META] = 0;
                p->action_mask0[RTE_PIPELINE_ACTION_TABLE] = 0;
 
                /* Input port user actions */
@@ -1300,6 +1303,9 @@ rte_pipeline_run(struct rte_pipeline *p)
                                p->action_mask0[RTE_PIPELINE_ACTION_PORT] |=
                                        p->action_mask1[
                                                RTE_PIPELINE_ACTION_PORT];
+                p->action_mask0[RTE_PIPELINE_ACTION_PORT_META] |=
+                    p->action_mask1[
+                        RTE_PIPELINE_ACTION_PORT_META];
                                p->action_mask0[RTE_PIPELINE_ACTION_TABLE] |=
                                        p->action_mask1[
                                                RTE_PIPELINE_ACTION_TABLE];





Thanks, Ildar


^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2015-02-20 20:55 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2015-02-20 16:25 [dpdk-dev] RTE_PIPELINE_ACTION_PORT_META doesn't work properly Ильдар Мустафин
2015-02-20 19:26 ` Dumitrescu, Cristian
2015-02-20 20:47   ` Thomas Monjalon
2015-02-20 20:55     ` Dumitrescu, Cristian

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).