OVS meters are created in advance and openflow rules refer to them by
their unique ID. New tc_police API is used to offload them. By calling
the API, police actions are created and meters are mapped to them.
These actions then can be used in tc filter rules by the index.
Signed-off-by: Jianbo Liu
For dpif-netlink, meters are mapped by tc to police actions with
one-to-one relationship. Implement meter offload API to set/get/del
the police action, and a hmap is used to save the mappings.
An id-pool is used to manage all the available police indexes, which
are 0x1000-0x1fff, reserved
As the police actions with indexes of 0x1000-0x1fff are
reserved for meter offload, to provide a clean environment for OVS,
these reserved police actions should be deleted on startup. So dump
all the police actions, delete those actions with indexes in this
range.
Signed-off-by: Jianbo
When offloading rule, tc should be filled with police index, instead
of meter id. As meter is mapped to police action, and the mapping is
inserted into meter_id_to_police_idx hmap, this hmap is used to find
the police index. Besides, an action cookie is added to save meter id
on rule creation, so
Add helpers to add, delete and get stats of police action with
the specified index.
Signed-off-by: Jianbo Liu
---
lib/netdev-linux.c | 133 +
lib/netdev-linux.h | 6 ++
lib/tc.c | 21 +++
lib/tc.h | 6 ++
4 files changed,
To reuse the code for manipulating police action, move the common
initialization code to a function, and change PPS parameters as meter
pktps is in unit of packet per second.
null_police is redundant because either BPS or PPS, not both, can be
configured in one message. So the police passed in to
Add function to parse police action from netlink message, and meter id
can be retrieved from action cockie as it will be saved there in later
patch.
Signed-off-by: Jianbo Liu
---
lib/netdev-offload-tc.c | 4 +++
lib/tc.c| 59 +
lib/tc.h
This series is to add support for tc offloading of ovs metering, and
enhance OVS to use new kernel feature which offload tc police action to
hardware.
To do the offloading, new APIs for meter are added in netdev-offload,
and OVS meters are mapped to tc police actions with one-to-one
relationship
Add API to offload meter to HW, and the corresponding functions to call
the meter callbacks from all the registered flow API providers.
The interfaces are like those related to meter in dpif_class, in order
to pass necessary info to HW.
Signed-off-by: Jianbo Liu
---
On Fri, 2022-04-29 at 20:50 +0200, Ilya Maximets wrote:
> On 4/29/22 20:01, Ilya Maximets wrote:
> > On 4/29/22 05:28, Jianbo Liu wrote:
> > > On Thu, 2022-04-28 at 14:00 +0200, Ilya Maximets wrote:
> > > > On 4/28/22 13:49, Ilya Maximets wrote:
> > > > > On 4/28/22 11:06, Jianbo Liu wrote:
> > >
LGTM
Acked-by: Terry Wilson
On Fri, Mar 11, 2022 at 9:22 AM Adrian Moreno wrote:
>
> Most of ofproto and dpif flows are based on key-value pairs. These
> key-value pairs can be represented in several ways, eg: key:value,
> key=value, key(value).
>
> Add the following classes that allow parsing
On 5/2/22 15:31, Terry Wilson wrote:
> Prior to 4e3966e64, when calling _uuid_to_row, it would raise an
> AttributeError when trying to access base.ref_table.rows if the
> referenced table was not registered. When called from
> Row.__getattr__(), this would appropriately raise an AttributeError.
>
On Wed, Apr 20, 2022 at 3:16 PM Numan Siddique wrote:
>
> On Wed, Apr 20, 2022 at 1:15 PM Ihar Hrachyshka wrote:
> >
> > Thanks for your review. See below.
> >
> > On Tue, Apr 19, 2022 at 11:43 AM Numan Siddique wrote:
> > >
> > > On Tue, Mar 29, 2022 at 8:47 PM Ihar Hrachyshka
> > > wrote:
>
Good catch Ales,
Acked-by: Mark Michelson
On 4/29/22 03:43, Ales Musil wrote:
Signed-off-by: Ales Musil
---
.ci/ovn-kubernetes/Dockerfile | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/.ci/ovn-kubernetes/Dockerfile b/.ci/ovn-kubernetes/Dockerfile
index
Prior to 4e3966e64, when calling _uuid_to_row, it would raise an
AttributeError when trying to access base.ref_table.rows if the
referenced table was not registered. When called from
Row.__getattr__(), this would appropriately raise an AttributeError.
After 4e3966e64, a KeyError would be raised,
15 matches
Mail list logo