[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date: Tue, 2 Feb 2021 16:30:35 -0300
From: Marcelo Ricardo Leitner <marcelo.leitner@...il.com>
To: David Ahern <dsahern@...il.com>
Cc: Jakub Kicinski <kuba@...nel.org>, netdev@...r.kernel.org
Subject: Re: [PATCH RESEND net-next] netlink: add tracepoint at NL_SET_ERR_MSG
On Tue, Feb 02, 2021 at 09:16:28AM -0700, David Ahern wrote:
> On 2/2/21 5:30 AM, Marcelo Ricardo Leitner wrote:
> >
> > Also, if the message is a common one, one may not be able to easily
> > distinguish them. Ideally this shouldn't happen, but when debugging
> > applications such as OVS, where lots of netlink requests are flying,
> > it saves us time. I can, for example, look at a perf capture and
> > search for cls_flower or so. Otherwise, it will all show up as
> > "af_netlink: <err_msg>"
>
> Modules should be using the NL_SET_ERR_MSG_MOD variant, so the message
> would be ""af_netlink: cls_flower: <err_msg>"
Ah, right. They don't always do, though (and that probably should be
fixed). Also, currently there is no _MOD variant for NL_SET_ERR_MSG_ATTR.
For example:
$ git grep NL_SET_ERR_MSG -- cls_flower.c
cls_flower.c: NL_SET_ERR_MSG_MOD(extack, "Failed to setup flow action");
cls_flower.c: NL_SET_ERR_MSG_ATTR(extack,
cls_flower.c: NL_SET_ERR_MSG_ATTR(extack,
cls_flower.c: NL_SET_ERR_MSG(extack, "Missing MPLS option \"depth\"");
...
>
> I get the value in knowing the call site, so not arguing against that.
> Just hoping that your experience matches theory.
Okay.
Thanks,
Marcelo
Powered by blists - more mailing lists