[ovs-dev] [PATCH ovs] dpif-netdev: Delete the flow limit in dpif-netdev
Tonghao Zhang
xiangxia.m.yue at gmail.com
Tue Jun 16 12:15:45 UTC 2020
On Tue, Jun 16, 2020 at 8:12 PM Tonghao Zhang <xiangxia.m.yue at gmail.com> wrote:
>
> On Mon, Mar 16, 2020 at 7:17 PM <xiangxia.m.yue at gmail.com> wrote:
> >
> > From: Tonghao Zhang <xiangxia.m.yue at gmail.com>
> >
> > The max number of flow in dpif-netdev is MAX_FLOWS,
> > the previous patch[1] try to install more flows,
> > and introduce the subcommand "dpif-netdev/pmd-set-max-flow"
> > to change the max flow limitation. But 'other_config:flow-limit'
> > option can limit that too.
> >
> > As Ilya Maximets say [2]:
> > | The MAX_FLOWS constant was there from the introduction of dpif-netdev,
> > | however, later new flow-limit mechanism was implemented that
> > | controls number of datapath flows in a dynamic way on ofproto level.
> > |
> > | So, maybe we can just remove the limit and fully rely on ofproto
> > | to decide what flow limit we need? There are no limitations for
> > | flow table size in dpif-netdev beside the artificial one.
> > | 'other_config:flow-limit' seems suitable to control this.
> >
> > [1] - https://mail.openvswitch.org/pipermail/ovs-dev/2020-January/366636.html
> > [2] - https://mail.openvswitch.org/pipermail/ovs-dev/2020-January/366677.html
> >
> > Suggested-by: Ilya Maximets <i.maximets at ovn.org>
> > Signed-off-by: Tonghao Zhang <xiangxia.m.yue at gmail.com>
> any progress ?
cc dev at openvswitch.org
any progress ? Do we have plan to review it or pick it up.
> > ---
> > lib/dpif-netdev.c | 12 ++----------
> > 1 file changed, 2 insertions(+), 10 deletions(-)
> >
> > diff --git a/lib/dpif-netdev.c b/lib/dpif-netdev.c
> > index a1c45f6..eb0e2da 100644
> > --- a/lib/dpif-netdev.c
> > +++ b/lib/dpif-netdev.c
> > @@ -96,9 +96,6 @@ DEFINE_STATIC_PER_THREAD_DATA(uint32_t, recirc_depth, 0)
> > /* Use instant packet send by default. */
> > #define DEFAULT_TX_FLUSH_INTERVAL 0
> >
> > -/* Configuration parameters. */
> > -enum { MAX_FLOWS = 65536 }; /* Maximum number of flows in flow table. */
> > -
> > /* Maximum number of meters in the table. */
> > #define METER_ENTRY_MAX (1 << 19)
> > /* Maximum number of bands / meter. */
> > @@ -3576,13 +3573,8 @@ flow_put_on_pmd(struct dp_netdev_pmd_thread *pmd,
> > netdev_flow = dp_netdev_pmd_lookup_flow(pmd, key, NULL);
> > if (!netdev_flow) {
> > if (put->flags & DPIF_FP_CREATE) {
> > - if (cmap_count(&pmd->flow_table) < MAX_FLOWS) {
> > - dp_netdev_flow_add(pmd, match, ufid, put->actions,
> > - put->actions_len);
> > - error = 0;
> > - } else {
> > - error = EFBIG;
> > - }
> > + dp_netdev_flow_add(pmd, match, ufid, put->actions,
> > + put->actions_len);
> > } else {
> > error = ENOENT;
> > }
> > --
> > 1.8.3.1
> >
>
>
> --
> Best regards, Tonghao
--
Best regards, Tonghao
More information about the dev
mailing list