[ovs-dev] [PATCH v3 1/8] match: Do not skip formatting a zero dp_hash.

Andy Zhou azhou at nicira.com
Mon Mar 16 17:34:51 UTC 2015


On Fri, Mar 13, 2015 at 4:51 PM, Jarno Rajahalme <jrajahalme at nicira.com> wrote:
> The dp_hash match should be printed whenever it is being matched.  We
> keep the old behavior for flow_format(), which is mostly used to
> format PACKET_IN messages. This keeps those messages tidier and avoids
> changing a lot of test cases.
>
> Signed-off-by: Jarno Rajahalme <jrajahalme at nicira.com>
> ---
>  lib/flow.c            |    3 +++
>  lib/match.c           |    2 +-
>  tests/dpif-netdev.at  |    2 +-
>  tests/ofproto-dpif.at |    4 ++--
>  4 files changed, 7 insertions(+), 4 deletions(-)
>
> diff --git a/lib/flow.c b/lib/flow.c
> index 965da41..aa1cc47 100644
> --- a/lib/flow.c
> +++ b/lib/flow.c
> @@ -872,6 +872,9 @@ flow_format(struct ds *ds, const struct flow *flow)
>      if (!flow->recirc_id) {
>          WC_UNMASK_FIELD(wc, recirc_id);
>      }
> +    if (!flow->dp_hash) {
> +        WC_UNMASK_FIELD(wc, dp_hash);
> +    }

The comment block above calling out printing zero value for in_port.
It seems the it needs
to be updated with other fields, such as skb_priority, pkt_mark,
recirc_id and dp_hash.

For the reset of this patch
Acked-by: Andy Zhou <azhou at nicira.com>

And thanks for noticing the output anomaly in the test cases.



More information about the dev mailing list