Skip to contentSkip to conversation

ip_pipeline: add flow actions pipeline

PATCH In review Jasvinder Singh 2 participants 2 messages Sep 30, 2015

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 ip_pipeline: add flow actions pipeline

Flow actions pipeline is an extension of
flow-classification pipeline. Some of the
operations of flow classification pipeline such
as traffic metering/marking(for e.g. Single
Rate Three Color Marker (srTCM), Two Rate Three
Color Marker trTCM)), policer can be performed
separately in flow action pipeline to avoid
excessive computational burden on the CPU core
running the flow-classification pipeline. The
Flow action pipeline implements various
function such as traffic metering, policer,
stats. Traffic mettering can configured as
per the required context, for examples- per
user, per traffic class or both. These
contexts can be applied by specifying
parameters in configuration file as shown
below;

[PIPELINE1]
type = FLOW_ACTIONS
core = 1
pktq_in = RXQ0.0 RXQ1.0 RXQ2.0 RXQ3.0
pktq_out = TXQ0.0 TXQ1.0 TXQ2.0 TXQ3.0
n_flows = 65536
n_meters_per_flow = 1
flow_id_offset = 158
ip_hdr_offset = 142
color_offset = 64

The entries of flow and dscp tables of flow
actions pipeline can be modified through
command-line interface. The commands to
add or delete entries to the flow table,
DSCP(differentiated services code point) table
and for statistics collection, etc have been
included. The key functions such as
Traffic Metering/marking and policer functions
have been implemented as flow-table action
handler.

---
 examples/ip_pipeline/Makefile                      |    2 +
 examples/ip_pipeline/init.c                        |    2 +
 .../ip_pipeline/pipeline/pipeline_actions_common.h |   83 +
 .../ip_pipeline/pipeline/pipeline_flow_actions.c   | 1808 ++++++++++++++++++++
 .../ip_pipeline/pipeline/pipeline_flow_actions.h   |   78 +
 .../pipeline/pipeline_flow_actions_be.c            |  973 +++++++++++
 .../pipeline/pipeline_flow_actions_be.h            |  168 ++
 7 files changed, 3114 insertions(+)
 create mode 100644 examples/ip_pipeline/pipeline/pipeline_flow_actions.c
 create mode 100644 examples/ip_pipeline/pipeline/pipeline_flow_actions.h
 create mode 100644 examples/ip_pipeline/pipeline/pipeline_flow_actions_be.c
 create mode 100644 examples/ip_pipeline/pipeline/pipeline_flow_actions_be.h
examples/ip_pipeline/Makefile +2 -0
index f3ff1ec..13d31de 100644
@@ -66,6 +66,8 @@ SRCS-$(CONFIG_RTE_LIBRTE_PIPELINE) += pipeline_firewall_be.c
 SRCS-$(CONFIG_RTE_LIBRTE_PIPELINE) += pipeline_firewall.c
 SRCS-$(CONFIG_RTE_LIBRTE_PIPELINE) += pipeline_flow_classification_be.c
 SRCS-$(CONFIG_RTE_LIBRTE_PIPELINE) += pipeline_flow_classification.c
+SRCS-$(CONFIG_RTE_LIBRTE_PIPELINE) += pipeline_flow_actions_be.c
+SRCS-$(CONFIG_RTE_LIBRTE_PIPELINE) += pipeline_flow_actions.c
 SRCS-$(CONFIG_RTE_LIBRTE_PIPELINE) += pipeline_routing_be.c
 SRCS-$(CONFIG_RTE_LIBRTE_PIPELINE) += pipeline_routing.c
 
examples/ip_pipeline/init.c +2 -0
index 3f9c68d..0088ece 100644
@@ -49,6 +49,7 @@
 #include "pipeline_passthrough.h"
 #include "pipeline_firewall.h"
 #include "pipeline_flow_classification.h"
+#include "pipeline_flow_actions.h"
 #include "pipeline_routing.h"
 
 #define APP_NAME_SIZE	32
@@ -1291,6 +1292,7 @@ int app_init(struct app_params *app)
 	app_pipeline_type_register(app, &pipeline_master);
 	app_pipeline_type_register(app, &pipeline_passthrough);
 	app_pipeline_type_register(app, &pipeline_flow_classification);
+	app_pipeline_type_register(app, &pipeline_flow_actions);
 	app_pipeline_type_register(app, &pipeline_firewall);
 	app_pipeline_type_register(app, &pipeline_routing);
 
examples/ip_pipeline/pipeline/pipeline_actions_common.h +83 -0

87 lines not on this page · raw message

examples/ip_pipeline/pipeline/pipeline_flow_actions.c new file +1808 -0

1,808 lines not on this page · raw message

examples/ip_pipeline/pipeline/pipeline_flow_actions.h new file +78 -0

78 lines not on this page · raw message

examples/ip_pipeline/pipeline/pipeline_flow_actions_be.c new file +973 -0

973 lines not on this page · raw message

examples/ip_pipeline/pipeline/pipeline_flow_actions_be.h new file +168 -0

32 lines not on this page · raw message

The rest of this diff is not shown. View the raw message.

Signature · 1 line
2.1.0

Part of the diff is not shown here. View the raw message.

Acked-by on v1 1/1
#1 lore raw
Quoted 25 lines

-----Original Message-----
From: Singh, Jasvinder
Sent: Wednesday, September 30, 2015 6:06 PM
To: [email protected]
Cc: Dumitrescu, Cristian
Subject: [PATCH] ip_pipeline: add flow actions pipeline

---
 examples/ip_pipeline/Makefile                      |    2 +
 examples/ip_pipeline/init.c                        |    2 +
 .../ip_pipeline/pipeline/pipeline_actions_common.h |   83 +
 .../ip_pipeline/pipeline/pipeline_flow_actions.c   | 1808
++++++++++++++++++++
 .../ip_pipeline/pipeline/pipeline_flow_actions.h   |   78 +
 .../pipeline/pipeline_flow_actions_be.c            |  973 +++++++++++
 .../pipeline/pipeline_flow_actions_be.h            |  168 ++
 7 files changed, 3114 insertions(+)
 create mode 100644 examples/ip_pipeline/pipeline/pipeline_flow_actions.c
 create mode 100644 examples/ip_pipeline/pipeline/pipeline_flow_actions.h
 create mode 100644
examples/ip_pipeline/pipeline/pipeline_flow_actions_be.c
 create mode 100644
Quoted 1 line

examples/ip_pipeline/pipeline/pipeline_flow_actions_be.h