[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <CALnP8ZZ60R3ToiKfTkF6JTA6UpL4=6D+D1b37b1S8_2OA-sGqA@mail.gmail.com>
Date: Fri, 2 Jun 2023 12:43:54 -0700
From: Marcelo Ricardo Leitner <mleitner@...hat.com>
To: Jamal Hadi Salim <jhs@...atatu.com>
Cc: netdev@...r.kernel.org, deb.chatterjee@...el.com, anjali.singhai@...el.com,
namrata.limaye@...el.com, tom@...anda.io, p4tc-discussions@...devconf.info,
Mahesh.Shirshyad@....com, Vipin.Jain@....com, tomasz.osinski@...el.com,
jiri@...nulli.us, xiyou.wangcong@...il.com, davem@...emloft.net,
edumazet@...gle.com, kuba@...nel.org, pabeni@...hat.com, vladbu@...dia.com,
simon.horman@...igine.com, khalidm@...dia.com, toke@...hat.com
Subject: Re: [PATCH RFC v2 net-next 07/28] net/sched: act_api: add struct
p4tc_action_ops as a parameter to lookup callback
On Wed, May 17, 2023 at 07:02:11AM -0400, Jamal Hadi Salim wrote:
> @@ -115,7 +115,8 @@ struct tc_action_ops {
> struct tcf_result *); /* called under RCU BH lock*/
> int (*dump)(struct sk_buff *, struct tc_action *, int, int);
> void (*cleanup)(struct tc_action *);
> - int (*lookup)(struct net *net, struct tc_action **a, u32 index);
> + int (*lookup)(struct net *net, const struct tc_action_ops *ops,
> + struct tc_action **a, u32 index);
> int (*init)(struct net *net, struct nlattr *nla,
> struct nlattr *est, struct tc_action **act,
> struct tcf_proto *tp,
> diff --git a/net/sched/act_api.c b/net/sched/act_api.c
> index ba0315e686bf..788127329d96 100644
> --- a/net/sched/act_api.c
> +++ b/net/sched/act_api.c
> @@ -728,7 +728,7 @@ int __tcf_idr_search(struct net *net, const struct tc_action_ops *ops,
> struct tc_action_net *tn = net_generic(net, ops->net_id);
>
> if (unlikely(ops->lookup))
> - return ops->lookup(net, a, index);
> + return ops->lookup(net, ops, a, index);
Interesting. I could swear that this patch would break the build if
only up to this patch was applied (like in a git bisect), but then,
currently no action is defining this method. :D
Marcelo
Powered by blists - more mailing lists