summaryrefslogtreecommitdiff
path: root/datapath-windows/ovsext/Actions.c
diff options
context:
space:
mode:
authorYin Lin <linyi@vmware.com>2017-04-20 15:26:08 -0700
committerGurucharan Shetty <guru@ovn.org>2017-04-21 10:06:03 -0700
commitae584afe5d2b62eda6623f73bd9b34bbf9365651 (patch)
treea047ab7715adc5bec59651694642e60707a4edfb /datapath-windows/ovsext/Actions.c
parent42c1e58e2952982568290a6e2fe9a6a84c355912 (diff)
downloadopenvswitch-ae584afe5d2b62eda6623f73bd9b34bbf9365651.tar.gz
datapath-windows: Pass fwdCtx to conntrack
There are dependencies in Contrack module such as NAT and fragmentation on OvsForwardingContext. This patch will make OvsForwardingContext public in order to implement these functionalities. Signed-off-by: Yin Lin <linyi@vmware.com> Acked-by: Alin Serdean <aserdean@cloudbasesolutions.com> Signed-off-by: Gurucharan Shetty <guru@ovn.org>
Diffstat (limited to 'datapath-windows/ovsext/Actions.c')
-rw-r--r--datapath-windows/ovsext/Actions.c61
1 files changed, 2 insertions, 59 deletions
diff --git a/datapath-windows/ovsext/Actions.c b/datapath-windows/ovsext/Actions.c
index 46f84bc74..3bd00a727 100644
--- a/datapath-windows/ovsext/Actions.c
+++ b/datapath-windows/ovsext/Actions.c
@@ -71,63 +71,6 @@ typedef struct _OVS_ACTION_STATS {
OVS_ACTION_STATS ovsActionStats;
/*
- * There a lot of data that needs to be maintained while executing the pipeline
- * as dictated by the actions of a flow, across different functions at different
- * levels. Such data is put together in a 'context' structure. Care should be
- * exercised while adding new members to the structure - only add ones that get
- * used across multiple stages in the pipeline/get used in multiple functions.
- */
-typedef struct OvsForwardingContext {
- POVS_SWITCH_CONTEXT switchContext;
- /* The NBL currently used in the pipeline. */
- PNET_BUFFER_LIST curNbl;
- /* NDIS forwarding detail for 'curNbl'. */
- PNDIS_SWITCH_FORWARDING_DETAIL_NET_BUFFER_LIST_INFO fwdDetail;
- /* Array of destination ports for 'curNbl'. */
- PNDIS_SWITCH_FORWARDING_DESTINATION_ARRAY destinationPorts;
- /* send flags while sending 'curNbl' into NDIS. */
- ULONG sendFlags;
- /* Total number of output ports, used + unused, in 'curNbl'. */
- UINT32 destPortsSizeIn;
- /* Total number of used output ports in 'curNbl'. */
- UINT32 destPortsSizeOut;
- /*
- * If 'curNbl' is not owned by OVS, they need to be tracked, if they need to
- * be freed/completed.
- */
- OvsCompletionList *completionList;
- /*
- * vport number of 'curNbl' when it is passed from the PIF bridge to the INT
- * bridge. ie. during tunneling on the Rx side.
- */
- UINT32 srcVportNo;
-
- /*
- * Tunnel key:
- * - specified in actions during tunneling Tx
- * - extracted from an NBL during tunneling Rx
- */
- OvsIPv4TunnelKey tunKey;
-
- /*
- * Tunneling - Tx:
- * To store the output port, when it is a tunneled port. We don't foresee
- * multiple tunneled ports as outport for any given NBL.
- */
- POVS_VPORT_ENTRY tunnelTxNic;
-
- /*
- * Tunneling - Rx:
- * Points to the Internal port on the PIF Bridge, if the packet needs to be
- * de-tunneled.
- */
- POVS_VPORT_ENTRY tunnelRxNic;
-
- /* header information */
- OVS_PACKET_HDR_INFO layers;
-} OvsForwardingContext;
-
-/*
* --------------------------------------------------------------------------
* OvsInitForwardingCtx --
* Function to init/re-init the 'ovsFwdCtx' context as the actions pipeline
@@ -2032,8 +1975,8 @@ OvsDoExecuteActions(POVS_SWITCH_CONTEXT switchContext,
}
}
- status = OvsExecuteConntrackAction(ovsFwdCtx.curNbl, layers,
- key, (const PNL_ATTR)a);
+ status = OvsExecuteConntrackAction(&ovsFwdCtx, key,
+ (const PNL_ATTR)a);
if (status != NDIS_STATUS_SUCCESS) {
OVS_LOG_ERROR("CT Action failed");
dropReason = L"OVS-conntrack action failed";