[ovs-dev] [PATCH V2 4/4] netdev-tc-offloads: Add support for action set
Eric Garver
e at erig.me
Sat Nov 18 19:52:02 UTC 2017
On Mon, Sep 18, 2017 at 07:16:04AM +0300, Roi Dayan wrote:
> From: Paul Blakey <paulb at mellanox.com>
>
> Implement support for offloading ovs action set using
> tc header rewrite action.
>
> Signed-off-by: Paul Blakey <paulb at mellanox.com>
> Reviewed-by: Roi Dayan <roid at mellanox.com>
> ---
> lib/netdev-tc-offloads.c | 201 +++++++++++++++++++++++++++++++++++++++++++++--
> 1 file changed, 195 insertions(+), 6 deletions(-)
>
> diff --git a/lib/netdev-tc-offloads.c b/lib/netdev-tc-offloads.c
> index 3c145c2..4044a77 100644
> --- a/lib/netdev-tc-offloads.c
> +++ b/lib/netdev-tc-offloads.c
[...]
> @@ -457,14 +575,77 @@ netdev_tc_flow_dump_next(struct netdev_flow_dump *dump,
> }
>
> static int
> +parse_put_flow_set_masked_action(struct tc_flower *flower,
> + const struct nlattr *set,
> + size_t set_len,
> + bool hasmask)
> +{
> + static struct vlog_rate_limit rl = VLOG_RATE_LIMIT_INIT(5, 20);
> + char *set_buff[set_len], *set_data, *set_mask;
This variable length array is causing some travis-ci failures.
https://travis-ci.org/erig0/ovs/jobs/304068614#L1428
> + char *key = (char *) &flower->rewrite.key;
> + char *mask = (char *) &flower->rewrite.mask;
> + const struct nlattr *attr;
> + int i, j, type;
> + size_t size;
> +
> + /* copy so we can set attr mask to 0 for used ovs key struct members */
> + memcpy(set_buff, set, set_len);
> + attr = (struct nlattr *) set_buff;
> +
[...]
More information about the dev
mailing list