[ovs-dev] [PATCH ovn v10 3/8] ovn-controller: I-P for datapath binding

Numan Siddique numans at ovn.org
Tue Jun 9 17:10:35 UTC 2020


On Mon, Jun 8, 2020 at 9:39 PM Dumitru Ceara <dceara at redhat.com> wrote:

> On 6/8/20 3:50 PM, numans at ovn.org wrote:
> > From: Numan Siddique <numans at ovn.org>
> >
> > This patch adds partial support of incremental processing of datapath
> binding.
> > If a datapath is deleted, then a full recompute is triggered if that
> > datapath is present in the 'local_datapaths' hmap of runtime data.
> >
> > Acked-by: Mark Michelson <mmichels at redhat.com>
> > Acked-by: Han Zhou <hzhou at ovn.org>
> > Signed-off-by: Numan Siddique <numans at ovn.org>
>
> Looks good to me.
>
> Acked-by: Dumitru Ceara <dceara at redhat.com>
>


Thanks Dumitru, Han and Mark  for the reviews.

I applied the first 3 patches of this series (addressing the review
comments) to master and also applied to branch-20.06.

@Han - If you have any additional comments on these patches please let me
know. I'll have follow up patches.

I'll update v11 of this series addressing the review comments from Dumitru.

Thanks
Numan


> Thanks,
> Dumitru
>
> > ---
> >  controller/ovn-controller.c | 25 ++++++++++++++++++++++++-
> >  tests/ovn-performance.at    |  6 +++---
> >  2 files changed, 27 insertions(+), 4 deletions(-)
> >
> > diff --git a/controller/ovn-controller.c b/controller/ovn-controller.c
> > index 871291874..687a33c88 100644
> > --- a/controller/ovn-controller.c
> > +++ b/controller/ovn-controller.c
> > @@ -1203,6 +1203,28 @@ runtime_data_sb_port_binding_handler(struct
> engine_node *node, void *data)
> >      return true;
> >  }
> >
> > +static bool
> > +runtime_data_sb_datapath_binding_handler(struct engine_node *node
> OVS_UNUSED,
> > +                                         void *data OVS_UNUSED)
> > +{
> > +    struct sbrec_datapath_binding_table *dp_table =
> > +        (struct sbrec_datapath_binding_table *)EN_OVSDB_GET(
> > +            engine_get_input("SB_datapath_binding", node));
> > +    const struct sbrec_datapath_binding *dp;
> > +    struct ed_type_runtime_data *rt_data = data;
> > +
> > +    SBREC_DATAPATH_BINDING_TABLE_FOR_EACH_TRACKED (dp, dp_table) {
> > +        if (sbrec_datapath_binding_is_deleted(dp)) {
> > +            if (get_local_datapath(&rt_data->local_datapaths,
> > +                                   dp->tunnel_key)) {
> > +                return false;
> > +            }
> > +        }
> > +    }
> > +
> > +    return true;
> > +}
> > +
> >  /* Connection tracking zones. */
> >  struct ed_type_ct_zones {
> >      unsigned long bitmap[BITMAP_N_LONGS(MAX_CT_ZONES)];
> > @@ -1951,7 +1973,8 @@ main(int argc, char *argv[])
> >      engine_add_input(&en_runtime_data, &en_ovs_qos, NULL);
> >
> >      engine_add_input(&en_runtime_data, &en_sb_chassis, NULL);
> > -    engine_add_input(&en_runtime_data, &en_sb_datapath_binding, NULL);
> > +    engine_add_input(&en_runtime_data, &en_sb_datapath_binding,
> > +                     runtime_data_sb_datapath_binding_handler);
> >      engine_add_input(&en_runtime_data, &en_sb_port_binding,
> >                       runtime_data_sb_port_binding_handler);
> >
> > diff --git a/tests/ovn-performance.at b/tests/ovn-performance.at
> > index 5dfc6f7ca..5cc1960b6 100644
> > --- a/tests/ovn-performance.at
> > +++ b/tests/ovn-performance.at
> > @@ -253,7 +253,7 @@ grep tunnel_egress_iface_carrier=up | wc -l) -eq 1
> >  ])
> >
> >  # Add router lr1
> > -OVN_CONTROLLER_EXPECT_HIT(
> > +OVN_CONTROLLER_EXPECT_NO_HIT(
> >      [hv1 hv2], [lflow_run],
> >      [ovn-nbctl --wait=hv lr-add lr1]
> >  )
> > @@ -264,7 +264,7 @@ for i in 1 2; do
> >      lrp=lr1-$ls
> >
> >      # Add switch $ls
> > -    OVN_CONTROLLER_EXPECT_HIT(
> > +    OVN_CONTROLLER_EXPECT_NO_HIT(
> >          [hv1 hv2], [lflow_run],
> >          [ovn-nbctl --wait=hv ls-add $ls]
> >      )
> > @@ -427,7 +427,7 @@ for i in 1 2; do
> >  done
> >
> >  # Delete router lr1
> > -OVN_CONTROLLER_EXPECT_HIT(
> > +OVN_CONTROLLER_EXPECT_NO_HIT(
> >      [hv1 hv2], [lflow_run],
> >      [ovn-nbctl --wait=hv lr-del lr1]
> >  )
> >
>
> _______________________________________________
> dev mailing list
> dev at openvswitch.org
> https://mail.openvswitch.org/mailman/listinfo/ovs-dev
>
>


More information about the dev mailing list