mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Steven Rostedt <rostedt@goodmis.org>
To: "Naveen N. Rao" <naveen.n.rao@linux.vnet.ibm.com>
Cc: Wang ShaoBo <bobo.shaobowang@huawei.com>,
	cj.chengjian@huawei.com, huawei.libin@huawei.com,
	xiexiuqi@huawei.com, naveen.n.rao@linux.ibm.com,
	anil.s.keshavamurthy@intel.com, davem@davemloft.net,
	linux-kernel@vger.kernel.org, ananth@linux.ibm.com
Subject: Re: [PATCH v2] kretprobe: avoid re-registration of the same kretprobe earlier
Date: Fri, 29 Jan 2021 11:28:49 -0500	[thread overview]
Message-ID: <20210129112849.29b0ecab@gandalf.local.home> (raw)
In-Reply-To: <20210129095347.GD117@DESKTOP-TDPLP67.localdomain>

On Fri, 29 Jan 2021 15:23:47 +0530
"Naveen N. Rao" <naveen.n.rao@linux.vnet.ibm.com> wrote:

> diff --git a/kernel/kprobes.c b/kernel/kprobes.c
> index f7fb5d135930fa..63a36f33565354 100644
> --- a/kernel/kprobes.c
> +++ b/kernel/kprobes.c
> @@ -1530,6 +1530,7 @@ static inline int check_kprobe_rereg(struct kprobe *p)
>                 ret = -EINVAL;
>         mutex_unlock(&kprobe_mutex);
> 
> +       WARN_ON(ret);
>         return ret;
>  }

Please use WARN_ON_ONCE(ret);

Thanks,

-- Steve

      parent reply	other threads:[~2021-01-29 16:30 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-01-28 12:44 Wang ShaoBo
2021-01-28 18:06 ` Steven Rostedt
     [not found]   ` <20210129222947.f873666f4e6110c62b7439f1@kernel.org>
2021-01-29 16:29     ` Steven Rostedt
     [not found] ` <20210129095347.GD117@DESKTOP-TDPLP67.localdomain>
2021-01-29 16:28   ` Steven Rostedt [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20210129112849.29b0ecab@gandalf.local.home \
    --to=rostedt@goodmis.org \
    --cc=ananth@linux.ibm.com \
    --cc=anil.s.keshavamurthy@intel.com \
    --cc=bobo.shaobowang@huawei.com \
    --cc=cj.chengjian@huawei.com \
    --cc=davem@davemloft.net \
    --cc=huawei.libin@huawei.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=naveen.n.rao@linux.ibm.com \
    --cc=naveen.n.rao@linux.vnet.ibm.com \
    --cc=xiexiuqi@huawei.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®