[ovs-dev] [PATCH ovn 2/5] ovn-trace: Don't assert for next(stage=ingress, ..).
numans at ovn.org
numans at ovn.org
Mon Oct 5 17:49:19 UTC 2020
From: Numan Siddique <numans at ovn.org>
The commit [1] allowed next action to advance from ingress to egress pipeline, but
ovn-trace was not modified to handle this condition. Also corrected the ovntrace node
format message as per the next stage.
[1] - b4b68177eb2f("Fix conntrack entry leaks because of TCP RST packets not sent to conntrack.")
Fixes: b4b68177eb2f("Fix conntrack entry leaks because of TCP RST packets not sent to conntrack.")
Signed-off-by: Numan Siddique <numans at ovn.org>
---
utilities/ovn-trace.c | 13 ++++++++-----
1 file changed, 8 insertions(+), 5 deletions(-)
diff --git a/utilities/ovn-trace.c b/utilities/ovn-trace.c
index 33afc4f43c..0920ae1599 100644
--- a/utilities/ovn-trace.c
+++ b/utilities/ovn-trace.c
@@ -1888,12 +1888,15 @@ execute_next(const struct ovnact_next *next,
enum ovnact_pipeline pipeline, struct ovs_list *super)
{
if (pipeline != next->pipeline) {
- ovs_assert(next->pipeline == OVNACT_P_INGRESS);
-
- uint16_t in_key = uflow->regs[MFF_LOG_INPORT - MFF_REG0];
+ uint16_t key = next->pipeline == OVNACT_P_INGRESS
+ ? uflow->regs[MFF_LOG_INPORT - MFF_REG0]
+ : uflow->regs[MFF_LOG_OUTPORT - MFF_REG0];
struct ovntrace_node *node = ovntrace_node_append(
- super, OVNTRACE_NODE_PIPELINE, "ingress(dp=\"%s\", inport=\"%s\")",
- dp->friendly_name, ovntrace_port_key_to_name(dp, in_key));
+ super, OVNTRACE_NODE_PIPELINE, "%s(dp=\"%s\", %s=\"%s\")",
+ next->pipeline == OVNACT_P_INGRESS ? "ingress" : "egress",
+ dp->friendly_name,
+ next->pipeline == OVNACT_P_INGRESS ? "inport" : "outport",
+ ovntrace_port_key_to_name(dp, key));
super = &node->subs;
}
trace__(dp, uflow, next->ltable, next->pipeline, super);
--
2.26.2
More information about the dev
mailing list