[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-Id: <20210516222003.29086ea4f04a956edb47b032@kernel.org>
Date: Sun, 16 May 2021 22:20:03 +0900
From: Masami Hiramatsu <mhiramat@...nel.org>
To: Joe Perches <joe@...ches.com>
Cc: Tiezhu Yang <yangtiezhu@...ngson.cn>,
Jonathan Corbet <corbet@....net>,
Marc Koderer <marc@...erer.com>,
Mauro Carvalho Chehab <mchehab+huawei@...nel.org>,
Christian Brauner <christian.brauner@...ntu.com>,
Jisheng Zhang <jszhang@...nel.org>,
Heiko Carstens <hca@...ux.ibm.com>,
Martin Schwidefsky <schwidefsky@...ibm.com>,
Johannes Thumshirn <jthumshirn@...e.de>,
Mathieu Desnoyers <mathieu.desnoyers@...ymtl.ca>,
Randy Dunlap <randy.dunlap@...cle.com>,
Ananth N Mavinakayanahalli <ananth@...ibm.com>,
Andrew Morton <akpm@...ux-foundation.org>,
linux-kernel@...r.kernel.org, Xuefeng Li <lixuefeng@...ngson.cn>
Subject: Re: [PATCH v3] samples/kprobes: Fix typo in handler_{post,fault}()
On Sun, 16 May 2021 06:14:58 -0700
Joe Perches <joe@...ches.com> wrote:
> On Sun, 2021-05-16 at 19:02 +0900, Masami Hiramatsu wrote:
> > On Sat, 15 May 2021 10:39:06 +0800
> > Tiezhu Yang <yangtiezhu@...ngson.cn> wrote:
> >
> > > It should use post_handler instead of pre_handler in handler_post().
> > >
> > > As Joe Perches suggested, it would be better to use pr_fmt and remove
> > > all the embedded pre/post strings. This would change the style of the
> > > output through.
> > >
> >
> > NAK, this also shows which handler cought the event.
> > If you wanna change it. Please replace it with __func__ instead.
> []
> > > diff --git a/samples/kprobes/kprobe_example.c b/samples/kprobes/kprobe_example.c
> []
> > > @@ -10,6 +10,8 @@
> > > * whenever kernel_clone() is invoked to create a new process.
> > > */
> > >
> > > +#define pr_fmt(fmt) "%s: " fmt, __func__
>
> It does that already via the pr_fmt which uses __func__.
Oops, I missed that. OK then it is good to me.
Thanks,
--
Masami Hiramatsu <mhiramat@...nel.org>
Powered by blists - more mailing lists