From f23d28456f4ce2c4720a9c100ceff828b79c2360 Mon Sep 17 00:00:00 2001 From: Ben Pfaff Date: Mon, 26 Dec 2011 14:42:48 -0800 Subject: [PATCH] dpif: Log each operation in dpif_operate(). Without logging of operation groups, it becomes more difficult to debug problems related to flow setups, since those go through operation groups. Signed-off-by: Ben Pfaff --- lib/dpif.c | 14 ++++++++++++++ 1 file changed, 14 insertions(+) diff --git a/lib/dpif.c b/lib/dpif.c index d8134698a..37c001285 100644 --- a/lib/dpif.c +++ b/lib/dpif.c @@ -992,6 +992,20 @@ dpif_operate(struct dpif *dpif, struct dpif_op **ops, size_t n_ops) if (dpif->dpif_class->operate) { dpif->dpif_class->operate(dpif, ops, n_ops); + + for (i = 0; i < n_ops; i++) { + struct dpif_op *op = ops[i]; + + switch (op->type) { + case DPIF_OP_FLOW_PUT: + log_flow_put_message(dpif, &op->u.flow_put, op->error); + break; + + case DPIF_OP_EXECUTE: + log_execute_message(dpif, &op->u.execute, op->error); + break; + } + } return; } -- 2.39.5