Thanks, that's just what I had in mind.

On Wed, Nov 30, 2011 at 02:06:05PM -0800, Pravin B Shelar wrote:
> Following is incremental patch according to comments from Ben.
> 
> --8<--------------------------cut here-------------------------->8--
> 
> ---
>  ofproto/ofproto-dpif.c |   16 +++++++++-------
>  1 files changed, 9 insertions(+), 7 deletions(-)
> 
> diff --git a/ofproto/ofproto-dpif.c b/ofproto/ofproto-dpif.c
> index 853a170..a7d7db5 100644
> --- a/ofproto/ofproto-dpif.c
> +++ b/ofproto/ofproto-dpif.c
> @@ -2807,16 +2807,18 @@ update_stats(struct ofproto_dpif *p)
>              facet_account(p, facet);
>              facet_push_stats(facet);
>          } else {
> -            struct ds s;
> +            if (!VLOG_DROP_WARN(&rl)) {
> +                struct ds s;
>  
> -            /* There's a flow in the datapath that we know nothing about, or 
> a
> -             * flow that shouldn't be installed but was anyway.  Delete it. 
> */
> -            ds_init(&s);
> -            odp_flow_key_format(key, key_len, &s);
> -            VLOG_WARN_RL(&rl, "unexpected flow from datapath %s", 
> ds_cstr(&s));
> -            ds_destroy(&s);
> +                ds_init(&s);
> +                odp_flow_key_format(key, key_len, &s);
> +                VLOG_WARN("unexpected flow from datapath %s", ds_cstr(&s));
> +                ds_destroy(&s);
> +            }
>  
>              COVERAGE_INC(facet_unexpected);
> +            /* There's a flow in the datapath that we know nothing about, or 
> a
> +             * flow that shouldn't be installed but was anyway.  Delete it. 
> */
>              dpif_flow_del(p->dpif, key, key_len, NULL);
>          }
>      }
> -- 
> 1.7.1
> 
> _______________________________________________
> dev mailing list
> dev@openvswitch.org
> http://openvswitch.org/mailman/listinfo/dev
_______________________________________________
dev mailing list
dev@openvswitch.org
http://openvswitch.org/mailman/listinfo/dev

Reply via email to